$npx -y skills add NatsuFox/Tapestry --skill synthesisConvert stored Tapestry artifacts into higher-level synthesis. Use when a user wants interpretation, consolidation, research notes, or analysis built on top of an already-ingested URL or note.
| 1 | # Tapestry Synthesis |
| 2 | |
| 3 | Analyze a stored Tapestry artifact: **$ARGUMENTS** |
| 4 | |
| 5 | ## When to use this skill |
| 6 | |
| 7 | Use this skill when: |
| 8 | - A user wants interpretation or analysis of already-ingested content |
| 9 | - You need to consolidate multiple sources into research notes |
| 10 | - The user asks for synthesis, insights, or higher-level understanding |
| 11 | - You need to organize ingested content into the knowledge base hierarchy |
| 12 | - The deterministic ingest is complete and model-based reasoning is needed |
| 13 | |
| 14 | ## Overview |
| 15 | |
| 16 | This skill is the workflow layer for model-eligible reasoning. |
| 17 | |
| 18 | Use it after deterministic ingest has already produced: |
| 19 | |
| 20 | 1. a capture JSON file |
| 21 | 2. a normalized feed JSON file |
| 22 | 3. a Markdown knowledge-base note |
| 23 | 4. a structured handoff payload describing the recommended analysis |
| 24 | |
| 25 | The package runtime does not call any model APIs directly. This skill owns the interpretation step. |
| 26 | |
| 27 | This skill is also responsible for maintaining the book-like knowledge base under `knowledge-base/`. |
| 28 | |
| 29 | **Important**: The synthesis mode configuration controls when this skill should be invoked: |
| 30 | - `auto`: Agent evaluates note accumulation and decides whether to merge (intelligent, load-based) |
| 31 | - `manual`: Only runs when explicitly requested by user |
| 32 | - `batch`: Runs after multiple ingests to process all at once |
| 33 | - `deterministic`: Runs automatically after every single ingest (high overhead) |
| 34 | |
| 35 | See `config/tapestry.config.json` for current mode setting. |
| 36 | |
| 37 | ## Workflow |
| 38 | |
| 39 | 1. Identify the target: |
| 40 | - if the user gave a stored note path, use it directly |
| 41 | - if the user gave a URL and it has not been ingested yet, run `$tapestry-ingest` first |
| 42 | 2. **IMPORTANT**: Change to the project root directory before running the script: |
| 43 | |
| 44 | ```bash |
| 45 | cd /path/to/your/tapestry/project |
| 46 | python synthesis/_scripts/load_context.py \ |
| 47 | "$ARGUMENTS" |
| 48 | ``` |
| 49 | |
| 50 | Or use the --project-root flag: |
| 51 | |
| 52 | ```bash |
| 53 | python synthesis/_scripts/load_context.py \ |
| 54 | --project-root /path/to/your/tapestry/project \ |
| 55 | "$ARGUMENTS" |
| 56 | ``` |
| 57 | |
| 58 | 3. Read the returned handoff payload carefully: |
| 59 | - `digest` is the deterministic baseline |
| 60 | - `analysis.skill`, `analysis.instructions`, and `analysis.deliverable` describe the intended workflow |
| 61 | - `note_text`, `feed_payload`, and `capture_payload` are the factual source materials |
| 62 | - **Identify the language** by reading the content naturally (title, body, comments) |
| 63 | 4. Ensure the book hierarchy exists: |
| 64 | |
| 65 | ```bash |
| 66 | cd /path/to/your/tapestry/project |
| 67 | python synthesis/_scripts/bootstrap_kb.py |
| 68 | ``` |
| 69 | |
| 70 | Or use the --project-root flag: |
| 71 | |
| 72 | ```bash |
| 73 | python synthesis/_scripts/bootstrap_kb.py \ |
| 74 | --project-root /path/to/your/tapestry/project |
| 75 | ``` |
| 76 | |
| 77 | 5. Read the knowledge-base governance files: |
| 78 | - `synthesis/_kb_rules/_shared-governance.md` |
| 79 | - `synthesis/_kb_rules/topic-taxonomy.md` |
| 80 | - `synthesis/_kb_rules/chapter-decision-rules.md` |
| 81 | 6. **CRITICAL**: Read the existing knowledge base structure thoroughly: |
| 82 | - Explore `knowledge-base/books/` to understand existing topics and chapters |
| 83 | - Read relevant `index.md` files to understand chapter scope and content |
| 84 | - Look for existing chapters where this content naturally fits |
| 85 | 7. **Default to integration** - Decide in this priority order: |
| 86 | 1. **FIRST CHOICE: Extend an existing chapter** - Integrate the new content into an existing chapter's narrative if it matches the chapter's central concept. Do NOT just append; weave it into the existing structure. |
| 87 | 2. **SECOND CHOICE: Create a new chapter** - Only if the content introduces a distinct subdomain that doesn't fit existing chapters |
| 88 | 3. **LAST RESORT: Restructure the topic tree** - Only if multiple chapters overlap heavily or the taxonomy has become incoherent |
| 89 | 8. **IMPORTANT**: Identify the language of the source content by reading it, then write your synthesis in that same language. Do not translate unless explicitly requested. |
| 90 | 9. When extending an existing chapter: |
| 91 | - Read the full chapter content first |
| 92 | - Identify where the new information fits thematically |
| 93 | - Integrate it into the existing narrative structure (don't append at the end) |
| 94 | - Update section headers if the new content shifts the conceptual balance |
| 95 | - Maintain consistent voice and formatting |
| 96 | 10. When creating a new chapter: |
| 97 | - Ensure it represents a recurring domain, not a one-off article |
| 98 | - Update the parent `index.md` to register the new chapter |
| 99 | - Follow the chapter structure patterns from existing chapters |
| 100 | 11. Return the synthesis clearly, grounded in the stored artifacts rather than vague recollection. |
| 101 | |
| 102 | ## Synthesis Quality Standards |
| 103 | |
| 104 | **IMPORTANT**: All synthesized content must go through this refinement process, regardless of the source crawler or content type. These standards ensure consistent, high-quality o |