documentation-sync-engine
Runs the fast stale-doc detector and dispatches the per-domain doc-sync skills for the affected canonical paths. Use when implementation lands, or just before handoff, on feature-development, bug-fix, refactor or migration work.
- License 许可
- MIT
- 所属仓库
- Eliyce/paqad-ai
- 最近更新
- 2026-11-13
- Stars
- ★ 8
- Forks
- 0
01 前言 Front Matter
- name
- documentation-sync-engine
- metadata
- { "cacheable": "false", "model_tier": "medium", "paqad-meta": "skill.meta.yaml", "output_format": "markdown" }
- description
- Runs the fast stale-doc detector and dispatches the per-domain doc-sync skills for the affected canonical paths. Use when implementation lands, or just before handoff, on feature-development, bug-fix, refactor or migration work.
02 资源文件 7
- 参考文档agents/openai.yaml192 B
- 资产文件assets/output.template.md544 B
- 资产文件assets/routing-table.txt437 B
- 参考文档references/orchestration-rules.md2.8 KB
- 脚本scripts/lint-output.sh1.3 KB
- 脚本scripts/route-paths.sh926 B
- 参考文档skill.meta.yaml575 B
03 SKILL.md 正文
What It Does
Acts as the canonical entry point for post-implementation documentation sync. Runs diff-doc-sync first to narrow to actually-stale canonical doc paths, then dispatches each path to the domain-specific maintainer (api, integration, error catalog, canonical, or glossary). Aggregates the results into a single report so the caller does not have to invoke five skills sequentially.
The point is to give callers one place to ask "sync the docs after this change" and get consistent, deduplicated output every time.
Use This When
After implementation lands (or just before handoff) on feature-development, bug-fix, refactor, or migration workflows. Skip when differential_refresh is disabled in the project profile and the team prefers running the per-domain skills directly.
Inputs
- Read the changed file list at
changed_files. - Use the detector at
detector_script_path(viadiff-doc-sync) to produce the stale canonical doc set. - Read
references/orchestration-rules.mdbefore dispatching so the routing rules and execution order stay consistent across runs. - When
target_domainsis non-empty, intersect the dispatched set with the requested domains.
Procedure
- Invoke
diff-doc-syncwith the changed file list to produce the candidate stale doc set (JSON array). - Pipe that array's paths into
scripts/route-paths.shto assign each path a delegate domain (api | integration | error | glossary | canonical); seeassets/routing-table.txtfor the mapping. - Apply
target_domainsfiltering if provided. - Invoke each delegate skill once with only its domain's paths.
- Aggregate delegate outputs and format per
assets/output.template.md. - Validate with
scripts/lint-output.sh.
Output Contract
- Return a heading named
Documentation Sync. - Provide a
Stale Doc Setline:Detected: {N} | Routed: {M} | Skipped (target_domains filter): {K}. - For each domain that ran, emit a third-level heading
### {domain}and list the paths the delegate updated, plus any consistency warnings the delegate raised. - Provide a
Known Driftaggregated section pulling from delegates' deferred-drift notes. - When the stale set is empty, return
Documentation Sync: no canonical docs require update.exactly.
See assets/output.template.md for the canonical shape; scripts/lint-output.sh enforces it.
Escalate / Stop Conditions
- Stop when
diff-doc-synccannot run (missing detector, missing changed-files list). - Warn when any delegate reports a consistency warning; surface every such warning in the consolidated report rather than swallowing it.
- Do not invent doc paths the detector did not report as stale.
- Do not re-route a path between delegates: the per-domain table in
references/orchestration-rules.mdis the only routing source of truth.
Resources
references/orchestration-rules.mdscripts/route-paths.shscripts/lint-output.shassets/output.template.mdassets/routing-table.txtagents/openai.yaml
04 同仓库更多 Skills
sample-skill
Sample bundled skill fixture
processing-invoices
Turns a supplier invoice into one ledger line. Use when a supplier invoice arrives and needs booking.
processing-invoices
Turns a supplier invoice into one ledger line. Use when a supplier invoice arrives and needs booking.
understand-idea
Chat and Claude Code: Step 1 of the discover journey: clarifies the goal, who benefits, success and constraints into the idea block. Use when the journey directs it to step 1, not directly.
size-work
Chat and Claude Code: Suggest a size for a ticket from comparable finished work, as a labelled suggestion the team still owns. Use it when someone asks "how big is this?", "roughly how much work is ABC-12?", or wants a backlog item sized. It finds the team's sizing scale at first use, picks two to five of the closest finished tickets with links, and gives a size or range with the drivers behind it and a confidence of low, medium or high, lowered and explained when the area's documents are template text. Every result is labelled a suggested size, never a date or a commitment. It writes nothing into the size field unless the user says "set it", and it refuses to overwrite an existing size unless the user asks to replace it. Produces the sizing block of the record.
refine-ticket
Chat and Claude Code: Improve one or more existing tracker tickets without losing the author's intent. Use it when someone wants a ticket read, diagnosed and tidied up ("this ticket is vague", "fix up ABC-12", "split this, it's too big"). It reads each ticket in full and snapshots it with its last-updated time, says what is wrong with evidence, and proposes a field-by-field before and after change set limited to summary, description, labels, parent, links and new child tickets on a split. It writes nothing until an explicit "apply it" bound to that exact change set, re-checks the ticket for conflicting edits just before writing, never replaces rich descriptions with plain text, never deletes or closes a ticket, and reads each ticket back after applying. Produces the existing and changes blocks of the record.