Skip to content

release: v1.15.3 — 定时总结输入层、管理后台可用性、交付开关两域与 MCP 资源交付 - #239

Merged
3aKHP merged 41 commits into
mainfrom
dev
Sep 10, 2026
Merged

release: v1.15.3 — 定时总结输入层、管理后台可用性、交付开关两域与 MCP 资源交付#239
3aKHP merged 41 commits into
mainfrom
dev

Conversation

@3aKHP

@3aKHP 3aKHP commented Sep 10, 2026

Copy link
Copy Markdown
Owner

Grade: Release

冻结内容

验证

  • 完整 pytest(2016 passed)、Ruff、前端 type-check/build(本周期各 PR 已执行)
  • CHANGELOG 与 pyproject 版本冻结(c7814ef)
  • tag 触发 release.yml 后核对:tag、版本、Windows ZIP、Docker 镜像 revision/digest、Release notes 一致
  • 合并后 main → dev 回灌(预期 ff-only)与下一目标版本 bump(1.15.4-dev.0)

升级说明

  • monthly_report.sample_per_day 移除,可改配 input_char_budget(默认 240000)
  • /llm delivery 三域语法;存量按群开关自动迁移

3aKHP added 30 commits September 9, 2026 06:33
- Header now references the themed-series versioning convention (docs/dev/versioning.md) instead of claiming SemVer compliance
- Preamble now vests final version-number interpretation and decision authority in the maintainer

- Major stays put by default, including on breaking changes, unless the maintainer explicitly decides otherwise; table row aligned
- Bash driver: canonical lowercase long options with --help usage; legacy single-dash CamelCase forms remain as aliases

- PowerShell driver: reads the project version and forwards it to the shared remote transaction

- Every release now carries a version identity: deployed pyproject version plus a timestamp captured server-side when the image build finishes, echoed in the image-built and release-complete log lines; rollback logs the target release version

- remote-deploy-v4.sh marks the hook point where the identity is available for operators to record with their own ops-trail tooling

- Docs updated (template README, admin deployment guide)
- Add bilingual SECURITY.md: private reporting channels, supported versions, scope, coordinated disclosure

- Add CODE_OF_CONDUCT.md as RFC 325799: RFC 2119 keywords, first-order forms, conformance proofs

- Add issue forms for bug reports, feature requests, and dev memos; disable blank issues

- Add default and release PR templates with change grading and verification checklists

- Extend check_id_literals scan paths to .github and SECURITY.md
- Monthly reports drop sample_per_day; full-window messages are assembled via week-fair char budget (quiet days kept whole, active days fill leftover, else equal-distance thin). New monthly_report.input_char_budget (default 240000) keeps final chat log at >=200k CJK tokens.

- Monthly logs gain week section headers so the model can cover every week; envelope message count reflects selected messages.

- Daily summaries switch from the legacy per-line formatter to the same compact period serializer (day sections, minute blocks, run merge, repeat collapse, URL domains, bot mark).

- Extract shared chat-log format note, name table, and injection guard; add light essay structure guidance for daily and period prompts.
Weekly and daily period user envelopes now report ser_stats.messages_in - messages_skipped, matching what compact serialization actually feeds the model. Monthly already used messages_selected. Pin with a unit test.
Weekly and daily period user envelopes now report ser_stats.messages_in - messages_skipped, matching what compact serialization actually feeds the model. Monthly already used messages_selected. Pin with a unit test.
…tion

feat(llm): monthly week-budget input and daily compact serializer
GitHub contents API upload from Windows rewrote the file with CRLF; .gitattributes requires LF.
Distinguish insert, backfill, duplicate and failure outcomes; ship and smoke-test the Windows migration script; count archive calendar days.
Keep message_sent events separate from ordinary commands and archive them through a dedicated matcher; cover real NoneBot dispatch.
Share one image budget and deduplication state across all messages in each request; preserve current-image priority and protocol tool batches.
Align generation and health metrics on accepted, discarded, failed and cancelled attempts; preserve historical unknowns and all measured costs.
fix: 修复 #232 合入后的消息、媒体与归档回归
- WebAdminActionQueue 新增 clear_finished(),仅删除已结束(succeeded/failed)记录

