@ainative/cody-cli 0.2.6 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/.ainative/AINATIVE.md +164 -0
  2. package/.ainative/CRITICAL_FILE_PLACEMENT_RULES.md +139 -0
  3. package/.ainative/README.md +163 -0
  4. package/.ainative/SDK_PUBLISHING_GUIDELINES.md +262 -0
  5. package/.ainative/git-rules.md +150 -0
  6. package/.ainative/settings.json +116 -0
  7. package/.ainative/skills/ci-cd-compliance/SKILL.md +33 -0
  8. package/.ainative/skills/code-quality/SKILL.md +35 -0
  9. package/.ainative/skills/file-placement/SKILL.md +59 -0
  10. package/.ainative/skills/git-workflow/SKILL.md +116 -0
  11. package/.ainative/skills/local-environment-check/SKILL.md +78 -0
  12. package/.ainative/skills/mandatory-tdd/SKILL.md +112 -0
  13. package/.ainative/skills/mcp-builder/SKILL.md +150 -0
  14. package/.claude/RAILWAY_DEPLOYMENT_GUIDE.md +118 -0
  15. package/.claude/hooks/README.md +68 -0
  16. package/.claude/hooks/commit-msg +26 -0
  17. package/.claude/hooks/install-hooks.sh +46 -0
  18. package/.claude/hooks/pre-commit +62 -0
  19. package/.claude/mcp.json.example +31 -0
  20. package/.claude/settings.json +24 -0
  21. package/.claude/skills/ci-cd-compliance/SKILL.md +33 -0
  22. package/.claude/skills/code-quality/SKILL.md +35 -0
  23. package/.claude/skills/file-placement/SKILL.md +59 -0
  24. package/.claude/skills/git-workflow/SKILL.md +116 -0
  25. package/.claude/skills/local-environment-check/SKILL.md +78 -0
  26. package/.claude/skills/mandatory-tdd/SKILL.md +112 -0
  27. package/.claude/skills/mcp-builder/SKILL.md +150 -0
  28. package/.cody/CODY.md +17 -0
  29. package/.cody/hooks/commit-msg +7 -0
  30. package/.cody/hooks/pre-commit +8 -0
  31. package/.cody/mcp.json +9 -0
  32. package/.cody/mcp.json.example +9 -0
  33. package/.cody/skills/ci-cd-compliance/SKILL.md +12 -0
  34. package/.cody/skills/code-quality/SKILL.md +10 -0
  35. package/.cody/skills/database-best-practices/SKILL.md +13 -0
  36. package/.cody/skills/delivery-checklist/SKILL.md +13 -0
  37. package/.cody/skills/file-placement/SKILL.md +11 -0
  38. package/.cody/skills/git-workflow/SKILL.md +9 -0
  39. package/.cody/skills/mandatory-tdd/SKILL.md +10 -0
  40. package/dist/cli.js +234 -234
  41. package/package.json +4 -1
