数字花园自动更新
每天 23:50 Brisbane 自动生成 branch、维护数字花园笔记、跑检查与构建并创建待审 PR 的流程说明。
这套 nightly automation 通过 GitHub Actions 维护数字花园内容,并保留人工 review 后 merge 的最终关口。
# 数字花园自动更新
## Workflow
- 定时:每天晚上 23:50 Brisbane 时间,对应 GitHub Actions `13:50 UTC`。
- 分支:自动创建或更新 `garden-auto/YYYY-MM-DD`。
- 内容:生成 daily reflection、distillation、maintenance plan,并在安全范围内补充已有公开笔记的维护记录。
- 校验:执行 `npm run garden:check`,再执行 `npm run build`,确保索引、发布产物和生产构建都能通过。
- 输出:如果当天有有效变更,就自动创建 PR,等待人工 review 后 merge。
## Key Files
- Workflow: `.github/workflows/daily-garden-automation.yml`
- Daily reflection generator: `scripts/garden-daily-automation.js`
- Distillation generator: `scripts/garden-distill-daily.js`
- Maintenance applier: `scripts/garden-apply-maintenance.js`
- Run artifacts: `.garden/automation/`
## Review Guardrails
- inbox/private 内容不能直接公开;公开候选内容必须保持 `requiresReview: true`。
- 自动化可以补充维护痕迹和候选笔记,但最终发布与合并仍由人工决定。
- 如果当天没有足够的 evidence-backed insight,允许 workflow 只产出诊断或 no-op 结果,而不是强行发布低质量内容。
## Why It Matters
这套自动化的目标不是替人发布文章,而是把真实产品工作变成可审查的候选知识。近期的 Codex 生产循环说明:只有 evidence、confidence、public safety 和人工 review 都成立时,工程活动才适合进入公开 garden。
这也是 [[codex-product-production-loop]] 的一部分:产品交付后,需要有一个低风险的方式把经验回写到笔记系统,而不是让每次修复都停留在聊天记录或临时命令里。
它还连接到 [[future-edge-cache-playbook]]:只有通过 review 的公开 note 才应该进入 RSS、feed、sitemap、static fallback 和未来 edge cache;private inbox 和 automation candidate 不应该被缓存成公开知识。
## Recent Update - 2026-W26
[[weekly-review-2026-w26]] adds a weekly review layer above the daily automation. Old unapproved candidates are now classified as private archived evidence, and `garden:check` groups warning output by type so future reviews can distinguish link, metadata, automation, and safety issues quickly.
## Update Log
<!-- garden-auto:daily-maintenance 2026-06-18 -->
- 2026-06-18: Maintenance note added by Daily Garden Automation. Reasons: health 50; no backlinks. Evidence: garden index 2026-06-18; public note digital-garden-auto-update.
- 2026-06-22: 补充自动化和 Codex 产品生产循环之间的关系。
- 2026-06-15: 明确 nightly branch、note maintenance、`garden:check`、`build`、auto PR、manual review/merge 的完整流程。
Open this garden note