Repository navigation
feat: add evidence-cited weekly report chat - #19
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
为已保存周报增加可追溯追问:模型必须读取绑定的快照,每条回答引用真实证据,并校验所引证据中的数字。未配置模型、证据无效或调用失败时明确降级,快照保持不变。
0005_weekly_chat、GET/POST messages API、审计和 20 条消息上限。get_saved_weekly_report,保持全局分析 allowlist 与 MCP 暴露名单不变。Verification
实际本地验证结果以
docs/TEST_REPORT.md最新审查修复记录为准。.venv/Scripts/python.exe -m pytest backend/tests -q(空LLM_API_KEY):337 passed, 6 skipped, 1 warning,167.31s;跳过项均需PROFITOPS_TEST_POSTGRES_URL,警告为 Starlette 弃用提示。npm --prefix frontend test -- --run:24 passed / 3 files;jsdom 输出 Tailwind CSS 解析诊断,测试通过。npm --prefix frontend run build:通过;主包 506.05 kB,仍有体积警告。.venv/Scripts/python.exe backend/evals/weekly_chat_replay.py:8/8,network_calls=0。.venv/Scripts/python.exe scripts/mcp_check.py:通过,6 个只读工具,无周报快照追问或写工具暴露。git diff --check:通过,仅 Git LF/CRLF 提示。新增回归覆盖双店完整工具载荷与 Fake API 成功、证据值保留、非金额整数拒绝换算、模型阶段独立写库,以及 12 个同步模型结果产生 10 组已保存问答、2 个 422、1 个线程和 10 条审计。
Boundaries
真实 DeepSeek、PostgreSQL 集成、浏览器 E2E、部署未验证。Fake/replay 成功不代表真实模型准确率。更大的快照超过配置上限时仍明确降级,不截断证据。审查修复无需新增数据库迁移,未对演示数据库执行迁移。无真实采购、调价或外部平台写操作。