- 新增 POST /ops/api/llm-runtime/actions/clear(带审计日志)

- 诊断页「最近动作」面板头部加 danger「清空历史」按钮(confirm + toast 惯例)

- 补 action_queue 与路由单测;docs/admin/web-admin.md 同步说明
- 人格 ID 与提供商 ID 补上 mono class,与模型 ID 统一走 --qq-font-mono,消除同行字体混排
- UsageScope 增加 run_id:日报/简报/周月报每次生成携带唯一 run_id,级联各跳用量事件与最终报文行共享(零接线读取,沿用 current_agent_loop_id 范式)

- summaries/period_reports/llm_usage_events 三表惰性迁移补 run_id 列

- 新增 GET /summaries/{gid}/{date}/generation-log 与 /period-reports/{gid}/{type}/{key}/generation-log:run_id 精确归因优先,历史报文按 (上一条报文, 本报文] 时间窗兜底(首条封顶 6h)

- 健康度卡收敛为每链路一行(调用/接受率/异常构成/均耗时/成本),删除完成原因分布表;/summaries-health 契约同步精简

- 报文详情底部加「生成日志」折叠区(懒加载):逐跳时间点/模型/耗时/token/finish/采纳结果 + 合计与归因方式

- 更新钉住测试(upsert run_id kwarg、scope kwargs、health 契约),新增归因路径单测
- usage 计量 ts 改在调度时刻打点(原为落库时刻):级联末跳落库晚于报文 generated_at 时会被时间窗兜底丢失或串到下一篇

- 兜底窗口下界封顶 6h,避免周报/月报共用 feature 时跨类型污染;非法时间戳改捕 ValueError

- generation-log 路由触发报文 store 惰性迁移,兼容未经 LLM 调用升级的旧 schema 库

- llm_usage_events 增加 run_id 索引

- SummaryView 生成日志加载加过期守卫、补 mono 字体样式、修正空日志文案口径

- 补测试:period 路由归因/404/422/旧 schema、jobs run_id 接缝、health 键集合、ts 打点时序回归
fix+feat: v1.15.3 前端小问题与总结页生成日志
- 为 24 个视图与 TraceDetailPanel 补充 UiInfoTip 说明点约 90 处,覆盖统计口径、限流机制、生成链路、trace 状态等非自明术语,文案均经后端代码核实

- UiTabs 新增可选 tip 字段,UiPageHeader 新增 #subtitle 插槽,均向后兼容

- ConfigView 文件列表与 LlmAboutView 种类 Tab 改消费后端已返回的 description 字段,api/config.ts 补 ConfigListItem 类型

- UiStatCard 统计卡片统一走既有 tip 属性
- 修复 PersonasView 编辑栏 v-else-if 链导致的「不可删除」说明气泡死代码(改为独立 v-if)

- 修正「新鲜输入」文案:去掉对 claude 协议行不成立的括号公式,补充 claude 口径说明

- 统一「(未归因)」标签为半角括号,与后端实际标签一致
inline-flex 容器内仅有 SVG 时基线取盒子底缘,图标骑在文字基线上显得偏高;为 .ui-info-tip 增加 vertical-align: -0.15em 使其与 CJK 文字视觉居中(flex 布局父容器内该属性被忽略,无副作用)
- UiInfoTip 触发元素由 button 改为 span[role=button][tabindex=0],消除嵌入 tab/列表项按钮时的嵌套 button 问题(补 Enter/Space 键盘触发)

- ConfigListItem 按列表接口实际载荷补 exists 字段,「缺失」标记改用 exists 判定(修复缺失文件不显示标记的既有问题),missing 注明为 load() 回填的派生字段

- 修正贴吧说明中不存在的群内指令 /贴吧 为 /tieba

- UiPageHeader 副标题插槽改为 subtitle 属性或插槽任一存在即渲染

