• GraphChatBar.vue 里"context 变了才拼说明、没变不重复"这条逻辑原来直接写在
    <script setup> 里,脱不开组件测不了。照抄 agentChatEvents.js 的先例抽成
    chatContextInjection.js 的纯函数(buildOutgoingMessage/contextKey),配一份
    不用挂载组件就能跑的单测,锁住这条不变式。
    
    Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
    Claude-Session: https://claude.ai/code/session_01YCd5WFjL1m31FaJXKx1j7Z
    yibo authored
     
    Browse File »
  • graph-console 页面底部新增可展开/收起的聊天条(GraphChatBar.vue,仿 MasterChatDrawer.vue
    写的自包含最小聊天组件),直接跟公司 ceo agent 对话,不用跳去 AgentChat 整页。会话持久化在
    localStorage(按 companyId 区分),刷新页面自动拉历史消息恢复。
    
    发消息时若当前选中的 task/goal 跟上次发送时不同,会在实际发给后端的文本前拼一行上下文说明,
    agent 不用用户手动复述在看哪个任务;聊天气泡里展示的仍是用户输入的原文,不被这行说明污染;
    上下文不变时不重复注入。
    
    Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
    Claude-Session: https://claude.ai/code/session_01YCd5WFjL1m31FaJXKx1j7Z
    yibo authored
     
    Browse File »