Skip to content

Commit 3594ca4

Browse files
mnriemgithub-actions[bot]Copilot
authored andcommitted
refactor: remove OpenAPI/GraphQL bias from templates (github#1652)
* chore: bump version to v0.0.5 [skip ci] * refactor: update documentation for interface contracts and integration patterns * Update pyproject.toml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update templates/commands/tasks.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update templates/commands/tasks.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> (cherry picked from commit 12405c0)
1 parent 66a0605 commit 3594ca4

3 files changed

Lines changed: 12 additions & 11 deletions

File tree

templates/commands/plan.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,10 +84,11 @@ You **MUST** consider the user input before proceeding (if not empty).
8484
- Validation rules from requirements
8585
- State transitions if applicable
8686

87-
2. **Generate API contracts** from functional requirements:
88-
- For each user action → endpoint
89-
- Use standard REST/GraphQL patterns
90-
- Output OpenAPI/GraphQL schema to `/contracts/`
87+
2. **Define interface contracts** (if project has external interfaces) → `/contracts/`:
88+
- Identify what interfaces the project exposes to users or other systems
89+
- Document the contract format appropriate for the project type
90+
- Examples: public APIs for libraries, command schemas for CLI tools, endpoints for web services, grammars for parsers, UI contracts for applications
91+
- Skip if project is purely internal (build scripts, one-off tools, etc.)
9192

9293
3. **Agent context update**:
9394
- Run `{AGENT_SCRIPT}`

templates/commands/tasks.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,14 @@ You **MUST** consider the user input before proceeding (if not empty).
3636
3737
2. **Load design documents**: Read from FEATURE_DIR:
3838
- **Required**: plan.md (tech stack, libraries, structure), spec.md (user stories with priorities)
39-
- **Optional**: data-model.md (entities), contracts/ (API endpoints), research.md (decisions), quickstart.md (test scenarios)
39+
- **Optional**: data-model.md (entities), contracts/ (interface contracts), research.md (decisions), quickstart.md (test scenarios)
4040
- Note: Not all projects have all documents. Generate tasks based on what's available.
4141
4242
3. **Execute task generation workflow**:
4343
- Load plan.md and extract tech stack, libraries, project structure
4444
- Load spec.md and extract user stories with their priorities (P1, P2, P3, etc.)
4545
- If data-model.md exists: Extract entities and map to user stories
46-
- If contracts/ exists: Map endpoints to user stories
46+
- If contracts/ exists: Map interface contracts to user stories
4747
- If research.md exists: Extract decisions for setup tasks
4848
- Generate tasks organized by user story (see Task Generation Rules below)
4949
- Generate dependency graph showing user story completion order
@@ -123,13 +123,13 @@ Every task MUST strictly follow this format:
123123
- Map all related components to their story:
124124
- Models needed for that story
125125
- Services needed for that story
126-
- Endpoints/UI needed for that story
126+
- Interfaces/UI needed for that story
127127
- If tests requested: Tests specific to that story
128128
- Mark story dependencies (most stories should be independent)
129129

130130
1. **From Contracts**:
131-
- Map each contract/endpoint → to the user story it serves
132-
- If tests requested: Each contract → contract test task [P] before implementation in that story's phase
131+
- Map each interface contract → to the user story it serves
132+
- If tests requested: Each interface contract → contract test task [P] before implementation in that story's phase
133133

134134
1. **From Data Model**:
135135
- Map each entity to the user story(ies) that need it
@@ -146,6 +146,6 @@ Every task MUST strictly follow this format:
146146
- **Phase 1**: Setup (project initialization)
147147
- **Phase 2**: Foundational (blocking prerequisites - MUST complete before user stories)
148148
- **Phase 3+**: User Stories in priority order (P1, P2, P3...)
149-
- Within each story: Tests (if requested) → Models → Services → Endpoints → Integration
149+
- Within each story: Tests (if requested) → Models → Services → Interfaces → Integration
150150
- Each phase should be a complete, independently testable increment
151151
- **Final Phase**: Polish & Cross-Cutting Concerns

templates/plan-template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
**Storage**: [if applicable, e.g., PostgreSQL, CoreData, files or N/A]
2424
**Testing**: [e.g., pytest, XCTest, cargo test or NEEDS CLARIFICATION]
2525
**Target Platform**: [e.g., Linux server, iOS 15+, WASM or NEEDS CLARIFICATION]
26-
**Project Type**: [single/web/mobile - determines source structure]
26+
**Project Type**: [e.g., library/cli/web-service/mobile-app/compiler/desktop-app or NEEDS CLARIFICATION]
2727
**Performance Goals**: [domain-specific, e.g., 1000 req/s, 10k lines/sec, 60 fps or NEEDS CLARIFICATION]
2828
**Constraints**: [domain-specific, e.g., <200ms p95, <100MB memory, offline-capable or NEEDS CLARIFICATION]
2929
**Scale/Scope**: [domain-specific, e.g., 10k users, 1M LOC, 50 screens or NEEDS CLARIFICATION]

0 commit comments

Comments
 (0)