Tài liệu tham khảo về khung MLKitEntityExtraction
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
class EntityExtractorOptions : NSObject
Các lựa chọn về MLKEntityExtractor
.
-
Mô hình cần sử dụng khi phân tích cú pháp thực thể trong văn bản.
-
-
Tạo một phiên bản mới của các tuỳ chọn EntityExtractor với giá trị nhận dạng mô hình đã cho.
Tham số
modelIdentifier
|
Mô hình sẽ sử dụng khi phân tích cú pháp địa chỉ và số điện thoại trong
.
|
Giá trị trả về
Một thực thể mới của MLKEntityExtractorOptions
được định cấu hình bằng mã nhận dạng mô hình đã cho.
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-25 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-25 UTC."],[[["\u003cp\u003e\u003ccode\u003eMLKEntityExtractorOptions\u003c/code\u003e provides configuration options for the \u003ccode\u003eMLKEntityExtractor\u003c/code\u003e class, primarily focusing on model selection for entity parsing.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003emodelIdentifier\u003c/code\u003e property specifies the model used for identifying entities within text, such as addresses and phone numbers.\u003c/p\u003e\n"],["\u003cp\u003eAlthough a default initializer is unavailable, you can create an \u003ccode\u003eMLKEntityExtractorOptions\u003c/code\u003e instance using \u003ccode\u003einit(modelIdentifier:)\u003c/code\u003e by providing the desired model identifier.\u003c/p\u003e\n"]]],[],null,["# MLKitEntityExtraction Framework Reference\n\nEntityExtractorOptions\n======================\n\n class EntityExtractorOptions : NSObject\n\nOptions for`MLKEntityExtractor`.\n- `\n ``\n ``\n `\n\n ### [modelIdentifier](#/c:objc(cs)MLKEntityExtractorOptions(py)modelIdentifier)\n\n `\n ` \n The model to use when parsing entities in the text. \n\n #### Declaration\n\n Swift \n\n var modelIdentifier: ../Type-Definitions.html#/c:MLKEntityExtractionModelIdentifier.h@T@MLKEntityExtractionModelIdentifier { get }\n\n- `\n ``\n ``\n `\n\n ### [-init](#/c:objc(cs)MLKEntityExtractorOptions(im)init)\n\n `\n ` \n Unavailable.\n- `\n ``\n ``\n `\n\n ### [init(modelIdentifier:)](#/c:objc(cs)MLKEntityExtractorOptions(im)initWithModelIdentifier:)\n\n `\n ` \n Creates a new instance of EntityExtractor options with the given model identifier. \n\n #### Declaration\n\n Swift \n\n init(modelIdentifier: ../Type-Definitions.html#/c:MLKEntityExtractionModelIdentifier.h@T@MLKEntityExtractionModelIdentifier)\n\n #### Parameters\n\n |-------------------------|--------------------------------------------------------------------|\n | ` `*modelIdentifier*` ` | The model to use when parsing addresses and phone numbers in text. |\n\n #### Return Value\n\n A new instance of `MLKEntityExtractorOptions` configured with the given model identifier."]]