مرجع چارچوب MLKitSmartReply
با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
MLKSmartReply
@interface MLKSmartReply : NSObject
یک شی که پاسخ های هوشمند را برای متن ورودی داده شده پیشنهاد می کند.
یک نمونه پاسخ هوشمند دریافت می کند که پاسخ های پیشنهادی را برای متن ورودی ارائه می دهد. این روش بدون نخ است.
اعلامیه
هدف-C
+ (nonnull MLKSmartReply *)smartReply;
ارزش بازگشتی
یک نمونه SmartReply
که پاسخهای پیشنهادی را ارائه میکند.
در چارچوب یک مکالمه چت، پاسخهایی را پیشنهاد میکند.
پارامترها
messages | دنباله ای از پیام های چت برای ایجاد یک پیشنهاد برای. |
completion | کنترل کننده برای تماس مجدد در صف اصلی با نتیجه یا خطای پیشنهاد. |
اعلامیه
هدف-C
- (nonnull instancetype)init;
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی."],[[["\u003cp\u003e\u003ccode\u003eMLKSmartReply\u003c/code\u003e suggests smart replies for given input text within a chat conversation.\u003c/p\u003e\n"],["\u003cp\u003eIt provides a method to get a \u003ccode\u003eSmartReply\u003c/code\u003e instance that is thread-safe.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003esuggestRepliesForMessages:completion:\u003c/code\u003e method generates reply suggestions based on a sequence of chat messages and returns the result or error through a completion handler.\u003c/p\u003e\n"],["\u003cp\u003eDirect initialization of \u003ccode\u003eMLKSmartReply\u003c/code\u003e is unavailable.\u003c/p\u003e\n"]]],[],null,["# MLKitSmartReply Framework Reference\n\nMLKSmartReply\n=============\n\n\n @interface MLKSmartReply : NSObject\n\nAn object that suggests smart replies for given input text.\n- `\n ``\n ``\n `\n\n ### [+smartReply](#/c:objc(cs)MLKSmartReply(cm)smartReply)\n\n `\n ` \n Gets a smart reply instance that provides suggested replies for input text. This method is thread\n safe. \n\n #### Declaration\n\n Objective-C \n\n + (nonnull MLKSmartReply *)smartReply;\n\n #### Return Value\n\n A `SmartReply` instance that provides suggested replies.\n- `\n ``\n ``\n `\n\n ### [-suggestRepliesForMessages:completion:](#/c:objc(cs)MLKSmartReply(im)suggestRepliesForMessages:completion:)\n\n `\n ` \n Suggests replies in the context of a chat conversation. \n\n #### Declaration\n\n Objective-C \n\n - (void)suggestRepliesForMessages:(nonnull NSArray\u003c../Classes/MLKTextMessage.html *\u003e *)messages\n completion:(nonnull ../Type-Definitions.html#/c:MLKSmartReply.h@T@MLKSmartReplyCallback)completion;\n\n #### Parameters\n\n |--------------------|-----------------------------------------------------------------------------|\n | ` `*messages*` ` | The sequence of chat messages to generate a suggestion for. |\n | ` `*completion*` ` | Handler to call back on the main queue with the suggestion result or error. |\n\n- `\n ``\n ``\n `\n\n ### [-init](#/c:objc(cs)MLKSmartReply(im)init)\n\n `\n ` \n Unavailable. \n\n #### Declaration\n\n Objective-C \n\n - (nonnull instancetype)init;"]]