- StatsView 群卡片头部将标签与说明点包入同一容器,修复 space-between 把问号挤到右缘

- 「未定价」口径抽为共享常量;「异常」表头说明标签名改为引用 outcomeLabels 同源派生

- 审计「目标类型」说明改为「常见取值」措辞;移除贴吧/词云说明中复述后端默认值的具体数值
- UiStatCard 渐变卡上的说明图标增加 on-primary 反色,修复对比度不足与悬停隐形

- ConfigListItem 收敛为单一 exists 字段,移除前端派生 missing,消除双布尔并行

- GroupsView 四个 tab 的说明迁移到 UiTabs.tip 字段,删除平行的 tabTips 映射;「立即生成」说明补简报取数口径

- 说明文案中的数字改为引用源码常量:LogsLive 回放/上限行数、LogsArchive 预览行数、Stats 活跃用户榜上限

- MemoryView 的 scope/置信度口径抽为共享常量;SummaryView 链路/接受长文案抽为常量与 outcomeTip 一致

- MCP「状态未知」说明移到状态文本处(原位置在版本号为空时永不渲染);贴吧同步状态说明改为状态无关措辞

- 规则名来源补 [[context_rules]];定时消息一次性标签与说明合并为单条件;调度页说明去除与行内文案重复的阈值

- UiPageHeader 副标题属性与插槽之间补分隔空格
feat(frontend): 推广悬浮问号说明至全部管理页面
- 配置键 agent_delivery_intermediate_enabled / agent_delivery_final_enabled 独立控制两域,旧键 agent_delivery_enabled 读取时按两域同值映射并告警

- group_settings 增 agent_delivery_intermediate / agent_delivery_final 两列,加列时一次性回填旧值(与 reset 语义解耦),旧列退役只读

- Recorder 按域路由逐 Turn 交付计划;中间轮关闭的 suppressed 项显式排除出 sink 发送清单

- /llm delivery 扩为 interim|final|all 三域子命令,无域 status 输出两域概览;Web Admin 群设置双三态开关

- 恢复此前不可达的组合:中间轮照常发送 + 最终正文整条单发;补迁移回填、四组合行为矩阵、抑制不外发与配置映射测试
- set_chat_agent_delivery_enabled 未知 domain 改抛 ValueError,不再静默兜底双域写

- 补组合 B(仅中间轮开)首段失败静默终止与组合 C(仅最终轮开)suppressed 不外发 + 最终首段失败的端到端断言

- 组合 B 断言 agent_turn_row_id 回填钩子齐全(record_final_receipt 消费路径)
- 域建模:DeliveryDomain StrEnum 枚举 + state.py match 分派,非法域在解析期拒绝

- 命令层抽模块级 _handle_delivery_command;域词汇统一为 intermediate/final/all(删除 interim→intermediate 翻译表);status 概览与单域分支显式互斥;DeliveryViews 具名结构 + 形参遮蔽改名

- 迁移回填按列独立门控,半迁移状态下不跨列覆写既有值;补半迁移回归测试

- optin 测试 oracle 修正:两域异值覆盖 + reset 单域保留断言 + 同群 resolve 断言(同群行为复跑受五 Turn 剧本耗尽约束,以 resolve 钉住 reset 生效路径)
- aborted_silently 改以「实际成功交付数」为据(summary().sent > 0):中间轮抑制 + 最终轮未及交付即中止时不再全静默,给出可见中止提示;补零交付可见/部分交付静默对照测试

- set_chat_agent_delivery_enabled 域入参入口归一 DeliveryDomain(domain),非法值显式 ValueError,修正 docstring 误导表述

- 抑制判定单一归属:_plan_deliveries 返回 (items, suppressed_ids),on_turn 直接消费不再复算;_pending_* 四项状态在 __init__ 显式声明,deliver_turn 去除 getattr 隐式默认

- 旧键告警限定真实回退场景(存在未显式配置的域才 warning),两域齐全时降为 debug

- 迁移加列+回填抽 _backfill_delivery_split_columns 命名帮手(列名循环),_ensure_schema 回归单一职责

