Platform Notes
- Optional helper plugins may help in some environments, but they must not be treated as required for this skill.
Doc Architect
Acknowledgement: Shared by Peter Bamuhigire, techguypeter.com, +256 784 464178.
Use When
- Generate Triple-Layer AGENTS.md documentation by scanning a project for its tech stack, data directory, and planning directory. Use when the user asks to standardize project documentation, generate agent files, or create AGENTS.md guides.
Evidence Produced
| Category |
Artifact |
Format |
Example |
| Release evidence |
Triple-Layer AGENTS.md output |
Generated AGENTS.md covering project tech stack, data directory, and planning directory layers |
AGENTS.md |
References
- Use the
references/ directory for deep detail after reading the core workflow below.
- Use the
templates/ directory when the task needs a structured deliverable.
- Use the
protocols/ directory for formal execution order or handoff rules.
Design and generate a portable Triple-Layer AGENTS.md documentation set that reflects the project’s real structure and constraints.
Modularize Instructions (Token Economy): Avoid consolidating all AI/dev guidance into a single AGENTS.md. Prefer smaller, focused docs (e.g., docs/setup.md, docs/api.md, docs/workflows.md) and reference them only when needed.
Documentation Standards (MANDATORY): ALL generated markdown files must follow strict formatting rules:
- 500-line hard limit - no exceptions for any .md file
- Two-tier structure: High-level TOC (Tier 1) + Deep dive docs (Tier 2)
- Smart subdirectory grouping for related documentation
- See
doc-standards.md for complete requirements
Core Outcome
Produce three aligned AGENTS.md files:
- Root AGENTS.md: Project identity, tech stack, global standards
- Data AGENTS.md: Data integrity rules and schema governance
- Planning AGENTS.md: Spec-driven development workflow
Trigger Phrases
The skill should activate when the user asks to:
- Standardize project documentation
- Generate agent files
Standard Operating Procedure (SOP)
Scan the workspace
- Inspect the root for identifiers (README, PROJECT_BRIEF, TECH_STACK, ARCHITECTURE, Codex, package.json, composer.json, *.sln, pyproject.toml).
- Locate likely data directories (database/, schema/, migrations/, sql/, db/).
- Locate planning/documentation directories (docs/, docs/plans/, planning/, specs/).
- Identify module/area entry points (menus, docs, feature folders) to group specs.
- Note template conventions (public/ as web root, per-panel includes, API outside public).
Identify the environment
- Determine primary language (PHP/C#/Python or other).
- Determine DB type (MySQL/PostgreSQL/SQLite/SQL Server/other).
- Determine deployment environment (Docker/Kubernetes/shared hosting/cloud).
Set up plan grouping (first-time)
- Create
docs/plans/<module>/ subdirectories for each discovered module/area.
- Update
docs/plans/AGENTS.md with the current module list.
- Create or update
docs/plans/INDEX.md as the master plan status index.
- Ensure the index includes status, urgency, last implementation date, and last modification date.
- Keep
docs/plans/AGENTS.md updated whenever plans are added or their status changes.
- Maintain a folder map at the top of
docs/plans/AGENTS.md and update it when requested.
- Note that developers can add new folders and update the list manually.
Generate Triple-Layer docs
- Use the templates in templates/root-agents.md.template, templates/data-agents.md.template, and templates/plan-agents.md.template.
- Populate with real findings and pull constraints from references/logic-library.md as needed.
- Create files at:
- Root: AGENTS.md at project root
- Data: database/schema/AGENTS.md (or best-fit schema directory)
- Planning: docs/plans/AGENTS.md (or best-fit planning directory)
Bundled Resources
- protocols/workflow.md: 3-step workflow used during generation
- templates/root-agents.md.template: Root AGENTS.md template
- templates/data-agents.md.template: Data AGENTS.md template
- templates/plan-agents.md.template: Planning AGENTS.md template
- references/logic-library.md: Domain constraint library for reuse
Common Pitfalls
- Do not invent tech stacks. Only infer from files found in the workspace.
- Do not place AGENTS.md in arbitrary locations; follow the best-fit paths above.
- Do not include contradictory rules across the three layers.
Quick Example
If a project uses Laravel + MySQL with docs/plans and database/schema:
- Root: AGENTS.md → PHP/Laravel, MySQL, deployment standards
- Data: database/schema/AGENTS.md → referential integrity, no-delete rules
- Plans: docs/plans/AGENTS.md → spec.md format and workflow steps
Cross-References to SDLC Skills
When generating AGENTS.md files, be aware of the complete SDLC documentation ecosystem:
SDLC Documentation Skills
| Skill |
Phase |
Documents Generated |
When to Reference |
sdlc-planning |
Planning |
Vision, SDP, SRS, SCMP, QA Plan, Risk Plan, Feasibility |
When plans directory contains SDLC planning docs |
sdlc-design |
Design |
SDD, Tech Spec, ICD, Database Design, API Docs, Code Standards |
When referencing architecture and design decisions |
sdlc-testing |
Testing |
Test Plan, Test Cases, V&V Plan, Test Report, Peer Reviews |
When referencing testing and quality standards |
sdlc-user-deploy |
Delivery |
User Manual, Ops Guide, Training, Release Notes, Maintenance, README |
When referencing deployment and user documentation |
Related Documentation Skills
| Skill |
Purpose |
Relationship |
project-requirements |
Raw requirements interview |
Input source for SDLC planning docs |
feature-planning |
Feature-level specs + implementation plans |
Stored in docs/plans/ (planning directory) |
manual-guide |
End-user manuals and guides |
Stored in /manuals/ (separate from AGENTS.md) |
update-Codex-documentation |
Keep project docs (README, AGENTS.md) updated |
Maintains project-level docs after changes |
SDLC Output Directory Structure
When scanning for documentation, expect this structure in projects using SDLC skills:
docs/
├── planning/ # sdlc-planning output (7 docs)
├── design/ # sdlc-design output (6 docs)
├── testing/ # sdlc-testing output (5 docs)
├── user-deploy/ # sdlc-user-deploy output (6 docs)
├── plans/ # feature-planning output
│ ├── AGENTS.md # Plans directory index (doc-architect manages this)
│ ├── INDEX.md # Plan status tracker
│ └── specs/ # Feature specifications
└── project-requirements/ # project-requirements output
Integration Rule: When generating the Planning AGENTS.md (docs/plans/AGENTS.md), include references to any SDLC documentation directories that exist alongside the plans directory.
Decision Rules
| Condition |
Action |
| Existing guidance is accurate |
Preserve and extend it |
| Repository fact is uncertain |
Inspect source files first |
| Rule belongs to one subtree |
Put it in the nearest scoped file |
Capability Contract
Read and search are required. Editing requires authorisation.
Degraded Mode
Fallback: without repository access, return a template and confirmation questions instead of inventing details.
Domain Anti-Patterns
- Repeating the same long rule at every layer.
- Inferring the stack only from directory names.
- Overwriting authored constraints.
- Linking files that do not exist.
- Putting specialist doctrine in the root navigation file.
Inputs
| Artefact |
Required? |
Purpose |
| Audience, decisions, source material, document set, and maintenance owner |
yes |
Design information architecture |
Outputs
- Produce document architecture, ownership map, navigation, templates, and maintenance rules.
1---2name: doc-architect3description: Use when generating or repairing layered AGENTS.md project guidance from verified repository structure, technology, data, and planning conventions.4---56## Platform Notes78- Optional helper plugins may help in some environments, but they must not be treated as required for this skill.910# Doc Architect11Acknowledgement: Shared by Peter Bamuhigire, techguypeter.com, +256 784 464178.1213<!-- dual-compat-start -->14## Use When1516- Generate Triple-Layer AGENTS.md documentation by scanning a project for its tech stack, data directory, and planning directory. Use when the user asks to standardize project documentation, generate agent files, or create AGENTS.md guides.1718## Evidence Produced1920| Category | Artifact | Format | Example |21|----------|----------|--------|---------|22| Release evidence | Triple-Layer AGENTS.md output | Generated AGENTS.md covering project tech stack, data directory, and planning directory layers | `AGENTS.md` |2324## References2526- Use the `references/` directory for deep detail after reading the core workflow below.27- Use the `templates/` directory when the task needs a structured deliverable.28- Use the `protocols/` directory for formal execution order or handoff rules.29<!-- dual-compat-end -->30Design and generate a portable Triple-Layer AGENTS.md documentation set that reflects the project’s real structure and constraints.3132**Modularize Instructions (Token Economy):** Avoid consolidating all AI/dev guidance into a single AGENTS.md. Prefer smaller, focused docs (e.g., docs/setup.md, docs/api.md, docs/workflows.md) and reference them only when needed.3334**Documentation Standards (MANDATORY):** ALL generated markdown files must follow strict formatting rules:35- **500-line hard limit** - no exceptions for any .md file36- **Two-tier structure**: High-level TOC (Tier 1) + Deep dive docs (Tier 2)37- **Smart subdirectory grouping** for related documentation38- **See `doc-standards.md` for complete requirements**3940## Core Outcome4142Produce three aligned AGENTS.md files:4344- **Root AGENTS.md**: Project identity, tech stack, global standards45- **Data AGENTS.md**: Data integrity rules and schema governance46- **Planning AGENTS.md**: Spec-driven development workflow4748## Trigger Phrases4950The skill should activate when the user asks to:5152- Standardize project documentation53- Generate agent files5455## Standard Operating Procedure (SOP)56571. **Scan the workspace**58 - Inspect the root for identifiers (README, PROJECT_BRIEF, TECH_STACK, ARCHITECTURE, Codex, package.json, composer.json, \*.sln, pyproject.toml).59 - Locate likely data directories (database/, schema/, migrations/, sql/, db/).60 - Locate planning/documentation directories (docs/, docs/plans/, planning/, specs/).61 - Identify module/area entry points (menus, docs, feature folders) to group specs.62 - Note template conventions (public/ as web root, per-panel includes, API outside public).63642. **Identify the environment**65 - Determine primary language (PHP/C#/Python or other).66 - Determine DB type (MySQL/PostgreSQL/SQLite/SQL Server/other).67 - Determine deployment environment (Docker/Kubernetes/shared hosting/cloud).68693. **Set up plan grouping (first-time)**70 - Create `docs/plans/<module>/` subdirectories for each discovered module/area.71 - Update `docs/plans/AGENTS.md` with the current module list.72 - Create or update `docs/plans/INDEX.md` as the master plan status index.73 - Ensure the index includes status, urgency, last implementation date, and last modification date.74 - Keep `docs/plans/AGENTS.md` updated whenever plans are added or their status changes.75 - Maintain a folder map at the top of `docs/plans/AGENTS.md` and update it when requested.76 - Note that developers can add new folders and update the list manually.77784. **Generate Triple-Layer docs**79 - Use the templates in [templates/root-agents.md.template](templates/root-agents.md.template), [templates/data-agents.md.template](templates/data-agents.md.template), and [templates/plan-agents.md.template](templates/plan-agents.md.template).80 - Populate with real findings and pull constraints from [references/logic-library.md](references/logic-library.md) as needed.81 - Create files at:82 - **Root**: AGENTS.md at project root83 - **Data**: database/schema/AGENTS.md (or best-fit schema directory)84 - **Planning**: docs/plans/AGENTS.md (or best-fit planning directory)8586## Bundled Resources8788- [protocols/workflow.md](protocols/workflow.md): 3-step workflow used during generation89- [templates/root-agents.md.template](templates/root-agents.md.template): Root AGENTS.md template90- [templates/data-agents.md.template](templates/data-agents.md.template): Data AGENTS.md template91- [templates/plan-agents.md.template](templates/plan-agents.md.template): Planning AGENTS.md template92- [references/logic-library.md](references/logic-library.md): Domain constraint library for reuse9394## Common Pitfalls9596- Do not invent tech stacks. Only infer from files found in the workspace.97- Do not place AGENTS.md in arbitrary locations; follow the best-fit paths above.98- Do not include contradictory rules across the three layers.99100## Quick Example101102If a project uses Laravel + MySQL with docs/plans and database/schema:103104- Root: AGENTS.md → PHP/Laravel, MySQL, deployment standards105- Data: database/schema/AGENTS.md → referential integrity, no-delete rules106- Plans: docs/plans/AGENTS.md → spec.md format and workflow steps107108## Cross-References to SDLC Skills109110When generating AGENTS.md files, be aware of the complete SDLC documentation ecosystem:111112### SDLC Documentation Skills113114| Skill | Phase | Documents Generated | When to Reference |115|-------|-------|--------------------|--------------------|116| `sdlc-planning` | Planning | Vision, SDP, SRS, SCMP, QA Plan, Risk Plan, Feasibility | When plans directory contains SDLC planning docs |117| `sdlc-design` | Design | SDD, Tech Spec, ICD, Database Design, API Docs, Code Standards | When referencing architecture and design decisions |118| `sdlc-testing` | Testing | Test Plan, Test Cases, V&V Plan, Test Report, Peer Reviews | When referencing testing and quality standards |119| `sdlc-user-deploy` | Delivery | User Manual, Ops Guide, Training, Release Notes, Maintenance, README | When referencing deployment and user documentation |120121### Related Documentation Skills122123| Skill | Purpose | Relationship |124|-------|---------|-------------|125| `project-requirements` | Raw requirements interview | Input source for SDLC planning docs |126| `feature-planning` | Feature-level specs + implementation plans | Stored in `docs/plans/` (planning directory) |127| `manual-guide` | End-user manuals and guides | Stored in `/manuals/` (separate from AGENTS.md) |128| `update-Codex-documentation` | Keep project docs (README, AGENTS.md) updated | Maintains project-level docs after changes |129130### SDLC Output Directory Structure131132When scanning for documentation, expect this structure in projects using SDLC skills:133134```135docs/136├── planning/ # sdlc-planning output (7 docs)137├── design/ # sdlc-design output (6 docs)138├── testing/ # sdlc-testing output (5 docs)139├── user-deploy/ # sdlc-user-deploy output (6 docs)140├── plans/ # feature-planning output141│ ├── AGENTS.md # Plans directory index (doc-architect manages this)142│ ├── INDEX.md # Plan status tracker143│ └── specs/ # Feature specifications144└── project-requirements/ # project-requirements output145```146147**Integration Rule:** When generating the Planning AGENTS.md (`docs/plans/AGENTS.md`), include references to any SDLC documentation directories that exist alongside the plans directory.148149## Decision Rules150151| Condition | Action |152|---|---|153| Existing guidance is accurate | Preserve and extend it |154| Repository fact is uncertain | Inspect source files first |155| Rule belongs to one subtree | Put it in the nearest scoped file |156157## Capability Contract158159Read and search are required. Editing requires authorisation.160161## Degraded Mode162163Fallback: without repository access, return a template and confirmation questions instead of inventing details.164165## Domain Anti-Patterns166167- Repeating the same long rule at every layer.168- Inferring the stack only from directory names.169- Overwriting authored constraints.170- Linking files that do not exist.171- Putting specialist doctrine in the root navigation file.172## Inputs173| Artefact | Required? | Purpose |174|---|---|---|175| Audience, decisions, source material, document set, and maintenance owner | yes | Design information architecture |176## Outputs177- Produce document architecture, ownership map, navigation, templates, and maintenance rules.