System State Audit — 2026-05-02

系统级体检。两天大刀阔斧后状态快照,作未来对话起跑线。

1. 各域规模

wiki/pages           84  (work — 功率电子 / 汽车电子 / 半导体 / 功能安全)
invest/wiki/pages   143  (投资,骨架完整内容深度参差)
english/wiki/pages   20  (基础语言层 + 场景层 + IELTS 5 件套)
reading/wiki/pages    4  (骨架,4 页方法论)
travel/wiki/pages     0  (仅 index)

平均行数 250-450 行 / 页。最长 topic-functional-safety.md 1570 行,最短 ~100 行。

2. 工具链全貌

工具触发当前状态
nextjs-deploy.ymlwiki/** push自动,~12-15 min, 含 build embeddings (5min timeout) + npm build (15min timeout)
worker-deploy.ymlworker/** push自动,~3 min, wrangler deploy 全自动
telegram_ingest.ymlcron 5minTG poll → / 路由到 sources/inbox//
ingest.ymlinbox push / clipping_slugLLM 处理 inbox → wiki//pending/
feed.yml12:00 BJTfeed 抓取 + 摘要
audit.yml(手动 / 周)内容矛盾检测
weekly.yml周一weekly digest
publish_pending.ymlissue closedpending → pages 移动

3. AI 系统当前架构

PWA (apps/web)  →  /api/ask  →  Worker (Cloudflare)
                                  ↓
                  Stage 1: hybrid retrieval
                  ├ keyword × 0.4 (scoreEntries)
                  └ semantic × 0.6 (Gemini embedding-001 cosine vs embeddings.json)
                                  ↓
                  Stage 2: chain (DeepSeek 主 → Perplexity 兜底 → Gemini 兜底兜底)
                                  ↓
                  Stage 3: prompt 反转(用户是 wiki 作者,补 wiki 没说的)
                                  ↓
                  25-27s 出 1500-2500 字研究报告

实测 4/4 query 一击命中 DeepSeek,无 fallback 浪费。

4. 已知未完成 / 待办

4.1 内容侧

  • invest 域: 143 页骨架完整,但只 Tesla 深扩(500+ 行)。Howard Marks / BYD / NVIDIA / sea-change 等都 100-200 行可继续深扩
  • reading: 4 页方法论,无具体阅读笔记
  • travel 域: 0 页,只 index
  • invest aliases dups: 30+ 个 alias 跨页(china-tech-giants 和单公司页都占同一 alias),架构性问题待用户拍板"deep wins"或"overview wins"
  • TODO 标记: 79 页含 LLM 自动生成的"通读全文后填入..."占位

4.2 系统侧

  • lint: 4029 warnings(99% section-no-prose), 可批量跑 auto_fix_section_prose.py --apply(需 GEMINI_API_KEY env)
  • invest sources-index.json total = 0: 491 个 PDF 在 sources/ 但未 build index. build_sources_index.py 可跑
  • CF Pages 迁移 (memory project_consider_cf_pages_migration.md): GH Pages CN TTFB 2-3s 痛点,等用户拍板

4.3 监控侧

  • 2026-05-08 后 (memory project_worker_routing_check_followup.md): 主动提醒看 worker 真实流量分布,看是否调 hybrid score 阈值

5. 2026-05-01/02 主要改动

5.1 内容 (15+ 新页)

  • 工作域: current/voltage/position/temperature-sensing-safety + gate-driver-safety + can-e2e-secoc + software-safety + bms-safety + asil-d-case-studies (9 篇 functional safety)
  • 工作域 fix: asil-decomposition (D=A+C 澄清 + (D) 括号税)
  • 英语域: tech-interview + peer-review-response + daily-writing-toolbox + pr-review-english + conference-talk-english + grammar-cohesion-complex-sentences (6 篇)
  • 投资域: tesla 深扩 115 → 500 行

5.2 系统 / 工具

  • worker /api/ask 全栈重构: wiki+Perplexity 两段式 → 全量 sonar-pro → DeepSeek 主路径(实测 A/B 后)
  • Hybrid semantic search (Gemini embedding cosine + keyword 加权)
  • Auto-deploy worker (worker-deploy.yml 不再手动 wrangler)
  • Auto-deploy embeddings (build_embeddings.py GH Actions step)
  • backlinks alias 反向 + 4-10× 加速(单 regex 大正则 + matchAll)
  • 成熟度标签 (frontmatter maturity + UI 徽章 + lint 校验)
  • SW v22 → v25 多次 cache invalidate
  • auto_fix_section_prose.py LLM 批量补散文桥梁工具
  • build_embeddings.py 加 5min CI timeout + circuit breaker

5.3 UI

  • 莫兰迪色板: sage → caramel(用户偏暖)
  • W 图标: 字体渲染 → SVG path 描(任意 size sharp)
  • Typography 阶梯清晰化: H1 24/H2 20/H3 17/H4 16/p 16
  • 缩进规范显式化(ul 1 级 flush, blockquote 1em + sage 边)
  • Table ≤ 3 列硬约束(prompt + spec)
  • Mermaid fontSize 14 → 12 + 1:1 渲染不缩放
  • RightCluster idle 30% + group-hover

5.4 系统清理

  • 删 9 个 dead script (5618 行 dead code)
  • docs/ai-search-worker.md 全重写
  • docs/obsidian-setup.md 标 DEPRECATED

6. 健康度评分(主观)

维度评分说明
Work 域内容深度9/10功能安全完整闭环,主线七层全覆盖
English 域内容深度8/1018 页全场景覆盖,部分 IELTS 还可深扩
Invest 域内容深度5/10143 页骨架但内容深度参差,需一对一深扩
Reading 域内容2/104 页方法论,实际书评 / reading list
Travel 域内容1/10仅 index,等 trip 才填
AI 搜索质量9/10DeepSeek 主路径深度报告,4/4 命中,引用质量高
自动化 (auto-deploy / ingest)9/10全自动,无手动步骤
UI / typography9/10莫兰迪 caramel + 统一 typography 阶梯
Mobile 体验7/10PWA 装到主屏 + SW cache,GH Pages CN TTFB 是瓶颈
文档完整性8/10docs/ + CLAUDE.md 反映当前架构

7. 下一阶段建议(等用户决策方向)

按 ROI 从高到低:

  1. invest 域内容深扩 — Tesla 范本已建,可复刻给 NVIDIA / BYD / 比亚迪 / Howard Marks / sea-change 等
  2. 跑 auto_fix_section_prose 批量修 lint 散文 warning(GEMINI_API_KEY local + dry-run review)
  3. CF Pages 迁移 PWA 性能根本解(用户拍板)
  4. invest sources/ 491 PDF 入 wiki(分类后 ingest pipeline 跑一遍)
  5. invest alias 冲突清理 (deep wins or overview wins 决策)
  6. Reading + Travel 域填内容 — 看用户实际有没有阅读 / 旅行 backlog

8. 跨页综合可读性

未来 Claude 开新对话需要快速理解整套系统时,读 4 个文件即可:

  1. CLAUDE.md — 系统总览(本次 audit 后已更新)
  2. docs/ai-search-worker.md — AI 搜索后端
  3. docs/operations.md — 日常操作流
  4. 本文件 — 当前状态快照