-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.dump_config.json
More file actions
228 lines (228 loc) · 12.9 KB
/
Copy path.dump_config.json
File metadata and controls
228 lines (228 loc) · 12.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
{
"version": 55,
"ignore_patterns": [
".dump_config.json",
".git",
"__pycache__",
"*.pyc",
"venv",
".env",
".DS_Store",
"codebase_dump.txt",
".claude",
".pytest_cache",
"*.egg-info",
".github",
"dist",
"LICENSE",
".gitignore",
".mypy_cache",
".ruff_cache",
"ai_response.md"
],
"include_patterns": [],
"profiles": {
"readme": {
"description": "Generate a professional, architect-level README.md for the current project",
"pre": [
"Act as a Senior Technical Writer and System Architect.",
"Your task is to analyze the provided codebase and generate a high-impact, professional README.md that captures both the 'How' and the 'Why' of the project.",
"",
"CRITICAL PHILOSOPHY:",
"A README is not just a CLI reference; it is the project's manifesto. Do NOT sacrifice the narrative 'Why' or the 'Workflow' sections for brevity. If the code implements a specific way of working (e.g., PLAN.md, spec-driven development), that must be the centerpiece of the documentation.",
"",
"ANALYSIS GUIDELINES:",
"1. **Architecture & Philosophy**: Identify the project's core design pattern. If it uses a structured input/output flow (e.g., 'Sandwich Architecture'), explain WHY this exists (e.g., grounding LLMs, preventing hallucinations).",
"2. **Technical Features**: Document advanced implementations found in the code:",
" - Smart content handling (truncation of large files, binary detection, specific encoding support).",
" - Environment awareness (Git integration, terminal-specific escape sequences like OSC52, or remote-work optimizations).",
" - Diagnostic integration (ingesting external tool/linter output).",
"3. **The 'Spec-Driven' Workflow**: Analyze CLI flags like --new-plan, --architect, or logic handling PLAN.md. Document the intended iterative development loop (Dump -> Discuss -> Plan -> Implement).",
"4. **Configuration**: Explain the .dump_config.json schema, versioning, and how users can customize profiles.",
"",
"README STRUCTURE:",
"- **Identity**: Project name and a high-impact one-liner.",
"- **The Philosophy**: Explain the logical flow (e.g., The Sandwich) and the problem it solves.",
"- **The Workflow**: A prominent, step-by-step guide on the intended project development lifecycle using the tool's specific features (like PLAN.md syncing).",
"- **Feature Highlights**: A list of technically-backed features.",
"- **Installation & Requirements**: Detect dependencies from setup files.",
"- **Usage & CLI Reference**: A clean table or list of commands.",
"",
"TONE & STYLE:",
"- Tone: Happy, developer-centric, and authoritative.",
"- Style: Use structured Markdown, tables for references, and syntax-highlighted code blocks.",
"- Accuracy: Only document what is present in the code. Do not invent capabilities."
],
"post": "Output the result in raw Markdown format. Ensure the 'Workflow' and 'Philosophy' sections are the most detailed parts of the document.",
"model": "claude-sonnet-4-5-20250929",
"auto_send": true
},
"cleanup": {
"description": "Clean code: formatting, docstrings, unused imports (Runs ruff & mypy)",
"run_commands": [
"ruff check . --output-format=full",
"mypy ."
],
"pre": [
"Act as a Senior Python Developer and Code Reviewer.",
"Your task is to perform a 'Spring Cleaning' on the codebase.",
"",
"INPUT DATA:",
"1. The source code in <files>.",
"2. The Linter Reports in <execution> (Ruff and Mypy).",
"",
"HANDLING MISSING TOOLS:",
"If the <execution> log shows 'command not found' or similar execution errors, IGNORE the missing tool and proceed with a manual review based on standard Python best practices.",
"",
"PRIORITIES:",
"1. **Linter Fixes**: You MUST fix every error reported in the <execution> tag. If Ruff complains about imports, remove them. If Mypy complains about types, fix the annotation.",
"2. **Standard Cleanup**: Even if no linter errors exist, look for:",
" - Dead code (commented-out blocks).",
" - Trivial comments (e.g., '# increments i').",
" - MISSING docstrings (add them if missing).",
"",
"CRITICAL: Be conservative. If a file is clean and passes linters, state 'No changes needed'."
],
"post": "Provide the changes in unified diff format or full file rewrites where necessary. Explicitly mention which Linter errors were resolved.",
"model": "gemini-3-flash-preview",
"auto_send": true
},
"optimize": {
"description": "Identify bottlenecks and suggest performance improvements",
"pre": [
"Act as a Lead Performance Engineer. Analyze the provided codebase for performance bottlenecks.",
"",
"Look for:",
"1. Algorithmic inefficiencies (High Big-O complexity, nested loops on large data).",
"2. I/O bottlenecks (File operations, Network calls inside loops).",
"3. Memory leaks or excessive memory usage.",
"4. Inefficient string concatenations in large loops.",
"",
"CRITICAL: Avoid premature optimization. Do not suggest micro-optimizations (e.g., replacing 'format' with 'f-strings') unless the code is clearly in a performance-critical hot path. If the performance gain is negligible, do not report it.",
"If no significant bottlenecks exist, explicitly state 'No optimizations needed'."
],
"post": "Output a numbered list of optimizations ordered by impact (High/Medium/Low). Follow each point with a specific code snippet showing the optimized implementation.",
"model": "deepseek-reasoner",
"auto_send": false
},
"architect": {
"description": "Generate a Project Roadmap & Specification (PLAN.md)",
"pre": [
"Act as a Product Manager and Software Architect.",
"Analyze the current state of the codebase to create a master specification file named 'PLAN.md'.",
"This file should serve as the source of truth for the project.",
"",
"Include:",
"1. **Current Status**: What is currently implemented and working?",
"2. **Architecture**: High-level overview of how modules interact.",
"3. **Roadmap**: A logical step-by-step plan for future development.",
"4. **Missing Features**: Gaps between the implied goal and current code.",
"5. **Tech Debt**: Areas that need refactoring (identified from the code)."
],
"post": "Output the content in Markdown format. This will be used to update the project PLAN.md.",
"model": "claude-sonnet-4-5-20250929",
"auto_send": false
},
"plan-next": {
"description": "Sync PLAN.md with code; stop if finished",
"pre": [
"Act as a Software Project Controller and Architect.",
"Your goal is to synchronize the existing 'PLAN.md' with the actual state of the codebase.",
"",
"STRICT RULES:",
"1. COMPARE the provided code against the current tasks in PLAN.md.",
"2. MARK finished tasks as \u2705 [DONE] in the updated plan.",
"3. REMOVE or REVISE tasks that the code has rendered obsolete.",
"4. STRICT COMPLETION: If all tasks are marked as \u2705 [DONE] and no critical stability issues exist, state 'PROJECT MILESTONES COMPLETE'.",
"5. NO FEATURE CREEP: Do not suggest new features. If the project is finished, do not create a next milestone. Only if tasks remain, group them into exactly one logical next milestone with technical specs."
],
"post": [
"Output the updated PLAN.md in clear Markdown.",
"If the project is complete, output the finished PLAN.md followed by a summary of the project's current stable state.",
"If tasks remain, follow the plan with a 'Developer Specification' section for the very next task.",
"Ensure codeblocks are syntactically correct."
],
"model": "gpt-5.2",
"auto_send": true
},
"refactor": {
"description": "Suggest architectural improvements and code cleanups",
"pre": [
"Act as a Senior Software Architect.",
"Review the code for 'code smells', structural weaknesses, and SOLID principle violations.",
"Look for opportunities to reduce complexity, improve decoupling, and enhance testability.",
"",
"CRITICAL RULES:",
"1. Avoid Over-engineering: Do not suggest complex design patterns (like Abstract Factories) for simple, linear logic.",
"2. Prioritize Readability: If a refactor makes the code 'smarter' but harder to read, do NOT suggest it.",
"3. If the current implementation is simple, effective, and maintainable, explicitly state 'No architectural changes needed'."
],
"post": "Provide a list of recommended refactors, ranked by impact (High/Medium/Low). Include specific code snippets or patterns for the most critical changes.",
"model": "claude-sonnet-4-5-20250929",
"auto_send": false
},
"coverage": {
"description": "Run coverage report and plan tests for missing lines",
"run_commands": [
"pytest --cov=src/dumpcode --cov-report=term-missing"
],
"pre": [
"Act as a Senior QA Engineer.",
"Review the codebase and the <execution> report.",
"",
"GOAL: Create a plan to reach >90% coverage.",
"1. Analyze lines marked 'Missing' in the report.",
"2. Determine which missing lines are critical logic vs. trivial boilerplate.",
"3. If coverage is already high (>90%) and no critical logic is missing, DO NOT generate a plan.",
"4. If gaps exist, outline exactly which tests need to be written."
],
"post": [
"If the project is healthy (High Coverage), output ONLY: **\u2705 Coverage is healthy. No actions needed.**",
"",
"Otherwise, output a file named `COVERAGE_PLAN.md` containing:",
"# Coverage Improvement Plan",
"## Missing Critical Paths",
"- `file.py`: Lines X-Y (Description of logic)",
"",
"## Proposed Tests",
"- [ ] `test_new_feature`: [Description of what to test]"
],
"model": "deepseek-chat",
"auto_send": true
},
"test-fixer": {
"description": "Run tests (verbose) and plan fixes for failures",
"run_commands": [
"pytest -v"
],
"pre": [
"Act as a CI/CD Reliability Engineer.",
"Analyze the <execution> report for failures and stability issues.",
"",
"PRIORITY:",
"1. FAILURES: Any non-zero exit code or 'FAILED' tests.",
"2. ERRORS: Any runtime errors in the log.",
"",
"STOPPING CONDITION:",
"If the Exit Code is 0 and all tests passed, DO NOT invent work. Output: **\u2705 All tests passed. System is stable.**"
],
"post": [
"If tests failed, output a file named `FIX_PLAN.md` containing:",
"# Test Repair Plan",
"## Diagnosis",
"- **Failure**: `test_name`",
"- **Error**: [Brief error content]",
"- **Root Cause**: [Analysis based on code + log]",
"",
"## Action Items",
"1. [Step-by-step fix instructions]",
"",
"## Verification",
"- Command to verify the fix"
],
"model": "gemini-3-flash-preview",
"auto_send": true
}
},
"use_xml": true
}