Purpose: fix a common survey failure mode:
This skill does not change prose by itself.
It produces a constraint sheet: output/CITATION_BUDGET_REPORT.md.
output/DRAFT.mdoutline/outline.yml (H3 ids/titles; used to allocate budgets per subsection)outline/writer_context_packs.jsonl (source of allowed_bibkeys_{selected,mapped,chapter,global} per H3)citations/ref.biboutput/CITATION_BUDGET_REPORT.mdcitations/ref.bib.The report should feel like a constraint sheet, not a random list:
recommended).Canonical (parseable) lines required (downstream validators depend on these):
queries.md:citation_target (recommended by default for A150++).- Global target (policy; blocking): >= ... - Gap: (gap-to-target; if 0, injection can be a no-op PASS)Optional (always reported; may be blocking depending on citation_target):
- Global recommended target: >= ... - Gap to recommended: Recommended prioritization (scope-safe):
allowed_bibkeys_selected → allowed_bibkeys_mapped → allowed_bibkeys_chapterallowed_bibkeys_global only for:After you generate the budget report:
citation-injector (LLM edits to output/DRAFT.md, NO NEW FACTS).draft-polisher to remove any “budget dump voice” while keeping citation keys unchanged.Important: citation-injector is LLM-first. Its script is validation-only.
1) Diagnose the global situation
output/DRAFT.md and estimate the “unique-key gap” (or use pipeline-auditor’s FAIL reason).2) Allocate budgets per H3 (scope-first)
outline/outline.yml to enumerate H3s in paper order.outline/writer_context_packs.jsonl.3) Write output/CITATION_BUDGET_REPORT.md
Required structure:
- Status: PASS|FAIL- Global target (policy; blocking): >= ... - Gap: ## Summary (gap + strategy)## Per-subsection budgets (H3 id/title → suggested keys → placement hint)If you want a deterministic first-pass budget report, run the helper script. Treat it as a baseline and refine the plan as needed.
python scripts/run.py --helppython scripts/run.py --workspace workspaces/--workspace --unit-id (optional)--inputs (rare override; prefer defaults)--outputs (rare override; default writes output/CITATION_BUDGET_REPORT.md)--checkpoint (optional)python scripts/run.py --workspace workspaces/output/CITATION_BUDGET_REPORT.md exists and has actionable, in-scope budgets.citation-injector, pipeline-auditor no longer FAILs on global unique citations.共 1 个版本