topic-decompose
Breaks a structured document into a hierarchical topic tree with estimated complexity ratings
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Breaks a structured document into a hierarchical topic tree with estimated complexity ratings
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
The SOLE WRITER to the V3.0 mem0 second brain. Invoked agentically by the executive at write moments — post-run, post-retro, post-spec-merge, manual /harvest. Decides which facts to classify into which memory type (principle/semantic/procedural/episodic/reflective), validates against the schema, and calls the deterministic plumbing in references/ via Bash. Blocks until writes are durable (poll event endpoint for SUCCEEDED). Never invoked from worker code.
Consult the V3.0 mem0 second brain agentically during executive planning, work selection, pre-spawn memory pack building, and failure diagnosis. Use this skill whenever the executive needs to remember prior runs, retros, or learned principles. Read-only — never writes. Drives the unified `mem0` CLI via Bash, orchestrating multiple iterative search queries (mem0 does not do multi-hop graph traversal natively, so iterative search IS the multi-hop).
Hook D — Failure-Diagnosis memory consultation. Runs at executive Phase 7 (after 3+ consecutive failures on a work item) BEFORE the failure-diagnosis skill itself runs. Consults the second brain for similar prior failures and successful retry strategies, then hands enriched context to the failure-diagnosis skill. Read-only. Invokes the memory-reader skill.
Hook E — Post-Retrospective Harvest. Runs after a retrospective markdown doc completes (per-run or weekly). Reads the retro fully and decides which durable lessons (reflective, semantic, procedural memories) to write to the second brain. Typically 3–8 writes per weekly retro, 0–3 per per-run retro. Invokes the memory-harvester skill for the actual writes.
Hook C — Post-Run Harvest. Runs after a worker completes (executive Phase 6 success path). Decides agentically which facts from the run to write to the second brain — typically 0–3 memory writes per run (one episodic, optionally a semantic or procedural). Invokes the memory-harvester skill to do the actual writes (with event-polling for durability).
Hook B — Pre-Spawn Memory Pack build. Runs before each worker spawn (executive Phase 4 prep). Reads the second brain for project-specific memories and produces a Memory Pack markdown block that worker-spawner injects into the worker's generated CLAUDE.md. Workers consume this as static markdown — they never call mem0 themselves. Read-only. Invokes the memory-reader skill.
| name | topic-decompose |
| description | Breaks a structured document into a hierarchical topic tree with estimated complexity ratings |
Break a structured document (syllabus, guide, outline, specification) into a hierarchical topic tree.
{{INPUT_PATH}} — Path to the source document. May be a local file path or a URL.{{OUTPUT_PATH}} — Path where the topic tree JSON file will be written.Acquire the source document.
{{INPUT_PATH}} is a URL (starts with http:// or https://), fetch it with WebFetch first, then parse the content.Analyze the document structure.
Assess complexity.
low, medium, or high based on:
Ensure granularity.
Write the output JSON.
Write a JSON file to {{OUTPUT_PATH}} with this structure:
{
"examTitle": "string — title of the subject area",
"sourceDocument": "string — input path or URL",
"generatedAt": "ISO 8601 timestamp",
"totalLeafTopics": "number",
"topics": [
{
"id": "string — unique identifier, e.g. 'domain-1'",
"title": "string — concise topic title",
"description": "string — 1-2 sentence description of what this covers",
"depth": 0,
"estimatedComplexity": "low | medium | high",
"subtopics": [
{
"id": "string — e.g. 'domain-1.topic-1'",
"title": "string",
"description": "string",
"depth": 1,
"estimatedComplexity": "low | medium | high",
"subtopics": [
{
"id": "string — e.g. 'domain-1.topic-1.sub-1'",
"title": "string",
"description": "string",
"depth": 2,
"estimatedComplexity": "low | medium | high",
"subtopics": []
}
]
}
]
}
]
}
networking.dns.record-types).