[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M71NH8MHJ3HDS103DS3J4YXQ":3,"skill-same:01M71NH8MHJ3HDS103DS3J4YXQ":134},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":44,"commitSha":45,"skillDirectory":46,"forksCount":47,"repositoryHtmlUrl":48,"repositoryHomepageUrl":6,"ownerHtmlUrl":49,"ownerBlogUrl":6,"ownerDescription":50,"updatedAt":51,"install":52,"resources":65},"01M71NH8MHJ3HDS103DS3J4YXQ","ln-100-documents-pipeline",null,"Creates complete project documentation system (project docs, reference, tasks, tests). Use when bootstrapping docs from scratch or regenerating all.","vitalikpestov\u002FSkills-Catalog","vitalikpestov","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F13882997?v=4","01M71N4QG0CWRXX4R24JQZXDDQ","Vitalik Pestov","01M71N4QGMSYRW607DDSE0CQMM",2,"MIT","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"documents","ln","ln 100 documents pipeline","pipeline","docs","reference","documentation system","From Scratch","use","complete project","tests","scratch","complete","system","project documentation","project docs","documentation","tasks","when","project","2026-11-10 10:56:23",false,"---\nname: ln-100-documents-pipeline\ndescription: \"Creates complete project documentation system (project docs, reference, tasks, tests). Use when bootstrapping docs from scratch or regenerating all.\"\nlicense: MIT\n---\n\n> **Paths:** File paths (`references\u002F`, `..\u002Fln-*`) are relative to this skill directory.\n\n**Type:** L1 Top Orchestrator\n**Category:** 1XX Documentation Pipeline\n\n# Documentation Pipeline (Orchestrator)\n\nThis skill orchestrates the creation of a complete documentation system by invoking one L2 coordinator plus 3 L2 workers. The coordinator (ln-110) delegates to 5 L3 workers for project docs; other L2 workers handle reference, tasks, and test domains. Each component validates its own output, and the orchestrator owns the final docs-quality acceptance gate.\n\n## Purpose\n\nTop-level orchestrator that creates a complete project documentation system in one invocation. Chains ln-110 coordinator + ln-120\u002F130\u002F140 workers sequentially, then runs global cleanup (deduplication, orphan reporting, cross-link validation).\n\n## Runtime Contract\n\n**MANDATORY READ:** Load `references\u002Fcoordinator_runtime_contract.md`, `references\u002Fdocs_pipeline_runtime_contract.md`, `references\u002Fdocs_generation_summary_contract.md`\n\nRuntime family: `docs-pipeline-runtime`\n\nIdentifier:\n- `docs-pipeline`\n\nPhases:\n1. `PHASE_0_CONFIG`\n2. `PHASE_1_LEGACY_SCAN`\n3. `PHASE_2_CONFIRMATION`\n4. `PHASE_3_DELEGATE`\n5. `PHASE_4_QUALITY_GATE`\n6. `PHASE_5_CLEANUP`\n7. `PHASE_6_SELF_CHECK`\n\nComponent summary contract:\n- `ln-110`, `ln-120`, `ln-130`, `ln-140` write or return `docs-generation` envelopes\n- `ln-100` consumes those summaries plus docs-quality checkpoints as orchestration SSOT\n\n## Architecture\n\n```\nln-100-documents-pipeline (L1 Top Orchestrator - this skill)\n|- ln-110-project-docs-coordinator (L2 Coordinator)\n|  |- ln-111-root-docs-creator (L3 Worker) -> 5 docs\n|  |- ln-112-project-core-creator (L3 Worker) -> 3 docs\n|  |- ln-113-backend-docs-creator (L3 Worker) -> 2 conditional\n|  |- ln-114-frontend-docs-creator (L3 Worker) -> 1 conditional\n|  `- ln-115-devops-docs-creator (L3 Worker) -> 1 always + 1 conditional\n|- ln-120-reference-docs-creator (L2 Worker)\n|- ln-130-tasks-docs-creator (L2 Worker)\n`- ln-140-test-docs-creator (L2 Worker - optional)\n```\n\n## When to Use This Skill\n\nThis skill should be used when:\n- Start a new IT project and need complete documentation system at once\n- Use automated workflow instead of manually invoking multiple workers\n- Create entire documentation structure (`AGENTS.md` canonical + `CLAUDE.md` import stub -> `docs\u002F`) in one go\n- Prefer orchestrated CREATE path over manual skill chaining\n- Need automatic global cleanup (deduplication, orphaned files, consolidation)\n\n**Alternative**: If you prefer granular control, invoke workers manually:\n1. [ln-110-project-docs-coordinator](..\u002Fln-110-project-docs-coordinator\u002FSKILL.md) - Root + Project docs (coordinates 5 L3 workers)\n2. [ln-120-reference-docs-creator](..\u002Fln-120-reference-docs-creator\u002FSKILL.md) - reference\u002F structure\n3. [ln-130-tasks-docs-creator](..\u002Fln-130-tasks-docs-creator\u002FSKILL.md) - tasks\u002FREADME.md + kanban\n4. [ln-140-test-docs-creator](..\u002Fln-140-test-docs-creator\u002FSKILL.md) - tests\u002FREADME.md (optional)\n\n**MANDATORY READ:** Load `references\u002Fdocs_quality_contract.md`.\n\n**Note**: Each worker validates its own local output in Phase 2\u002F3. The orchestrator still owns the final docs-quality manifest, verification, and repair loop before cleanup can continue.\n\n## Workflow\n\nThe skill follows a 5-phase orchestration workflow: **Legacy Migration (optional)** -> User confirmation -> Invoke coordinator + workers sequentially -> Global cleanup -> Summary.\n\n---\n\n### Phase 0: Source Documentation Cleanup (OPTIONAL)\n\n**Objective**: Detect non-canonical documentation, normalize any useful facts, and remove duplicate documentation paths before generation.\n\n**Trigger**: Runs at pipeline start when the repo already contains documentation outside the canonical layout.\n\n**Process**:\n\n**0a. Non-Canonical Source Detection**:\n- Scan project for non-standard documentation using patterns from `references\u002Flegacy_detection_patterns.md`:\n  - **Root .md files**: `ARCHITECTURE.md`, `REQUIREMENTS.md`, `STACK.md`, `API.md`, `DATABASE.md`, `DEPLOYMENT.md`\n  - **Non-canonical folders**: `documentation\u002F`, `doc\u002F`, `wiki\u002F`, or `docs\u002F` with wrong structure\n  - **README.md sections**: `## Architecture`, `## Tech Stack`, `## Requirements`, etc.\n  - **CONTRIBUTING.md sections**: `## Development`, `## Code Style`, `## Coding Standards`\n- Build `source_manifest`: list of { path, detected_type, target_doc, confidence }\n- If no non-canonical docs are found -> skip to Phase 1\n\n**0b. Fact Extraction**:\n- For each detected source file:\n  - Parse markdown structure (headers, lists, code blocks)\n  - Apply type-specific extractor (**MANDATORY READ:** Load `references\u002Flegacy_detection_patterns.md`):\n    - `architecture_extractor` -> { layers[], components[], diagrams[] }\n    - `requirements_extractor` -> { functional[], non_functional[] }\n    - `tech_stack_extractor` -> { frontend, backend, database, versions }\n    - `principles_extractor` -> { principles[], anti_patterns[] }\n    - `api_spec_extractor` -> { endpoints[], authentication }\n    - `database_schema_extractor` -> { tables[], relationships[] }\n    - `runbook_extractor` -> { prerequisites[], install_steps[], env_vars[] }\n    - `infrastructure_extractor` -> { servers[], domains[], ports[], services[], artifacts{}, cicd{} }\n  - Score content quality (0.0-1.0)\n- Store results in `source_notes`\n\n**0c. User Confirmation**:\n- Display detected non-canonical files:\n  ```\n  Non-Canonical Documentation Detected:\n\n  | File | Type | Confidence | Target |\n  |------|------|------------|--------|\n  | README.md (## Architecture) | architecture | HIGH | docs\u002Fproject\u002Farchitecture.md |\n  | docs\u002FARCHITECTURE.md | architecture | HIGH | docs\u002Fproject\u002Farchitecture.md |\n  | CONTRIBUTING.md (## Development) | principles | MEDIUM | docs\u002Fprinciples.md |\n\n  Cleanup Options:\n  1. NORMALIZE (recommended): Extract facts -> Archive -> Remove duplicate sources\n  2. ARCHIVE ONLY: Backup without extraction\n  3. SKIP: Leave non-canonical docs as-is (may cause duplication)\n\n  Choose option (1\u002F2\u002F3): _\n  ```\n- If user selects \"1\" (NORMALIZE):\n  - Optional: \"Review extracted facts before folding them into the canonical context? (yes\u002Fno)\"\n  - Confirm: \"Proceed with cleanup and archive non-canonical files?\"\n- If user selects \"2\" (ARCHIVE ONLY):\n  - Confirm: \"Archive non-canonical files to .archive\u002F? Content will NOT be normalized.\"\n- If user selects \"3\" (SKIP):\n  - Warn: \"Non-canonical files will remain. This may cause duplication issues.\"\n  - Proceed to Phase 1\n\n**0d. Backup and Archive**:\n- Create `.archive\u002Fsource-docs-{timestamp}\u002F` directory\n- Structure:\n  ```\n  .archive\u002F\n  `- source-docs-YYYY-MM-DD-HHMMSS\u002F\n      |- README_cleanup.md          # Rollback instructions\n      |- original\u002F                  # Exact copies of non-canonical files\n      |  |- README.md\n      |  |- ARCHITECTURE.md\n      |  `- documentation\u002F\n      `- extracted\u002F                 # Extracted facts (for reference)\n          |- architecture_content.md\n          `- principles_content.md\n  ```\n- Copy all detected source files to `original\u002F`\n- Save extracted facts to `extracted\u002F`\n- Generate `README_cleanup.md` with rollback instructions\n\n**0e. Context Normalization**:\n- Build `SOURCE_DOC_NOTES` from extracted facts:\n  ```json\n  {\n    \"SOURCE_DOC_NOTES\": {\n      \"architecture_notes\": { \"sections\": [...], \"diagrams\": [...] },\n      \"requirements_notes\": { \"functional\": [...] },\n      \"principles_notes\": { \"principles\": [...] },\n      \"tech_stack_notes\": { \"frontend\": \"...\", \"backend\": \"...\" },\n      \"api_notes\": { \"endpoints\": [...] },\n      \"database_notes\": { \"tables\": [...] },\n      \"runbook_notes\": { \"install_steps\": [...] },\n      \"infrastructure_notes\": { \"servers\": [...], \"domains\": [...], \"ports\": {} }\n    }\n  }\n  ```\n- Merge extracted facts into the coordinator input as supporting evidence only\n- Workers consume normalized context fields and current source facts directly; there is no legacy-only branch\n- Priority order: **Current source facts + normalized project documentation > template defaults**\n\n**0f. Cleanup (Non-Canonical Files)**:\n- For root-level files (README.md, CONTRIBUTING.md):\n  - Do NOT delete\n  - Remove duplicated sections using Edit tool\n  - Add links to new locations:\n    - `## Architecture` -> replace with link: `[Architecture](docs\u002Fproject\u002Farchitecture.md)`\n    - `## Tech Stack` -> replace with link: `[Tech Stack](docs\u002Fproject\u002Ftech_stack.md)`\n- For standalone non-canonical files (ARCHITECTURE.md, documentation\u002F):\n  - Delete files (already backed up)\n  - Log: \"Deleted: ARCHITECTURE.md (migrated to docs\u002Fproject\u002Farchitecture.md)\"\n- Clean empty non-canonical directories\n\n**Output**: `cleanup_summary` { normalized_count, archived_count, skipped_count, source_doc_notes }\n\n### Phase 1: User Confirmation\n\n**Objective**: Check existing files, explain workflow, and get user approval.\n\n**Process**:\n\n0. **Cleanup Summary** (if Phase 0 ran):\n   - Show: \"Normalized {N} non-canonical documents\"\n   - Show: \"Archived to .archive\u002Fsource-docs-{date}\u002F\"\n   - Show: \"Coordinator input enriched with normalized source notes\"\n\n1. **Pre-flight Check** (scan existing documentation):\n   - Use Glob tool to check all potential files:\n    - **Root docs**: `AGENTS.md`, `CLAUDE.md`, `docs\u002FREADME.md`, `docs\u002Fdocumentation_standards.md`, `docs\u002Fprinciples.md`\n     - **Reference structure** (5 items): `docs\u002Freference\u002FREADME.md`, `docs\u002Freference\u002Fadrs\u002F`, `docs\u002Freference\u002Fguides\u002F`, `docs\u002Freference\u002Fmanuals\u002F`, `docs\u002Freference\u002Fresearch\u002F`\n     - **Tasks docs** (2 files): `docs\u002Ftasks\u002FREADME.md`, `docs\u002Ftasks\u002Fkanban_board.md`\n     - **Project docs** (up to 8 files): `docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md`, `api_spec.md`, `database_schema.md`, `design_guidelines.md`, `infrastructure.md`, `runbook.md`\n     - **Test docs** (2 files): `docs\u002Freference\u002Fguides\u002Ftesting-strategy.md`, `tests\u002FREADME.md`\n   - Count existing vs missing files\n   - Show user summary:\n     ```\n     Documentation Status:\n     Found: X existing files\n     Missing: Y files\n\n     Pipeline will create ONLY missing files.\n     Existing files will be preserved (no overwrites).\n     ```\n\n2. Show user what will be created:\n   - Root + Project documentation (`AGENTS.md` canonical + `CLAUDE.md` import stub + `docs\u002FREADME.md` + `documentation_standards.md` + `principles.md` + `docs\u002Fproject\u002F` via ln-110-project-docs-coordinator)\n   - Reference structure (docs\u002Freference\u002F via ln-120-reference-docs-creator)\n   - Task management docs (docs\u002Ftasks\u002F via ln-130-tasks-docs-creator)\n   - Test documentation (tests\u002F via ln-140-test-docs-creator - optional)\n   - Estimated time: 15-20 minutes with interactive dialog\n\n3. Ask: \"Proceed with creating missing files? (yes\u002Fno)\"\n\n4. Ask: \"Include test documentation (tests\u002FREADME.md)? (yes\u002Fno)\"\n\n**Output**: File scan summary + user approval + test docs preference\n\n---\n\n### Phase 2: Invoke Coordinator + Workers Sequentially\n\n**Objective**: Create complete documentation system by invoking L2 coordinator + 4 L2 workers in order.\n\n**Process** (AUTOMATIC invocations with Skill tool):\n\n**2a. Create Root + Project Documentation**:\n- **Invocation**: `Skill(skill: \"ln-110-project-docs-coordinator\")` -> AUTOMATIC\n- **Input**: Pass normalized source notes from Phase 0 when cleanup was performed\n- **Behavior**: Coordinator gathers context ONCE, then delegates to 5 L3 workers:\n  - ln-111-root-docs-creator -> root docs (AGENTS.md canonical + CLAUDE.md stub + docs\u002FREADME.md + documentation_standards.md + principles.md)\n  - ln-112-project-core-creator -> 3 core docs\n  - ln-113-backend-docs-creator -> 2 conditional\n  - ln-114-frontend-docs-creator -> 1 conditional (if hasFrontend)\n  - ln-115-devops-docs-creator -> 2 docs: 1 always + 1 conditional\n- **Output**: Root docs (`AGENTS.md` canonical + `CLAUDE.md` `@AGENTS.md` import stub + `docs\u002FREADME.md` + `docs\u002Fdocumentation_standards.md` + `docs\u002Fprinciples.md`) + Project docs (`docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md`, `infrastructure.md` + conditional: `api_spec.md`, `database_schema.md`, `design_guidelines.md`, `runbook.md`)\n- **Store**: Save `context_store` from ln-110 result (contains TECH_STACK for ln-120)\n- **Validation**: Each L3 worker validates output (SCOPE, metadata markers, top sections, Maintenance)\n- **Verify**: All documents exist before continuing\n\n**2b. Create Reference Structure + Smart Documents**:\n- **Invocation**: `Skill(skill: \"ln-120-reference-docs-creator\")` -> AUTOMATIC\n- **Input**: Pass `context_store` from ln-110 (TECH_STACK enables smart document creation)\n- **Output**: `docs\u002Freference\u002FREADME.md` + `adrs\u002F`, `guides\u002F`, `manuals\u002F`, `research\u002F` directories + **justified ADRs\u002FGuides\u002FManuals**\n- **Smart Creation**: Creates documents only for nontrivial technology choices (see ln-120 justification rules)\n- **Validation**: ln-120 validates output in Phase 2\u002F3\n- **Verify**: Reference hub exists before continuing\n\n**2c. Create Task Management Docs**:\n- **Invocation**: `Skill(skill: \"ln-130-tasks-docs-creator\")` -> AUTOMATIC\n- **Output**: `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md` (if user provides Linear config)\n- **Validation**: ln-130 validates output in Phase 2\u002F3\n- **Verify**: Tasks README exists before continuing\n\n**2d. Create Test Documentation (Optional)**:\n- **Condition**: If user approved test docs in Phase 1\n- **Invocation**: `Skill(skill: \"ln-140-test-docs-creator\")` -> AUTOMATIC\n- **Output**: `tests\u002FREADME.md` (test documentation with Story-Level Test Task Pattern)\n- **Validation**: ln-140 validates output in Phase 2\u002F3\n- **Skip**: If \"no\" -> can run ln-140-test-docs-creator later manually\n\n**2e. Extract Skills from Documentation (Optional)**:\n- **Condition**: User approved skill extraction in Phase 1, or invoked manually later\n- **Invocation**: `Skill(skill: \"ln-160-docs-skill-extractor\")` -> AUTOMATIC\n- **Input**: All docs created by ln-110 through ln-140\n- **Output**: `.claude\u002Fcommands\u002F*.md` files extracted from procedural documentation sections\n- **Skip**: If not approved -> can run ln-160-docs-skill-extractor later manually\n\n**Output**: Complete documentation system with coordinator + 4 workers completed and validated\n\n## Worker Invocation (MANDATORY)\n\n**Host Skill Invocation:** `Skill(skill: \"...\", args: \"...\")` is mandatory delegation.\n- Claude: call the Skill tool exactly as shown.\n- Codex: if no Skill tool exists, locate the named skill in available skills, read its `SKILL.md`, treat `args` as `$ARGUMENTS`, execute that skill workflow, then return here with its result\u002Fartifact.\n- Do not inline worker logic or mark the worker complete without executing the target skill.\n\n## TodoWrite format (mandatory)\nAdd ALL invocations to todos before starting:\n```\n- Invoke ln-110-project-docs-coordinator (pending)\n- Invoke ln-120-reference-docs-creator (pending)\n- Invoke ln-130-tasks-docs-creator (pending)\n- Invoke ln-140-test-docs-creator (pending)\n- Run Global Cleanup (Phase 3) (pending)\n- Show Summary (Phase 4) (pending)\n```\nMark each as in_progress when starting, completed when worker returns success.\n\n---\n\n### Phase 3: Global Cleanup and Consolidation\n\n**Objective**: Remove duplicates, orphaned files, consolidate knowledge across ALL documentation.\n\n**Trigger**: Only after ALL workers complete Phase 2\u002F3 validation.\n\n**Process**:\n\n**3a. Build docs-quality manifest**\n\nCreate one normalized manifest from worker outputs before any cleanup:\n\n1. Collect `created_files`, `skipped_files`, and `quality_inputs` from ln-110, ln-120, ln-130, and ln-140\n2. Merge `quality_inputs.doc_paths` and `quality_inputs.owners`, deduplicate paths, and fail fast if any worker omitted the normalized return contract\n3. Write the explicit manifest with the shared verifier:\n   ```bash\n   node {skills_repo_root}\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs manifest \\\n     --project-root . \\\n    --files \"AGENTS.md,CLAUDE.md,docs\u002FREADME.md,docs\u002Fproject\u002Frequirements.md\" \\\n     --output docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-manifest.json\n   ```\n4. Keep the manifest as the Single Source of Truth for all Phase 3 quality decisions\n\n**3b. Run centralized docs-quality verifier**\n\nRun the shared verifier against the manifest:\n\n```bash\nnode {skills_repo_root}\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs verify \\\n  --project-root . \\\n  --manifest docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-manifest.json \\\n  --output docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-report.json\n```\n\nVerifier checks come from the shared docs-quality contract\u002Frules and include:\n- SCOPE tags in required docs\n- Maintenance section + markers\n- Forbidden placeholders and leaked template metadata\n- Broken internal links\n- Disallowed code fences\n- Stale inline dates\n- Non-official stack documentation links\n\n**Gate:** No HIGH\u002FCRITICAL findings may remain before Phase 3 cleanup proceeds.\n\n**3c. Bounded repair loop**\n\nIf verifier reports HIGH\u002FCRITICAL findings:\n\n1. **Pass 1 - deterministic inline fixes**:\n   - Add missing SCOPE tags\n   - Add or complete `## Maintenance`\n   - Normalize broken internal links when target is obvious\n   - Refresh stale generated dates\n   - Remove leaked template metadata and unresolved markers\n   - Replace illegal fenced code with tables, commands, or links\n2. **Pass 2 - owner-scoped semantic repair**:\n   - Group remaining findings by `quality_inputs.owners[path]`\n   - Re-invoke only the owning worker with the scoped findings for its files\n   - Do not rerun unrelated workers\n3. Re-run the verifier after each repair pass\n4. Stop after 2 repair iterations total\n5. If any HIGH\u002FCRITICAL findings remain, fail the pipeline instead of emitting low-quality docs\n\nRecord the verifier summary and doc-registry output in the Phase 5 final output.\n\n**3d. Scan for duplicate content**\n\n1. **Read all .md files in docs\u002F**\n   - Use Glob tool: `pattern: \"docs\u002F**\u002F*.md\"`\n   - Store list of all documentation files\n\n2. **Identify duplicate sections:**\n   - For each file:\n     - Read file content\n     - Extract section headers (##, ###)\n     - Extract section content (text between headers)\n   - Compare sections across files:\n     - If 2+ sections have:\n       - Same heading (case-insensitive)\n       - >80% content similarity (simple word overlap check)\n     - Mark as duplicate\n\n3. **Determine canonical version:**\n   - Rules for canonical location:\n     - \"Development Principles\" -> principles.md (always canonical)\n     - \"Testing Strategy\" -> testing-strategy.md (always canonical)\n     - \"Linear Configuration\" -> tasks\u002Fkanban_board.md (always canonical)\n     - For other duplicates: Keep in FIRST file encountered (alphabetical order)\n\n4. **Remove duplicates:**\n   - For each duplicate section:\n     - Use Edit tool to delete from non-canonical files\n     - Use Edit tool to add link to canonical location:\n       ```markdown\n       Canonical source: [Development Principles](..\u002Fprinciples.md#development-principles)\n       ```\n   - Track count of removed duplicates\n\n5. **Log results:**\n   - \"Removed {count} duplicate sections\"\n   - List: \"{section_name} removed from {file} (canonical: {canonical_file})\"\n\n**3e. Report unexpected files (advisory)**\n\n1. **List all .md files in docs\u002F**\n   - Use Glob tool: `pattern: \"docs\u002F**\u002F*.md\"`\n\n2. **Check against expected structure** (files created by workers + user-created reference docs)\n\n3. **Report findings (DO NOT move\u002Fdelete\u002Farchive):**\n   - List unexpected files with advisory message\n   - User decides what to do with them\n   - Log: \"{count} unexpected files found (not in expected structure) -> listed for user review\"\n\n**3f. Consolidate knowledge**\n\n1. **Identify scattered information:**\n   - Known patterns:\n     - Linear config scattered: kanban_board.md + tasks\u002FREADME.md\n     - Development principles scattered: AGENTS.md + principles.md + architecture.md\n     - Testing info scattered: testing-strategy.md + tests\u002FREADME.md + architecture.md\n\n2. **For each scattered concept:**\n   - Determine Single Source of Truth (SSoT):\n     - Linear config -> kanban_board.md\n     - Development principles -> principles.md\n     - Testing strategy -> testing-strategy.md\n\n3. **Update non-SSoT files:**\n   - Use Edit tool to replace duplicate content with link:\n     ```markdown\n     Canonical source: [Linear Configuration](..\u002Ftasks\u002Fkanban_board.md#linear-configuration)\n     ```\n   - Track consolidation count\n\n4. **Log results:**\n   - \"Consolidated {count} scattered concepts\"\n   - List: \"{concept} consolidated to {SSoT_file}\"\n\n**3g. Cross-link validation**\n\n1. **Scan all .md files for internal links:**\n   - For each file:\n     - Read content\n     - Extract all markdown links: `[text](path)`\n     - Filter internal links (relative paths, not http:\u002F\u002F)\n\n2. **Verify link targets exist:**\n   - For each link:\n     - Resolve relative path\n     - Check if target file exists (Glob tool)\n     - If missing: Mark as broken\n\n3. **Fix broken links:**\n   - For each broken link:\n     - If target was archived: Update link to archive path\n     - If target never existed: Remove link (convert to plain text)\n   - Track fix count\n\n4. **Add missing critical links:**\n   - **AGENTS.md -> docs\u002FREADME.md:**\n     - Read AGENTS.md\n     - Check for link to docs\u002FREADME.md\n     - If missing: Add in \"Documentation Hub\" section\n   - **docs\u002FREADME.md -> section READMEs:**\n     - Check for links to project\u002F, reference\u002F, tasks\u002F, tests\u002F READMEs\n     - If missing: Add\n   - Track added links count\n\n5. **Log results:**\n   - \"Fixed {count} broken links\"\n   - \"Added {count} missing critical links\"\n   - List changes\n\n**3h. Final report**\n\n```\nGlobal Cleanup Complete:\n\nStructure:\n- Removed {N} duplicate sections (canonical: principles.md)\n- Found {N} unexpected files (listed for user review)\n- Consolidated {N} scattered concepts\n\nLinks:\n- Fixed {N} broken links\n- Added {N} missing critical links:\n  - list of added links\n```\n\n**Output**: All documentation cleaned up, duplicates removed, unexpected files reported, knowledge consolidated, cross-links validated\n\n---\n\n### Phase 4: Summary and Next Steps\n\n**Objective**: Provide complete overview of created system.\n\n**Process**:\n1. List all created files with sizes:\n   - `AGENTS.md` (canonical project entry point)\n   - `CLAUDE.md` (`@AGENTS.md` import stub for Claude Code)\n   - `docs\u002FREADME.md` (root documentation hub)\n   - `docs\u002Fdocumentation_standards.md` (60 universal requirements)\n   - `docs\u002Fprinciples.md` (11 development principles)\n   - `docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md` + conditional documents (3-7 total)\n   - `docs\u002Freference\u002FREADME.md` (reference hub with empty adrs\u002F, guides\u002F, manuals\u002F, research\u002F directories)\n   - `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md`\n   - `tests\u002FREADME.md` (if created)\n\n2. Show documentation system features:\n   - SCOPE tags (document boundaries defined)\n   - Maintenance sections (update triggers + verification)\n   - README hub (central navigation)\n   - DAG structure (Directed Acyclic Graph navigation)\n   - Living documentation ready\n   - Deduplicated content (canonical sources only)\n   - Validated cross-links (no broken links)\n\n3. Recommend next steps:\n   - \"Review generated documentation (AGENTS.md canonical + CLAUDE.md stub -> docs\u002F)\"\n   - \"Run ln-210-epic-coordinator to decompose scope into Epics\"\n   - \"Share documentation with technical stakeholders\"\n\n4. Summarize the docs-quality gate:\n   - `Verifier score: X\u002F10`\n   - `Repair passes used: 0-2`\n   - `Remaining warnings: list LOW\u002FMEDIUM only`\n\n**Output**: Summary message with file list, verifier status, and recommendations\n\n---\n\n## Complete Output Structure\n\n```\nproject_root\u002F\n|- AGENTS.md                         # Canonical project entry point (map-first root)\n|- CLAUDE.md                         # Derived Anthropic entrypoint\n|- docs\u002F\n|  |- README.md                     # Root documentation hub (general standards)\n|  |- documentation_standards.md    # 60 universal requirements (Claude Code + industry standards)\n|  |- principles.md                 # 11 development principles (Standards First, YAGNI, KISS, DRY, etc.)\n|  |- project\u002F\n|  |  |- requirements.md           # Functional Requirements (NO NFR per project policy)\n|  |  |- architecture.md           # arc42-based architecture with C4 Model\n|  |  |- tech_stack.md             # Technology versions, Docker config\n|  |  |- api_spec.md               # API endpoints (conditional)\n|  |  |- database_schema.md        # Database schema (conditional)\n|  |  |- design_guidelines.md      # UI\u002FUX system (conditional)\n|  |  |- infrastructure.md         # Infrastructure inventory (always)\n|  |  `- runbook.md                # Operations guide (conditional)\n|  |- reference\u002F\n|  |  |- README.md                 # Reference documentation hub (registries)\n|  |  |- adrs\u002F                     # Empty, ready for ADRs\n|  |  |- guides\u002F                   # Empty, ready for guides\n|  |  |- manuals\u002F                  # Empty, ready for manuals\n|  |  `- research\u002F                 # Empty, ready for research\n|  |- tasks\u002F\n|  |  |- README.md                 # Task management system rules\n|  |  `- kanban_board.md           # Linear integration (optional)\n`- tests\u002F\n   `- README.md                    # Test documentation (optional)\n```\n\n---\n\n## Integration with Project Workflow\n\n**Recommended workflow for new projects:**\n\n1. **ln-100-documents-pipeline** (this skill) - Create complete documentation system\n2. **ln-210-epic-coordinator** - Decompose scope into Epics (Linear Projects)\n3. **ln-220-story-coordinator** - Create User Stories for each Epic (automatic decomposition + replan)\n4. **ln-300-task-coordinator** - Break down Stories into implementation tasks (automatic decomposition + replan)\n5. **ln-310-multi-agent-validator** - Verify Stories before development\n6. **ln-400-story-executor** - Orchestrate Story implementation\n7. **Story quality gate** - Review completed Stories\n\n---\n\n## Trade-offs\n\n**Trade-offs:**\n- Less granular control (can't skip coordinator phases)\n- Longer execution time (15-20 minutes)\n- Global cleanup runs even if only one file was created\n\n**When to use manual approach instead:**\n- Need one specific ADR\u002Fguide\u002Fmanual -> use references\u002Ftemplates\u002F + references\u002Fdocumentation_creation.md\n\n---\n\n## Documentation Standards\n\nAll documents created by this pipeline MUST follow these rules:\n\n| Rule | Description | Enforcement |\n|------|-------------|-------------|\n| **NO_CODE Rule** | Documents describe contracts, not implementations | No code blocks >5 lines; use tables\u002FASCII\u002Flinks |\n| **Stack Adaptation** | Links must match project TECH_STACK | .NET -> Microsoft docs, JS -> MDN |\n| **Format Priority** | Tables\u002FASCII > Lists (enumerations only) > Text | Tables for params, config, alternatives |\n\nThese standards are enforced by L3 workers (ln-111-115), ln-120\u002F130\u002F140, and the shared docs-quality gate.\n\n---\n\n## Error Handling\n\nIf any invoked skill fails:\n1. Notify user which skill failed\n2. Show error message from failed skill\n3. Recommend manual invocation for debugging\n4. List already completed steps (partial progress)\n\n---\n\n## Technical Implementation Notes\n\n**Skill Invocation:**\n- Uses **Skill tool** with command parameter\n- Waits for each skill to complete before proceeding\n- Verifies output files exist before moving to next phase\n\n**File Verification:**\n- Uses **Glob** tool to check docs\u002Fproject\u002F structure\n- Lists file sizes for user confirmation\n- Warns if expected files missing\n\n**Global Cleanup:**\n- Uses **Glob** tool to find all .md files\n- Uses **Read** tool to analyze content\n- Uses **Edit** tool to remove duplicates and add links\n- Reports unexpected files (advisory, no auto-archive)\n\n**Docs-Quality Gate:**\n- Uses `references\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs` to build a manifest from worker outputs\n- Uses the shared verifier before cleanup and again after repair passes\n- Fails fast on unresolved HIGH\u002FCRITICAL findings instead of emitting low-quality documentation\n\n**Standards Compliance:**\n- All output follows same standards as underlying skills\n- ISO\u002FIEC\u002FIEEE 29148:2018 (Requirements)\n- ISO\u002FIEC\u002FIEEE 42010:2022 (Architecture)\n- arc42 + C4 Model + Michael Nygard's ADR Format\n\n---\n\n## Critical Rules\n\n- **Idempotent:** Creates only missing files; existing files are preserved without overwrite\n- **Sequential invocation:** Workers must be invoked in order (ln-110 -> ln-120 -> ln-130 -> ln-140); each verified before next\n- **Docs-quality gate mandatory:** Phase 3 must build manifest -> run verifier -> execute bounded repair loop before cleanup continues\n- **Global cleanup mandatory:** Phase 3 (deduplication, orphan reporting, SSoT consolidation, cross-link validation) runs only after docs-quality gate passes\n- **User confirmation required:** Pre-flight check and explicit approval before any file creation\n- **NO_CODE Rule:** All generated documents use tables\u002FASCII\u002Flinks; no code blocks >5 lines\n\n## Phase 5: Meta-Analysis\n\nOptional reference: load `references\u002Fmeta_analysis_protocol.md` only when the user asks for post-run meta-analysis or protocol-formatted run reflection.\n\nSkill type: `planning-coordinator`. When requested, run after all phases complete. Output to chat using the `planning-coordinator` format.\n\n## Reference Files\n\n- Non-canonical source patterns: `references\u002Flegacy_detection_patterns.md`\n- Worker skills: `ln-110-project-docs-coordinator`, `ln-120-reference-docs-creator`, `ln-130-tasks-docs-creator`, `ln-140-test-docs-creator`\n- Shared docs-quality contract: `references\u002Fdocs_quality_contract.md`\n- Shared verifier CLI: `references\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs`\n\n## Definition of Done\n\nBefore completing work, verify ALL checkpoints:\n\n**Source Cleanup (Phase 0 - if applicable):**\n- [ ] Non-canonical documentation patterns applied (Glob + Grep)\n- [ ] Source manifest built: { path, type, confidence, target }\n- [ ] User selected cleanup option (NORMALIZE \u002F ARCHIVE \u002F SKIP)\n- [ ] If NORMALIZE: facts extracted using type-specific extractors\n- [ ] Backup created: `.archive\u002Fsource-docs-{timestamp}\u002Foriginal\u002F`\n- [ ] Extracted facts saved: `.archive\u002Fsource-docs-{timestamp}\u002Fextracted\u002F`\n- [ ] README_cleanup.md generated with rollback instructions\n- [ ] SOURCE_DOC_NOTES prepared for coordinator input\n- [ ] Non-canonical files cleaned up (sections removed from README.md, standalone files deleted)\n\n**User Confirmation (Phase 1):**\n- [ ] Migration summary shown (if Phase 0 ran)\n- [ ] Workflow explained to user (coordinator + 4 workers: ln-110 -> ln-120 -> ln-130 -> ln-140)\n- [ ] User approved: \"Proceed with complete documentation system creation? (yes\u002Fno)\"\n- [ ] Test docs preference captured: \"Include test documentation? (yes\u002Fno)\"\n\n**Coordinator + Workers Invoked Sequentially (Phase 2):**\n- [ ] ln-110-project-docs-coordinator invoked -> Output verified: Root docs (`AGENTS.md` + `CLAUDE.md` + `docs\u002FREADME.md` + `docs\u002Fdocumentation_standards.md` + `docs\u002Fprinciples.md`) + Project docs (`docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md` + conditional files)\n- [ ] ln-120-reference-docs-creator invoked -> Output verified: `docs\u002Freference\u002FREADME.md` + directories (adrs\u002F, guides\u002F, manuals\u002F, research\u002F) + justified ADRs\u002FGuides\u002FManuals based on TECH_STACK\n- [ ] ln-130-tasks-docs-creator invoked -> Output verified: `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md`\n- [ ] ln-140-test-docs-creator invoked (if enabled) -> Output verified: `tests\u002FREADME.md`\n- [ ] Each component validated its own output (SCOPE, metadata markers, top sections, Maintenance, POSIX compliance)\n- [ ] Each worker returned normalized `created_files`, `skipped_files`, `quality_inputs`, and `validation_status`\n\n**File Verification Complete:**\n- [ ] All expected files exist (Glob tool used to verify structure)\n- [ ] File sizes listed for user confirmation\n- [ ] Warning displayed if expected files missing\n\n**Global Cleanup Complete (Phase 3):**\n- [ ] 3a: Manifest built from normalized worker outputs\n- [ ] 3b: Shared verifier executed against the manifest\n- [ ] 3c: Bounded repair loop completed; no HIGH\u002FCRITICAL findings remain\n- [ ] 3d: Duplicate sections identified and removed (>80% similarity)\n- [ ] 3d: Links added to canonical locations (principles.md, testing-strategy.md, kanban_board.md)\n- [ ] 3e: Unexpected files reported (advisory, no auto-archive)\n- [ ] 3f: Scattered concepts consolidated to Single Source of Truth (SSoT)\n- [ ] 3g: Internal links validated (broken links fixed, critical links added)\n- [ ] 3h: Final report generated (quality gate summary, counts, lists, actions)\n\n**Summary Displayed (Phase 4):**\n- [ ] All created files listed with sizes\n- [ ] Documentation system features highlighted (SCOPE, metadata markers, Quick Navigation, Agent Entry, Maintenance, README hubs, DAG structure, deduplicated content, validated links)\n- [ ] Docs-quality verifier summary shown (score, repair passes, remaining LOW\u002FMEDIUM warnings)\n- [ ] Next steps recommended (ln-210-epic-coordinator)\n\n**Error Handling (if applicable):**\n- [ ] If any worker failed: User notified which worker failed, error message shown, manual invocation recommended, partial progress listed\n\n**Output:** Complete documentation system (`AGENTS.md` canonical + `CLAUDE.md` `@AGENTS.md` import stub + docs\u002F with README.md, documentation_standards.md, principles.md + optionally tests\u002F) with global cleanup (no duplicates, orphaned files reported, consolidated knowledge, validated cross-links)\n\n---\n\n**Version:** 8.1.0\n**Last Updated:** 2025-01-12\n","> **Paths:** File paths (`references\u002F`, `..\u002Fln-*`) are relative to this skill directory.\n\n**Type:** L1 Top Orchestrator\n**Category:** 1XX Documentation Pipeline\n\n# Documentation Pipeline (Orchestrator)\n\nThis skill orchestrates the creation of a complete documentation system by invoking one L2 coordinator plus 3 L2 workers. The coordinator (ln-110) delegates to 5 L3 workers for project docs; other L2 workers handle reference, tasks, and test domains. Each component validates its own output, and the orchestrator owns the final docs-quality acceptance gate.\n\n## Purpose\n\nTop-level orchestrator that creates a complete project documentation system in one invocation. Chains ln-110 coordinator + ln-120\u002F130\u002F140 workers sequentially, then runs global cleanup (deduplication, orphan reporting, cross-link validation).\n\n## Runtime Contract\n\n**MANDATORY READ:** Load `references\u002Fcoordinator_runtime_contract.md`, `references\u002Fdocs_pipeline_runtime_contract.md`, `references\u002Fdocs_generation_summary_contract.md`\n\nRuntime family: `docs-pipeline-runtime`\n\nIdentifier:\n- `docs-pipeline`\n\nPhases:\n1. `PHASE_0_CONFIG`\n2. `PHASE_1_LEGACY_SCAN`\n3. `PHASE_2_CONFIRMATION`\n4. `PHASE_3_DELEGATE`\n5. `PHASE_4_QUALITY_GATE`\n6. `PHASE_5_CLEANUP`\n7. `PHASE_6_SELF_CHECK`\n\nComponent summary contract:\n- `ln-110`, `ln-120`, `ln-130`, `ln-140` write or return `docs-generation` envelopes\n- `ln-100` consumes those summaries plus docs-quality checkpoints as orchestration SSOT\n\n## Architecture\n\n```\nln-100-documents-pipeline (L1 Top Orchestrator - this skill)\n|- ln-110-project-docs-coordinator (L2 Coordinator)\n|  |- ln-111-root-docs-creator (L3 Worker) -> 5 docs\n|  |- ln-112-project-core-creator (L3 Worker) -> 3 docs\n|  |- ln-113-backend-docs-creator (L3 Worker) -> 2 conditional\n|  |- ln-114-frontend-docs-creator (L3 Worker) -> 1 conditional\n|  `- ln-115-devops-docs-creator (L3 Worker) -> 1 always + 1 conditional\n|- ln-120-reference-docs-creator (L2 Worker)\n|- ln-130-tasks-docs-creator (L2 Worker)\n`- ln-140-test-docs-creator (L2 Worker - optional)\n```\n\n## When to Use This Skill\n\nThis skill should be used when:\n- Start a new IT project and need complete documentation system at once\n- Use automated workflow instead of manually invoking multiple workers\n- Create entire documentation structure (`AGENTS.md` canonical + `CLAUDE.md` import stub -> `docs\u002F`) in one go\n- Prefer orchestrated CREATE path over manual skill chaining\n- Need automatic global cleanup (deduplication, orphaned files, consolidation)\n\n**Alternative**: If you prefer granular control, invoke workers manually:\n1. [ln-110-project-docs-coordinator](..\u002Fln-110-project-docs-coordinator\u002FSKILL.md) - Root + Project docs (coordinates 5 L3 workers)\n2. [ln-120-reference-docs-creator](..\u002Fln-120-reference-docs-creator\u002FSKILL.md) - reference\u002F structure\n3. [ln-130-tasks-docs-creator](..\u002Fln-130-tasks-docs-creator\u002FSKILL.md) - tasks\u002FREADME.md + kanban\n4. [ln-140-test-docs-creator](..\u002Fln-140-test-docs-creator\u002FSKILL.md) - tests\u002FREADME.md (optional)\n\n**MANDATORY READ:** Load `references\u002Fdocs_quality_contract.md`.\n\n**Note**: Each worker validates its own local output in Phase 2\u002F3. The orchestrator still owns the final docs-quality manifest, verification, and repair loop before cleanup can continue.\n\n## Workflow\n\nThe skill follows a 5-phase orchestration workflow: **Legacy Migration (optional)** -> User confirmation -> Invoke coordinator + workers sequentially -> Global cleanup -> Summary.\n\n---\n\n### Phase 0: Source Documentation Cleanup (OPTIONAL)\n\n**Objective**: Detect non-canonical documentation, normalize any useful facts, and remove duplicate documentation paths before generation.\n\n**Trigger**: Runs at pipeline start when the repo already contains documentation outside the canonical layout.\n\n**Process**:\n\n**0a. Non-Canonical Source Detection**:\n- Scan project for non-standard documentation using patterns from `references\u002Flegacy_detection_patterns.md`:\n  - **Root .md files**: `ARCHITECTURE.md`, `REQUIREMENTS.md`, `STACK.md`, `API.md`, `DATABASE.md`, `DEPLOYMENT.md`\n  - **Non-canonical folders**: `documentation\u002F`, `doc\u002F`, `wiki\u002F`, or `docs\u002F` with wrong structure\n  - **README.md sections**: `## Architecture`, `## Tech Stack`, `## Requirements`, etc.\n  - **CONTRIBUTING.md sections**: `## Development`, `## Code Style`, `## Coding Standards`\n- Build `source_manifest`: list of { path, detected_type, target_doc, confidence }\n- If no non-canonical docs are found -> skip to Phase 1\n\n**0b. Fact Extraction**:\n- For each detected source file:\n  - Parse markdown structure (headers, lists, code blocks)\n  - Apply type-specific extractor (**MANDATORY READ:** Load `references\u002Flegacy_detection_patterns.md`):\n    - `architecture_extractor` -> { layers[], components[], diagrams[] }\n    - `requirements_extractor` -> { functional[], non_functional[] }\n    - `tech_stack_extractor` -> { frontend, backend, database, versions }\n    - `principles_extractor` -> { principles[], anti_patterns[] }\n    - `api_spec_extractor` -> { endpoints[], authentication }\n    - `database_schema_extractor` -> { tables[], relationships[] }\n    - `runbook_extractor` -> { prerequisites[], install_steps[], env_vars[] }\n    - `infrastructure_extractor` -> { servers[], domains[], ports[], services[], artifacts{}, cicd{} }\n  - Score content quality (0.0-1.0)\n- Store results in `source_notes`\n\n**0c. User Confirmation**:\n- Display detected non-canonical files:\n  ```\n  Non-Canonical Documentation Detected:\n\n  | File | Type | Confidence | Target |\n  |------|------|------------|--------|\n  | README.md (## Architecture) | architecture | HIGH | docs\u002Fproject\u002Farchitecture.md |\n  | docs\u002FARCHITECTURE.md | architecture | HIGH | docs\u002Fproject\u002Farchitecture.md |\n  | CONTRIBUTING.md (## Development) | principles | MEDIUM | docs\u002Fprinciples.md |\n\n  Cleanup Options:\n  1. NORMALIZE (recommended): Extract facts -> Archive -> Remove duplicate sources\n  2. ARCHIVE ONLY: Backup without extraction\n  3. SKIP: Leave non-canonical docs as-is (may cause duplication)\n\n  Choose option (1\u002F2\u002F3): _\n  ```\n- If user selects \"1\" (NORMALIZE):\n  - Optional: \"Review extracted facts before folding them into the canonical context? (yes\u002Fno)\"\n  - Confirm: \"Proceed with cleanup and archive non-canonical files?\"\n- If user selects \"2\" (ARCHIVE ONLY):\n  - Confirm: \"Archive non-canonical files to .archive\u002F? Content will NOT be normalized.\"\n- If user selects \"3\" (SKIP):\n  - Warn: \"Non-canonical files will remain. This may cause duplication issues.\"\n  - Proceed to Phase 1\n\n**0d. Backup and Archive**:\n- Create `.archive\u002Fsource-docs-{timestamp}\u002F` directory\n- Structure:\n  ```\n  .archive\u002F\n  `- source-docs-YYYY-MM-DD-HHMMSS\u002F\n      |- README_cleanup.md          # Rollback instructions\n      |- original\u002F                  # Exact copies of non-canonical files\n      |  |- README.md\n      |  |- ARCHITECTURE.md\n      |  `- documentation\u002F\n      `- extracted\u002F                 # Extracted facts (for reference)\n          |- architecture_content.md\n          `- principles_content.md\n  ```\n- Copy all detected source files to `original\u002F`\n- Save extracted facts to `extracted\u002F`\n- Generate `README_cleanup.md` with rollback instructions\n\n**0e. Context Normalization**:\n- Build `SOURCE_DOC_NOTES` from extracted facts:\n  ```json\n  {\n    \"SOURCE_DOC_NOTES\": {\n      \"architecture_notes\": { \"sections\": [...], \"diagrams\": [...] },\n      \"requirements_notes\": { \"functional\": [...] },\n      \"principles_notes\": { \"principles\": [...] },\n      \"tech_stack_notes\": { \"frontend\": \"...\", \"backend\": \"...\" },\n      \"api_notes\": { \"endpoints\": [...] },\n      \"database_notes\": { \"tables\": [...] },\n      \"runbook_notes\": { \"install_steps\": [...] },\n      \"infrastructure_notes\": { \"servers\": [...], \"domains\": [...], \"ports\": {} }\n    }\n  }\n  ```\n- Merge extracted facts into the coordinator input as supporting evidence only\n- Workers consume normalized context fields and current source facts directly; there is no legacy-only branch\n- Priority order: **Current source facts + normalized project documentation > template defaults**\n\n**0f. Cleanup (Non-Canonical Files)**:\n- For root-level files (README.md, CONTRIBUTING.md):\n  - Do NOT delete\n  - Remove duplicated sections using Edit tool\n  - Add links to new locations:\n    - `## Architecture` -> replace with link: `[Architecture](docs\u002Fproject\u002Farchitecture.md)`\n    - `## Tech Stack` -> replace with link: `[Tech Stack](docs\u002Fproject\u002Ftech_stack.md)`\n- For standalone non-canonical files (ARCHITECTURE.md, documentation\u002F):\n  - Delete files (already backed up)\n  - Log: \"Deleted: ARCHITECTURE.md (migrated to docs\u002Fproject\u002Farchitecture.md)\"\n- Clean empty non-canonical directories\n\n**Output**: `cleanup_summary` { normalized_count, archived_count, skipped_count, source_doc_notes }\n\n### Phase 1: User Confirmation\n\n**Objective**: Check existing files, explain workflow, and get user approval.\n\n**Process**:\n\n0. **Cleanup Summary** (if Phase 0 ran):\n   - Show: \"Normalized {N} non-canonical documents\"\n   - Show: \"Archived to .archive\u002Fsource-docs-{date}\u002F\"\n   - Show: \"Coordinator input enriched with normalized source notes\"\n\n1. **Pre-flight Check** (scan existing documentation):\n   - Use Glob tool to check all potential files:\n    - **Root docs**: `AGENTS.md`, `CLAUDE.md`, `docs\u002FREADME.md`, `docs\u002Fdocumentation_standards.md`, `docs\u002Fprinciples.md`\n     - **Reference structure** (5 items): `docs\u002Freference\u002FREADME.md`, `docs\u002Freference\u002Fadrs\u002F`, `docs\u002Freference\u002Fguides\u002F`, `docs\u002Freference\u002Fmanuals\u002F`, `docs\u002Freference\u002Fresearch\u002F`\n     - **Tasks docs** (2 files): `docs\u002Ftasks\u002FREADME.md`, `docs\u002Ftasks\u002Fkanban_board.md`\n     - **Project docs** (up to 8 files): `docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md`, `api_spec.md`, `database_schema.md`, `design_guidelines.md`, `infrastructure.md`, `runbook.md`\n     - **Test docs** (2 files): `docs\u002Freference\u002Fguides\u002Ftesting-strategy.md`, `tests\u002FREADME.md`\n   - Count existing vs missing files\n   - Show user summary:\n     ```\n     Documentation Status:\n     Found: X existing files\n     Missing: Y files\n\n     Pipeline will create ONLY missing files.\n     Existing files will be preserved (no overwrites).\n     ```\n\n2. Show user what will be created:\n   - Root + Project documentation (`AGENTS.md` canonical + `CLAUDE.md` import stub + `docs\u002FREADME.md` + `documentation_standards.md` + `principles.md` + `docs\u002Fproject\u002F` via ln-110-project-docs-coordinator)\n   - Reference structure (docs\u002Freference\u002F via ln-120-reference-docs-creator)\n   - Task management docs (docs\u002Ftasks\u002F via ln-130-tasks-docs-creator)\n   - Test documentation (tests\u002F via ln-140-test-docs-creator - optional)\n   - Estimated time: 15-20 minutes with interactive dialog\n\n3. Ask: \"Proceed with creating missing files? (yes\u002Fno)\"\n\n4. Ask: \"Include test documentation (tests\u002FREADME.md)? (yes\u002Fno)\"\n\n**Output**: File scan summary + user approval + test docs preference\n\n---\n\n### Phase 2: Invoke Coordinator + Workers Sequentially\n\n**Objective**: Create complete documentation system by invoking L2 coordinator + 4 L2 workers in order.\n\n**Process** (AUTOMATIC invocations with Skill tool):\n\n**2a. Create Root + Project Documentation**:\n- **Invocation**: `Skill(skill: \"ln-110-project-docs-coordinator\")` -> AUTOMATIC\n- **Input**: Pass normalized source notes from Phase 0 when cleanup was performed\n- **Behavior**: Coordinator gathers context ONCE, then delegates to 5 L3 workers:\n  - ln-111-root-docs-creator -> root docs (AGENTS.md canonical + CLAUDE.md stub + docs\u002FREADME.md + documentation_standards.md + principles.md)\n  - ln-112-project-core-creator -> 3 core docs\n  - ln-113-backend-docs-creator -> 2 conditional\n  - ln-114-frontend-docs-creator -> 1 conditional (if hasFrontend)\n  - ln-115-devops-docs-creator -> 2 docs: 1 always + 1 conditional\n- **Output**: Root docs (`AGENTS.md` canonical + `CLAUDE.md` `@AGENTS.md` import stub + `docs\u002FREADME.md` + `docs\u002Fdocumentation_standards.md` + `docs\u002Fprinciples.md`) + Project docs (`docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md`, `infrastructure.md` + conditional: `api_spec.md`, `database_schema.md`, `design_guidelines.md`, `runbook.md`)\n- **Store**: Save `context_store` from ln-110 result (contains TECH_STACK for ln-120)\n- **Validation**: Each L3 worker validates output (SCOPE, metadata markers, top sections, Maintenance)\n- **Verify**: All documents exist before continuing\n\n**2b. Create Reference Structure + Smart Documents**:\n- **Invocation**: `Skill(skill: \"ln-120-reference-docs-creator\")` -> AUTOMATIC\n- **Input**: Pass `context_store` from ln-110 (TECH_STACK enables smart document creation)\n- **Output**: `docs\u002Freference\u002FREADME.md` + `adrs\u002F`, `guides\u002F`, `manuals\u002F`, `research\u002F` directories + **justified ADRs\u002FGuides\u002FManuals**\n- **Smart Creation**: Creates documents only for nontrivial technology choices (see ln-120 justification rules)\n- **Validation**: ln-120 validates output in Phase 2\u002F3\n- **Verify**: Reference hub exists before continuing\n\n**2c. Create Task Management Docs**:\n- **Invocation**: `Skill(skill: \"ln-130-tasks-docs-creator\")` -> AUTOMATIC\n- **Output**: `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md` (if user provides Linear config)\n- **Validation**: ln-130 validates output in Phase 2\u002F3\n- **Verify**: Tasks README exists before continuing\n\n**2d. Create Test Documentation (Optional)**:\n- **Condition**: If user approved test docs in Phase 1\n- **Invocation**: `Skill(skill: \"ln-140-test-docs-creator\")` -> AUTOMATIC\n- **Output**: `tests\u002FREADME.md` (test documentation with Story-Level Test Task Pattern)\n- **Validation**: ln-140 validates output in Phase 2\u002F3\n- **Skip**: If \"no\" -> can run ln-140-test-docs-creator later manually\n\n**2e. Extract Skills from Documentation (Optional)**:\n- **Condition**: User approved skill extraction in Phase 1, or invoked manually later\n- **Invocation**: `Skill(skill: \"ln-160-docs-skill-extractor\")` -> AUTOMATIC\n- **Input**: All docs created by ln-110 through ln-140\n- **Output**: `.claude\u002Fcommands\u002F*.md` files extracted from procedural documentation sections\n- **Skip**: If not approved -> can run ln-160-docs-skill-extractor later manually\n\n**Output**: Complete documentation system with coordinator + 4 workers completed and validated\n\n## Worker Invocation (MANDATORY)\n\n**Host Skill Invocation:** `Skill(skill: \"...\", args: \"...\")` is mandatory delegation.\n- Claude: call the Skill tool exactly as shown.\n- Codex: if no Skill tool exists, locate the named skill in available skills, read its `SKILL.md`, treat `args` as `$ARGUMENTS`, execute that skill workflow, then return here with its result\u002Fartifact.\n- Do not inline worker logic or mark the worker complete without executing the target skill.\n\n## TodoWrite format (mandatory)\nAdd ALL invocations to todos before starting:\n```\n- Invoke ln-110-project-docs-coordinator (pending)\n- Invoke ln-120-reference-docs-creator (pending)\n- Invoke ln-130-tasks-docs-creator (pending)\n- Invoke ln-140-test-docs-creator (pending)\n- Run Global Cleanup (Phase 3) (pending)\n- Show Summary (Phase 4) (pending)\n```\nMark each as in_progress when starting, completed when worker returns success.\n\n---\n\n### Phase 3: Global Cleanup and Consolidation\n\n**Objective**: Remove duplicates, orphaned files, consolidate knowledge across ALL documentation.\n\n**Trigger**: Only after ALL workers complete Phase 2\u002F3 validation.\n\n**Process**:\n\n**3a. Build docs-quality manifest**\n\nCreate one normalized manifest from worker outputs before any cleanup:\n\n1. Collect `created_files`, `skipped_files`, and `quality_inputs` from ln-110, ln-120, ln-130, and ln-140\n2. Merge `quality_inputs.doc_paths` and `quality_inputs.owners`, deduplicate paths, and fail fast if any worker omitted the normalized return contract\n3. Write the explicit manifest with the shared verifier:\n   ```bash\n   node {skills_repo_root}\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs manifest \\\n     --project-root . \\\n    --files \"AGENTS.md,CLAUDE.md,docs\u002FREADME.md,docs\u002Fproject\u002Frequirements.md\" \\\n     --output docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-manifest.json\n   ```\n4. Keep the manifest as the Single Source of Truth for all Phase 3 quality decisions\n\n**3b. Run centralized docs-quality verifier**\n\nRun the shared verifier against the manifest:\n\n```bash\nnode {skills_repo_root}\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs verify \\\n  --project-root . \\\n  --manifest docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-manifest.json \\\n  --output docs\u002Fproject\u002F.audit\u002Fln-100\u002Fdocs-quality-report.json\n```\n\nVerifier checks come from the shared docs-quality contract\u002Frules and include:\n- SCOPE tags in required docs\n- Maintenance section + markers\n- Forbidden placeholders and leaked template metadata\n- Broken internal links\n- Disallowed code fences\n- Stale inline dates\n- Non-official stack documentation links\n\n**Gate:** No HIGH\u002FCRITICAL findings may remain before Phase 3 cleanup proceeds.\n\n**3c. Bounded repair loop**\n\nIf verifier reports HIGH\u002FCRITICAL findings:\n\n1. **Pass 1 - deterministic inline fixes**:\n   - Add missing SCOPE tags\n   - Add or complete `## Maintenance`\n   - Normalize broken internal links when target is obvious\n   - Refresh stale generated dates\n   - Remove leaked template metadata and unresolved markers\n   - Replace illegal fenced code with tables, commands, or links\n2. **Pass 2 - owner-scoped semantic repair**:\n   - Group remaining findings by `quality_inputs.owners[path]`\n   - Re-invoke only the owning worker with the scoped findings for its files\n   - Do not rerun unrelated workers\n3. Re-run the verifier after each repair pass\n4. Stop after 2 repair iterations total\n5. If any HIGH\u002FCRITICAL findings remain, fail the pipeline instead of emitting low-quality docs\n\nRecord the verifier summary and doc-registry output in the Phase 5 final output.\n\n**3d. Scan for duplicate content**\n\n1. **Read all .md files in docs\u002F**\n   - Use Glob tool: `pattern: \"docs\u002F**\u002F*.md\"`\n   - Store list of all documentation files\n\n2. **Identify duplicate sections:**\n   - For each file:\n     - Read file content\n     - Extract section headers (##, ###)\n     - Extract section content (text between headers)\n   - Compare sections across files:\n     - If 2+ sections have:\n       - Same heading (case-insensitive)\n       - >80% content similarity (simple word overlap check)\n     - Mark as duplicate\n\n3. **Determine canonical version:**\n   - Rules for canonical location:\n     - \"Development Principles\" -> principles.md (always canonical)\n     - \"Testing Strategy\" -> testing-strategy.md (always canonical)\n     - \"Linear Configuration\" -> tasks\u002Fkanban_board.md (always canonical)\n     - For other duplicates: Keep in FIRST file encountered (alphabetical order)\n\n4. **Remove duplicates:**\n   - For each duplicate section:\n     - Use Edit tool to delete from non-canonical files\n     - Use Edit tool to add link to canonical location:\n       ```markdown\n       Canonical source: [Development Principles](..\u002Fprinciples.md#development-principles)\n       ```\n   - Track count of removed duplicates\n\n5. **Log results:**\n   - \"Removed {count} duplicate sections\"\n   - List: \"{section_name} removed from {file} (canonical: {canonical_file})\"\n\n**3e. Report unexpected files (advisory)**\n\n1. **List all .md files in docs\u002F**\n   - Use Glob tool: `pattern: \"docs\u002F**\u002F*.md\"`\n\n2. **Check against expected structure** (files created by workers + user-created reference docs)\n\n3. **Report findings (DO NOT move\u002Fdelete\u002Farchive):**\n   - List unexpected files with advisory message\n   - User decides what to do with them\n   - Log: \"{count} unexpected files found (not in expected structure) -> listed for user review\"\n\n**3f. Consolidate knowledge**\n\n1. **Identify scattered information:**\n   - Known patterns:\n     - Linear config scattered: kanban_board.md + tasks\u002FREADME.md\n     - Development principles scattered: AGENTS.md + principles.md + architecture.md\n     - Testing info scattered: testing-strategy.md + tests\u002FREADME.md + architecture.md\n\n2. **For each scattered concept:**\n   - Determine Single Source of Truth (SSoT):\n     - Linear config -> kanban_board.md\n     - Development principles -> principles.md\n     - Testing strategy -> testing-strategy.md\n\n3. **Update non-SSoT files:**\n   - Use Edit tool to replace duplicate content with link:\n     ```markdown\n     Canonical source: [Linear Configuration](..\u002Ftasks\u002Fkanban_board.md#linear-configuration)\n     ```\n   - Track consolidation count\n\n4. **Log results:**\n   - \"Consolidated {count} scattered concepts\"\n   - List: \"{concept} consolidated to {SSoT_file}\"\n\n**3g. Cross-link validation**\n\n1. **Scan all .md files for internal links:**\n   - For each file:\n     - Read content\n     - Extract all markdown links: `[text](path)`\n     - Filter internal links (relative paths, not http:\u002F\u002F)\n\n2. **Verify link targets exist:**\n   - For each link:\n     - Resolve relative path\n     - Check if target file exists (Glob tool)\n     - If missing: Mark as broken\n\n3. **Fix broken links:**\n   - For each broken link:\n     - If target was archived: Update link to archive path\n     - If target never existed: Remove link (convert to plain text)\n   - Track fix count\n\n4. **Add missing critical links:**\n   - **AGENTS.md -> docs\u002FREADME.md:**\n     - Read AGENTS.md\n     - Check for link to docs\u002FREADME.md\n     - If missing: Add in \"Documentation Hub\" section\n   - **docs\u002FREADME.md -> section READMEs:**\n     - Check for links to project\u002F, reference\u002F, tasks\u002F, tests\u002F READMEs\n     - If missing: Add\n   - Track added links count\n\n5. **Log results:**\n   - \"Fixed {count} broken links\"\n   - \"Added {count} missing critical links\"\n   - List changes\n\n**3h. Final report**\n\n```\nGlobal Cleanup Complete:\n\nStructure:\n- Removed {N} duplicate sections (canonical: principles.md)\n- Found {N} unexpected files (listed for user review)\n- Consolidated {N} scattered concepts\n\nLinks:\n- Fixed {N} broken links\n- Added {N} missing critical links:\n  - list of added links\n```\n\n**Output**: All documentation cleaned up, duplicates removed, unexpected files reported, knowledge consolidated, cross-links validated\n\n---\n\n### Phase 4: Summary and Next Steps\n\n**Objective**: Provide complete overview of created system.\n\n**Process**:\n1. List all created files with sizes:\n   - `AGENTS.md` (canonical project entry point)\n   - `CLAUDE.md` (`@AGENTS.md` import stub for Claude Code)\n   - `docs\u002FREADME.md` (root documentation hub)\n   - `docs\u002Fdocumentation_standards.md` (60 universal requirements)\n   - `docs\u002Fprinciples.md` (11 development principles)\n   - `docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md` + conditional documents (3-7 total)\n   - `docs\u002Freference\u002FREADME.md` (reference hub with empty adrs\u002F, guides\u002F, manuals\u002F, research\u002F directories)\n   - `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md`\n   - `tests\u002FREADME.md` (if created)\n\n2. Show documentation system features:\n   - SCOPE tags (document boundaries defined)\n   - Maintenance sections (update triggers + verification)\n   - README hub (central navigation)\n   - DAG structure (Directed Acyclic Graph navigation)\n   - Living documentation ready\n   - Deduplicated content (canonical sources only)\n   - Validated cross-links (no broken links)\n\n3. Recommend next steps:\n   - \"Review generated documentation (AGENTS.md canonical + CLAUDE.md stub -> docs\u002F)\"\n   - \"Run ln-210-epic-coordinator to decompose scope into Epics\"\n   - \"Share documentation with technical stakeholders\"\n\n4. Summarize the docs-quality gate:\n   - `Verifier score: X\u002F10`\n   - `Repair passes used: 0-2`\n   - `Remaining warnings: list LOW\u002FMEDIUM only`\n\n**Output**: Summary message with file list, verifier status, and recommendations\n\n---\n\n## Complete Output Structure\n\n```\nproject_root\u002F\n|- AGENTS.md                         # Canonical project entry point (map-first root)\n|- CLAUDE.md                         # Derived Anthropic entrypoint\n|- docs\u002F\n|  |- README.md                     # Root documentation hub (general standards)\n|  |- documentation_standards.md    # 60 universal requirements (Claude Code + industry standards)\n|  |- principles.md                 # 11 development principles (Standards First, YAGNI, KISS, DRY, etc.)\n|  |- project\u002F\n|  |  |- requirements.md           # Functional Requirements (NO NFR per project policy)\n|  |  |- architecture.md           # arc42-based architecture with C4 Model\n|  |  |- tech_stack.md             # Technology versions, Docker config\n|  |  |- api_spec.md               # API endpoints (conditional)\n|  |  |- database_schema.md        # Database schema (conditional)\n|  |  |- design_guidelines.md      # UI\u002FUX system (conditional)\n|  |  |- infrastructure.md         # Infrastructure inventory (always)\n|  |  `- runbook.md                # Operations guide (conditional)\n|  |- reference\u002F\n|  |  |- README.md                 # Reference documentation hub (registries)\n|  |  |- adrs\u002F                     # Empty, ready for ADRs\n|  |  |- guides\u002F                   # Empty, ready for guides\n|  |  |- manuals\u002F                  # Empty, ready for manuals\n|  |  `- research\u002F                 # Empty, ready for research\n|  |- tasks\u002F\n|  |  |- README.md                 # Task management system rules\n|  |  `- kanban_board.md           # Linear integration (optional)\n`- tests\u002F\n   `- README.md                    # Test documentation (optional)\n```\n\n---\n\n## Integration with Project Workflow\n\n**Recommended workflow for new projects:**\n\n1. **ln-100-documents-pipeline** (this skill) - Create complete documentation system\n2. **ln-210-epic-coordinator** - Decompose scope into Epics (Linear Projects)\n3. **ln-220-story-coordinator** - Create User Stories for each Epic (automatic decomposition + replan)\n4. **ln-300-task-coordinator** - Break down Stories into implementation tasks (automatic decomposition + replan)\n5. **ln-310-multi-agent-validator** - Verify Stories before development\n6. **ln-400-story-executor** - Orchestrate Story implementation\n7. **Story quality gate** - Review completed Stories\n\n---\n\n## Trade-offs\n\n**Trade-offs:**\n- Less granular control (can't skip coordinator phases)\n- Longer execution time (15-20 minutes)\n- Global cleanup runs even if only one file was created\n\n**When to use manual approach instead:**\n- Need one specific ADR\u002Fguide\u002Fmanual -> use references\u002Ftemplates\u002F + references\u002Fdocumentation_creation.md\n\n---\n\n## Documentation Standards\n\nAll documents created by this pipeline MUST follow these rules:\n\n| Rule | Description | Enforcement |\n|------|-------------|-------------|\n| **NO_CODE Rule** | Documents describe contracts, not implementations | No code blocks >5 lines; use tables\u002FASCII\u002Flinks |\n| **Stack Adaptation** | Links must match project TECH_STACK | .NET -> Microsoft docs, JS -> MDN |\n| **Format Priority** | Tables\u002FASCII > Lists (enumerations only) > Text | Tables for params, config, alternatives |\n\nThese standards are enforced by L3 workers (ln-111-115), ln-120\u002F130\u002F140, and the shared docs-quality gate.\n\n---\n\n## Error Handling\n\nIf any invoked skill fails:\n1. Notify user which skill failed\n2. Show error message from failed skill\n3. Recommend manual invocation for debugging\n4. List already completed steps (partial progress)\n\n---\n\n## Technical Implementation Notes\n\n**Skill Invocation:**\n- Uses **Skill tool** with command parameter\n- Waits for each skill to complete before proceeding\n- Verifies output files exist before moving to next phase\n\n**File Verification:**\n- Uses **Glob** tool to check docs\u002Fproject\u002F structure\n- Lists file sizes for user confirmation\n- Warns if expected files missing\n\n**Global Cleanup:**\n- Uses **Glob** tool to find all .md files\n- Uses **Read** tool to analyze content\n- Uses **Edit** tool to remove duplicates and add links\n- Reports unexpected files (advisory, no auto-archive)\n\n**Docs-Quality Gate:**\n- Uses `references\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs` to build a manifest from worker outputs\n- Uses the shared verifier before cleanup and again after repair passes\n- Fails fast on unresolved HIGH\u002FCRITICAL findings instead of emitting low-quality documentation\n\n**Standards Compliance:**\n- All output follows same standards as underlying skills\n- ISO\u002FIEC\u002FIEEE 29148:2018 (Requirements)\n- ISO\u002FIEC\u002FIEEE 42010:2022 (Architecture)\n- arc42 + C4 Model + Michael Nygard's ADR Format\n\n---\n\n## Critical Rules\n\n- **Idempotent:** Creates only missing files; existing files are preserved without overwrite\n- **Sequential invocation:** Workers must be invoked in order (ln-110 -> ln-120 -> ln-130 -> ln-140); each verified before next\n- **Docs-quality gate mandatory:** Phase 3 must build manifest -> run verifier -> execute bounded repair loop before cleanup continues\n- **Global cleanup mandatory:** Phase 3 (deduplication, orphan reporting, SSoT consolidation, cross-link validation) runs only after docs-quality gate passes\n- **User confirmation required:** Pre-flight check and explicit approval before any file creation\n- **NO_CODE Rule:** All generated documents use tables\u002FASCII\u002Flinks; no code blocks >5 lines\n\n## Phase 5: Meta-Analysis\n\nOptional reference: load `references\u002Fmeta_analysis_protocol.md` only when the user asks for post-run meta-analysis or protocol-formatted run reflection.\n\nSkill type: `planning-coordinator`. When requested, run after all phases complete. Output to chat using the `planning-coordinator` format.\n\n## Reference Files\n\n- Non-canonical source patterns: `references\u002Flegacy_detection_patterns.md`\n- Worker skills: `ln-110-project-docs-coordinator`, `ln-120-reference-docs-creator`, `ln-130-tasks-docs-creator`, `ln-140-test-docs-creator`\n- Shared docs-quality contract: `references\u002Fdocs_quality_contract.md`\n- Shared verifier CLI: `references\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs`\n\n## Definition of Done\n\nBefore completing work, verify ALL checkpoints:\n\n**Source Cleanup (Phase 0 - if applicable):**\n- [ ] Non-canonical documentation patterns applied (Glob + Grep)\n- [ ] Source manifest built: { path, type, confidence, target }\n- [ ] User selected cleanup option (NORMALIZE \u002F ARCHIVE \u002F SKIP)\n- [ ] If NORMALIZE: facts extracted using type-specific extractors\n- [ ] Backup created: `.archive\u002Fsource-docs-{timestamp}\u002Foriginal\u002F`\n- [ ] Extracted facts saved: `.archive\u002Fsource-docs-{timestamp}\u002Fextracted\u002F`\n- [ ] README_cleanup.md generated with rollback instructions\n- [ ] SOURCE_DOC_NOTES prepared for coordinator input\n- [ ] Non-canonical files cleaned up (sections removed from README.md, standalone files deleted)\n\n**User Confirmation (Phase 1):**\n- [ ] Migration summary shown (if Phase 0 ran)\n- [ ] Workflow explained to user (coordinator + 4 workers: ln-110 -> ln-120 -> ln-130 -> ln-140)\n- [ ] User approved: \"Proceed with complete documentation system creation? (yes\u002Fno)\"\n- [ ] Test docs preference captured: \"Include test documentation? (yes\u002Fno)\"\n\n**Coordinator + Workers Invoked Sequentially (Phase 2):**\n- [ ] ln-110-project-docs-coordinator invoked -> Output verified: Root docs (`AGENTS.md` + `CLAUDE.md` + `docs\u002FREADME.md` + `docs\u002Fdocumentation_standards.md` + `docs\u002Fprinciples.md`) + Project docs (`docs\u002Fproject\u002Frequirements.md`, `architecture.md`, `tech_stack.md` + conditional files)\n- [ ] ln-120-reference-docs-creator invoked -> Output verified: `docs\u002Freference\u002FREADME.md` + directories (adrs\u002F, guides\u002F, manuals\u002F, research\u002F) + justified ADRs\u002FGuides\u002FManuals based on TECH_STACK\n- [ ] ln-130-tasks-docs-creator invoked -> Output verified: `docs\u002Ftasks\u002FREADME.md` + optionally `kanban_board.md`\n- [ ] ln-140-test-docs-creator invoked (if enabled) -> Output verified: `tests\u002FREADME.md`\n- [ ] Each component validated its own output (SCOPE, metadata markers, top sections, Maintenance, POSIX compliance)\n- [ ] Each worker returned normalized `created_files`, `skipped_files`, `quality_inputs`, and `validation_status`\n\n**File Verification Complete:**\n- [ ] All expected files exist (Glob tool used to verify structure)\n- [ ] File sizes listed for user confirmation\n- [ ] Warning displayed if expected files missing\n\n**Global Cleanup Complete (Phase 3):**\n- [ ] 3a: Manifest built from normalized worker outputs\n- [ ] 3b: Shared verifier executed against the manifest\n- [ ] 3c: Bounded repair loop completed; no HIGH\u002FCRITICAL findings remain\n- [ ] 3d: Duplicate sections identified and removed (>80% similarity)\n- [ ] 3d: Links added to canonical locations (principles.md, testing-strategy.md, kanban_board.md)\n- [ ] 3e: Unexpected files reported (advisory, no auto-archive)\n- [ ] 3f: Scattered concepts consolidated to Single Source of Truth (SSoT)\n- [ ] 3g: Internal links validated (broken links fixed, critical links added)\n- [ ] 3h: Final report generated (quality gate summary, counts, lists, actions)\n\n**Summary Displayed (Phase 4):**\n- [ ] All created files listed with sizes\n- [ ] Documentation system features highlighted (SCOPE, metadata markers, Quick Navigation, Agent Entry, Maintenance, README hubs, DAG structure, deduplicated content, validated links)\n- [ ] Docs-quality verifier summary shown (score, repair passes, remaining LOW\u002FMEDIUM warnings)\n- [ ] Next steps recommended (ln-210-epic-coordinator)\n\n**Error Handling (if applicable):**\n- [ ] If any worker failed: User notified which worker failed, error message shown, manual invocation recommended, partial progress listed\n\n**Output:** Complete documentation system (`AGENTS.md` canonical + `CLAUDE.md` `@AGENTS.md` import stub + docs\u002F with README.md, documentation_standards.md, principles.md + optionally tests\u002F) with global cleanup (no duplicates, orphaned files reported, consolidated knowledge, validated cross-links)\n\n---\n\n**Version:** 8.1.0\n**Last Updated:** 2025-01-12\n",{"name":5,"license":15,"description":7},"main","fbfb242f793fdf040f3a1a6b100896c188c228c8","_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline",1,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog","https:\u002F\u002Fgithub.com\u002Fvitalikpestov","Listing on crypto exchanges","2026-06-15 22:12:56",{"source":8,"skillName":5,"commands":53,"prompt":63,"zipAvailable":64},[54,57,60],{"tool":55,"command":56},"npx","npx skills add vitalikpestov\u002FSkills-Catalog --skill ln-100-documents-pipeline",{"tool":58,"command":59},"bunx","bunx skills add vitalikpestov\u002FSkills-Catalog --skill ln-100-documents-pipeline",{"tool":61,"command":62},"pnpm","pnpm dlx skills add vitalikpestov\u002FSkills-Catalog --skill ln-100-documents-pipeline","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002FSKILL.md",true,[66,72,76,80,84,88,92,96,100,106,110,114,118,122,126,130],{"path":67,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":70,"sourceHtmlUrl":71},"references\u002Fcoordinator_runtime_contract.md","REFERENCE","参考文档",2707,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fcoordinator_runtime_contract.md",{"path":73,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":74,"sourceHtmlUrl":75},"references\u002Fcoordinator_summary_contract.md",1009,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fcoordinator_summary_contract.md",{"path":77,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":78,"sourceHtmlUrl":79},"references\u002Fdocs_generation_summary_contract.md",535,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fdocs_generation_summary_contract.md",{"path":81,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":82,"sourceHtmlUrl":83},"references\u002Fdocs_pipeline_runtime_contract.md",954,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fdocs_pipeline_runtime_contract.md",{"path":85,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":86,"sourceHtmlUrl":87},"references\u002Fdocs_quality_contract.md",2236,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fdocs_quality_contract.md",{"path":89,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":90,"sourceHtmlUrl":91},"references\u002Fdocumentation_creation.md",4417,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fdocumentation_creation.md",{"path":93,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":94,"sourceHtmlUrl":95},"references\u002Flegacy_detection_patterns.md",12099,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Flegacy_detection_patterns.md",{"path":97,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":98,"sourceHtmlUrl":99},"references\u002Fmeta_analysis_protocol.md",1509,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fmeta_analysis_protocol.md",{"path":101,"resourceType":102,"resourceTypeDesc":103,"sizeBytes":104,"sourceHtmlUrl":105},"references\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs","SCRIPT","脚本",3241,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Fcli.mjs",{"path":107,"resourceType":102,"resourceTypeDesc":103,"sizeBytes":108,"sourceHtmlUrl":109},"references\u002Fscripts\u002Fdocs-quality\u002Flib\u002Fmanifest.mjs",4153,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Flib\u002Fmanifest.mjs",{"path":111,"resourceType":102,"resourceTypeDesc":103,"sizeBytes":112,"sourceHtmlUrl":113},"references\u002Fscripts\u002Fdocs-quality\u002Flib\u002Frules.mjs",2038,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Flib\u002Frules.mjs",{"path":115,"resourceType":102,"resourceTypeDesc":103,"sizeBytes":116,"sourceHtmlUrl":117},"references\u002Fscripts\u002Fdocs-quality\u002Flib\u002Fverify.mjs",12636,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Fscripts\u002Fdocs-quality\u002Flib\u002Fverify.mjs",{"path":119,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":120,"sourceHtmlUrl":121},"references\u002Ftemplates\u002Fadr_template.md",2940,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Ftemplates\u002Fadr_template.md",{"path":123,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":124,"sourceHtmlUrl":125},"references\u002Ftemplates\u002Fguide_template.md",3177,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Ftemplates\u002Fguide_template.md",{"path":127,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":128,"sourceHtmlUrl":129},"references\u002Ftemplates\u002Fmanual_template.md",4692,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Ftemplates\u002Fmanual_template.md",{"path":131,"resourceType":68,"resourceTypeDesc":69,"sizeBytes":132,"sourceHtmlUrl":133},"references\u002Ftemplates\u002Fresearch_template.md",3100,"https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_AI-Automation\u002Fclaude-code-skills-levnikolaevich\u002Fplugins\u002Fdocumentation-pipeline\u002Fskills\u002Fln-100-documents-pipeline\u002Freferences\u002Ftemplates\u002Fresearch_template.md",[135,163,188,205,228,255],{"skillNo":136,"name":137,"nameZh":6,"description":138,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":139,"categories":140,"keywords":141,"publishedAt":162},"01M71V1MC994P553631JZSWVYD","solana-dev","Use when user asks to \"build a Solana dapp\", \"write an Anchor program\", \"create a token\", \"debug Solana errors\", \"set up wallet connection\", \"test my Solana program\", \"deploy to devnet\", or \"explain Solana concepts\" (rent, accounts, PDAs, CPIs, etc.). End-to-end Solana development playbook covering wallet connection, Anchor\u002FPinocchio programs, Codama client generation, LiteSVM\u002FMollusk\u002FSurfpool testing, and security checklists. Integrates with the Solana MCP server for live documentation search. Prefers framework-kit (@solana\u002Fclient + @solana\u002Freact-hooks) for UI, wallet-standard-first connection (incl. ConnectorKit), @solana\u002Fkit for client\u002FRPC code, and @solana\u002Fweb3-compat for legacy boundaries.","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Web3\u002Fsolana-dev\u002Fskill\u002FSKILL.md",[],[142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161],"dev","solana dev","solana","Wallet","search","testing","solana cli","kit","MCP","web3","react","create","server","write","playbook","live","security","ui","concepts","toolchain","2026-11-10 13:02:02",{"skillNo":164,"name":165,"nameZh":6,"description":166,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":167,"categories":168,"keywords":169,"publishedAt":162},"01M71TYQPHE2YGKTT7DG9QCW3K","generating-trading-signals","Generate trading signals using technical indicators (RSI, MACD, Bollinger Bands, etc.).\nCombines multiple indicators into composite signals with confidence scores.\nUse when analyzing assets for trading opportunities or checking technical indicators.\nTrigger with phrases like \"get trading signals\", \"check indicators\", \"analyze for entry\",\n\"scan for opportunities\", \"generate buy\u002Fsell signals\", or \"technical analysis\".","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Trading-Finance\u002Fgenerating-trading-signals\u002FSKILL.md",[],[170,171,172,173,174,175,176,177,178,179,180,181,27,37,182,183,184,185,186,187],"generating trading signals","signals","trading signals","trading","get","technical indicators","for","scan","rsi","trigger","python","technical","Bash","analysis","code","io","check","analyze",{"skillNo":189,"name":190,"nameZh":6,"description":191,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":192,"categories":193,"keywords":194,"publishedAt":162},"01M71TY4CR3GKGQ3M12X9WN95Y","prediction-monitor","Prediction Monitor - Auto-activating skill for ML Deployment.\nTriggers on: prediction monitor, prediction monitor\nPart of the ML Deployment skill category.","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Trading-Finance\u002FAI Predictions\u002Fprediction-monitor\u002FSKILL.md",[],[195,196,197,176,198,199,155,200,201,202,203,204,182],"prediction","monitor","prediction monitor","deployment","read","edit","triggers","grep","auto","ml",{"skillNo":206,"name":207,"nameZh":6,"description":208,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":209,"categories":210,"keywords":211,"publishedAt":162},"01M71TXD9MYXZC39HCPP909HTZ","strategy-advisor","High-level strategic thinking and business decision guidance for planning and direction-setting.\nUse when: making strategic decisions, evaluating business options, setting direction, analyzing\ntrade-offs, or when user mentions strategy, business planning, competitive analysis, or long-term planning.","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Product-Apps\u002Fstrategy-advisor\u002FSKILL.md",[],[212,213,214,215,216,217,218,219,220,176,221,222,223,27,224,225,37,226,183,227],"strategy advisor","strategy","advisor","competitive","setting","thinking","planning","direction","trade-offs","long","decision","strategic","business","apps","decisions","trade",{"skillNo":229,"name":230,"nameZh":6,"description":231,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":232,"sourceHtmlUrl":233,"categories":234,"keywords":235,"publishedAt":162},"01M71TWHBT2R1P1FNWTW67ZREP","app-paywall-pilot","Design, audit, debug, and implement App Store-compliant mobile paywalls, subscription flows, pricing screens, trials, offers, feature gates, and subscription lifecycle UX. Use when the user asks to audit my paywall, fix App Store 3.1.2 rejection, improve trial-to-paid, choose plans\u002Fprices\u002Ftrials, review RevenueCat\u002FAdapty\u002FApphud\u002FSuperwall setup, calculate LTV\u002FROAS, or build paywall implementation.","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Product-Apps\u002Ffrom-dosesync\u002Fapp-paywall-pilot\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Product-Apps\u002Ffrom-dosesync\u002Fapp-paywall-pilot\u002FSKILL.md",[],[236,237,238,239,240,241,242,243,244,245,246,247,37,248,249,250,251,252,253,254],"app","paywall","app paywall pilot","paid","paywalls","prices","choose","flows","fix","improve","design","app store","review","audit","ux","subscription","mobile","my","calculate",{"skillNo":256,"name":257,"nameZh":6,"description":258,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":259,"licenseFileUrl":260,"sourceHtmlUrl":261,"categories":262,"keywords":263,"publishedAt":162},"01M71TWET8GFKEB7ZHJPMQX29V","figma","Use the Figma MCP server to fetch design context, screenshots, variables, and assets from Figma, and to translate Figma nodes into production code. Trigger when a task involves Figma URLs, node IDs, design-to-code implementation, or Figma MCP setup and troubleshooting.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Product-Apps\u002Ffigma\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fvitalikpestov\u002FSkills-Catalog\u002Fblob\u002Fmain\u002F_Product-Apps\u002Ffigma\u002FSKILL.md",[],[257,264,265,266,267,179,246,150,27,37,268,269,184,270,154,271,272,273,274,275],"fetch","ids","mcp setup","translate","mcp server","Variables","task","Nodes","figma mcp","code implementation","node","assets"]