This commit is contained in:
2026-01-31 23:17:58 +08:00
parent 6ae504823b
commit 81bc50ce17
5 changed files with 133 additions and 17 deletions

View File

@@ -24,6 +24,9 @@ NS_ASSUME_NONNULL_BEGIN
/// 添加用户消息
- (void)appendUserMessage:(NSString *)text;
/// 添加用户消息(绑定本次请求 requestId
- (void)appendUserMessage:(NSString *)text requestId:(NSString *)requestId;
/// 标记最后一条用户消息结束加载
- (void)markLastUserMessageLoadingComplete;
@@ -40,12 +43,23 @@ NS_ASSUME_NONNULL_BEGIN
/// 添加 loading AI 消息
- (void)appendLoadingAssistantMessage;
/// 添加 loading AI 消息(绑定本次请求 requestId
- (void)appendLoadingAssistantMessageWithRequestId:(NSString *)requestId;
/// 移除 loading AI 消息
- (void)removeLoadingAssistantMessage;
/// 移除 loading AI 消息(按 requestId 精确移除)
- (void)removeLoadingAssistantMessageWithRequestId:(NSString *)requestId;
/// 更新聊天列表底部 inset
- (void)updateChatViewBottomInset:(CGFloat)bottomInset;
/// 更新指定 requestId 对应的 AI 回复(替换 loading 占位消息)
- (void)updateAssistantMessageWithRequestId:(NSString *)requestId
text:(NSString *)text
audioId:(nullable NSString *)audioId;
@end
NS_ASSUME_NONNULL_END