feat(api): 访谈人格/回复长度策略、口述归一、背景语气与输入净稿全链路
Chat 访谈 - 新增 persona 系统(default / warm_listener / curious_guide)与 background_voice 语气层 - 回复长度由 compute_reply_plan 统一决策(brief / standard / expanded),融合信息密度启发式 - 输入净稿(input_normalize):编排层可选 rules/llm 归一用户口语后再喂模型与记忆检索 - 记忆证据注入:按用户话检索 memory evidence 并注入 prompt Memoir 回忆录 - 口述归一(oral_normalize):segment 原文保留,story 管线取派生净稿作叙事输入 - segment 入队批次门闸:累计字数 + 最长等待秒数,减少零碎提交 - fidelity_check / prompts / narrative_agent 微调 - Alembic 0005:清理跨章节 story 外键 Infra - Dockerfile 加入 ffmpeg - pyproject.toml 新增依赖并同步 uv.lock - .env.example / .env.production 补全新配置项 Tests - 新增 test_background_voice、test_chat_input_normalize、test_experience_regressions - 扩展 test_interview_prompts、test_interview_reply_length、test_story_route_oral_invariant Made-with: Cursor
This commit is contained in:
@@ -99,12 +99,15 @@ export function useCreateConversation() {
|
||||
queryClient.setQueryData<ConversationListItem[]>(
|
||||
conversationKeys.lists(),
|
||||
(old) => {
|
||||
const startedMs = Date.parse(newConversation.started_at);
|
||||
const now = Date.now();
|
||||
const item: ConversationListItem = {
|
||||
id: newConversation.id,
|
||||
title: '岁月知己',
|
||||
avatarUrl: null,
|
||||
latestMessagePreview: '',
|
||||
latestMessageTime: Date.now(),
|
||||
latestMessageTime: now,
|
||||
startedAt: Number.isFinite(startedMs) ? startedMs : now,
|
||||
unreadCount: 0,
|
||||
isDefaultAssistant: true,
|
||||
hasUserMessage: false,
|
||||
|
||||
@@ -18,6 +18,8 @@ export interface ConversationListItem {
|
||||
avatarUrl: string | null;
|
||||
latestMessagePreview: string;
|
||||
latestMessageTime: number;
|
||||
/** 对话初次创建时间(UTC 毫秒),与列表排序用的最近活动无关 */
|
||||
startedAt?: number;
|
||||
unreadCount: number;
|
||||
isDefaultAssistant: boolean;
|
||||
/** 是否已有用户发出的文本或语音(仅助手/空会话为 false,用于「打个招呼」复用同一会话) */
|
||||
|
||||
Reference in New Issue
Block a user