@@ -0,0 +1,116 @@
1
+ ---
2
+ name: git-workflow
3
+ description: Git commit, PR, and branching standards with ZERO TOLERANCE for AI attribution. Use when (1) Creating commits, (2) Writing commit messages, (3) Creating pull requests, (4) Writing PR descriptions, (5) Branching or merging code. ABSOLUTE RULE - NEVER include "Claude", "Anthropic", "AI-generated", emojis with "Generated with", or any AI tool attribution in commits, PRs, issues, or documentation.
4
+ ---
5
+
6
+ # Git & PR Workflow Standards
7
+
8
+ ## Core Principles
9
+
10
+ * **Small PRs:** <=300 LOC changed ideally
11
+ * **Commit often:** Early, meaningful commits with clear messages
12
+ * **Linear history:** Prefer rebase over merge commits
13
+ * **Professional:** No AI attribution, no tool branding, clean descriptions
14
+
15
+ ## ABSOLUTE ZERO-TOLERANCE RULE: NO AI ATTRIBUTION
16
+
17
+ **NEVER, UNDER ANY CIRCUMSTANCES, include ANY of the following in:**
18
+ * Git commit messages
19
+ * Pull request descriptions
20
+ * Issue comments
21
+ * GitHub discussions
22
+ * Code comments
23
+ * Documentation
24
+ * ANY public-facing repository content
25
+
26
+ ### STRICTLY FORBIDDEN TEXT - NEVER USE
27
+
28
+ * "Claude"
29
+ * "Anthropic"
30
+ * "claude.com"
31
+ * "Claude Code"
32
+ * "Generated with Claude"
33
+ * "Co-Authored-By: Claude"
34
+ * Any emoji followed by "Generated with" or "Powered by"
35
+ * Any reference to AI assistants, AI code generation, or automated tools
36
+ * Any branding, attribution, or links to third-party AI services
37
+
38
+ ### CORRECT FORMAT - ALWAYS USE
39
+
40
+ * Clean, professional commit messages
41
+ * Clear description of what changed
42
+ * Explanation of why the change was made
43
+ * No attribution, no branding, no tool references
44
+
45
+ ## Examples
46
+
47
+ ### FORBIDDEN COMMIT
48
+
49
+ ```
50
+ Add multi-dimension vector support
51
+
52
+ - Support for 384, 768, 1024, and 1536 dimensions
53
+
54
+ Generated with [Claude Code](https://claude.com/claude-code)
55
+
56
+ Co-Authored-By: Claude <noreply@anthropic.com>
57
+ ```
58
+
59
+ ### CORRECT COMMIT
60
+
61
+ ```
62
+ Add multi-dimension vector support
63
+
64
+ - Support for 384, 768, 1024, and 1536 dimensions
65
+ - Update validation logic for new dimensions
66
+ - Add comprehensive test coverage
67
+ ```
68
+
69
+ ### FORBIDDEN PR DESCRIPTION
70
+
71
+ ```markdown
72
+ ## Summary
73
+ Implemented new authentication flow with JWT tokens.
74
+
75
+ ## Test Plan
76
+ All tests passing.
77
+
78
+ ---
79
+ Powered by Claude
80
+ ```
81
+
82
+ ### CORRECT PR DESCRIPTION
83
+
84
+ ```markdown
85
+ ## Summary
86
+ Implemented new authentication flow with JWT tokens.
87
+
88
+ ## Test Plan
89
+ All tests passing.
90
+ ```
91
+
92
+ ## Enforcement
93
+
94
+ * **ZERO TOLERANCE** rule with **NO EXCEPTIONS**
95
+ * Every commit must be verified before pushing
96
+ * Every PR must be reviewed for attribution before creating
97
+ * If attribution is found, it must be removed immediately via force push or amendment
98
+ * This rule applies to ALL repositories, ALL projects, ALL commits
99
+
100
+ ## PR Requirements
101
+
102
+ Every PR must include:
103
+
104
+ * **Problem/Context:** What issue are we solving and why?
105
+ * **Solution summary:** How does this change address the problem?
106
+ * **Test plan:** Commands + results proving functionality
107
+ * **Risk/rollback:** Potential issues and how to revert if needed
108
+ * **Story link + Type + Estimate:** Link to issue/story with type (feature/bug/chore) and points
109
+
110
+ ## Reference Files
111
+
112
+ See `references/ai-attribution-enforcement.md` for comprehensive forbidden text list and enforcement details.
113
+
114
+ See `references/pr-templates.md` for complete PR templates for feature, bug, and chore PRs.
115
+
116
+ See `references/branch-conventions.md` for branch naming patterns and examples.
@@ -0,0 +1,78 @@
1
+ ---
2
+ name: local-environment-check
3
+ description: Verify local development environment is correctly configured. Use when (1) Setting up a new development machine, (2) Debugging environment issues, (3) Onboarding new team members, (4) Verifying tool versions, (5) Checking port availability.
4
+ ---
5
+
6
+ # Local Environment Check
7
+
8
+ ## Purpose
9
+
10
+ Verify that the local development environment has all required tools, correct versions, and proper configuration before starting work.
11
+
12
+ ## Checks to Perform
13
+
14
+ ### 1. Required Tools
15
+ ```bash
16
+ # Check Node.js
17
+ node --version # Expected: v18+ or v20+
18
+
19
+ # Check npm/bun/pnpm
20
+ npm --version # Expected: 9+
21
+ bun --version # If using bun
22
+ pnpm --version # If using pnpm
23
+
24
+ # Check Python (if applicable)
25
+ python3 --version # Expected: 3.10+
26
+ pip --version
27
+
28
+ # Check Git
29
+ git --version # Expected: 2.30+
30
+
31
+ # Check GitHub CLI
32
+ gh --version
33
+ gh auth status # Verify authenticated
34
+ ```
35
+
36
+ ### 2. Environment Variables
37
+ ```bash
38
+ # Check required env vars are set
39
+ env | grep -E "^(NODE_ENV|API_URL|DATABASE_URL)" || echo "Missing env vars"
40
+
41
+ # Check .env file exists
42
+ [ -f .env ] && echo ".env exists" || echo "WARNING: No .env file"
43
+ ```
44
+
45
+ ### 3. Port Availability
46
+ ```bash
47
+ # Check if common dev ports are free
48
+ lsof -i :3000 2>/dev/null && echo "Port 3000 in use" || echo "Port 3000 available"
49
+ lsof -i :5432 2>/dev/null && echo "Port 5432 in use" || echo "Port 5432 available"
50
+ lsof -i :8080 2>/dev/null && echo "Port 8080 in use" || echo "Port 8080 available"
51
+ ```
52
+
53
+ ### 4. Dependencies
54
+ ```bash
55
+ # Install and verify dependencies
56
+ npm install # or bun install / pnpm install
57
+ npm run build # Verify build works
58
+ npm test # Verify tests pass
59
+ ```
60
+
61
+ ### 5. Git Configuration
62
+ ```bash
63
+ # Verify git hooks are installed
64
+ ls -la .git/hooks/pre-commit .git/hooks/commit-msg 2>/dev/null
65
+
66
+ # If missing, install them
67
+ bash .claude/hooks/install-hooks.sh
68
+ ```
69
+
70
+ ## Troubleshooting
71
+
72
+ | Issue | Solution |
73
+ |-------|---------|
74
+ | Node version too old | Use `nvm install 20` |
75
+ | Port already in use | Kill process: `kill $(lsof -t -i:3000)` |
76
+ | Missing env vars | Copy from `.env.example`: `cp .env.example .env` |
77
+ | Git hooks not installed | Run `bash .claude/hooks/install-hooks.sh` |
78
+ | npm install fails | Delete `node_modules` and `package-lock.json`, retry |
@@ -0,0 +1,112 @@
1
+ ---
2
+ name: mandatory-tdd
3
+ description: Enforces Test-Driven Development (TDD) with BDD-style tests and mandatory test execution. Use when (1) Writing any new code or feature, (2) Fixing bugs, (3) Refactoring existing code, (4) Creating pull requests, (5) Closing issues. CRITICAL RULE - Tests MUST be actually executed with proof of passing status and coverage >= 80% before ANY commit, PR, or issue closure.
4
+ ---
5
+
6
+ # Mandatory TDD/BDD Testing Strategy
7
+
8
+ ## Core Principles
9
+
10
+ * **BDD Style:** Use `describe/it` syntax for unit, integration, and functional/API tests
11
+ * **Test-First:** Write failing tests before implementation
12
+ * **Deterministic:** Use data-testid, role, or label selectors (never brittle CSS/XPath)
13
+ * **Fast & Light:** Prefer fast unit/integration tests; save heavy e2e for nightly unless required
14
+
15
+ ## Example BDD Structure
16
+
17
+ ```js
18
+ describe('Calculator', () => {
19
+ describe('addition', () => {
20
+ it('adds two positive numbers', () => {
21
+ expect(add(5, 7)).to.equal(12);
22
+ });
23
+ });
24
+ });
25
+ ```
26
+
27
+ ## MANDATORY TEST EXECUTION REQUIREMENT
28
+
29
+ **BEFORE claiming tests pass or closing any issue:**
30
+
31
+ 1. **ACTUALLY RUN THE TESTS** - Execute test suite with coverage
32
+ 2. **VERIFY THEY PASS** - Confirm all tests show green/passing status
33
+ 3. **CHECK COVERAGE** - Verify minimum 80% coverage requirement met
34
+ 4. **INCLUDE OUTPUT** - Paste actual test execution output in PR/commit/issue
35
+
36
+ ### ABSOLUTELY FORBIDDEN
37
+
38
+ * Writing tests but NOT running them
39
+ * Claiming "All tests passing" without proof
40
+ * Stating "80%+ coverage" without actual coverage report
41
+ * Closing issues without running test suite
42
+ * Creating PRs without executing pytest/jest/etc.
43
+ * Assuming tests work based on syntax checking alone
44
+
45
+ ### REQUIRED WORKFLOW
46
+
47
+ **Backend (Python/FastAPI):**
48
+ ```bash
49
+ cd /path/to/your/backend
50
+ python3 -m pytest tests/test_your_feature.py -v --cov=app.your.module --cov-report=term-missing
51
+
52
+ # Verify output shows:
53
+ # - All tests passed (green checkmarks)
54
+ # - Coverage >= 80%
55
+ # - No import errors or test failures
56
+ ```
57
+
58
+ **Frontend (TypeScript/React):**
59
+ ```bash
60
+ cd /path/to/your/frontend
61
+ npm test -- --coverage
62
+
63
+ # Verify output shows:
64
+ # - All tests passed
65
+ # - Coverage >= 80% for statements, branches, functions, lines
66
+ ```
67
+
68
+ ### Evidence Requirement
69
+
70
+ Every PR, commit, or issue closure involving tests MUST include:
71
+
72
+ ```
73
+ ## Test Execution Evidence
74
+
75
+ ### Command Run:
76
+ `pytest tests/test_feature.py -v --cov=app.module`
77
+
78
+ ### Output:
79
+ test_create_item PASSED [ 5%]
80
+ test_validation PASSED [ 10%]
81
+ ==================== 20 passed in 3.42s ====================
82
+ Coverage: 87%
83
+
84
+ ### Coverage Report:
85
+ app/api/v1/endpoints/feature.py 422 35 87%
86
+ app/schemas/item.py 192 18 91%
87
+ ```
88
+
89
+ ## Why This Matters
90
+
91
+ * **Prevents false confidence** - Tests may have import errors, assertion failures
92
+ * **Catches infrastructure issues** - Broken test setup, missing dependencies
93
+ * **Validates coverage claims** - Actual coverage may be lower than estimated
94
+ * **Ensures production readiness** - Code that doesn't pass tests shouldn't ship
95
+ * **Saves debugging time** - Finding test failures BEFORE merge, not after
96
+
97
+ ## Enforcement
98
+
99
+ * **MANDATORY** requirement with **NO EXCEPTIONS**
100
+ * Tests must be run LOCALLY before any git commit
101
+ * Test output must be included in PR descriptions
102
+ * Coverage reports must show actual percentages, not estimates
103
+ * If tests cannot run due to infrastructure issues, **DOCUMENT THE ISSUE** and fix it before proceeding
104
+ * Never claim "tests passing" without proving it with actual command output
105
+
106
+ **THIS IS A ZERO-TOLERANCE RULE. ALWAYS RUN TESTS AND PROVIDE PROOF.**
107
+
108
+ ## Reference Files
109
+
110
+ See `references/bdd-patterns.md` for detailed BDD test pattern examples across unit, integration, and API tests.
111
+
112
+ See `references/coverage-requirements.md` for detailed coverage configuration, thresholds, and exclusion patterns.
@@ -0,0 +1,150 @@
1
+ ---
2
+ name: mcp-builder
3
+ description: Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node.js (MCP SDK).
4
+ ---
5
+
6
+ # MCP Builder Guide
7
+
8
+ ## What is an MCP Server?
9
+
10
+ Model Context Protocol (MCP) servers expose tools that AI agents (Claude Code, Cursor, Windsurf, etc.) can call directly. You can build custom MCP servers to integrate any API or service.
11
+
12
+ ## Python -- FastMCP
13
+
14
+ ```bash
15
+ pip install fastmcp
16
+ ```
17
+
18
+ ```python
19
+ # my_mcp_server.py
20
+ from fastmcp import FastMCP
21
+ import requests
22
+
23
+ mcp = FastMCP("my-tools")
24
+ API_KEY = "your_api_key"
25
+ BASE = "https://your-api.example.com"
26
+
27
+ @mcp.tool()
28
+ def get_status() -> dict:
29
+ """Get current service status."""
30
+ return requests.get(
31
+ f"{BASE}/api/v1/status",
32
+ headers={"X-API-Key": API_KEY}
33
+ ).json()
34
+
35
+ @mcp.tool()
36
+ def search_items(query: str, limit: int = 5) -> dict:
37
+ """Search items by query."""
38
+ return requests.post(
39
+ f"{BASE}/api/v1/search",
40
+ headers={"X-API-Key": API_KEY},
41
+ json={"query": query, "limit": limit}
42
+ ).json()
43
+
44
+ if __name__ == "__main__":
45
+ mcp.run()
46
+ ```
47
+
48
+ ```bash
49
+ python my_mcp_server.py
50
+ ```
51
+
52
+ ## Node.js -- MCP SDK
53
+
54
+ ```bash
55
+ npm install @modelcontextprotocol/sdk
56
+ ```
57
+
58
+ ```typescript
59
+ // server.ts
60
+ import { Server } from '@modelcontextprotocol/sdk/server/index.js';
61
+ import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
62
+
63
+ const server = new Server(
64
+ { name: 'my-mcp-server', version: '1.0.0' },
65
+ { capabilities: { tools: {} } }
66
+ );
67
+
68
+ server.setRequestHandler('tools/list', async () => ({
69
+ tools: [{
70
+ name: 'get_status',
71
+ description: 'Get current service status',
72
+ inputSchema: { type: 'object', properties: {} }
73
+ }]
74
+ }));
75
+
76
+ server.setRequestHandler('tools/call', async (request) => {
77
+ if (request.params.name === 'get_status') {
78
+ const resp = await fetch('https://your-api.example.com/api/v1/status', {
79
+ headers: { 'X-API-Key': process.env.API_KEY! }
80
+ });
81
+ return { content: [{ type: 'text', text: JSON.stringify(await resp.json()) }] };
82
+ }
83
+ });
84
+
85
+ const transport = new StdioServerTransport();
86
+ await server.connect(transport);
87
+ ```
88
+
89
+ ## Configure in Claude Code
90
+
91
+ ```json
92
+ // .claude/mcp.json
93
+ {
94
+ "mcpServers": {
95
+ "my-tools": {
96
+ "command": "python",
97
+ "args": ["my_mcp_server.py"],
98
+ "env": { "API_KEY": "your_api_key" }
99
+ }
100
+ }
101
+ }
102
+ ```
103
+
104
+ For a published npm package:
105
+ ```json
106
+ {
107
+ "mcpServers": {
108
+ "my-tools": {
109
+ "command": "npx",
110
+ "args": ["my-mcp-package"],
111
+ "env": { "API_KEY": "your_api_key" }
112
+ }
113
+ }
114
+ }
115
+ ```
116
+
117
+ ## SKILL.md Format
118
+
119
+ Every MCP tool should have a matching skill file so agents know when to call it:
120
+
121
+ ```markdown
122
+ ---
123
+ name: my-tool-name
124
+ description: One-line description. Use when (1) scenario, (2) scenario, (3) scenario.
125
+ ---
126
+
127
+ # Tool Name
128
+
129
+ Brief description and usage examples.
130
+ ```
131
+
132
+ Place in `.claude/skills/my-tool-name/SKILL.md`.
133
+
134
+ ## Publish to npm
135
+
136
+ ```bash
137
+ # package.json
138
+ {
139
+ "name": "my-mcp-server",
140
+ "version": "1.0.0",
141
+ "bin": { "my-mcp-server": "./dist/server.js" },
142
+ "main": "./dist/server.js"
143
+ }
144
+
145
+ npm publish
146
+ ```
147
+
148
+ ## References
149
+
150
+ - MCP spec: `https://modelcontextprotocol.io`
package/.cody/CODY.md ADDED
@@ -0,0 +1,17 @@
1
+ # Cody — Your AI Engineering Lead
2
+
3
+ ## Identity
4
+ - **Name**: Cody
5
+ - **Role**: Senior AI Engineer + Technical Advisor
6
+ - **Style**: Direct, technically precise, no fluff
7
+
8
+ ## Mandate
9
+ 1. Lead technical architecture decisions
10
+ 2. Enforce TDD, code quality, and security standards
11
+ 3. Ship production-grade code with 90%+ test coverage
12
+ 4. Never break production — reversible changes, verify before merge
13
+
14
+ ## Communication
15
+ - Responds as a senior engineer, not a chatbot
16
+ - Gets to the point fast
17
+ - When something is wrong, says so clearly and fixes it
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ # Block AI attribution in commit messages
3
+ if grep -qiE "(co-authored-by:.*claude|co-authored-by:.*chatgpt|generated with)" "$1"; then
4
+ echo "ERROR: Remove AI attribution from commit message"
5
+ exit 1
6
+ fi
7
+ echo "Commit message: PASS"
@@ -0,0 +1,8 @@
1
+ #!/bin/bash
2
+ # Check file placement
3
+ VIOLATIONS=$(git diff --cached --name-only --diff-filter=A | grep -E '^[^/]+\.md$' | grep -v -E '^(README\.md)$' || true)
4
+ if [ ! -z "$VIOLATIONS" ]; then
5
+ echo "ERROR: .md files must go in docs/ subdirectory"
6
+ exit 1
7
+ fi
8
+ echo "File placement: PASS"
package/.cody/mcp.json ADDED
@@ -0,0 +1,9 @@
1
+ {
2
+ "mcpServers": {
3
+ "zerodb": {
4
+ "type": "http",
5
+ "url": "https://api.ainative.studio/v1/mcp/zerodb-mcp/messages",
6
+ "description": "ZeroDB vector database and storage"
7
+ }
8
+ }
9
+ }
@@ -0,0 +1,9 @@
1
+ {
2
+ "mcpServers": {
3
+ "example": {
4
+ "command": "npx",
5
+ "args": ["-y", "@modelcontextprotocol/server-filesystem", "."],
6
+ "description": "Local filesystem access"
7
+ }
8
+ }
9
+ }
@@ -0,0 +1,12 @@
1
+ ---
2
+ name: ci-cd-compliance
3
+ description: CI/CD pipeline requirements and deployment standards
4
+ ---
5
+ ## CI/CD Standards
6
+ - All commits must pass CI before merge
7
+ - Staging deploys required before production
8
+ - Use feature flags for risky changes
9
+ - Rollback plan documented for every deploy
10
+ - Environment variables managed via CI secrets, never hardcoded
11
+ - Database migrations must be backward-compatible
12
+ - Health checks required for all deployed services
@@ -0,0 +1,10 @@
1
+ ---
2
+ name: code-quality
3
+ description: Coding style, security, and accessibility standards
4
+ ---
5
+ ## Standards
6
+ - camelCase for vars/functions, PascalCase for classes
7
+ - 4-space indentation
8
+ - Never log secrets or PII
9
+ - Validate all inputs
10
+ - Explicit error types with actionable messages
@@ -0,0 +1,13 @@
1
+ ---
2
+ name: database-best-practices
3
+ description: Database query safety and connection management
4
+ ---
5
+ ## Database Best Practices
6
+ - Always use connection pooling — never raw connections
7
+ - Close connections and sessions explicitly after use
8
+ - Use parameterized queries — never string interpolation for SQL
9
+ - Add indexes for frequently queried columns
10
+ - Migrations must be idempotent and backward-compatible
11
+ - Monitor connection pool usage in production
12
+ - Use transactions for multi-step writes
13
+ - Set query timeouts to prevent runaway queries
@@ -0,0 +1,13 @@
1
+ ---
2
+ name: delivery-checklist
3
+ description: Pre-delivery acceptance checklist before merge
4
+ ---
5
+ ## Delivery Checklist
6
+ - [ ] All tests pass with >= 90% coverage
7
+ - [ ] No linting errors or warnings
8
+ - [ ] PR description includes summary, test plan, and risk/rollback
9
+ - [ ] Issue linked and status updated
10
+ - [ ] No secrets, credentials, or PII in code
11
+ - [ ] Breaking changes documented
12
+ - [ ] Reviewer approved
13
+ - [ ] CI pipeline green
@@ -0,0 +1,11 @@
1
+ ---
2
+ name: file-placement
3
+ description: File organization and placement rules
4
+ ---
5
+ ## File Placement Rules
6
+ - Documentation (.md) files go in `docs/` subdirectories
7
+ - Only `README.md` is allowed at project root
8
+ - Scripts go in `scripts/` directory
9
+ - Config files go in `config/` or project root
10
+ - Tests mirror source directory structure in `tests/`
11
+ - No orphan files — every file belongs in a designated directory
@@ -0,0 +1,9 @@
1
+ ---
2
+ name: git-workflow
3
+ description: Git commit, PR, and branching standards
4
+ ---
5
+ ## Git Workflow
6
+ - Branch: `feature/{issue}-{slug}`, `bug/{issue}-{slug}`
7
+ - Commits: reference issue numbers (`Refs #123`)
8
+ - PRs: include summary, test plan, risk/rollback
9
+ - No AI attribution in commits
@@ -0,0 +1,10 @@
1
+ ---
2
+ name: mandatory-tdd
3
+ description: Test-Driven Development with BDD-style tests
4
+ ---
5
+ ## TDD Workflow
6
+ 1. RED: Write failing tests first
7
+ 2. GREEN: Minimal code to pass
8
+ 3. REFACTOR: Improve with tests green
9
+ - Coverage >= 90%
10
+ - Run tests before every commit