# yongxin-yang/spec-agent-prompt-my architecture

> Architecture diagram of the GitHub repository yongxin-yang/spec-agent-prompt-my, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/yongxin-yang/spec-agent-prompt-my
- Repository: https://github.com/yongxin-yang/spec-agent-prompt-my

## Overview

This repository is a lightweight Document-Driven Development (DDD) framework: it provides durable project knowledge, task-specific specification templates, AI-agent guidance, and structural checks. The documented workflow moves from research and Docus updates through Specs, implementation, tests, and documentation updates. The tree supports concrete templates, agents, and structure-check scripts; the README describes broader workflow stages, but sampled source does not establish runtime orchestration or semantic consistency checking, so those links are not depicted as implemented integrations.

Main entry points: [`constitutions`](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/constitutions) (Project principles), [`.docusdd/scripts`](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/scripts) (Structure checks), [`.docusdd/templates`](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/templates) (Spec templates), [`.github/agents/DDD-implementor.agent.md`](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-implementor.agent.md) (Implementor)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_knowledge["Docus knowledge"]
  node_constitutions["Project principles"]
  node_structures["System structure"]
  node_file_guidance["File guidance"]
  node_readme["DDD workflow<br/>[README.md]"]
end

subgraph group_specs["Specs workflow"]
  node_spec_templates["Spec templates<br/>[templates]"]
  node_quickstart["Quickstart<br/>[quickstart.md]"]
end

subgraph group_agents["AI guidance"]
  node_constitution_agent["Constitution builder"]
  node_explainer_agent["Requirement explainer"]
  node_implementor_agent["Implementor"]
end

subgraph group_checks["Structure checks"]
  node_structure_scripts["Structure checks<br/>[scripts]"]
  node_code_check["Code structure check"]
  node_docus_check["Docus structure check"]
  node_spec_check["Specs structure check"]
end

node_developer(("Developer"))
node_research["Research"]
node_project_code["Project code"]
node_project_tests["Project tests"]

node_developer -->|"investigates"| node_research
node_research -->|"informs updates"| node_constitutions
node_developer -->|"maintains"| node_constitutions
node_developer -->|"maintains"| node_structures
node_developer -->|"documents files"| node_file_guidance
node_constitutions -->|"rules propagate"| node_spec_templates
node_constitutions -->|"rules propagate"| node_constitution_agent
node_constitutions -->|"rules propagate"| node_readme
node_constitutions -->|"rules propagate"| node_quickstart
node_developer -->|"plans work with"| node_spec_templates
node_spec_templates -->|"guides requirements"| node_explainer_agent
node_spec_templates -->|"guides tasks"| node_implementor_agent
node_implementor_agent -->|"generates implementation"| node_project_code
node_implementor_agent -->|"generates tests"| node_project_tests
node_project_code -->|"is verified by"| node_project_tests
node_developer -->|"runs checks"| node_structure_scripts
node_structure_scripts -->|"includes"| node_code_check
node_structure_scripts -->|"includes"| node_docus_check
node_structure_scripts -->|"includes"| node_spec_check
node_developer -->|"updates knowledge"| node_constitutions

click node_constitutions "https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/constitutions"
click node_structures "https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/structures"
click node_file_guidance "https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/constitutions"
click node_spec_templates "https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/templates"
click node_quickstart "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/quickstart.md"
click node_constitution_agent "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-constitution-builder.agent.md"
click node_explainer_agent "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-require-explainer.agent.md"
click node_implementor_agent "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-implementor.agent.md"
click node_structure_scripts "https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/scripts"
click node_code_check "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_codefile_structure.ps1"
click node_docus_check "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_docus_structure.ps1"
click node_spec_check "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_specs_structure.ps1"
click node_readme "https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/README.md"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_constitutions,node_structures,node_file_guidance,node_readme toneBlue
class node_spec_templates,node_quickstart toneAmber
class node_constitution_agent,node_explainer_agent,node_implementor_agent toneMint
class node_structure_scripts,node_code_check,node_docus_check,node_spec_check toneRose
class node_developer,node_research,node_project_code,node_project_tests toneIndigo
```

## Components

### Docus knowledge

- [Project principles](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/constitutions): `constitutions`
- [System structure](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/structures): `structures`
- [File guidance](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/constitutions): `constitutions`
- [DDD workflow](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/README.md): `README.md`

### Specs workflow

- [Spec templates](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/templates): `.docusdd/templates`
- [Quickstart](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/quickstart.md): `quickstart.md`

### AI guidance

- [Constitution builder](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-constitution-builder.agent.md): `.github/agents/DDD-constitution-builder.agent.md`
- [Requirement explainer](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-require-explainer.agent.md): `.github/agents/DDD-require-explainer.agent.md`
- [Implementor](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.github/agents/DDD-implementor.agent.md): `.github/agents/DDD-implementor.agent.md`

### Structure checks

- [Structure checks](https://github.com/yongxin-yang/spec-agent-prompt-my/tree/master/.docusdd/scripts): `.docusdd/scripts`
- [Code structure check](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_codefile_structure.ps1): `.docusdd/scripts/check_codefile_structure.ps1`
- [Docus structure check](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_docus_structure.ps1): `.docusdd/scripts/check_docus_structure.ps1`
- [Specs structure check](https://github.com/yongxin-yang/spec-agent-prompt-my/blob/master/.docusdd/scripts/check_specs_structure.ps1): `.docusdd/scripts/check_specs_structure.ps1`

### Other components

- **Developer**
- **Research**
- **Project code**
- **Project tests**

## Connections

- Developer → Research: investigates
- Research → Project principles: informs updates
- Developer → Project principles: maintains
- Developer → System structure: maintains
- Developer → File guidance: documents files
- Project principles → Spec templates: rules propagate
- Project principles → Constitution builder: rules propagate
- Project principles → DDD workflow: rules propagate
- Project principles → Quickstart: rules propagate
- Developer → Spec templates: plans work with
- Spec templates → Requirement explainer: guides requirements
- Spec templates → Implementor: guides tasks
- Implementor → Project code: generates implementation
- Implementor → Project tests: generates tests
- Project code → Project tests: is verified by
- Developer → Structure checks: runs checks
- Structure checks → Code structure check: includes
- Structure checks → Docus structure check: includes
- Structure checks → Specs structure check: includes
- Developer → Project principles: updates knowledge
