devflow-file-standards
Dimon94/cc-devflow๐ One-command requirement development flow for Claude Code - Complete workflow system with sub-agents, quality gates, and intelligent automation
SKILL.md
name: devflow-file-standards description: File naming conventions, directory structure, and YAML frontmatter standards for CC-DevFlow. Consolidates shared conventions from all agents.
DevFlow File Standards
Purpose
Consolidate file naming, directory structure, and format conventions that are shared across multiple agents and commands. This skill does NOT duplicate agent-specific standards.
Requirement IDs
Format
REQ-\d{3} # e.g., REQ-001, REQ-042, REQ-123
Usage
- Flow commands: All
/flow-*commands accept REQ-ID as argument - Git branches:
feature/REQ-XXX-{slug-title} - Directory paths:
devflow/requirements/REQ-XXX/ - Status tracking:
orchestration_status.jsoncontainsreqIdfield
Source
- Enforced by: All 13 agents
- Validated by:
.claude/scripts/check-prerequisites.sh
Task IDs
Format
T\d{3} # e.g., T001, T042, T123
Usage in TASKS.md
- [ ] **T001** [P] Task description
- [ ] **T010** [US1] User story 1 task
Labels
[P]: Parallel execution possible[US#]: User story number (e.g., [US1], [US2])
Source
- Generated by: planner agent
- Format defined in:
.claude/docs/templates/TASKS_TEMPLATE.md
Directory Structure
Requirements
devflow/requirements/REQ-XXX/
โโโ research/ # /flow-init ่พๅบ
โ โโโ research.md # consolidate-research.sh ็ๆ
โ โโโ tasks.json # generate-research-tasks.sh ็ๆ
โ โโโ internal/
โ โ โโโ codebase-overview.md
โ โโโ mcp/ # MCP ๆๅกๅจ่ฐๆฅ๏ผๅฏ้๏ผ
โ โโโ codebase-tech-analysis.md # /flow-tech ่พๅบ
โโโ PRD.md # /flow-prd ่พๅบ (prd-writer agent)
โโโ TECH_DESIGN.md # /flow-tech ่พๅบ (tech-architect agent)
โโโ data-model.md # /flow-tech ่พๅบ (extract-data-model.sh)
โโโ contracts/ # /flow-tech ่พๅบ (export-contracts.sh)
โ โโโ api-users.yaml # OpenAPI contracts
โ โโโ api-auth.yaml
โโโ quickstart.md # /flow-tech ่พๅบ (generate-quickstart.sh)
โโโ UI_PROTOTYPE.html # /flow-ui ่พๅบ (ui-designer agent, ๅฏ้)
โโโ EPIC.md # /flow-epic ่พๅบ (planner agent)
โโโ TASKS.md # /flow-epic ่พๅบ (planner agent)
โโโ reviews/ # /flow-qa ่พๅบ
โ โโโ TEST_PLAN.md # qa-tester agent
โ โโโ TEST_REPORT.md # qa-tester agent
โ โโโ SECURITY_REPORT.md # security-reviewer agent
โโโ EXECUTION_LOG.md # ไบไปถๆฅๅฟ (ๆๆ flow ๅฝไปค่ฟฝๅ )
โโโ orchestration_status.json # ็ถๆ่ท่ธช (ๆๆ flow ๅฝไปคๆดๆฐ)
โโโ README.md # ๅทฅไฝๆตๆๅ
### Bugs
devflow/bugs/BUG-XXX/ โโโ BUG_ANALYSIS.md # /flow-fix ่พๅบ (bug-analyzer agent) โโโ PLAN.md # /flow-fix ่พๅบ (planner agent) โโโ TASKS.md # /flow-fix ่พๅบ (planner agent) โโโ EXECUTION_LOG.md โโโ status.json # ็ฑปไผผ orchestration_status.json
### Source
- Created by: `.claude/scripts/create-requirement.sh`
- Template: `.claude/docs/templates/` ็ฎๅฝ
- Enforced by: All flow commands
## YAML Frontmatter
### Document Types
#### PRD.md
```yaml
---
reqId: REQ-123
title: User Authentication
version: 1.0.0
createdAt: 2025-10-31T12:34:56Z
updatedAt: 2025-10-31T15:20:30Z
status: approved
author: prd-writer agent
---
TECH_DESIGN.md
---
reqId: REQ-123
version: 1.0.0
architecture: Microservices
techStack:
- Node.js
- PostgreSQL
- Redis
createdAt: 2025-10-31T14:10:00Z
author: tech-architect agent
---
EPIC.md
---
reqId: REQ-123
title: User Authentication Epic
version: 1.0.0
estimatedEffort: 5 days
createdAt: 2025-10-31T16:00:00Z
author: planner agent
---
TASKS.md
---
reqId: REQ-123
totalTasks: 25
completedTasks: 0
version: 1.0.0
createdAt: 2025-10-31T16:30:00Z
updatedAt: 2025-10-31T16:30:00Z
author: planner agent
---
Source
- Enforced by: prd-writer, tech-architect, planner agents
- Parsed by:
.claude/scripts/check-prerequisites.sh,.claude/scripts/generate-status-report.sh
orchestration_status.json
Structure (Requirements)
{
"reqId": "REQ-123",
"title": "User Authentication",
"status": "initialized",
"phase": "planning",
"phase0_complete": false,
"phase1_complete": false,
"completedSteps": [],
"createdAt": "2025-10-31T12:34:56Z",
"updatedAt": "2025-10-31T12:34:56Z"
}
Status Values
initialized โ /flow-init ๅฎๆ
prd_generation_in_progress โ /flow-prd ๆง่กไธญ
prd_generation_failed โ /flow-prd ๅคฑ่ดฅ๏ผๅฏ้่ฏ๏ผ
prd_complete โ /flow-prd ๅฎๆ
tech_design_in_progress โ /flow-tech ๆง่กไธญ
tech_design_failed โ /flow-tech ๅคฑ่ดฅ
tech_design_complete โ /flow-tech ๅฎๆ
epic_generation_in_progress โ /flow-epic ๆง่กไธญ
epic_generation_failed โ /flow-epic ๅคฑ่ดฅ
epic_complete โ /flow-epic ๅฎๆ
development_in_progress โ /flow-dev ๆง่กไธญ
development_complete โ /flow-dev ๅฎๆ
qa_in_progress โ /flow-qa ๆง่กไธญ
qa_complete โ /flow-qa ๅฎๆ
released โ /flow-release ๅฎๆ
Phase Values
planning โ ้ๆฑ่งๅ้ถๆฎต (init, prd)
design โ ๆๆฏ่ฎพ่ฎก้ถๆฎต (tech, ui)
epic_planning โ ไปปๅก่งๅ้ถๆฎต (epic)
implementation โ ๅผๅ้ถๆฎต (dev)
qa โ ่ดจ้ไฟ้้ถๆฎต (qa)
release โ ๅๅธ้ถๆฎต (release)
Source
- Updated by: All flow commands
- Read by: cc-devflow-orchestrator skill, check-prerequisites.sh
- Schema: Implicitly defined across all flow command docs
status.json (for Bugs)
Structure
{
"bugId": "BUG-456",
"title": "Fix login timeout",
"status": "initialized",
"phase": "analysis",
"severity": "high",
"createdAt": "2025-10-31T12:34:56Z",
"updatedAt": "2025-10-31T12:34:56Z"
}
Severity Values
critical โ ไธฅ้๏ผ็ณป็ปไธๅฏ็จ
high โ ้ซ๏ผๆ ธๅฟๅ่ฝๅๅฝฑๅ
medium โ ไธญ๏ผ้จๅๅ่ฝๅๅฝฑๅ
low โ ไฝ๏ผ่ฝปๅพฎ้ฎ้ข
Source
- Used by:
/flow-fixcommand - Updated by: bug-analyzer agent
File Naming Patterns
Markdown Documents
UPPERCASE_WITH_UNDERSCORES.md # Primary documents (PRD.md, EPIC.md, TASKS.md)
lowercase-with-dashes.md # Supporting documents (data-model.md, quickstart.md)
Scripts
kebab-case.sh # All bash scripts (check-prerequisites.sh)
kebab-case.ts # All TypeScript scripts (skill-activation-prompt.ts)
Directories
lowercase # Top-level (devflow/, research/, contracts/)
kebab-case # Multi-word (codebase-tech-analysis/)
Source
- Implicitly enforced by: All agents and scripts
- No explicit validator
Contract Files
Format
api-{resource}.yaml # OpenAPI 3.0 format
graphql-{schema}.graphql # GraphQL schema
Example
contracts/
โโโ api-users.yaml # User management API
โโโ api-auth.yaml # Authentication API
โโโ graphql-schema.graphql # GraphQL schema (if used)
Source
- Generated by: tech-architect agent via
export-contracts.sh - Referenced by: planner agent in TASKS.md (Phase 2 contract tests)
Special Files
.gitignore Patterns (for devflow/)
# โ
Should be committed
devflow/requirements/**/PRD.md
devflow/requirements/**/EPIC.md
devflow/requirements/**/TASKS.md
devflow/requirements/**/orchestration_status.json
# โ Should NOT be committed
devflow/requirements/**/.env
devflow/requirements/**/secrets/
devflow/requirements/**/node_modules/
.claude/tsc-cache/ (PostToolUse tracking)
.claude/tsc-cache/
โโโ {session_id}/
โโโ edited-files.log # Timestamp:path:repo
โโโ affected-repos.txt # List of affected repos (e.g., devflow/REQ-123)
Source
- Generated by: PostToolUse hook (post-tool-use-tracker.sh)
- Read by: check-prerequisites.sh (for REQ_ID inference)
Agent-Specific Standards (NOT in this skill)
This skill does NOT contain agent-specific content standards:
- prd-writer: INVEST principles, Anti-Expansion mandate, Given-When-Then โ See prd-writer agent
- tech-architect: Architecture patterns, tech stack justification, Phase -1 Gates โ See tech-architect agent
- ui-designer: 80+ design masters, responsive design rules, NO PLACEHOLDER โ See ui-designer agent
- planner: Task breakdown methodology, TDD sequence, Phase -1 Gates enforcement โ See planner agent
- qa-tester: Test strategy, coverage requirements, performance benchmarks โ See qa-tester agent
Rationale: Those are agent execution standards (how to generate content), not file format standards (how to name/structure files).
Usage Examples
Query 1: "What's the format of REQ-ID?"
Answer: REQ-\d{3} (e.g., REQ-001, REQ-042, REQ-123)
Query 2: "Where does PRD.md go?"
Answer: devflow/requirements/REQ-XXX/PRD.md
Query 3: "What fields are in orchestration_status.json?"
Answer: reqId, title, status, phase, phase0_complete, phase1_complete, completedSteps, createdAt, updatedAt
Query 4: "How do I name a contract file?"
Answer: api-{resource}.yaml (e.g., api-users.yaml, api-auth.yaml)
Query 5: "What's the YAML frontmatter for TASKS.md?"
Answer: reqId, totalTasks, completedTasks, version, createdAt, updatedAt, author
Design Principle
This skill does NOT contain:
- โ Agent execution standards (PRD content rules, tech design methodology, etc.)
- โ Detailed Phase Gate logic (that's in flow command files)
- โ Complete template contents (that's in
.claude/docs/templates/)
This skill ONLY contains:
- โ File naming conventions (shared across all agents)
- โ Directory structure (created by scripts, used by all agents)
- โ YAML frontmatter format (enforced by multiple agents)
- โ orchestration_status.json schema (updated by all flow commands)
- โ Cross-cutting file format standards
Rationale: Avoid duplication ("ไธ้ไธๆผ" principle). Agents own content standards, this skill owns format standards.