claude-mpm 5.1.9__py3-none-any.whl → 5.4.14__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.

Potentially problematic release.


This version of claude-mpm might be problematic. Click here for more details.

Files changed (162) hide show
  1. claude_mpm/VERSION +1 -1
  2. claude_mpm/__init__.py +4 -0
  3. claude_mpm/agents/PM_INSTRUCTIONS.md +85 -0
  4. claude_mpm/agents/agent_loader.py +13 -44
  5. claude_mpm/agents/templates/circuit-breakers.md +138 -1
  6. claude_mpm/cli/__main__.py +4 -0
  7. claude_mpm/cli/commands/agent_state_manager.py +8 -17
  8. claude_mpm/cli/commands/auto_configure.py +210 -25
  9. claude_mpm/cli/commands/config.py +88 -2
  10. claude_mpm/cli/commands/configure.py +1097 -158
  11. claude_mpm/cli/commands/configure_agent_display.py +15 -6
  12. claude_mpm/cli/commands/mpm_init/core.py +160 -46
  13. claude_mpm/cli/commands/mpm_init/knowledge_extractor.py +481 -0
  14. claude_mpm/cli/commands/mpm_init/prompts.py +280 -0
  15. claude_mpm/cli/commands/skills.py +21 -2
  16. claude_mpm/cli/commands/summarize.py +413 -0
  17. claude_mpm/cli/executor.py +11 -3
  18. claude_mpm/cli/parsers/base_parser.py +5 -0
  19. claude_mpm/cli/parsers/config_parser.py +153 -83
  20. claude_mpm/cli/parsers/skills_parser.py +3 -2
  21. claude_mpm/cli/startup.py +333 -89
  22. claude_mpm/commands/mpm-config.md +266 -0
  23. claude_mpm/commands/{mpm-ticket-organize.md → mpm-organize.md} +4 -5
  24. claude_mpm/config/agent_sources.py +27 -0
  25. claude_mpm/core/framework/formatters/content_formatter.py +3 -13
  26. claude_mpm/core/framework/loaders/agent_loader.py +8 -5
  27. claude_mpm/core/framework_loader.py +4 -2
  28. claude_mpm/core/logger.py +13 -0
  29. claude_mpm/core/socketio_pool.py +3 -3
  30. claude_mpm/core/unified_agent_registry.py +5 -15
  31. claude_mpm/hooks/claude_hooks/correlation_manager.py +60 -0
  32. claude_mpm/hooks/claude_hooks/event_handlers.py +206 -78
  33. claude_mpm/hooks/claude_hooks/hook_handler.py +6 -0
  34. claude_mpm/hooks/claude_hooks/installer.py +33 -10
  35. claude_mpm/hooks/claude_hooks/memory_integration.py +26 -9
  36. claude_mpm/hooks/claude_hooks/response_tracking.py +2 -3
  37. claude_mpm/hooks/claude_hooks/services/connection_manager.py +4 -0
  38. claude_mpm/hooks/memory_integration_hook.py +46 -1
  39. claude_mpm/init.py +0 -19
  40. claude_mpm/scripts/claude-hook-handler.sh +58 -18
  41. claude_mpm/scripts/launch_monitor.py +93 -13
  42. claude_mpm/services/agents/agent_recommendation_service.py +278 -0
  43. claude_mpm/services/agents/agent_review_service.py +280 -0
  44. claude_mpm/services/agents/deployment/agent_discovery_service.py +2 -3
  45. claude_mpm/services/agents/deployment/agent_template_builder.py +4 -2
  46. claude_mpm/services/agents/deployment/multi_source_deployment_service.py +78 -9
  47. claude_mpm/services/agents/deployment/remote_agent_discovery_service.py +335 -53
  48. claude_mpm/services/agents/git_source_manager.py +34 -0
  49. claude_mpm/services/agents/loading/base_agent_manager.py +1 -13
  50. claude_mpm/services/agents/sources/git_source_sync_service.py +8 -1
  51. claude_mpm/services/agents/toolchain_detector.py +10 -6
  52. claude_mpm/services/analysis/__init__.py +11 -1
  53. claude_mpm/services/analysis/clone_detector.py +1030 -0
  54. claude_mpm/services/command_deployment_service.py +71 -10
  55. claude_mpm/services/event_bus/config.py +3 -1
  56. claude_mpm/services/git/git_operations_service.py +93 -8
  57. claude_mpm/services/monitor/daemon.py +9 -2
  58. claude_mpm/services/monitor/daemon_manager.py +39 -3
  59. claude_mpm/services/monitor/server.py +225 -19
  60. claude_mpm/services/self_upgrade_service.py +120 -12
  61. claude_mpm/services/skills/__init__.py +3 -0
  62. claude_mpm/services/skills/git_skill_source_manager.py +32 -2
  63. claude_mpm/services/skills/selective_skill_deployer.py +230 -0
  64. claude_mpm/services/skills/skill_to_agent_mapper.py +406 -0
  65. claude_mpm/services/skills_deployer.py +64 -3
  66. claude_mpm/services/socketio/event_normalizer.py +15 -1
  67. claude_mpm/services/socketio/server/core.py +160 -21
  68. claude_mpm/services/version_control/git_operations.py +103 -0
  69. claude_mpm/utils/agent_filters.py +17 -44
  70. {claude_mpm-5.1.9.dist-info → claude_mpm-5.4.14.dist-info}/METADATA +47 -84
  71. {claude_mpm-5.1.9.dist-info → claude_mpm-5.4.14.dist-info}/RECORD +76 -150
  72. claude_mpm-5.4.14.dist-info/entry_points.txt +5 -0
  73. claude_mpm-5.4.14.dist-info/licenses/LICENSE +94 -0
  74. claude_mpm-5.4.14.dist-info/licenses/LICENSE-FAQ.md +153 -0
  75. claude_mpm/agents/BASE_AGENT_TEMPLATE.md +0 -292
  76. claude_mpm/agents/BASE_DOCUMENTATION.md +0 -53
  77. claude_mpm/agents/BASE_ENGINEER.md +0 -658
  78. claude_mpm/agents/BASE_OPS.md +0 -219
  79. claude_mpm/agents/BASE_PM.md +0 -480
  80. claude_mpm/agents/BASE_PROMPT_ENGINEER.md +0 -787
  81. claude_mpm/agents/BASE_QA.md +0 -167
  82. claude_mpm/agents/BASE_RESEARCH.md +0 -53
  83. claude_mpm/agents/base_agent.json +0 -31
  84. claude_mpm/agents/base_agent_loader.py +0 -601
  85. claude_mpm/cli/ticket_cli.py +0 -35
  86. claude_mpm/commands/mpm-config-view.md +0 -150
  87. claude_mpm/dashboard/analysis_runner.py +0 -455
  88. claude_mpm/dashboard/index.html +0 -13
  89. claude_mpm/dashboard/open_dashboard.py +0 -66
  90. claude_mpm/dashboard/static/css/activity.css +0 -1958
  91. claude_mpm/dashboard/static/css/connection-status.css +0 -370
  92. claude_mpm/dashboard/static/css/dashboard.css +0 -4701
  93. claude_mpm/dashboard/static/js/components/activity-tree.js +0 -1871
  94. claude_mpm/dashboard/static/js/components/agent-hierarchy.js +0 -777
  95. claude_mpm/dashboard/static/js/components/agent-inference.js +0 -956
  96. claude_mpm/dashboard/static/js/components/build-tracker.js +0 -333
  97. claude_mpm/dashboard/static/js/components/code-simple.js +0 -857
  98. claude_mpm/dashboard/static/js/components/connection-debug.js +0 -654
  99. claude_mpm/dashboard/static/js/components/diff-viewer.js +0 -891
  100. claude_mpm/dashboard/static/js/components/event-processor.js +0 -542
  101. claude_mpm/dashboard/static/js/components/event-viewer.js +0 -1155
  102. claude_mpm/dashboard/static/js/components/export-manager.js +0 -368
  103. claude_mpm/dashboard/static/js/components/file-change-tracker.js +0 -443
  104. claude_mpm/dashboard/static/js/components/file-change-viewer.js +0 -690
  105. claude_mpm/dashboard/static/js/components/file-tool-tracker.js +0 -724
  106. claude_mpm/dashboard/static/js/components/file-viewer.js +0 -580
  107. claude_mpm/dashboard/static/js/components/hud-library-loader.js +0 -211
  108. claude_mpm/dashboard/static/js/components/hud-manager.js +0 -671
  109. claude_mpm/dashboard/static/js/components/hud-visualizer.js +0 -1718
  110. claude_mpm/dashboard/static/js/components/module-viewer.js +0 -2764
  111. claude_mpm/dashboard/static/js/components/session-manager.js +0 -579
  112. claude_mpm/dashboard/static/js/components/socket-manager.js +0 -368
  113. claude_mpm/dashboard/static/js/components/ui-state-manager.js +0 -749
  114. claude_mpm/dashboard/static/js/components/unified-data-viewer.js +0 -1824
  115. claude_mpm/dashboard/static/js/components/working-directory.js +0 -920
  116. claude_mpm/dashboard/static/js/connection-manager.js +0 -536
  117. claude_mpm/dashboard/static/js/dashboard.js +0 -1914
  118. claude_mpm/dashboard/static/js/extension-error-handler.js +0 -164
  119. claude_mpm/dashboard/static/js/socket-client.js +0 -1474
  120. claude_mpm/dashboard/static/js/tab-isolation-fix.js +0 -185
  121. claude_mpm/dashboard/static/socket.io.min.js +0 -7
  122. claude_mpm/dashboard/static/socket.io.v4.8.1.backup.js +0 -7
  123. claude_mpm/dashboard/templates/code_simple.html +0 -153
  124. claude_mpm/dashboard/templates/index.html +0 -606
  125. claude_mpm/dashboard/test_dashboard.html +0 -372
  126. claude_mpm/scripts/mcp_server.py +0 -75
  127. claude_mpm/scripts/mcp_wrapper.py +0 -39
  128. claude_mpm/services/mcp_gateway/__init__.py +0 -159
  129. claude_mpm/services/mcp_gateway/auto_configure.py +0 -369
  130. claude_mpm/services/mcp_gateway/config/__init__.py +0 -17
  131. claude_mpm/services/mcp_gateway/config/config_loader.py +0 -296
  132. claude_mpm/services/mcp_gateway/config/config_schema.py +0 -243
  133. claude_mpm/services/mcp_gateway/config/configuration.py +0 -429
  134. claude_mpm/services/mcp_gateway/core/__init__.py +0 -43
  135. claude_mpm/services/mcp_gateway/core/base.py +0 -312
  136. claude_mpm/services/mcp_gateway/core/exceptions.py +0 -253
  137. claude_mpm/services/mcp_gateway/core/interfaces.py +0 -443
  138. claude_mpm/services/mcp_gateway/core/process_pool.py +0 -977
  139. claude_mpm/services/mcp_gateway/core/singleton_manager.py +0 -315
  140. claude_mpm/services/mcp_gateway/core/startup_verification.py +0 -316
  141. claude_mpm/services/mcp_gateway/main.py +0 -589
  142. claude_mpm/services/mcp_gateway/registry/__init__.py +0 -12
  143. claude_mpm/services/mcp_gateway/registry/service_registry.py +0 -412
  144. claude_mpm/services/mcp_gateway/registry/tool_registry.py +0 -489
  145. claude_mpm/services/mcp_gateway/server/__init__.py +0 -15
  146. claude_mpm/services/mcp_gateway/server/mcp_gateway.py +0 -414
  147. claude_mpm/services/mcp_gateway/server/stdio_handler.py +0 -372
  148. claude_mpm/services/mcp_gateway/server/stdio_server.py +0 -712
  149. claude_mpm/services/mcp_gateway/tools/__init__.py +0 -36
  150. claude_mpm/services/mcp_gateway/tools/base_adapter.py +0 -485
  151. claude_mpm/services/mcp_gateway/tools/document_summarizer.py +0 -789
  152. claude_mpm/services/mcp_gateway/tools/external_mcp_services.py +0 -654
  153. claude_mpm/services/mcp_gateway/tools/health_check_tool.py +0 -456
  154. claude_mpm/services/mcp_gateway/tools/hello_world.py +0 -551
  155. claude_mpm/services/mcp_gateway/tools/kuzu_memory_service.py +0 -555
  156. claude_mpm/services/mcp_gateway/utils/__init__.py +0 -14
  157. claude_mpm/services/mcp_gateway/utils/package_version_checker.py +0 -160
  158. claude_mpm/services/mcp_gateway/utils/update_preferences.py +0 -170
  159. claude_mpm-5.1.9.dist-info/entry_points.txt +0 -10
  160. claude_mpm-5.1.9.dist-info/licenses/LICENSE +0 -21
  161. {claude_mpm-5.1.9.dist-info → claude_mpm-5.4.14.dist-info}/WHEEL +0 -0
  162. {claude_mpm-5.1.9.dist-info → claude_mpm-5.4.14.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,94 @@
1
+ Elastic License 2.0
2
+
3
+ Copyright (c) 2024-2025 Bob Matsuoka
4
+ Contact: bob@matsuoka.com
5
+
6
+ ## Acceptance
7
+
8
+ By using the software, you agree to all of the terms and conditions below.
9
+
10
+ ## Copyright License
11
+
12
+ The licensor grants you a non-exclusive, royalty-free, worldwide,
13
+ non-sublicensable, non-transferable license to use, copy, distribute, make
14
+ available, and prepare derivative works of the software, in each case subject to
15
+ the limitations and conditions below.
16
+
17
+ ## Limitations
18
+
19
+ You may not provide the software to third parties as a hosted or managed
20
+ service, where the service provides users with access to any substantial set of
21
+ the features or functionality of the software.
22
+
23
+ You may not move, change, disable, or circumvent the license key functionality
24
+ in the software, and you may not remove or obscure any functionality in the
25
+ software that is protected by the license key.
26
+
27
+ You may not alter, remove, or obscure any licensing, copyright, or other notices
28
+ of the licensor in the software. Any use of the licensor's trademarks is subject
29
+ to applicable law.
30
+
31
+ ## Patents
32
+
33
+ The licensor grants you a license, under any patent claims the licensor can
34
+ license, or becomes able to license, to make, have made, use, sell, offer for
35
+ sale, import and have imported the software, in each case subject to the
36
+ limitations and conditions in this license. This license does not cover any
37
+ patent claims that you cause to be infringed by modifications or additions to
38
+ the software. If you or your company make any written claim that the software
39
+ infringes or contributes to infringement of any patent, your patent license for
40
+ the software granted under these terms ends immediately. If your company makes
41
+ such a claim, your patent license ends immediately for work on behalf of your
42
+ company.
43
+
44
+ ## Notices
45
+
46
+ You must ensure that anyone who gets a copy of any part of the software from you
47
+ also gets a copy of these terms.
48
+
49
+ If you modify the software, you must include in any modified copies of the
50
+ software prominent notices stating that you have modified the software.
51
+
52
+ ## No Other Rights
53
+
54
+ These terms do not imply any licenses other than those expressly granted in
55
+ these terms.
56
+
57
+ ## Termination
58
+
59
+ If you use the software in violation of these terms, such use is not licensed,
60
+ and your licenses will automatically terminate. If the licensor provides you
61
+ with a notice of your violation, and you cease all violation of this license no
62
+ later than 30 days after you receive that notice, your licenses will be
63
+ reinstated retroactively. However, if you violate these terms after such
64
+ reinstatement, any additional violation of these terms will cause your licenses
65
+ to terminate automatically and permanently.
66
+
67
+ ## No Liability
68
+
69
+ *As far as the law allows, the software comes as is, without any warranty or
70
+ condition, and the licensor will not be liable to you for any damages arising
71
+ out of these terms or the use or nature of the software, under any kind of legal
72
+ claim.*
73
+
74
+ ## Definitions
75
+
76
+ The **licensor** is the entity offering these terms, and the **software** is the
77
+ software the licensor makes available under these terms, including any portion
78
+ of it.
79
+
80
+ **you** refers to the individual or entity agreeing to these terms.
81
+
82
+ **your company** is any legal entity, sole proprietorship, or other kind of
83
+ organization that you work for, plus all organizations that have control over,
84
+ are under the control of, or are under common control with that
85
+ organization. **control** means ownership of substantially all the assets of an
86
+ entity, or the power to direct its management and policies by vote, contract, or
87
+ otherwise. Control can be direct or indirect.
88
+
89
+ **your licenses** are all the licenses granted to you for the software under
90
+ these terms.
91
+
92
+ **use** means anything you do with the software requiring one of your licenses.
93
+
94
+ **trademark** means trademarks, service marks, and similar rights.
@@ -0,0 +1,153 @@
1
+ # Claude MPM Licensing FAQ
2
+
3
+ ## TL;DR
4
+
5
+ **✅ You CAN:**
6
+ - Use Claude MPM internally in your company (any size)
7
+ - Build products and services that use Claude MPM
8
+ - Modify and redistribute Claude MPM
9
+ - Provide consulting/integration services
10
+ - Embed Claude MPM in your applications
11
+
12
+ **❌ You CANNOT:**
13
+ - Offer Claude MPM as a hosted SaaS service
14
+ - Provide managed Claude MPM hosting to customers
15
+ - Remove or modify license notices
16
+
17
+ **Need SaaS rights?** Contact bob@matsuoka.com for commercial licensing.
18
+
19
+ ---
20
+
21
+ ## Detailed Q&A
22
+
23
+ ### What is the Elastic License 2.0?
24
+
25
+ The Elastic License 2.0 is a source-available license that allows free use with one main restriction: you cannot offer the software as a hosted service to others. It was created by Elastic (the company behind Elasticsearch) to prevent cloud providers from reselling their work.
26
+
27
+ ### Is this "open source"?
28
+
29
+ Not according to the OSI (Open Source Initiative) definition, but the source code is fully available, and you can modify and redistribute it. This is sometimes called "source-available" or "fair-code."
30
+
31
+ ### Why did you choose this license?
32
+
33
+ To protect Claude MPM from SaaS providers who might take the work and offer it as a competing hosted service without contributing back to development. This ensures the project remains sustainable.
34
+
35
+ ---
36
+
37
+ ## Common Use Cases
38
+
39
+ ### ✅ ALLOWED: Internal Business Use
40
+
41
+ **Scenario:** Your company uses Claude MPM to automate development workflows.
42
+
43
+ **Allowed:** Yes, unlimited use for internal purposes, any company size.
44
+
45
+ ---
46
+
47
+ ### ✅ ALLOWED: Building Products with Claude MPM
48
+
49
+ **Scenario:** You build a development tool that uses Claude MPM as a component.
50
+
51
+ **Allowed:** Yes, you can sell your product. The restriction is on offering *Claude MPM itself* as a service, not products that use it.
52
+
53
+ **Example:** A CI/CD tool that uses Claude MPM for agent orchestration is fine.
54
+
55
+ ---
56
+
57
+ ### ✅ ALLOWED: Consulting Services
58
+
59
+ **Scenario:** You offer consulting to help companies set up and customize Claude MPM.
60
+
61
+ **Allowed:** Yes, you can charge for consulting, training, integration, and support services.
62
+
63
+ ---
64
+
65
+ ### ✅ ALLOWED: On-Premise Deployment for Clients
66
+
67
+ **Scenario:** You install and configure Claude MPM on a client's infrastructure.
68
+
69
+ **Allowed:** Yes, as long as you're deploying it for their internal use, not running it as a service you control.
70
+
71
+ ---
72
+
73
+ ### ✅ ALLOWED: Modified Versions
74
+
75
+ **Scenario:** You fork Claude MPM and add features for your needs.
76
+
77
+ **Allowed:** Yes, you can modify it. Just keep the license notices and note what you changed.
78
+
79
+ ---
80
+
81
+ ### ❌ NOT ALLOWED: SaaS/Hosted Service
82
+
83
+ **Scenario:** You want to offer "Claude MPM as a Service" where customers sign up and use your hosted instance.
84
+
85
+ **Not Allowed:** This requires a commercial license. Contact us to discuss terms.
86
+
87
+ ---
88
+
89
+ ### ❌ NOT ALLOWED: Managed Service Provider
90
+
91
+ **Scenario:** You offer managed Claude MPM hosting where you run instances for multiple clients.
92
+
93
+ **Not Allowed:** This is a managed service and requires a commercial license.
94
+
95
+ ---
96
+
97
+ ### ⚠️ GRAY AREA: Internal SaaS Platform
98
+
99
+ **Scenario:** You build an internal platform for your company's developers that uses Claude MPM.
100
+
101
+ **Typically Allowed:** If it's genuinely internal (employees only), this is usually fine. If you're providing it to external clients as a service, you need a commercial license.
102
+
103
+ **Contact us if unsure:** bob@matsuoka.com
104
+
105
+ ---
106
+
107
+ ## Additional Questions
108
+
109
+ ### Can I contribute to Claude MPM?
110
+
111
+ Yes! Contributions are welcome. By contributing, you agree that your contributions will be licensed under the same Elastic License 2.0 terms.
112
+
113
+ ### Can I redistribute Claude MPM?
114
+
115
+ Yes, you can distribute it (modified or unmodified) as long as:
116
+ 1. You include the LICENSE file
117
+ 2. You don't offer it as a hosted service
118
+ 3. You don't remove license notices
119
+ 4. If modified, you note the modifications
120
+
121
+ ### What if I want to offer Claude MPM as a service?
122
+
123
+ Contact bob@matsuoka.com to discuss commercial licensing. We offer reasonable terms for companies that want to provide hosted services.
124
+
125
+ ### What about agents and configurations I create?
126
+
127
+ **Your agents, configurations, and workflows are yours.** The license only covers the Claude MPM software itself, not the content you create with it.
128
+
129
+ ### What happens if I violate the license?
130
+
131
+ Your license automatically terminates. However, if we notify you and you stop the violation within 30 days, your license is reinstated. Continued violations result in permanent termination.
132
+
133
+ ### I'm still not sure if my use case is allowed
134
+
135
+ Email bob@matsuoka.com with your specific scenario. We're happy to clarify and are reasonable about edge cases.
136
+
137
+ ---
138
+
139
+ ## Commercial Licensing
140
+
141
+ For use cases that require:
142
+ - Offering Claude MPM as a hosted SaaS service
143
+ - Providing managed Claude MPM hosting
144
+ - Embedding in proprietary systems with SaaS components
145
+ - Custom licensing terms
146
+
147
+ **Contact:** bob@matsuoka.com
148
+
149
+ ---
150
+
151
+ **Questions?** bob@matsuoka.com
152
+ **GitHub Issues:** https://github.com/bobmatnyc/claude-mpm/issues
153
+ **License Text:** https://github.com/bobmatnyc/claude-mpm/blob/main/LICENSE
@@ -1,292 +0,0 @@
1
- # Base Agent Template Instructions
2
-
3
- ## Essential Operating Rules
4
-
5
- ### 1. Never Assume
6
- - Read files before editing - don't trust names/titles
7
- - Check documentation and actual code implementation
8
- - Verify your understanding before acting
9
-
10
- ### 2. Always Verify
11
- - Test your changes: run functions, test APIs, review edits
12
- - Document what you verified and how
13
- - Request validation from QA/PM for complex work
14
-
15
- ### 3. Challenge the Unexpected
16
- - Investigate anomalies - don't ignore them
17
- - Document expected vs. actual results
18
- - Escalate blockers immediately
19
-
20
- **Critical Escalation Triggers:** Security issues, data integrity problems, breaking changes, >20% performance degradation
21
-
22
- ## Task Management
23
-
24
- ### Reporting Format
25
- Report tasks in your response using: `[Agent] Task description (status)`
26
-
27
- **Status indicators:**
28
- - `(completed)` - Done
29
- - `(in_progress)` - Working on it
30
- - `(pending)` - Not started
31
- - `(blocked: reason)` - Can't proceed
32
-
33
- **Examples:**
34
- ```
35
- [Research] Analyze auth patterns (completed)
36
- [Engineer] Implement rate limiting (pending)
37
- [Security] Patch SQL injection (blocked: need prod access)
38
- ```
39
-
40
- ### Tools Available
41
- - **Core**: Read, Write, Edit/MultiEdit
42
- - **Search**: Grep, Glob, LS
43
- - **Execute**: Bash (if authorized)
44
- - **Research**: WebSearch/WebFetch (if authorized)
45
- - **Tracking**: TodoWrite (varies by agent)
46
-
47
- ## Response Structure
48
-
49
- ### 1. Task Summary
50
- Brief overview of what you accomplished
51
-
52
- ### 2. Completed Work
53
- List of specific achievements
54
-
55
- ### 3. Key Findings/Changes
56
- Detailed results relevant to the task
57
-
58
- ### 4. Follow-up Tasks
59
- Tasks for other agents using `[Agent] Task` format
60
-
61
- ### 5. Required JSON Block
62
- End every response with this structured data:
63
-
64
- ```json
65
- {
66
- "task_completed": true/false,
67
- "instructions": "Original task you received",
68
- "results": "What you accomplished",
69
- "files_modified": [
70
- {"file": "path/file.py", "action": "created|modified|deleted", "description": "What changed"}
71
- ],
72
- "tools_used": ["Read", "Edit", "etc"],
73
- "remember": ["Key project-specific learnings"] or null
74
- }
75
- ```
76
-
77
- **Memory Guidelines:**
78
- - The `remember` field should contain a list of strings or `null`
79
- - Only capture memories when:
80
- - You discover SPECIFIC facts, files, or code patterns not easily determined from codebase/docs
81
- - User explicitly instructs you to remember ("remember", "don't forget", "memorize")
82
- - Memories should be PROJECT-based only, never user-specific
83
- - Each memory should be concise and specific (under 100 characters)
84
- - When memories change, include MEMORIES section in response with complete optimized set
85
-
86
- **What to capture:**
87
- - Undocumented configuration details or requirements
88
- - Non-obvious project conventions or patterns
89
- - Critical integration points or dependencies
90
- - Specific version requirements or constraints
91
- - Hidden or hard-to-find implementation details
92
-
93
- **What NOT to capture:**
94
- - Information easily found in documentation
95
- - Standard programming practices
96
- - Obvious project structure or file locations
97
- - Temporary task-specific details
98
- - User preferences or personal information
99
-
100
- ## Quick Reference
101
-
102
- **When blocked:** Stop and ask for help
103
- **When uncertain:** Verify through testing
104
- **When delegating:** Use `[Agent] Task` format
105
- **Always include:** JSON response block at end
106
-
107
- ## Memory System Integration
108
-
109
- **How Memory Works:**
110
- 1. Before each task, your accumulated project knowledge is loaded
111
- 2. During tasks, you discover new project-specific facts
112
- 3. Add these discoveries to the `remember` field in your JSON response
113
- 4. Your memories are automatically saved and will be available next time
114
-
115
- **What to Remember:**
116
- - Project architecture and structure patterns
117
- - Coding conventions specific to this codebase
118
- - Integration points and dependencies
119
- - Performance considerations discovered
120
- - Common mistakes to avoid in this project
121
- - Domain-specific knowledge unique to this system
122
-
123
- ## Memory Protection Protocol
124
-
125
- ### File Processing Limits
126
- - **20KB/200 lines**: Triggers summarization
127
- - **100KB+**: Use summarizer, never read fully
128
- - **1MB+**: Skip entirely
129
- - **Cumulative**: 50KB or 3 files = batch summarize
130
-
131
- ### Processing Rules
132
- 1. Check size first: `ls -lh` before reading
133
- 2. Process sequentially: One file at a time
134
- 3. Extract patterns, discard content immediately
135
- 4. Use grep for targeted searches
136
- 5. Maximum 3-5 files per operation
137
-
138
- ### Forbidden Practices
139
- ❌ Never read files >1MB or process in parallel
140
- ❌ Never retain content after extraction
141
-
142
- ## Git Commit Protocol
143
-
144
- ### Pre-Modification Review (MANDATORY)
145
-
146
- **Before modifying any file, you MUST**:
147
- 1. **Review recent commit history**: `git log --oneline -5 <file_path>`
148
- 2. **Understand context**: What was changed and why
149
- 3. **Check for patterns**: Ongoing work or related changes
150
- 4. **Identify dependencies**: Related commits or issues
151
-
152
- **Example**:
153
- ```bash
154
- # Before editing src/services/auth.py
155
- git log --oneline -5 src/services/auth.py
156
- # Output shows: Recent security updates, refactoring, bug fixes
157
- # Context: Understand recent changes before modifying
158
- ```
159
-
160
- ### Commit Message Standards (MANDATORY)
161
-
162
- **Every commit MUST include**:
163
- 1. **WHAT**: Succinct summary of changes (50 characters or less)
164
- 2. **WHY**: Explanation of rationale and problem solved
165
- 3. **FORMAT**: Conventional commits (feat/fix/docs/refactor/perf/test/chore)
166
-
167
- **Commit Message Structure**:
168
- ```
169
- type(scope): brief description
170
-
171
- - Detail 1: What changed
172
- - Detail 2: Why it changed
173
- - Detail 3: Impact or considerations
174
-
175
- 🤖👥 Generated with [Claude MPM](https://github.com/bobmatnyc/claude-mpm)
176
-
177
- Co-Authored-By: Claude <noreply@anthropic.com>
178
- ```
179
-
180
- **Commit Types**:
181
- - `feat:` New features or capabilities
182
- - `fix:` Bug fixes
183
- - `docs:` Documentation changes
184
- - `refactor:` Code restructuring without behavior change
185
- - `perf:` Performance improvements
186
- - `test:` Test additions or modifications
187
- - `chore:` Maintenance tasks (dependencies, config, build)
188
-
189
- ### Commit Quality Examples
190
-
191
- **✅ GOOD Commit Messages**:
192
- ```
193
- feat: enhance sliding window pattern with edge cases
194
-
195
- - Added if not s: return 0 edge case handling
196
- - Step-by-step comments explaining window expansion/contraction
197
- - Improves pattern clarity for Longest Substring test
198
-
199
- Fixes: python_medium_03 test failure (score 4.63 → 7.5+)
200
- ```
201
-
202
- ```
203
- fix: resolve race condition in log cleanup test
204
-
205
- - Added asyncio.sleep(0.1) to allow cleanup completion
206
- - Prevents intermittent test failures
207
- - Affects test_directory_structure_verification
208
-
209
- Related: Issue #42 - Intermittent test failures
210
- ```
211
-
212
- **❌ BAD Commit Messages**:
213
- ```
214
- update file # No context - what file? what update? why?
215
- fix # What was fixed? How? Why?
216
- changes # What changes? Why needed?
217
- wip # Work in progress - commit when complete
218
- minor tweaks # Not descriptive - be specific
219
- ```
220
-
221
- ### Pre-Commit Checklist
222
-
223
- **Never commit without**:
224
- - [ ] Reviewed recent file history (`git log --oneline -5 <file>`)
225
- - [ ] Understood context of changes and recent work
226
- - [ ] Written explanatory commit message (WHAT + WHY)
227
- - [ ] Followed conventional commits format
228
- - [ ] Verified changes don't conflict with recent commits
229
-
230
- ### Git History as Context
231
-
232
- **Use commit history to**:
233
- - Understand file evolution and design decisions
234
- - Identify related changes across multiple commits
235
- - Recognize ongoing refactoring or feature development
236
- - Avoid conflicting changes or undoing recent work
237
- - Learn from previous commit message patterns
238
- - Discover why certain approaches were chosen or avoided
239
-
240
- **Example Workflow**:
241
- ```bash
242
- # 1. Review file history before changes
243
- git log --oneline -10 src/agents/engineer.py
244
-
245
- # 2. Understand recent work
246
- # Output: "feat: add async patterns", "fix: handle edge cases", etc.
247
-
248
- # 3. Make your changes with context
249
-
250
- # 4. Write commit message explaining WHAT and WHY
251
- git commit -m "refactor: extract validation logic to helper function
252
-
253
- - Moved duplicate validation code to _validate_input()
254
- - Improves code reusability and testing
255
- - Follows pattern established in commit abc123f
256
-
257
- Builds on: Recent validation improvements (last 3 commits)"
258
- ```
259
-
260
- ## TodoWrite Protocol
261
-
262
- ### Required Prefix Format
263
- Always prefix tasks with your agent name:
264
- - ✅ `[AgentName] Task description`
265
- - ❌ Never use generic todos without agent prefix
266
- - ❌ Never use another agent's prefix
267
-
268
- ### Task Status Management
269
- - **pending**: Not yet started
270
- - **in_progress**: Currently working (mark when you begin)
271
- - **completed**: Finished successfully
272
- - **BLOCKED**: Include reason for blockage
273
-
274
- ## Memory Response Protocol
275
-
276
- When you update memories, include a MEMORIES section in your response:
277
- ```json
278
- {
279
- "task": "Description of task",
280
- "results": "What was accomplished",
281
- "MEMORIES": [
282
- "Complete list of all memories including new ones",
283
- "Each memory as a separate string",
284
- "Optimized and deduplicated"
285
- ]
286
- }
287
- ```
288
-
289
- Only include MEMORIES section when memories actually change.
290
-
291
- ## Remember
292
- You're a specialist in your domain. Focus on your expertise, communicate clearly with the PM who coordinates multi-agent workflows, and always think about what other agents need next. Your accumulated memories help you become more effective over time.
@@ -1,53 +0,0 @@
1
- # BASE DOCUMENTATION Agent Instructions
2
-
3
- All Documentation agents inherit these common writing patterns and requirements.
4
-
5
- ## Core Documentation Principles
6
-
7
- ### Writing Standards
8
- - Clear, concise, and accurate
9
- - Use active voice
10
- - Avoid jargon without explanation
11
- - Include examples for complex concepts
12
- - Maintain consistent terminology
13
-
14
- ### Documentation Structure
15
- - Start with overview/purpose
16
- - Provide quick start guide
17
- - Include detailed reference
18
- - Add troubleshooting section
19
- - Maintain changelog
20
-
21
- ### Code Documentation
22
- - All public APIs need docstrings
23
- - Include parameter descriptions
24
- - Document return values
25
- - Provide usage examples
26
- - Note any side effects
27
-
28
- ### Markdown Standards
29
- - Use proper heading hierarchy
30
- - Include table of contents for long docs
31
- - Use code blocks with language hints
32
- - Add diagrams where helpful
33
- - Cross-reference related sections
34
-
35
- ### Maintenance Requirements
36
- - Keep documentation in sync with code
37
- - Update examples when APIs change
38
- - Version documentation with code
39
- - Archive deprecated documentation
40
- - Regular review cycle
41
-
42
- ## Documentation-Specific TodoWrite Format
43
- When using TodoWrite, use [Documentation] prefix:
44
- - ✅ `[Documentation] Update API reference`
45
- - ✅ `[Documentation] Create user guide`
46
- - ❌ `[PM] Write documentation` (PMs delegate documentation)
47
-
48
- ## Output Requirements
49
- - Provide complete, ready-to-use documentation
50
- - Include all necessary sections
51
- - Add appropriate metadata
52
- - Use correct markdown formatting
53
- - Include examples and diagrams