zcbot/tests
caoqianming 5cf92ec71a feat(rendering): 通用报告走平台渲染器 report profile + 基座引导,少让模型手撸 python-docx(bump 0.58.35)
接 0.58.34(语法预检=止血),这条根治那一头。关键发现:平台早有成熟 md→docx(+pdf)
渲染器 rendering/(bind-mount /sandbox/rendering:ro,任何 run_python 可达,与 skill
无关),标题/正文/列表/表格/图片图题/mermaid/化学式下标/目录/house 字体全有,
paper/proposal/brief 三 profile 在用。烧 token 的验收报告没走它、在裸手撸 python-docx,
唯一原因是没引导把"随手写 Word 报告"指向它。故不造轮子,只两件小事:

1. rendering/docx_manuscript.py 加 report profile(复用全套渲染;差异=报告不是申报书:
   目录默认无[--toc 才带]/章节不强制分页/页边距 2.5-2.5/列表含"第X章节"不含"条"),
   render.py --profile 加 report 选项 + 路由。
2. core/agent_builder.py 基座 prompt 加软引导:出 Word 报告→正文写成 sections/*.md
   调 render.py --profile report,别手撸 python-docx 内联中文。

取舍红线(与用户对齐):渲染器是首选加法不是替代——绝不硬拦 run_python 生成文档,
确需精细定制版式/改写已有 docx/处理 xlsx 等渲染器覆盖不了的照样自由写代码;软引导
让位于更具体的 skill render 指引(proposal/paper)。刻意不把渲染器指路塞进语法预检
hint(会 overload 只该管语法的检查、误导合法手撸),预检保持只诊断语法。三层叠加:
渲染器(根治)> 预检(0.58.34)> RepeatGuard err-streak(0.58.33),run_python 能力不削。

测试 tests/test_rendering.py(四 profile 端到端 + report 目录可选)+ CLI e2e
(render.py --profile report 出 37KB docx)全绿;py_compile 校三文件无语法错。
DESIGN §8.6 记该 profile + 并存红线。additive,不碰对外 API/DB 契约。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-17 09:32:02 +08:00
..
frontend_task_progress.test.mjs fix(web): 进度条自愈——回放层强制单调完成(d1285247 复盘,bump 0.36.2) 2026-07-03 11:16:34 +08:00
test_broker_redis.py feat(broker): 外置 Redis pub/sub——蓝绿跨实例 SSE/cancel 可达(bump 0.42.0) 2026-07-06 14:51:39 +08:00
test_changelog.py feat(changelog): 用户版更新日志 CHANGELOG.md + /v1/changelog + 点版本号弹层(bump 0.55.0) 2026-07-09 16:49:26 +08:00
test_context_compaction.py fix(context): 发送期补齐悬空 tool_calls,断中断 run 留下的协议崩 + bump 0.20.2 2026-06-21 15:08:20 +08:00
test_context_fold.py feat(context): §8.8 Phase 2 长会话中段折叠摘要 + 头部压缩指示环(bump 0.54.1) 2026-07-09 12:39:31 +08:00
test_disk_quota.py Stage C 收尾包:资源 yaml + 磁盘配额 + 网络放开 + 容器内源持久化 2026-05-27 08:35:53 +08:00
test_executor_docker.py fix(exec): run_python script_path 宿主预检+前缀容错+code 落盘回退(bump 0.58.22) 2026-07-13 16:41:43 +08:00
test_load_skill.py feat(skills): 用户私有 skill(.skills)+ 创作工具 + skill-creator + Web 查看页 2026-06-11 09:46:39 +08:00
test_loop_empty_response.py feat(loop): 空响应防御——provider 吐空自动重试 + warn 自停不静默 done + 面板留痕(bump 0.58.32) 2026-07-15 15:29:49 +08:00
test_loop_malformed_retry.py feat(loop): 空响应防御——provider 吐空自动重试 + warn 自停不静默 done + 面板留痕(bump 0.58.32) 2026-07-15 15:29:49 +08:00
test_loop_repeat_guard.py fix(loop): 堵失败聚集两裂缝——必填key被吞畸形走非流式重试 + RepeatGuard连续同错streak拦(bump 0.58.33) 2026-07-17 08:22:42 +08:00
test_pptx_guard.py fix(guard): ppt 伪导出根治三层——平台机检门 + 禁令去菜谱 + 脚本 hint 纪律(bump 0.40.0) 2026-07-06 13:40:54 +08:00
test_pptx_render.py feat(preview): pptx 在线预览 —— LibreOffice→PDF + 复用 PDF iframe(DESIGN §8.3 Stage 1) 2026-06-09 13:04:02 +08:00
test_pysyntax.py feat(run_python): 宿主语法预检——中文正文硬拼进源码的语法坏码提前拦下+锐化诊断(bump 0.58.34) 2026-07-17 08:55:55 +08:00
test_rendering.py feat(rendering): 通用报告走平台渲染器 report profile + 基座引导,少让模型手撸 python-docx(bump 0.58.35) 2026-07-17 09:32:02 +08:00
test_run_python_script_path.py fix(exec): run_python script_path 宿主预检+前缀容错+code 落盘回退(bump 0.58.22) 2026-07-13 16:41:43 +08:00
test_salvage.py feat(loop): 畸形 tool_call arguments 就地抢救(salvage)省一次非流式重试(bump 0.58.24) 2026-07-15 09:20:38 +08:00
test_sandbox_check.py Stage C Step 5: main.py sandbox check + lifespan fs quota WARN 2026-05-26 16:41:16 +08:00
test_secret_host_tools.py feat(mp): mp_search_summary 批量入参 formulas[] 定点解检索烧 token(bump 0.58.28) 2026-07-15 10:49:35 +08:00
test_shortcuts.py feat(shortcuts): 加快捷指令(触发词→完整指令,入口层确定性展开)(bump 0.35.0) 2026-07-01 14:58:55 +08:00
test_skill_model_pinning.py feat(skill): skill 定向模型——ppt 触发自动热切 GLM-5.2(bump 0.39.0) 2026-07-06 08:57:32 +08:00
test_static_vendor.py Disable static asset caching 2026-06-08 09:16:31 +08:00
test_svg_alignment_check.py feat(ppt): 反纯文字页+图表落地硬门(7aa49195 二代陶瓷 deck 复盘,bump 0.38.0) 2026-07-03 13:34:51 +08:00
test_system_prompt_paths.py test(prompt): 锁住 docker 下 system prompt 不漏宿主路径(药3 复核收口) 2026-06-09 11:30:32 +08:00
test_task_progress_tool.py Add task progress tool 2026-06-08 08:44:16 +08:00
test_tool_output_compaction.py Reduce chat context token usage 2026-06-04 16:41:14 +08:00
test_toolfail_malformed.py feat(loop): 空响应防御——provider 吐空自动重试 + warn 自停不静默 done + 面板留痕(bump 0.58.32) 2026-07-15 15:29:49 +08:00
test_usage_accounting.py feat(usage): 记账给前缀缓存命中折价 + 前端体现缓存命中/真实成本 2026-06-05 08:26:09 +08:00
test_user_skills.py feat(skills): 用户私有 skill(.skills)+ 创作工具 + skill-creator + Web 查看页 2026-06-11 09:46:39 +08:00