Agentic Spec-To-Knowledge Derivation
Required Context
Load these files before deriving, doctoring, or repairing assets:
docs/solutions/l1/arch/business-asset-knowledge-model.mdskills/agentic-spec-to-knowledge-derivation/rules/derivation.mdskills/agentic-spec-to-knowledge-derivation/rules/agentic-memory-alignment.mdskills/agentic-spec-to-knowledge-derivation/rules/secret-redaction.md
Workflow
Read the source Superpowers Spec and compute its repository-relative path.
Read
docs/assets/builder/asset-index.yamlwhen it exists and verify the source Superpowers Spec is listed as a formalasset_kind: specasset for the phase.If the source Superpowers Spec is not listed, add a fallback derivation change that creates or registers a formal
asset_kind: specasset for the original source Spec, with repo-relative path, current source hash, phase id, and asset-index membership. This fallback records the source document itself; it must not rewrite, move, or delete the original source Spec.Read relevant existing L1/L2/L3 assets under
docs/solutions/.Use the templates under
templates/to add, modify, or delete durable business assets.Use agentic-memory family conventions for source fidelity, durable knowledge shape, and archive-compatible structure. Do not shell out to
agentic-memoryCLI from this skill.Write L1/L2/L3 asset changes only after the user has requested derivation or repair.
Run deterministic CLI lint or doctor:
agentic spec-derivation lint --manifest docs/assets/builder/derivations/<phase-id>.yaml <workspace>Module fallback:
PYTHONPATH=python python -m agentic_core.cli spec-derivation lint --manifest docs/assets/builder/derivations/<phase-id>.yaml <workspace>When
long_document_modetriggers, create a source chunk index, dispatch read-only chunk extraction subagents when available, collectsource-chunk-fact-packetoutputs, synthesize the source coverage ledger as the main agent, and block if any critical chunk remains incomplete.In long-document derivation, preserve
source_chunk_index_refandsource_coverage_ledger_refin the manifest and keepbusiness-flow.operationsgrounded in source-backed operation contracts.If deterministic lint fails for structural reasons, run CLI repair once.
If business meaning is missing or inconsistent, run semantic doctor and semantic repair using
prompts/doctor.mdandprompts/repair.md.Re-run deterministic lint after semantic repair.
Prepare the confirm request for Agent Chat /
agent-runtime.
Guardrails
- Do not modify or delete the Superpowers Spec during derivation, doctor, or repair.
- Derivation and repair must not commit, tag, push, reset, rebase, stash, or force push.
- Semantic repair may modify or physically delete only L1/L2/L3 business assets.
- 主 agent 是唯一 synthesis owner。Read-only subagents may extract chunk facts, but they must not write manifests, ledgers, specs, or final assets.
- Confirm must revalidate manifest, asset index, source hash, source refs, dirty paths, Git guard, and phase metadata before committing.