新增: 待发箱抽屉与对话体验前端批
- 待发箱抽屉: ChatInput ⏰ 入口 + OutboxDrawer + useAiOutbox IPC 封装
- U2 进度语义三层: 内容层(最近动作) + 静默三档降速脉冲, 永不自动判死
- 流式心跳自愈: 竞态窗口旧任务迟到完成事件误收敛的自愈判定(949 前端兜底)
- 953 截断提示: 末条气泡渲染截断标记 + 继续输出按钮, 事件契约透传
This commit is contained in:
@@ -463,6 +463,12 @@ export type AiChatEvent = ({
|
||||
* undefined/false=真实值。前端 MessageList 据此标注『估算』区分 estimated vs real。
|
||||
*/
|
||||
is_estimated?: boolean
|
||||
/**
|
||||
* 看板 953: 最终回复是否因 provider max_tokens 上限被截断(finish_reason=length)。
|
||||
* true=正常收敛但内容被腰斩,MessageList 末条 assistant 气泡渲染截断提示条 + 继续输出按钮;
|
||||
* undefined/false=完整(旧后端事件无此字段,按 false 兜底,向后兼容)。
|
||||
*/
|
||||
truncated_by_max_tokens?: boolean
|
||||
/**
|
||||
* incomplete 场景细分(达上限自动收尾 vs 网络中断,前端据此区分提示文案):
|
||||
* "max_rounds"=达最大轮次后端自动收尾;其他/缺省=网络中断等异常。
|
||||
@@ -647,6 +653,13 @@ export interface AiMessage {
|
||||
prompt_cache_miss_tokens?: number
|
||||
/** 思考 token(deepseek-reasoner/o1 reasoning_tokens)。老消息 undefined。 */
|
||||
reasoning_tokens?: number
|
||||
/**
|
||||
* 看板 953: 该 assistant 回复因 provider max_tokens 上限被截断(live 态 AiCompleted 事件透传标记)。
|
||||
* 末条 assistant 带此标记时 MessageList 渲染截断提示条 + 继续输出按钮;用户再发消息/
|
||||
* 继续输出后新气泡顶掉末条位置,标记自然失效,无需清除逻辑。仅 live 内存标记不入库
|
||||
* (reload 后历史消息不带,截断提示属当轮即时性信息,可接受口径)。
|
||||
*/
|
||||
truncatedByMaxTokens?: boolean
|
||||
timestamp: number
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user