- RecorderConfig 字段统一为 agent_delivery_intermediate/final_enabled,与配置/存储/Web 同词根
- on/off/reset 改互斥分发(动作表 + 单点 finish),与 status 分支控制流惯用法一致

- status 命令单次取值快照复用,消除重复读库;_handle_delivery_command 改收子 token,去除隐式偏移约定

- 存储列/Web 字段补 _enabled 后缀(agent_delivery_intermediate/final_enabled),趁未进生产库零迁移窗口与配置键全链同名

- set_chat_agent_delivery_enabled 域注解放宽 DeliveryDomain | str,签名/实作/文档一致

- web 测试三条收口:旧键静默忽略 docstring 修正、llm.toml 加载失败兜底分支用例、列表投影两域字段用例
feat(llm): 交付开关拆分为中间轮/最终轮两域
- EmbeddedResource 的内联 text 在 MIME 属文本族(text/*、application/json|xml|yaml|x-yaml|toml|javascript、缺省视为文本)时交付进工具文本管线,GitHub MCP get_file_contents 读文件正文可达模型

- 60,000 code point 截断 + 固定标记;blob/非文本 MIME/空白正文/audio/link 维持扣留,URI 不随正文渲染(query 凭据边界不变)

- 文档 §8 内容边界同步;单测补文本族交付、非文本扣留、精确截断边界、isError 交付;集成测试补交付路径(正文达 provider、URI query 不泄漏)
- _mime_type_from 在清洗前剥离 MIME 参数(;charset=…),带参数的 application/json 等文本族资源与图片 MIME 精确匹配恢复命中

- 抽 _bounded_resource_text 统一承载 strip/截断/标记,消除双次 strip 的全量副本分配;资源常量块移至图片常量组之后,顶层定义两空行(E305)

- 单测参数化改由 _DELIVERABLE_RESOURCE_MIME_TYPES 派生并补大写/charset 形态;截断断言去魔法值、常量导入提顶
feat(mcp): 内联文本资源有界交付
- Consolidate 233-238 and dev-direct changelog drafts into the 1.15.3 section

- Version 1.15.3; Unreleased reset with compare links updated

@khpilot khpilot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bot Review — 💬 Comment

本 PR v1.15.3 涵盖月报字符预算分配、日报压缩序列化、生成日志与健康度、交付开关两域拆分、MCP 资源有界交付等多项功能,代码规模覆盖 127 个 patch 单元。general reviewer 的覆盖率仅 36/127 并有 4 个批次执行失败,未完成的 91 个单元中可能包含本次变更的核心逻辑(如 period_serializer.py 的新函数、llm 模块的 response_acceptance/summarize.py、usage.py、frontend 的 SummaryView、period_reports.ts 等),因此无法基于不完整的证据给出 approve 或 request_changes 的裁决。style reviewer 的 24 项 findings(全部为 should-fix 与 nit)中,值得在后续 PR 优先处理的有:文档口径不一致(README/ROADMAP 与实现及 CHANGELOG 的矛盾)、period_serializer 内双重标题构造与职责混杂、response_acceptance 混入 feature 分支知识、测试文件跨层放置与 fixture 重复副本。建议 general reviewer 在后续专项 review 中完成剩余 91 个单元的审查,尤其关注 src/quickquip/chat/period_serializer.py 的 build_monthly_chat_input、src/quickquip/llm/ 族、frontend/src/views/SummaryView.vue 与 tests/integration/ 跨层测试。

No findings reported.

Review provenance

  • General reviewer: incomplete — 36/127 units completed, 4 failed batches
  • Style reviewer: complete — 127/127 units completed
  • Coverage: incomplete — manifest=complete; general=incomplete(4 failed batches); style=complete
  • Reviewed head: c7814ef (base a7815ca)

Automated review by @KHPilot. Reply with @KHPilot to ask follow-up questions.

@3aKHP
3aKHP merged commit 386d5a7 into main Sep 10, 2026
6 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant