kollabor 0.4.9__py3-none-any.whl → 0.4.15__py3-none-any.whl

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 (192) hide show
  1. agents/__init__.py +2 -0
  2. agents/coder/__init__.py +0 -0
  3. agents/coder/agent.json +4 -0
  4. agents/coder/api-integration.md +2150 -0
  5. agents/coder/cli-pretty.md +765 -0
  6. agents/coder/code-review.md +1092 -0
  7. agents/coder/database-design.md +1525 -0
  8. agents/coder/debugging.md +1102 -0
  9. agents/coder/dependency-management.md +1397 -0
  10. agents/coder/git-workflow.md +1099 -0
  11. agents/coder/refactoring.md +1454 -0
  12. agents/coder/security-hardening.md +1732 -0
  13. agents/coder/system_prompt.md +1448 -0
  14. agents/coder/tdd.md +1367 -0
  15. agents/creative-writer/__init__.py +0 -0
  16. agents/creative-writer/agent.json +4 -0
  17. agents/creative-writer/character-development.md +1852 -0
  18. agents/creative-writer/dialogue-craft.md +1122 -0
  19. agents/creative-writer/plot-structure.md +1073 -0
  20. agents/creative-writer/revision-editing.md +1484 -0
  21. agents/creative-writer/system_prompt.md +690 -0
  22. agents/creative-writer/worldbuilding.md +2049 -0
  23. agents/data-analyst/__init__.py +30 -0
  24. agents/data-analyst/agent.json +4 -0
  25. agents/data-analyst/data-visualization.md +992 -0
  26. agents/data-analyst/exploratory-data-analysis.md +1110 -0
  27. agents/data-analyst/pandas-data-manipulation.md +1081 -0
  28. agents/data-analyst/sql-query-optimization.md +881 -0
  29. agents/data-analyst/statistical-analysis.md +1118 -0
  30. agents/data-analyst/system_prompt.md +928 -0
  31. agents/default/__init__.py +0 -0
  32. agents/default/agent.json +4 -0
  33. agents/default/dead-code.md +794 -0
  34. agents/default/explore-agent-system.md +585 -0
  35. agents/default/system_prompt.md +1448 -0
  36. agents/kollabor/__init__.py +0 -0
  37. agents/kollabor/analyze-plugin-lifecycle.md +175 -0
  38. agents/kollabor/analyze-terminal-rendering.md +388 -0
  39. agents/kollabor/code-review.md +1092 -0
  40. agents/kollabor/debug-mcp-integration.md +521 -0
  41. agents/kollabor/debug-plugin-hooks.md +547 -0
  42. agents/kollabor/debugging.md +1102 -0
  43. agents/kollabor/dependency-management.md +1397 -0
  44. agents/kollabor/git-workflow.md +1099 -0
  45. agents/kollabor/inspect-llm-conversation.md +148 -0
  46. agents/kollabor/monitor-event-bus.md +558 -0
  47. agents/kollabor/profile-performance.md +576 -0
  48. agents/kollabor/refactoring.md +1454 -0
  49. agents/kollabor/system_prompt copy.md +1448 -0
  50. agents/kollabor/system_prompt.md +757 -0
  51. agents/kollabor/trace-command-execution.md +178 -0
  52. agents/kollabor/validate-config.md +879 -0
  53. agents/research/__init__.py +0 -0
  54. agents/research/agent.json +4 -0
  55. agents/research/architecture-mapping.md +1099 -0
  56. agents/research/codebase-analysis.md +1077 -0
  57. agents/research/dependency-audit.md +1027 -0
  58. agents/research/performance-profiling.md +1047 -0
  59. agents/research/security-review.md +1359 -0
  60. agents/research/system_prompt.md +492 -0
  61. agents/technical-writer/__init__.py +0 -0
  62. agents/technical-writer/agent.json +4 -0
  63. agents/technical-writer/api-documentation.md +2328 -0
  64. agents/technical-writer/changelog-management.md +1181 -0
  65. agents/technical-writer/readme-writing.md +1360 -0
  66. agents/technical-writer/style-guide.md +1410 -0
  67. agents/technical-writer/system_prompt.md +653 -0
  68. agents/technical-writer/tutorial-creation.md +1448 -0
  69. core/__init__.py +0 -2
  70. core/application.py +343 -88
  71. core/cli.py +229 -10
  72. core/commands/menu_renderer.py +463 -59
  73. core/commands/registry.py +14 -9
  74. core/commands/system_commands.py +2461 -14
  75. core/config/loader.py +151 -37
  76. core/config/service.py +18 -6
  77. core/events/bus.py +29 -9
  78. core/events/executor.py +205 -75
  79. core/events/models.py +27 -8
  80. core/fullscreen/command_integration.py +20 -24
  81. core/fullscreen/components/__init__.py +10 -1
  82. core/fullscreen/components/matrix_components.py +1 -2
  83. core/fullscreen/components/space_shooter_components.py +654 -0
  84. core/fullscreen/plugin.py +5 -0
  85. core/fullscreen/renderer.py +52 -13
  86. core/fullscreen/session.py +52 -15
  87. core/io/__init__.py +29 -5
  88. core/io/buffer_manager.py +6 -1
  89. core/io/config_status_view.py +7 -29
  90. core/io/core_status_views.py +267 -347
  91. core/io/input/__init__.py +25 -0
  92. core/io/input/command_mode_handler.py +711 -0
  93. core/io/input/display_controller.py +128 -0
  94. core/io/input/hook_registrar.py +286 -0
  95. core/io/input/input_loop_manager.py +421 -0
  96. core/io/input/key_press_handler.py +502 -0
  97. core/io/input/modal_controller.py +1011 -0
  98. core/io/input/paste_processor.py +339 -0
  99. core/io/input/status_modal_renderer.py +184 -0
  100. core/io/input_errors.py +5 -1
  101. core/io/input_handler.py +211 -2452
  102. core/io/key_parser.py +7 -0
  103. core/io/layout.py +15 -3
  104. core/io/message_coordinator.py +111 -2
  105. core/io/message_renderer.py +129 -4
  106. core/io/status_renderer.py +147 -607
  107. core/io/terminal_renderer.py +97 -51
  108. core/io/terminal_state.py +21 -4
  109. core/io/visual_effects.py +816 -165
  110. core/llm/agent_manager.py +1063 -0
  111. core/llm/api_adapters/__init__.py +44 -0
  112. core/llm/api_adapters/anthropic_adapter.py +432 -0
  113. core/llm/api_adapters/base.py +241 -0
  114. core/llm/api_adapters/openai_adapter.py +326 -0
  115. core/llm/api_communication_service.py +167 -113
  116. core/llm/conversation_logger.py +322 -16
  117. core/llm/conversation_manager.py +556 -30
  118. core/llm/file_operations_executor.py +84 -32
  119. core/llm/llm_service.py +934 -103
  120. core/llm/mcp_integration.py +541 -57
  121. core/llm/message_display_service.py +135 -18
  122. core/llm/plugin_sdk.py +1 -2
  123. core/llm/profile_manager.py +1183 -0
  124. core/llm/response_parser.py +274 -56
  125. core/llm/response_processor.py +16 -3
  126. core/llm/tool_executor.py +6 -1
  127. core/logging/__init__.py +2 -0
  128. core/logging/setup.py +34 -6
  129. core/models/resume.py +54 -0
  130. core/plugins/__init__.py +4 -2
  131. core/plugins/base.py +127 -0
  132. core/plugins/collector.py +23 -161
  133. core/plugins/discovery.py +37 -3
  134. core/plugins/factory.py +6 -12
  135. core/plugins/registry.py +5 -17
  136. core/ui/config_widgets.py +128 -28
  137. core/ui/live_modal_renderer.py +2 -1
  138. core/ui/modal_actions.py +5 -0
  139. core/ui/modal_overlay_renderer.py +0 -60
  140. core/ui/modal_renderer.py +268 -7
  141. core/ui/modal_state_manager.py +29 -4
  142. core/ui/widgets/base_widget.py +7 -0
  143. core/updates/__init__.py +10 -0
  144. core/updates/version_check_service.py +348 -0
  145. core/updates/version_comparator.py +103 -0
  146. core/utils/config_utils.py +685 -526
  147. core/utils/plugin_utils.py +1 -1
  148. core/utils/session_naming.py +111 -0
  149. fonts/LICENSE +21 -0
  150. fonts/README.md +46 -0
  151. fonts/SymbolsNerdFont-Regular.ttf +0 -0
  152. fonts/SymbolsNerdFontMono-Regular.ttf +0 -0
  153. fonts/__init__.py +44 -0
  154. {kollabor-0.4.9.dist-info → kollabor-0.4.15.dist-info}/METADATA +54 -4
  155. kollabor-0.4.15.dist-info/RECORD +228 -0
  156. {kollabor-0.4.9.dist-info → kollabor-0.4.15.dist-info}/top_level.txt +2 -0
  157. plugins/agent_orchestrator/__init__.py +39 -0
  158. plugins/agent_orchestrator/activity_monitor.py +181 -0
  159. plugins/agent_orchestrator/file_attacher.py +77 -0
  160. plugins/agent_orchestrator/message_injector.py +135 -0
  161. plugins/agent_orchestrator/models.py +48 -0
  162. plugins/agent_orchestrator/orchestrator.py +403 -0
  163. plugins/agent_orchestrator/plugin.py +976 -0
  164. plugins/agent_orchestrator/xml_parser.py +191 -0
  165. plugins/agent_orchestrator_plugin.py +9 -0
  166. plugins/enhanced_input/box_styles.py +1 -0
  167. plugins/enhanced_input/color_engine.py +19 -4
  168. plugins/enhanced_input/config.py +2 -2
  169. plugins/enhanced_input_plugin.py +61 -11
  170. plugins/fullscreen/__init__.py +6 -2
  171. plugins/fullscreen/example_plugin.py +1035 -222
  172. plugins/fullscreen/setup_wizard_plugin.py +592 -0
  173. plugins/fullscreen/space_shooter_plugin.py +131 -0
  174. plugins/hook_monitoring_plugin.py +436 -78
  175. plugins/query_enhancer_plugin.py +66 -30
  176. plugins/resume_conversation_plugin.py +1494 -0
  177. plugins/save_conversation_plugin.py +98 -32
  178. plugins/system_commands_plugin.py +70 -56
  179. plugins/tmux_plugin.py +154 -78
  180. plugins/workflow_enforcement_plugin.py +94 -92
  181. system_prompt/default.md +952 -886
  182. core/io/input_mode_manager.py +0 -402
  183. core/io/modal_interaction_handler.py +0 -315
  184. core/io/raw_input_processor.py +0 -946
  185. core/storage/__init__.py +0 -5
  186. core/storage/state_manager.py +0 -84
  187. core/ui/widget_integration.py +0 -222
  188. core/utils/key_reader.py +0 -171
  189. kollabor-0.4.9.dist-info/RECORD +0 -128
  190. {kollabor-0.4.9.dist-info → kollabor-0.4.15.dist-info}/WHEEL +0 -0
  191. {kollabor-0.4.9.dist-info → kollabor-0.4.15.dist-info}/entry_points.txt +0 -0
  192. {kollabor-0.4.9.dist-info → kollabor-0.4.15.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,1077 @@
1
+ <!-- Codebase Analysis skill - systematic investigation of unfamiliar codebases -->
2
+
3
+ codebase-analysis mode: READ ONLY INVESTIGATION
4
+
5
+ when this skill is active, you follow systematic codebase exploration.
6
+ this is a comprehensive guide to analyzing unfamiliar software projects.
7
+
8
+
9
+ PHASE 0: ENVIRONMENT AND PROJECT TYPE VERIFICATION
10
+
11
+ before analyzing ANY codebase, identify the project type and tools.
12
+
13
+
14
+ identify primary language
15
+
16
+ <terminal>head -20 README.md 2>/dev/null || echo "no README found"</terminal>
17
+
18
+ <terminal>find . -maxdepth 2 -name "*.py" -o -name "*.js" -o -name "*.ts" -o -name "*.go" -o -name "*.rs" -o -name "*.java" -o -name "*.rb" -o -name "*.php" | head -20</terminal>
19
+
20
+ <terminal>ls -la | grep -E "\.(py|js|ts|go|rs|java|rb|php)$"</terminal>
21
+
22
+
23
+ detect package manager
24
+
25
+ python projects:
26
+ <terminal>ls -la | grep -E "(requirements\.txt|pyproject\.toml|setup\.py|Pipfile|poetry\.lock|pyproject\.toml)"</terminal>
27
+
28
+ javascript/node projects:
29
+ <terminal>ls -la | grep -E "(package\.json|package-lock\.json|yarn\.lock|pnpm-lock\.yaml)"</terminal>
30
+
31
+ rust projects:
32
+ <terminal>ls -la | grep -E "Cargo\.toml"</terminal>
33
+
34
+ go projects:
35
+ <terminal>ls -la | grep -E "go\.mod"</terminal>
36
+
37
+ java/maven projects:
38
+ <terminal>ls -la | grep -E "pom\.xml"</terminal>
39
+
40
+ java/gradle projects:
41
+ <terminal>ls -la | grep -E "build\.gradle"</terminal>
42
+
43
+
44
+ detect framework
45
+
46
+ python web frameworks:
47
+ <terminal>grep -r "flask\|django\|fastapi\|tornado\|aiohttp" --include="*.py" . 2>/dev/null | head -5</terminal>
48
+
49
+ javascript frameworks:
50
+ <terminal>grep -r "react\|vue\|angular\|svelte\|next\|nuxt" package.json 2>/dev/null | head -5</terminal>
51
+
52
+ <terminal>cat package.json 2>/dev/null | grep -E "(express|koa|hapi|nest)"</terminal>
53
+
54
+
55
+ detect build system
56
+
57
+ <terminal>ls -la | grep -E "(Makefile|CMake|build\.sh|webpack\.config|vite\.config|tsconfig\.json)"</terminal>
58
+
59
+ <terminal>cat Makefile 2>/dev/null | head -20</terminal>
60
+
61
+ <terminal>cat pyproject.toml 2>/dev/null | grep -A5 "\[build-system\]"</terminal>
62
+
63
+
64
+ verify project structure
65
+
66
+ <terminal>ls -la</terminal>
67
+
68
+ <terminal>tree -L 2 -I 'node_modules|venv|__pycache__|target|.git' 2>/dev/null || find . -maxdepth 2 -type d | grep -v -E "(node_modules|venv|__pycache__|target|.git|\.pytest_cache)" | head -30</terminal>
69
+
70
+ <terminal>find . -maxdepth 1 -type d | sort</terminal>
71
+
72
+
73
+ detect version control
74
+
75
+ <terminal>ls -la .git 2>/dev/null && echo "git repo" || echo "no git"</terminal>
76
+
77
+ <terminal>git remote -v 2>/dev/null | head -5</terminal>
78
+
79
+ <terminal>git log --oneline -10 2>/dev/null</terminal>
80
+
81
+
82
+ detect testing framework
83
+
84
+ python:
85
+ <terminal>find . -name "test_*.py" -o -name "*_test.py" | head -10</terminal>
86
+ <terminal>grep -r "pytest\|unittest\|nose" --include="*.py" . 2>/dev/null | head -5</terminal>
87
+
88
+ javascript:
89
+ <terminal>grep -E "(jest|mocha|jasmine|vitest|cypress)" package.json 2>/dev/null</terminal>
90
+
91
+ <terminal>ls -la __tests__ tests/ spec/ 2>/dev/null</terminal>
92
+
93
+
94
+ PHASE 1: ENTRY POINTS AND EXECUTION FLOW
95
+
96
+
97
+ identify main entry points
98
+
99
+ python projects:
100
+ <terminal>find . -name "main.py" -o -name "__main__.py" -o -name "app.py" -o -name "run.py" | head -10</terminal>
101
+
102
+ <terminal>grep -r "if __name__" --include="*.py" . 2>/dev/null | head -10</terminal>
103
+
104
+ javascript projects:
105
+ <terminal>cat package.json 2>/dev/null | grep -A3 '"bin"'</terminal>
106
+ <terminal>cat package.json 2>/dev/null | grep -A3 '"main"'</terminal>
107
+ <terminal>find . -name "index.js" -o -name "server.js" -o -name "app.js" | head -10</terminal>
108
+
109
+ rust:
110
+ <terminal>cat Cargo.toml 2>/dev/null | grep -A5 "\[bin\]"</terminal>
111
+ <terminal>find src -name "main.rs"</terminal>
112
+
113
+ go:
114
+ <terminal>find . -name "main.go"</terminal>
115
+
116
+
117
+ identify cli entry points
118
+
119
+ <terminal>cat pyproject.toml 2>/dev/null | grep -A10 "\[project\.scripts\]\|\[project\.entry-points\]"</terminal>
120
+
121
+ <terminal>cat setup.py 2>/dev/null | grep -A10 "entry_points"</terminal>
122
+
123
+ <terminal>grep -r "argparse\|click\|typer\|fire" --include="*.py" . 2>/dev/null | head -10</terminal>
124
+
125
+
126
+ identify web server entry points
127
+
128
+ python:
129
+ <terminal>grep -r "app\.run\|uvicorn\|gunicorn\|waitress" --include="*.py" . 2>/dev/null | head -10</terminal>
130
+
131
+ <terminal>grep -r "@app\.route\|@router\|FastAPI\|Flask" --include="*.py" . 2>/dev/null | head -10</terminal>
132
+
133
+ javascript:
134
+ <terminal>grep -r "app\.listen\|server\.listen" --include="*.js" . 2>/dev/null | head -10</terminal>
135
+
136
+ <terminal>cat package.json 2>/dev/null | grep -A5 '"scripts"'</terminal>
137
+
138
+
139
+ trace execution flow
140
+
141
+ step 1: read the main entry file
142
+ <read><file>PATH_TO_MAIN_FILE</file></read>
143
+
144
+ step 2: identify imports and dependencies
145
+ <terminal>grep "^import\|^from" PATH_TO_MAIN_FILE 2>/dev/null</terminal>
146
+
147
+ step 3: find where initialization happens
148
+ <terminal>grep -n "def main\|class.*App\|if __name__" PATH_TO_MAIN_FILE 2>/dev/null</terminal>
149
+
150
+ step 4: trace the call chain
151
+ identify the first function called
152
+ identify what classes are instantiated
153
+ identify what configuration is loaded
154
+
155
+
156
+ document the execution flow template
157
+
158
+ entry point: [file and line where execution starts]
159
+
160
+ initialization sequence:
161
+ [1] [what happens first]
162
+ [2] [what happens second]
163
+ [3] [what happens third]
164
+
165
+ key modules loaded:
166
+ - [module name] - [purpose]
167
+ - [module name] - [purpose]
168
+
169
+ main loop/event handler:
170
+ [location of main event loop or request handler]
171
+
172
+
173
+ PHASE 2: PROJECT STRUCTURE MAPPING
174
+
175
+
176
+ map directory structure
177
+
178
+ <terminal>find . -type d -not -path "*/node_modules/*" -not -path "*/.git/*" -not -path "*/venv/*" -not -path "*/__pycache__/*" -not -path "*/target/*" -not -path "*/\.pytest_cache/*" | head -50</terminal>
179
+
180
+ <terminal>tree -L 3 -I 'node_modules|venv|__pycache__|target|.git|dist|build' 2>/dev/null || echo "tree not installed"</terminal>
181
+
182
+
183
+ categorize directories by purpose
184
+
185
+ source code locations:
186
+ <terminal>find . -type d -name "src" -o -name "lib" -o -name "app" -o -name "core" -o -name "server"</terminal>
187
+
188
+ test locations:
189
+ <terminal>find . -type d -name "test*" -o -name "spec*" -o -name "__tests__"</terminal>
190
+
191
+ config locations:
192
+ <terminal>find . -type d -name "config" -o -name "settings" -o -name "conf"</terminal>
193
+
194
+ documentation locations:
195
+ <terminal>find . -type d -name "doc*" -o -name "examples"</terminal>
196
+
197
+
198
+ analyze file distribution
199
+
200
+ python:
201
+ <terminal>find . -name "*.py" -not -path "*/venv/*" -not -path "*/__pycache__/*" | wc -l</terminal>
202
+
203
+ <terminal>find . -name "*.py" -not -path "*/venv/*" -not -path "*/__pycache__/*" -exec wc -l {} + | sort -rn | head -20</terminal>
204
+
205
+ javascript:
206
+ <terminal>find . -name "*.js" -not -path "*/node_modules/*" -not -path "*/dist/*" | wc -l</terminal>
207
+
208
+ <terminal>find . -name "*.ts" -not -path "*/node_modules/*" | wc -l</terminal>
209
+
210
+ identify largest files:
211
+ <terminal>find . -name "*.py" -o -name "*.js" -o -name "*.ts" | grep -v node_modules | xargs wc -l 2>/dev/null | sort -rn | head -20</terminal>
212
+
213
+
214
+ identify code organization patterns
215
+
216
+ pattern: feature-based
217
+ src/
218
+ auth/
219
+ database/
220
+ api/
221
+ utils/
222
+
223
+ pattern: layer-based
224
+ src/
225
+ models/
226
+ controllers/
227
+ services/
228
+ repositories/
229
+
230
+ pattern: platform-based
231
+ frontend/
232
+ backend/
233
+ shared/
234
+
235
+ identify which pattern this project follows:
236
+ <terminal>ls -la src/ 2>/dev/null || ls -la app/ 2>/dev/null || ls -la lib/ 2>/dev/null</terminal>
237
+
238
+
239
+ PHASE 3: DEPENDENCY GRAPH ANALYSIS
240
+
241
+
242
+ analyze direct dependencies
243
+
244
+ python - requirements.txt:
245
+ <read><file>requirements.txt</file></read>
246
+
247
+ python - pyproject.toml:
248
+ <terminal>cat pyproject.toml 2>/dev/null | grep -A20 "\[project\.dependencies\]"</terminal>
249
+
250
+ javascript:
251
+ <terminal>cat package.json 2>/dev/null | grep -A50 '"dependencies"'</terminal>
252
+
253
+ rust:
254
+ <terminal>cat Cargo.toml 2>/dev/null | grep -A50 "\[dependencies\]"</terminal>
255
+
256
+
257
+ identify external library usage
258
+
259
+ python:
260
+ <terminal>grep -rh "^import\|^from" --include="*.py" src/ app/ 2>/dev/null | sort | uniq -c | sort -rn | head -30</terminal>
261
+
262
+ what to look for:
263
+ - web frameworks (flask, django, fastapi)
264
+ - database clients (sqlalchemy, pymongo, psycopg2)
265
+ - auth libraries (authlib, pyjwt, passlib)
266
+ - utilities (requests, click, python-dotenv)
267
+ - data processing (pandas, numpy)
268
+
269
+ javascript:
270
+ <terminal>grep -rh "^import\|^const.*require" --include="*.js" --include="*.ts" src/ 2>/dev/null | sort | uniq -c | sort -rn | head -30</terminal>
271
+
272
+
273
+ identify internal module coupling
274
+
275
+ python:
276
+ <terminal>grep -rh "^from \.\|^from .*import" --include="*.py" src/ 2>/dev/null | sed 's/from //' | sed 's/ import.*//' | sort | uniq -c | sort -rn</terminal>
277
+
278
+ find which modules are imported most:
279
+ <terminal>grep -r "^from" --include="*.py" . 2>/dev/null | grep -v "from \." | grep -v "from __future__" | cut -d: -f2 | cut -d' ' -f2 | cut -d'.' -f1 | sort | uniq -c | sort -rn | head -20</terminal>
280
+
281
+
282
+ identify circular dependencies risk
283
+
284
+ look for:
285
+ - modules that import each other
286
+ - top-level imports that may cause issues
287
+
288
+ python check:
289
+ <terminal>grep -r "^import" --include="*.py" . 2>/dev/null | grep -v "__pycache__" | cut -d: -f1 | xargs -I{} basename {} .py | sort | uniq -c | sort -rn | head -20</terminal>
290
+
291
+
292
+ document dependency insights
293
+
294
+ critical external dependencies:
295
+ - [library] - [version] - [purpose] - [alternatives]
296
+
297
+ internal hot spots:
298
+ - [module] - imported by [n] other modules
299
+
300
+ coupling concerns:
301
+ - [module a] <-> [module b] potential circular dependency
302
+ - [module] - high coupling, may need refactoring
303
+
304
+ dependency health:
305
+ - [ ] dependencies actively maintained
306
+ - [ ] no deprecated dependencies in use
307
+ - [ ] dependency versions are compatible
308
+
309
+
310
+ PHASE 4: CONFIGURATION ANALYSIS
311
+
312
+
313
+ locate configuration files
314
+
315
+ <terminal>find . -maxdepth 2 -type f \( -name "*.env*" -o -name "*config*" -o -name "*settings*" -o -name "*.yaml" -o -name "*.yml" -o -name "*.toml" -o -name "*.ini" \) | grep -v node_modules | head -20</terminal>
316
+
317
+ <terminal>ls -la | grep -E "\.(env|yaml|yml|toml|ini|json)$"</terminal>
318
+
319
+ <terminal>find . -name ".env*" -o -name "config.*" -o -name "settings.*" | head -20</terminal>
320
+
321
+
322
+ analyze configuration patterns
323
+
324
+ environment variable usage:
325
+ <terminal>grep -rh "os\.getenv\|os\.environ\|process\.env" --include="*.py" --include="*.js" --include="*.ts" . 2>/dev/null | sort | uniq | head -30</terminal>
326
+
327
+ <terminal>grep -rh "getenv\|environ" --include="*.py" . 2>/dev/null | grep -v "__pycache__" | sort | uniq | head -30</terminal>
328
+
329
+
330
+ identify configuration schema
331
+
332
+ <read><file>config.py 2>/dev/null || settings.py 2>/dev/null || src/config.py 2>/dev/null</file></read>
333
+
334
+ look for:
335
+ - configuration classes
336
+ - default values
337
+ - validation logic
338
+ - environment override patterns
339
+
340
+
341
+ document configuration findings
342
+
343
+ configuration locations:
344
+ - [file] - [purpose]
345
+
346
+ environment variables used:
347
+ - [VAR_NAME] - [purpose] - [default value if any]
348
+
349
+ configuration patterns:
350
+ - [pattern used, e.g., 12-factor app, singleton config, etc.]
351
+
352
+
353
+ PHASE 5: DATA MODEL ANALYSIS
354
+
355
+
356
+ identify data models
357
+
358
+ python:
359
+ <terminal>find . -name "models.py" -o -name "model.py" -o -name "schemas.py" -o -name "types.py" | head -10</terminal>
360
+
361
+ <terminal>grep -r "class.*\(Model\|Base\)" --include="*.py" . 2>/dev/null | grep -v "__pycache__" | head -30</terminal>
362
+
363
+ <terminal>grep -r "@dataclass\|from pydantic\|from sqlalchemy" --include="*.py" . 2>/dev/null | head -20</terminal>
364
+
365
+ javascript/typescript:
366
+ <terminal>grep -r "interface\|type.*=" --include="*.ts" --include="*.tsx" . 2>/dev/null | head -30</terminal>
367
+
368
+ <terminal>grep -r "mongoose\.Schema\|sequelize\.define" --include="*.js" --include="*.ts" . 2>/dev/null | head -20</terminal>
369
+
370
+
371
+ analyze model relationships
372
+
373
+ read key model files:
374
+ <read><file>PATH_TO_MODELS</file></read>
375
+
376
+ identify:
377
+ - one-to-many relationships
378
+ - many-to-many relationships
379
+ - foreign keys
380
+ - cascade behaviors
381
+
382
+ python orm hints:
383
+ <terminal>grep -r "relationship\|ForeignKey\|back_populates\|backref" --include="*.py" . 2>/dev/null | head -30</terminal>
384
+
385
+
386
+ identify database schema
387
+
388
+ <terminal>find . -name "schema.sql" -o -name "migrations" -o -name "alembic"</terminal>
389
+
390
+ <terminal>ls -la migrations/ 2>/dev/null || echo "no migrations directory"</terminal>
391
+
392
+ <terminal>find . -name "*.sql" | head -10</terminal>
393
+
394
+
395
+ document data model
396
+
397
+ core entities:
398
+ - [entity name] - [purpose] - [key fields]
399
+
400
+ relationships:
401
+ - [entity a] -> [entity b] - [relationship type]
402
+
403
+ data persistence:
404
+ - database: [postgresql/mysql/sqlite/mongodb/etc]
405
+ - orm: [sqlalchemy/django orm/mongoose/etc]
406
+ - migration tool: [alembic/flyway/etc]
407
+
408
+
409
+ PHASE 6: API AND INTERFACE ANALYSIS
410
+
411
+
412
+ identify api endpoints
413
+
414
+ rest apis:
415
+ <terminal>grep -r "@app\.route\|@bp\.route\|@router\|@.*\.get\|@.*\.post" --include="*.py" . 2>/dev/null | head -30</terminal>
416
+
417
+ <terminal>grep -r "app\.(get|post|put|delete|patch)" --include="*.js" --include="*.ts" . 2>/dev/null | head -30</terminal>
418
+
419
+ graphql:
420
+ <terminal>find . -name "*.graphql" -o -name "schema.graphql" | head -10</terminal>
421
+
422
+ <terminal>grep -r "type Query\|type Mutation" --include="*.graphql" --include="*.ts" --include="*.js" . 2>/dev/null | head -20</terminal>
423
+
424
+
425
+ map api structure
426
+
427
+ <terminal>grep -rh "@.*\.route\|@.*\.get\|@.*\.post" --include="*.py" . 2>/dev/null | sort</terminal>
428
+
429
+ <terminal>grep -rh "router\.(get|post|put|delete|patch)" --include="*.ts" --include="*.js" . 2>/dev/null | sort</terminal>
430
+
431
+ for each endpoint found:
432
+ - read the handler function
433
+ - identify request format
434
+ - identify response format
435
+ - identify authentication requirements
436
+
437
+
438
+ identify authentication/authorization
439
+
440
+ <terminal>grep -r "@login_required\|@auth\|authenticate\|authorize" --include="*.py" --include="*.js" --include="*.ts" . 2>/dev/null | head -20</terminal>
441
+
442
+ <terminal>grep -r "jwt\|oauth\|session\|cookie" --include="*.py" --include="*.js" . 2>/dev/null | grep -v "__pycache__" | grep -v node_modules | head -30</terminal>
443
+
444
+
445
+ identify middleware and interceptors
446
+
447
+ <terminal>grep -r "middleware\|interceptor\|before_request\|after_request" --include="*.py" --include="*.js" . 2>/dev/null | head -20</terminal>
448
+
449
+ <terminal>find . -name "*middleware*" | grep -v node_modules</terminal>
450
+
451
+
452
+ document api surface
453
+
454
+ api base url: [from config or main file]
455
+
456
+ public endpoints:
457
+ - [method] [path] - [description]
458
+
459
+ authenticated endpoints:
460
+ - [method] [path] - [auth type] - [description]
461
+
462
+ webhooks/events:
463
+ - [path] - [trigger]
464
+
465
+ middleware chain:
466
+ [1] [middleware name] - [purpose]
467
+ [2] [middleware name] - [purpose]
468
+
469
+
470
+ PHASE 7: ERROR HANDLING AND LOGGING
471
+
472
+
473
+ analyze error handling patterns
474
+
475
+ python:
476
+ <terminal>grep -r "try:\|except\|raise " --include="*.py" . 2>/dev/null | wc -l</terminal>
477
+
478
+ <terminal>grep -r "except Exception" --include="*.py" . 2>/dev/null | head -20</terminal>
479
+
480
+ <terminal>grep -r "class.*Error\|class.*Exception" --include="*.py" . 2>/dev/null | head -30</terminal>
481
+
482
+ javascript:
483
+ <terminal>grep -r "try {\|catch\|throw new" --include="*.js" --include="*.ts" . 2>/dev/null | wc -l</terminal>
484
+
485
+
486
+ identify custom exceptions
487
+
488
+ <terminal>find . -name "exceptions.py" -o -name "errors.py" -o -name "error.py"</terminal>
489
+
490
+ <read><file>PATH_TO_EXCEPTIONS_FILE</file></read>
491
+
492
+ document:
493
+ - exception hierarchy
494
+ - when each exception is raised
495
+ - how exceptions are handled globally
496
+
497
+
498
+ analyze logging patterns
499
+
500
+ python:
501
+ <terminal>grep -r "import logging\|logger\." --include="*.py" . 2>/dev/null | head -30</terminal>
502
+
503
+ <terminal>grep -rh "logger\.(debug|info|warning|error|critical)" --include="*.py" . 2>/dev/null | sort | uniq -c | sort -rn</terminal>
504
+
505
+ javascript:
506
+ <terminal>grep -r "console\.(log|warn|error|debug)" --include="*.js" --include="*.ts" . 2>/dev/null | wc -l</terminal>
507
+
508
+ <terminal>grep -r "winston\|pino\|bunyan" --include="*.js" --include="*.ts" . 2>/dev/null | head -20</terminal>
509
+
510
+
511
+ identify log configuration
512
+
513
+ <terminal>find . -name "logging.conf" -o -name "*log*.json" -o -name "*log*.yaml"</terminal>
514
+
515
+ <terminal>grep -r "basicConfig\|getLogger\|dictConfig" --include="*.py" . 2>/dev/null | head -20</terminal>
516
+
517
+
518
+ document error handling
519
+
520
+ error handling strategy:
521
+ - [global exception handler location]
522
+ - [error reporting format]
523
+
524
+ logging configuration:
525
+ - [log levels used]
526
+ - [log destinations: file/stdout/service]
527
+ - [log format]
528
+
529
+ custom exceptions:
530
+ - [exception name] - [when raised]
531
+
532
+
533
+ PHASE 8: TESTING COVERAGE ANALYSIS
534
+
535
+
536
+ identify test files
537
+
538
+ <terminal>find . -name "test_*.py" -o -name "*_test.py" -o -name "*.test.js" -o -name "*.spec.js" -o -name "*.spec.ts" | grep -v node_modules | head -30</terminal>
539
+
540
+ <terminal>find . -type d -name "test*" -o -name "spec*" -o -name "__tests__" | head -10</terminal>
541
+
542
+
543
+ analyze test structure
544
+
545
+ <terminal>ls -la tests/ 2>/dev/null || ls -la test/ 2>/dev/null || ls -la __tests__/ 2>/dev/null</terminal>
546
+
547
+ <terminal>find tests/ -type f -name "*.py" 2>/dev/null | wc -l</terminal>
548
+
549
+ <terminal>grep -r "def test_\|describe\|it(" tests/ 2>/dev/null | wc -l</terminal>
550
+
551
+
552
+ identify test utilities and fixtures
553
+
554
+ python:
555
+ <terminal>find tests/ -name "conftest.py" -o -name "fixtures.py" -o -name "utils.py" -o -name "helpers.py"</terminal>
556
+
557
+ <terminal>grep -r "@pytest\.fixture\|@fixture" tests/ 2>/dev/null | head -30</terminal>
558
+
559
+ javascript:
560
+ <terminal>find tests/ -name "setup.*" -o -name "helpers.*" -o -name "mocks.*"</terminal>
561
+
562
+
563
+ identify test doubles and mocks
564
+
565
+ <terminal>grep -r "mock\|stub\|spy" tests/ 2>/dev/null | head -30</terminal>
566
+
567
+ <terminal>grep -r "mocker\|patch\|unittest\.mock" tests/ 2>/dev/null | head -20</terminal>
568
+
569
+
570
+ analyze test coverage
571
+
572
+ <terminal>python -m pytest --collect-only 2>/dev/null | tail -5</terminal>
573
+
574
+ <terminal>python -m pytest tests/ --collect-only -q 2>/dev/null | tail -3</terminal>
575
+
576
+ check if coverage is configured:
577
+ <terminal>grep -r "pytest-cov\|coverage" pyproject.toml setup.cfg pytest.ini 2>/dev/null</terminal>
578
+
579
+
580
+ document test coverage
581
+
582
+ test framework: [pytest/unittest/jest/mocha/etc]
583
+
584
+ test locations:
585
+ - [directory] - [type of tests]
586
+
587
+ test counts:
588
+ - unit tests: [approximately]
589
+ - integration tests: [approximately]
590
+ - e2e tests: [approximately]
591
+
592
+ coverage status:
593
+ - coverage tool: [yes/no]
594
+ - coverage percentage: [if available]
595
+
596
+ testing gaps:
597
+ - [modules without tests]
598
+ - [scenarios not covered]
599
+
600
+
601
+ PHASE 9: ASYNC AND CONCURRENCY PATTERNS
602
+
603
+
604
+ identify async code
605
+
606
+ python:
607
+ <terminal>grep -r "async def\|await " --include="*.py" . 2>/dev/null | wc -l</terminal>
608
+
609
+ <terminal>grep -r "asyncio\|aiohttp\|asyncpg" --include="*.py" . 2>/dev/null | head -20</terminal>
610
+
611
+ javascript:
612
+ <terminal>grep -r "async.*function\|await " --include="*.js" --include="*.ts" . 2>/dev/null | wc -l</terminal>
613
+
614
+ <terminal>grep -r "Promise\|\.then(" --include="*.js" --include="*.ts" . 2>/dev/null | head -20</terminal>
615
+
616
+
617
+ identify threading and multiprocessing
618
+
619
+ python:
620
+ <terminal>grep -r "Thread\|Process\|Pool\|Queue\|Lock\|Semaphore" --include="*.py" . 2>/dev/null | head -30</terminal>
621
+
622
+ <terminal>grep -r "@threaded\|@synchronized" --include="*.py" . 2>/dev/null | head -10</terminal>
623
+
624
+ javascript:
625
+ <terminal>grep -r "Worker\|cluster\|child_process" --include="*.js" --include="*.ts" . 2>/dev/null | head -20</terminal>
626
+
627
+
628
+ identify event loop patterns
629
+
630
+ python:
631
+ <terminal>grep -r "loop\.run\|asyncio\.run\|loop\.create_task" --include="*.py" . 2>/dev/null | head -20</terminal>
632
+
633
+ <terminal>grep -r "asyncio\.gather\|asyncio\.create_task" --include="*.py" . 2>/dev/null | head -20</terminal>
634
+
635
+
636
+ identify shared state and locks
637
+
638
+ <terminal>grep -r "global\|_instance\|singleton" --include="*.py" . 2>/dev/null | head -30</terminal>
639
+
640
+ <terminal>grep -r "Lock\|RLock\|Semaphore\|Event\|Condition" --include="*.py" . 2>/dev/null | head -20</terminal>
641
+
642
+
643
+ document concurrency patterns
644
+
645
+ async framework: [asyncio/tornado/etc]
646
+
647
+ async entry points:
648
+ - [function] - [location]
649
+
650
+ concurrency risks:
651
+ - [shared mutable state identified]
652
+ - [potential race conditions]
653
+
654
+ event loop:
655
+ - [where event loop is created]
656
+ - [how tasks are scheduled]
657
+
658
+
659
+ PHASE 10: CODE PATTERNS AND ANTI-PATTERNS
660
+
661
+
662
+ identify design patterns
663
+
664
+ creational patterns:
665
+ <terminal>grep -r "class.*Factory\|def create_" --include="*.py" . 2>/dev/null | head -20</terminal>
666
+
667
+ <terminal>grep -r "class.*Builder\|class.*Singleton" --include="*.py" . 2>/dev/null | head -20</terminal>
668
+
669
+ structural patterns:
670
+ <terminal>grep -r "class.*Adapter\|class.*Decorator\|class.*Proxy" --include="*.py" . 2>/dev/null | head -20</terminal>
671
+
672
+ behavioral patterns:
673
+ <terminal>grep -r "class.*Observer\|class.*Strategy\|class.*Command" --include="*.py" . 2>/dev/null | head -20</terminal>
674
+
675
+
676
+ identify code smells
677
+
678
+ long functions:
679
+ <terminal>find . -name "*.py" -exec awk '/^def /{if(NR>200)print FILENAME":"NR":"NR-200}' {} \; 2>/dev/null | head -20</terminal>
680
+
681
+ duplicated code indicators:
682
+ <terminal>find . -name "*.py" -exec wc -l {} + | sort -rn | head -20</terminal>
683
+
684
+ god objects:
685
+ <terminal>find . -name "*.py" -exec awk 'NF>0 && /^class /{name=$2} /^def /{count[name]++} END{for(n in count)if(count[n]>20)print n, count[n]}' {} \; 2>/dev/null</terminal>
686
+
687
+
688
+ identify architectural patterns
689
+
690
+ <terminal>find . -type d -name "service*" -o -name "repository*" -o -name "controller*" -o -name "view*"</terminal>
691
+
692
+ <terminal>grep -r "class.*Service\|class.*Repository\|class.*Controller" --include="*.py" . 2>/dev/null | head -30</terminal>
693
+
694
+
695
+ document patterns found
696
+
697
+ design patterns:
698
+ - [pattern name] - [location] - [purpose]
699
+
700
+ code quality concerns:
701
+ - [smell type] - [location] - [severity]
702
+
703
+ architectural pattern:
704
+ - [mvc/mvp/mvvm/layered/hexagonal/etc]
705
+
706
+
707
+ PHASE 11: DOCUMENTATION ASSESSMENT
708
+
709
+
710
+ assess documentation quality
711
+
712
+ <terminal>find . -name "README*" -o -name "CONTRIBUTING*" -o -name "CHANGELOG*" -o -name "ARCHITECTURE*" | head -20</terminal>
713
+
714
+ <terminal>find . -name "*.md" -type f | grep -v node_modules | head -20</terminal>
715
+
716
+ <terminal>ls -la docs/ 2>/dev/null || echo "no docs directory"</terminal>
717
+
718
+
719
+ analyze code documentation
720
+
721
+ python docstrings:
722
+ <terminal>grep -r '"""' --include="*.py" . 2>/dev/null | wc -l</terminal>
723
+
724
+ <terminal>grep -r "^def " --include="*.py" . 2>/dev/null | wc -l</terminal>
725
+
726
+ calculate docstring coverage ratio
727
+
728
+ type hints:
729
+ <terminal>grep -r " -> \|: int\|: str\|: List\|: Dict" --include="*.py" . 2>/dev/null | head -30</terminal>
730
+
731
+ javascript jsdoc/tsg:
732
+ <terminal>grep -r "/\*\*" --include="*.js" --include="*.ts" . 2>/dev/null | wc -l</terminal>
733
+
734
+
735
+ identify api documentation
736
+
737
+ <terminal>find . -name "swagger.*" -o -name "openapi.*" -o -name "*.yaml" -o -name "*.json" | grep -E "(api|doc|spec)" | head -10</terminal>
738
+
739
+ <terminal>grep -r "@swagger\|@api.doc" --include="*.py" . 2>/dev/null | head -20</terminal>
740
+
741
+
742
+ document documentation status
743
+
744
+ user documentation:
745
+ - [ ] README with installation
746
+ - [ ] usage examples
747
+ - [ ] contributing guidelines
748
+ - [ ] changelog
749
+
750
+ developer documentation:
751
+ - [ ] architecture overview
752
+ - [ ] api documentation
753
+ - [ ] development setup
754
+ - [ ] code comments/docstrings
755
+
756
+ documentation coverage:
757
+ - docstrings: [estimated percentage]
758
+ - type hints: [yes/partial/no]
759
+
760
+
761
+ PHASE 12: SECURITY ASSESSMENT
762
+
763
+
764
+ identify security mechanisms
765
+
766
+ authentication:
767
+ <terminal>grep -r "authenticate\|login\|password\|credential" --include="*.py" --include="*.js" . 2>/dev/null | grep -v "__pycache__" | grep -v node_modules | head -20</terminal>
768
+
769
+ authorization:
770
+ <terminal>grep -r "authorize\|permission\|role\|access" --include="*.py" --include="*.js" . 2>/dev/null | grep -v "__pycache__" | grep -v node_modules | head -20</terminal>
771
+
772
+ encryption:
773
+ <terminal>grep -r "encrypt\|decrypt\|cipher\|crypto" --include="*.py" --include="*.js" . 2>/dev/null | grep -v "__pycache__" | grep -v node_modules | head -20</terminal>
774
+
775
+
776
+ identify sensitive data handling
777
+
778
+ <terminal>grep -ri "secret\|password\|api_key\|token" --include="*.py" --include="*.js" --include="*.env*" . 2>/dev/null | grep -v node_modules | grep -v "__pycache__" | head -30</terminal>
779
+
780
+ <terminal>find . -name ".env*" -o -name "*secret*" -o -name "*credential*" | grep -v node_modules</terminal>
781
+
782
+
783
+ identify input validation
784
+
785
+ <terminal>grep -r "validate\|sanitize\|escape\|clean" --include="*.py" --include="*.js" . 2>/dev/null | grep -v node_modules | head -30</terminal>
786
+
787
+ <terminal>grep -r "pydantic\|cerberus\|marshmallow\|joi" --include="*.py" --include="*.js" . 2>/dev/null | head -20</terminal>
788
+
789
+
790
+ identify sql injection risks
791
+
792
+ <terminal>grep -r "execute.*%s\|execute.*format\|execute.*+" --include="*.py" . 2>/dev/null | head -20</terminal>
793
+
794
+ <terminal>grep -r "SELECT.*FROM.*\(format\|%\|+\)" --include="*.py" --include="*.js" . 2>/dev/null | head -20</terminal>
795
+
796
+
797
+ document security findings
798
+
799
+ authentication:
800
+ - method: [jwt/session/oauth/etc]
801
+ - implementation: [library/location]
802
+
803
+ authorization:
804
+ - model: [rbac/acl/abac/etc]
805
+ - implementation: [location]
806
+
807
+ security concerns:
808
+ - [potential vulnerability] - [location] - [severity]
809
+
810
+ sensitive data:
811
+ - [type] - [storage method]
812
+
813
+
814
+ PHASE 13: PERFORMANCE CONSIDERATIONS
815
+
816
+
817
+ identify caching mechanisms
818
+
819
+ <terminal>grep -r "cache\|Cache" --include="*.py" --include="*.js" . 2>/dev/null | grep -v node_modules | grep -v "__pycache__" | head -30</terminal>
820
+
821
+ <terminal>grep -r "redis\|memcached\|lru_cache" --include="*.py" . 2>/dev/null | head -20</terminal>
822
+
823
+
824
+ identify database query patterns
825
+
826
+ <terminal>grep -r "SELECT.*\*" --include="*.py" . 2>/dev/null | head -20</terminal>
827
+
828
+ <terminal>grep -r "\.filter\|\.where\|\.find" --include="*.py" . 2>/dev/null | head -30</terminal>
829
+
830
+ <terminal>grep -r "N+1\|eager\|preload\|joinedload" --include="*.py" . 2>/dev/null | head -20</terminal>
831
+
832
+
833
+ identify expensive operations
834
+
835
+ <terminal>grep -r "for.*in.*range\|while.*:" --include="*.py" . 2>/dev/null | head -30</terminal>
836
+
837
+ <terminal>grep -r "time\.sleep\|asyncio\.sleep" --include="*.py" . 2>/dev/null | head -20</terminal>
838
+
839
+
840
+ identify connection pooling
841
+
842
+ <terminal>grep -r "pool\|Pool\|connection" --include="*.py" . 2>/dev/null | head -30</terminal>
843
+
844
+ <terminal>grep -r "engine\.connect\|session\.begin" --include="*.py" . 2>/dev/null | head -20</terminal>
845
+
846
+
847
+ document performance findings
848
+
849
+ caching:
850
+ - [type] - [location] - [ttl]
851
+
852
+ database optimization:
853
+ - [indexes used]
854
+ - [n+1 query risks]
855
+
856
+ performance concerns:
857
+ - [concern] - [location] - [impact]
858
+
859
+
860
+ PHASE 14: BUILD AND DEPLOYMENT
861
+
862
+
863
+ identify build process
864
+
865
+ <terminal>cat Makefile 2>/dev/null | head -30</terminal>
866
+
867
+ <terminal>cat package.json 2>/dev/null | grep -A10 '"scripts"'</terminal>
868
+
869
+ <terminal>cat pyproject.toml 2>/dev/null | grep -A10 "\[build-system\]"</terminal>
870
+
871
+
872
+ identify ci/cd configuration
873
+
874
+ <terminal>find .github -name "*.yml" -o -name "*.yaml" 2>/dev/null</terminal>
875
+
876
+ <terminal>find .gitlab-ci.yml .gitlab-ci.yml docker-compose.yml Dockerfile 2>/dev/null</terminal>
877
+
878
+ <terminal>cat .github/workflows/*.yml 2>/dev/null | head -50</terminal>
879
+
880
+
881
+ identify deployment configuration
882
+
883
+ <terminal>find . -name "Dockerfile*" -o -name "docker-compose*" -o -name "kubernetes*" -o -name "helm*" | head -10</terminal>
884
+
885
+ <terminal>find . -name "*.tf" -o -name "terraform*" | head -10</terminal>
886
+
887
+ <terminal>cat Dockerfile 2>/dev/null | head -30</terminal>
888
+
889
+
890
+ identify environment configuration
891
+
892
+ <terminal>find . -name ".env*" -o -name "*production*" -o -name "*staging*" | head -20</terminal>
893
+
894
+ <terminal>grep -r "NODE_ENV\|FLASK_ENV\|DJANGO_SETTINGS\|ENVIRONMENT" --include="*.py" --include="*.js" . 2>/dev/null | head -20</terminal>
895
+
896
+
897
+ document build and deployment
898
+
899
+ build process:
900
+ - [steps to build]
901
+
902
+ ci/cd:
903
+ - [platform] - [pipeline file]
904
+
905
+ deployment:
906
+ - [method] - [configuration]
907
+
908
+ environments:
909
+ - [development]
910
+ - [staging]
911
+ - [production]
912
+
913
+
914
+ PHASE 15: ANALYSIS REPORT TEMPLATE
915
+
916
+
917
+ use this template to structure your findings:
918
+
919
+
920
+ project: [name]
921
+
922
+ overview:
923
+ language: [primary language(s)]
924
+ framework: [main framework(s)]
925
+ purpose: [what the project does]
926
+ size: [lines of code, file count]
927
+
928
+
929
+ entry points:
930
+ main: [file and line]
931
+ cli: [if applicable]
932
+ web: [if applicable]
933
+ worker: [if applicable]
934
+
935
+
936
+ architecture:
937
+ pattern: [architectural pattern identified]
938
+ layers:
939
+ - [layer] - [directory] - [purpose]
940
+ key modules:
941
+ - [module] - [purpose] - [dependencies]
942
+
943
+
944
+ data model:
945
+ database: [type]
946
+ orm: [if applicable]
947
+ key entities:
948
+ - [entity] - [fields] - [relationships]
949
+
950
+
951
+ api surface:
952
+ base: [url/path]
953
+ public endpoints:
954
+ - [method] [path] - [description]
955
+ authenticated endpoints:
956
+ - [method] [path] - [description]
957
+
958
+
959
+ dependencies:
960
+ critical:
961
+ - [library] - [purpose] - [version]
962
+ internal:
963
+ - [hot spots]
964
+ - [coupling concerns]
965
+
966
+
967
+ testing:
968
+ framework: [name]
969
+ coverage: [percentage if known]
970
+ gaps:
971
+ - [areas without tests]
972
+
973
+
974
+ code quality:
975
+ patterns:
976
+ - [design patterns found]
977
+ concerns:
978
+ - [code smells identified]
979
+ documentation:
980
+ - [quality assessment]
981
+
982
+
983
+ security:
984
+ auth: [method]
985
+ concerns:
986
+ - [potential issues]
987
+
988
+
989
+ performance:
990
+ caching: [strategy]
991
+ concerns:
992
+ - [potential bottlenecks]
993
+
994
+
995
+ deployment:
996
+ build: [process]
997
+ ci/cd: [platform]
998
+ environments: [list]
999
+
1000
+
1001
+ recommendations:
1002
+ [1] [high priority improvement]
1003
+ [2] [medium priority improvement]
1004
+ [3] [low priority improvement]
1005
+
1006
+
1007
+ PHASE 16: ANALYSIS RULES (STRICT MODE)
1008
+
1009
+
1010
+ while this skill is active, these rules are MANDATORY:
1011
+
1012
+ [1] NEVER modify files
1013
+ research agent only reads and reports
1014
+ use <read> and <terminal> tags only
1015
+ no <edit> or <create> tags
1016
+
1017
+ [2] verify before assuming
1018
+ use commands to confirm hypotheses
1019
+ don't guess based on file names
1020
+ read actual content to understand
1021
+
1022
+ [3] document everything
1023
+ keep structured notes
1024
+ use the report template
1025
+ include file paths and line numbers
1026
+
1027
+ [4] follow the dependency chain
1028
+ start from entry points
1029
+ trace imports and calls
1030
+ understand before judging
1031
+
1032
+ [5] identify patterns, not just problems
1033
+ recognize intentional architecture
1034
+ distinguish between style and bug
1035
+ note both good and bad patterns
1036
+
1037
+ [6] be thorough
1038
+ explore all directories
1039
+ check configuration files
1040
+ read documentation
1041
+
1042
+ [7] stay objective
1043
+ report findings neutrally
1044
+ provide evidence for claims
1045
+ note uncertainty
1046
+
1047
+
1048
+ FINAL REMINDERS
1049
+
1050
+
1051
+ codebase analysis is reconnaissance
1052
+
1053
+ you are mapping terrain, not building roads.
1054
+ understanding precedes recommendation.
1055
+
1056
+
1057
+ context is everything
1058
+
1059
+ a pattern that is wrong in one context
1060
+ may be intentional in another.
1061
+ consider the project's constraints.
1062
+
1063
+
1064
+ the report is your output
1065
+
1066
+ a clear, structured report enables action.
1067
+ include evidence for every claim.
1068
+ provide file paths and line numbers.
1069
+
1070
+
1071
+ you are the first step
1072
+
1073
+ analysis leads to planning.
1074
+ planning leads to implementation.
1075
+ your thoroughness enables quality.
1076
+
1077
+ now go explore some code.