Go to file
caoqianming 07959eb738 refactor(ppt): 版式 helper 抽成可 import 模块 + 修中文字体没真生效 + quality_check 配色查纳入填充色
逐页生成是"每页一个 run_python",以前 ~150 行 helper(配色常量/add_textbox/
apply_brand 等)要在每页里默写一遍 —— 烧 token 且长 deck 里坐标会漂(第 7 页
apply_brand 跟第 2 页对不上)。

- 新增 scripts/pptx_helpers.py:每页 import pptx_helpers as P 调用;含 new_presentation
  / load(按文件实际尺寸回填画布常量,逐页进程间同步) / add_slide / set_palette(默认
  商务红,spec_path= 自动取 spec 前 3 个 hex 作主/辅/强调)入口。
- 字体修复:python-pptx font.name 只写 <a:latin>,中文字形走 <a:ea> 槽位没设 ——
  "指定微软雅黑却没真生效"的根因。set_text 改为同时写 latin=Arial + ea/cs=微软雅黑,
  中英混排各命中正确字体。
- quality_check.py 配色检查纳入形状填充色(品牌条/徽章/圆点/标签/底块以前全漏),
  并把粗阈值"≤5 色"改成贴合三色制的"非灰阶色 ≤3"(灰/黑/白按 R/G/B 极差 ≤12 排除),
  否则计入填充后合规商务红 deck 会狂报假阳;spec 比对也只比非灰阶色。
- 联动:layouts.md(helper 块换成 import 起手 + API 速查,9 个示例全改 P. 调用)、
  icons.md A5 示例、SKILL.md 资源/阶段二、PROGRESS.md。

冒烟测试过:ea 字体确写入、set_palette 覆盖生效、quality_check 正常解析;
合规红 deck 无配色 warning、塞 4+ 彩色触发、ACCENT 强调线填充被正确捕获。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 15:43:09 +08:00
config models: 加 local.{r1,qwen3} 内网模型档案,涉密任务用 2026-05-28 15:55:37 +08:00
core feat(web): 文件面板底部展示用户已用存储 + 配额 2026-06-04 15:00:36 +08:00
db/migrations Stage C 收尾包:资源 yaml + 磁盘配额 + 网络放开 + 容器内源持久化 2026-05-27 08:35:53 +08:00
deploy fix(deploy): npm 默认源改回腾讯 — npmmirror 访问不稳 2026-06-03 11:00:28 +08:00
prompts/system skills+general_v1: ppt 歧义反问 + 路由产物形式歧义先问 2026-05-27 15:36:25 +08:00
scripts feat(tools): documents/pymatgen secret-bearing 能力改 host-side tools,key 不进 sandbox 2026-06-01 09:35:10 +08:00
skills refactor(ppt): 版式 helper 抽成可 import 模块 + 修中文字体没真生效 + quality_check 配色查纳入填充色 2026-06-04 15:43:09 +08:00
tests fix(sandbox): shell 也注入 PYTHONPATH + HOME=/tmp(修只读 rootfs 两副作用) 2026-06-04 14:12:53 +08:00
tools fix(tools): MP 工具改服务端限量查询,止血 IP 被封根因 2026-06-01 15:11:16 +08:00
web feat(web): 文件面板底部展示用户已用存储 + 配额 2026-06-04 15:00:36 +08:00
.gitattributes Add .gitattributes: force LF for shell + Dockerfile 2026-05-26 10:45:17 +08:00
.gitignore skills+core(命名约定): task 级宪法文件 <date>-<short_id>-<name>.spec.md + spec_lock → spec 简化 2026-05-20 14:03:21 +08:00
CLAUDE.md docs(claude): 加 Shell 语法规约 — 别把 PowerShell here-string 喂给 Bash 工具 2026-06-02 12:28:23 +08:00
DESIGN.md docs: 精简 PROGRESS 每条压回 1-2 句 + DESIGN 状态表去重 2026-06-03 13:26:10 +08:00
DOCUMENT_SEARCH_API.md feat(skill): documents skill 接内部材料学科知识库(document_search API) 2026-05-21 15:31:21 +08:00
EMBED.md feat(web): embed 模式接受 ?task_id=<uuid> URL 参数自动定位 task 2026-05-22 15:27:19 +08:00
PROGRESS.md refactor(ppt): 版式 helper 抽成可 import 模块 + 修中文字体没真生效 + quality_check 配色查纳入填充色 2026-06-04 15:43:09 +08:00
RUN.md fix(deploy): npm 默认源改回腾讯 — npmmirror 访问不稳 2026-06-03 11:00:28 +08:00
SCIENTIFIC_SKILLS.md skills: 加 pymatgen / stats_ml / plot_pub(建材院无机材料场景) 2026-05-28 11:33:59 +08:00
SKILL_LIST.md feat(tools): documents/pymatgen secret-bearing 能力改 host-side tools,key 不进 sandbox 2026-06-01 09:35:10 +08:00
alembic.ini core(§7 B Step 1): Storage 基建 — SQLAlchemy ORM + alembic + db CLI 2026-05-14 10:41:44 +08:00
main.py Stage C Step 5: main.py sandbox check + lifespan fs quota WARN 2026-05-26 16:41:16 +08:00
requirements.txt skills: 加 pymatgen / stats_ml / plot_pub(建材院无机材料场景) 2026-05-28 11:33:59 +08:00