claude-mpm 4.15.2__py3-none-any.whl → 4.20.3__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 (203) hide show
  1. claude_mpm/VERSION +1 -1
  2. claude_mpm/agents/BASE_ENGINEER.md +286 -0
  3. claude_mpm/agents/BASE_PM.md +255 -23
  4. claude_mpm/agents/PM_INSTRUCTIONS.md +40 -0
  5. claude_mpm/agents/agent_loader.py +4 -4
  6. claude_mpm/agents/templates/agentic-coder-optimizer.json +9 -2
  7. claude_mpm/agents/templates/api_qa.json +7 -1
  8. claude_mpm/agents/templates/clerk-ops.json +8 -1
  9. claude_mpm/agents/templates/code_analyzer.json +4 -1
  10. claude_mpm/agents/templates/dart_engineer.json +11 -1
  11. claude_mpm/agents/templates/data_engineer.json +11 -1
  12. claude_mpm/agents/templates/documentation.json +6 -1
  13. claude_mpm/agents/templates/engineer.json +18 -1
  14. claude_mpm/agents/templates/gcp_ops_agent.json +8 -1
  15. claude_mpm/agents/templates/golang_engineer.json +11 -1
  16. claude_mpm/agents/templates/java_engineer.json +12 -2
  17. claude_mpm/agents/templates/local_ops_agent.json +216 -37
  18. claude_mpm/agents/templates/nextjs_engineer.json +11 -1
  19. claude_mpm/agents/templates/ops.json +8 -1
  20. claude_mpm/agents/templates/php-engineer.json +11 -1
  21. claude_mpm/agents/templates/project_organizer.json +9 -2
  22. claude_mpm/agents/templates/prompt-engineer.json +5 -1
  23. claude_mpm/agents/templates/python_engineer.json +19 -4
  24. claude_mpm/agents/templates/qa.json +7 -1
  25. claude_mpm/agents/templates/react_engineer.json +11 -1
  26. claude_mpm/agents/templates/refactoring_engineer.json +8 -1
  27. claude_mpm/agents/templates/research.json +4 -1
  28. claude_mpm/agents/templates/ruby-engineer.json +11 -1
  29. claude_mpm/agents/templates/rust_engineer.json +23 -8
  30. claude_mpm/agents/templates/security.json +6 -1
  31. claude_mpm/agents/templates/svelte-engineer.json +225 -0
  32. claude_mpm/agents/templates/ticketing.json +6 -1
  33. claude_mpm/agents/templates/typescript_engineer.json +11 -1
  34. claude_mpm/agents/templates/vercel_ops_agent.json +8 -1
  35. claude_mpm/agents/templates/version_control.json +8 -1
  36. claude_mpm/agents/templates/web_qa.json +7 -1
  37. claude_mpm/agents/templates/web_ui.json +11 -1
  38. claude_mpm/cli/commands/__init__.py +2 -0
  39. claude_mpm/cli/commands/configure.py +164 -16
  40. claude_mpm/cli/commands/configure_agent_display.py +6 -6
  41. claude_mpm/cli/commands/configure_behavior_manager.py +8 -8
  42. claude_mpm/cli/commands/configure_navigation.py +20 -18
  43. claude_mpm/cli/commands/configure_startup_manager.py +14 -14
  44. claude_mpm/cli/commands/configure_template_editor.py +8 -8
  45. claude_mpm/cli/commands/mpm_init.py +109 -24
  46. claude_mpm/cli/commands/skills.py +434 -0
  47. claude_mpm/cli/executor.py +2 -0
  48. claude_mpm/cli/interactive/__init__.py +3 -0
  49. claude_mpm/cli/interactive/skills_wizard.py +491 -0
  50. claude_mpm/cli/parsers/base_parser.py +7 -0
  51. claude_mpm/cli/parsers/skills_parser.py +137 -0
  52. claude_mpm/cli/startup.py +83 -0
  53. claude_mpm/commands/mpm-auto-configure.md +52 -0
  54. claude_mpm/commands/mpm-help.md +3 -0
  55. claude_mpm/commands/mpm-init.md +112 -6
  56. claude_mpm/commands/mpm-version.md +113 -0
  57. claude_mpm/commands/mpm.md +1 -0
  58. claude_mpm/config/agent_config.py +2 -2
  59. claude_mpm/constants.py +12 -0
  60. claude_mpm/core/config.py +42 -0
  61. claude_mpm/core/enums.py +18 -0
  62. claude_mpm/core/factories.py +1 -1
  63. claude_mpm/core/optimized_agent_loader.py +3 -3
  64. claude_mpm/core/types.py +2 -9
  65. claude_mpm/dashboard/static/js/dashboard.js +0 -14
  66. claude_mpm/dashboard/templates/index.html +3 -41
  67. claude_mpm/hooks/__init__.py +8 -0
  68. claude_mpm/hooks/claude_hooks/response_tracking.py +35 -1
  69. claude_mpm/hooks/session_resume_hook.py +121 -0
  70. claude_mpm/models/resume_log.py +340 -0
  71. claude_mpm/services/agents/auto_config_manager.py +1 -1
  72. claude_mpm/services/agents/deployment/agent_configuration_manager.py +1 -1
  73. claude_mpm/services/agents/deployment/agent_record_service.py +1 -1
  74. claude_mpm/services/agents/deployment/agent_validator.py +17 -1
  75. claude_mpm/services/agents/deployment/async_agent_deployment.py +1 -1
  76. claude_mpm/services/agents/deployment/local_template_deployment.py +1 -1
  77. claude_mpm/services/agents/deployment/validation/__init__.py +3 -1
  78. claude_mpm/services/agents/deployment/validation/validation_result.py +1 -9
  79. claude_mpm/services/agents/local_template_manager.py +1 -1
  80. claude_mpm/services/agents/recommender.py +47 -0
  81. claude_mpm/services/cli/resume_service.py +617 -0
  82. claude_mpm/services/cli/session_manager.py +87 -0
  83. claude_mpm/services/cli/session_resume_helper.py +352 -0
  84. claude_mpm/services/core/models/health.py +1 -28
  85. claude_mpm/services/core/path_resolver.py +1 -1
  86. claude_mpm/services/infrastructure/monitoring/__init__.py +1 -1
  87. claude_mpm/services/infrastructure/monitoring/aggregator.py +12 -12
  88. claude_mpm/services/infrastructure/monitoring/base.py +5 -13
  89. claude_mpm/services/infrastructure/monitoring/network.py +7 -6
  90. claude_mpm/services/infrastructure/monitoring/process.py +13 -12
  91. claude_mpm/services/infrastructure/monitoring/resources.py +7 -6
  92. claude_mpm/services/infrastructure/monitoring/service.py +16 -15
  93. claude_mpm/services/infrastructure/resume_log_generator.py +439 -0
  94. claude_mpm/services/local_ops/__init__.py +1 -1
  95. claude_mpm/services/local_ops/crash_detector.py +1 -1
  96. claude_mpm/services/local_ops/health_checks/http_check.py +2 -1
  97. claude_mpm/services/local_ops/health_checks/process_check.py +2 -1
  98. claude_mpm/services/local_ops/health_checks/resource_check.py +2 -1
  99. claude_mpm/services/local_ops/health_manager.py +1 -1
  100. claude_mpm/services/local_ops/restart_manager.py +1 -1
  101. claude_mpm/services/mcp_config_manager.py +7 -131
  102. claude_mpm/services/session_manager.py +205 -1
  103. claude_mpm/services/shared/async_service_base.py +16 -27
  104. claude_mpm/services/shared/lifecycle_service_base.py +1 -14
  105. claude_mpm/services/socketio/handlers/__init__.py +5 -2
  106. claude_mpm/services/socketio/handlers/hook.py +10 -0
  107. claude_mpm/services/socketio/handlers/registry.py +4 -2
  108. claude_mpm/services/socketio/server/main.py +7 -7
  109. claude_mpm/services/unified/deployment_strategies/local.py +1 -1
  110. claude_mpm/services/version_service.py +104 -1
  111. claude_mpm/skills/__init__.py +42 -0
  112. claude_mpm/skills/agent_skills_injector.py +331 -0
  113. claude_mpm/skills/bundled/LICENSE_ATTRIBUTIONS.md +79 -0
  114. claude_mpm/skills/bundled/__init__.py +6 -0
  115. claude_mpm/skills/bundled/api-documentation.md +393 -0
  116. claude_mpm/skills/bundled/async-testing.md +571 -0
  117. claude_mpm/skills/bundled/code-review.md +143 -0
  118. claude_mpm/skills/bundled/collaboration/brainstorming/SKILL.md +75 -0
  119. claude_mpm/skills/bundled/collaboration/dispatching-parallel-agents/SKILL.md +184 -0
  120. claude_mpm/skills/bundled/collaboration/requesting-code-review/SKILL.md +107 -0
  121. claude_mpm/skills/bundled/collaboration/requesting-code-review/code-reviewer.md +146 -0
  122. claude_mpm/skills/bundled/collaboration/writing-plans/SKILL.md +118 -0
  123. claude_mpm/skills/bundled/database-migration.md +199 -0
  124. claude_mpm/skills/bundled/debugging/root-cause-tracing/SKILL.md +177 -0
  125. claude_mpm/skills/bundled/debugging/systematic-debugging/CREATION-LOG.md +119 -0
  126. claude_mpm/skills/bundled/debugging/systematic-debugging/SKILL.md +148 -0
  127. claude_mpm/skills/bundled/debugging/systematic-debugging/references/anti-patterns.md +483 -0
  128. claude_mpm/skills/bundled/debugging/systematic-debugging/references/examples.md +452 -0
  129. claude_mpm/skills/bundled/debugging/systematic-debugging/references/troubleshooting.md +449 -0
  130. claude_mpm/skills/bundled/debugging/systematic-debugging/references/workflow.md +411 -0
  131. claude_mpm/skills/bundled/debugging/systematic-debugging/test-academic.md +14 -0
  132. claude_mpm/skills/bundled/debugging/systematic-debugging/test-pressure-1.md +58 -0
  133. claude_mpm/skills/bundled/debugging/systematic-debugging/test-pressure-2.md +68 -0
  134. claude_mpm/skills/bundled/debugging/systematic-debugging/test-pressure-3.md +69 -0
  135. claude_mpm/skills/bundled/debugging/verification-before-completion/SKILL.md +175 -0
  136. claude_mpm/skills/bundled/debugging/verification-before-completion/references/common-failures.md +213 -0
  137. claude_mpm/skills/bundled/debugging/verification-before-completion/references/gate-function.md +314 -0
  138. claude_mpm/skills/bundled/debugging/verification-before-completion/references/verification-patterns.md +227 -0
  139. claude_mpm/skills/bundled/docker-containerization.md +194 -0
  140. claude_mpm/skills/bundled/express-local-dev.md +1429 -0
  141. claude_mpm/skills/bundled/fastapi-local-dev.md +1199 -0
  142. claude_mpm/skills/bundled/git-workflow.md +414 -0
  143. claude_mpm/skills/bundled/imagemagick.md +204 -0
  144. claude_mpm/skills/bundled/json-data-handling.md +223 -0
  145. claude_mpm/skills/bundled/main/artifacts-builder/SKILL.md +74 -0
  146. claude_mpm/skills/bundled/main/internal-comms/SKILL.md +32 -0
  147. claude_mpm/skills/bundled/main/internal-comms/examples/3p-updates.md +47 -0
  148. claude_mpm/skills/bundled/main/internal-comms/examples/company-newsletter.md +65 -0
  149. claude_mpm/skills/bundled/main/internal-comms/examples/faq-answers.md +30 -0
  150. claude_mpm/skills/bundled/main/internal-comms/examples/general-comms.md +16 -0
  151. claude_mpm/skills/bundled/main/mcp-builder/SKILL.md +328 -0
  152. claude_mpm/skills/bundled/main/mcp-builder/reference/evaluation.md +602 -0
  153. claude_mpm/skills/bundled/main/mcp-builder/reference/mcp_best_practices.md +915 -0
  154. claude_mpm/skills/bundled/main/mcp-builder/reference/node_mcp_server.md +916 -0
  155. claude_mpm/skills/bundled/main/mcp-builder/reference/python_mcp_server.md +752 -0
  156. claude_mpm/skills/bundled/main/mcp-builder/scripts/connections.py +150 -0
  157. claude_mpm/skills/bundled/main/mcp-builder/scripts/evaluation.py +372 -0
  158. claude_mpm/skills/bundled/main/skill-creator/SKILL.md +209 -0
  159. claude_mpm/skills/bundled/main/skill-creator/scripts/init_skill.py +302 -0
  160. claude_mpm/skills/bundled/main/skill-creator/scripts/package_skill.py +111 -0
  161. claude_mpm/skills/bundled/main/skill-creator/scripts/quick_validate.py +65 -0
  162. claude_mpm/skills/bundled/nextjs-local-dev.md +807 -0
  163. claude_mpm/skills/bundled/pdf.md +141 -0
  164. claude_mpm/skills/bundled/performance-profiling.md +567 -0
  165. claude_mpm/skills/bundled/refactoring-patterns.md +180 -0
  166. claude_mpm/skills/bundled/security-scanning.md +327 -0
  167. claude_mpm/skills/bundled/systematic-debugging.md +473 -0
  168. claude_mpm/skills/bundled/test-driven-development.md +378 -0
  169. claude_mpm/skills/bundled/testing/condition-based-waiting/SKILL.md +123 -0
  170. claude_mpm/skills/bundled/testing/test-driven-development/SKILL.md +145 -0
  171. claude_mpm/skills/bundled/testing/test-driven-development/references/anti-patterns.md +543 -0
  172. claude_mpm/skills/bundled/testing/test-driven-development/references/examples.md +741 -0
  173. claude_mpm/skills/bundled/testing/test-driven-development/references/integration.md +470 -0
  174. claude_mpm/skills/bundled/testing/test-driven-development/references/philosophy.md +458 -0
  175. claude_mpm/skills/bundled/testing/test-driven-development/references/workflow.md +639 -0
  176. claude_mpm/skills/bundled/testing/testing-anti-patterns/SKILL.md +304 -0
  177. claude_mpm/skills/bundled/testing/webapp-testing/SKILL.md +96 -0
  178. claude_mpm/skills/bundled/testing/webapp-testing/examples/console_logging.py +35 -0
  179. claude_mpm/skills/bundled/testing/webapp-testing/examples/element_discovery.py +40 -0
  180. claude_mpm/skills/bundled/testing/webapp-testing/examples/static_html_automation.py +34 -0
  181. claude_mpm/skills/bundled/testing/webapp-testing/scripts/with_server.py +107 -0
  182. claude_mpm/skills/bundled/vite-local-dev.md +1061 -0
  183. claude_mpm/skills/bundled/web-performance-optimization.md +2305 -0
  184. claude_mpm/skills/bundled/xlsx.md +157 -0
  185. claude_mpm/skills/registry.py +286 -0
  186. claude_mpm/skills/skill_manager.py +310 -0
  187. claude_mpm/skills/skills_registry.py +351 -0
  188. claude_mpm/skills/skills_service.py +730 -0
  189. claude_mpm/utils/agent_dependency_loader.py +2 -2
  190. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/METADATA +211 -33
  191. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/RECORD +195 -115
  192. claude_mpm/agents/INSTRUCTIONS_OLD_DEPRECATED.md +0 -602
  193. claude_mpm/dashboard/static/css/code-tree.css +0 -1639
  194. claude_mpm/dashboard/static/js/components/code-tree/tree-breadcrumb.js +0 -353
  195. claude_mpm/dashboard/static/js/components/code-tree/tree-constants.js +0 -235
  196. claude_mpm/dashboard/static/js/components/code-tree/tree-search.js +0 -409
  197. claude_mpm/dashboard/static/js/components/code-tree/tree-utils.js +0 -435
  198. claude_mpm/dashboard/static/js/components/code-tree.js +0 -5869
  199. claude_mpm/dashboard/static/js/components/code-viewer.js +0 -1386
  200. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/WHEEL +0 -0
  201. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/entry_points.txt +0 -0
  202. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/licenses/LICENSE +0 -0
  203. {claude_mpm-4.15.2.dist-info → claude_mpm-4.20.3.dist-info}/top_level.txt +0 -0
claude_mpm/cli/startup.py CHANGED
@@ -79,6 +79,87 @@ def setup_configure_command_environment(args):
79
79
  logging.getLogger("claude_mpm").setLevel(logging.WARNING)
80
80
 
81
81
 
82
+ def deploy_bundled_skills():
83
+ """
84
+ Deploy bundled Claude Code skills on startup.
85
+
86
+ WHY: Automatically deploy skills from the bundled/ directory to .claude/skills/
87
+ to ensure skills are available for agents without manual intervention.
88
+
89
+ DESIGN DECISION: Deployment happens silently on startup with logging only.
90
+ Failures are logged but don't block startup to ensure claude-mpm remains
91
+ functional even if skills deployment fails. Respects auto_deploy config setting.
92
+ """
93
+ try:
94
+ # Check if auto-deploy is disabled in config
95
+ from ..config.config_loader import ConfigLoader
96
+
97
+ config_loader = ConfigLoader()
98
+ try:
99
+ config = config_loader.load_config()
100
+ skills_config = config.get("skills", {})
101
+ if not skills_config.get("auto_deploy", True):
102
+ # Auto-deploy disabled, skip silently
103
+ return
104
+ except Exception:
105
+ # If config loading fails, assume auto-deploy is enabled (default)
106
+ pass
107
+
108
+ # Import and run skills deployment
109
+ from ..skills.skills_service import SkillsService
110
+
111
+ skills_service = SkillsService()
112
+ deployment_result = skills_service.deploy_bundled_skills()
113
+
114
+ # Log results
115
+ from ..core.logger import get_logger
116
+
117
+ logger = get_logger("cli")
118
+
119
+ if deployment_result.get("deployed"):
120
+ logger.info(
121
+ f"Skills: Deployed {len(deployment_result['deployed'])} skill(s)"
122
+ )
123
+
124
+ if deployment_result.get("errors"):
125
+ logger.warning(
126
+ f"Skills: {len(deployment_result['errors'])} skill(s) failed to deploy"
127
+ )
128
+
129
+ except Exception as e:
130
+ # Import logger here to avoid circular imports
131
+ from ..core.logger import get_logger
132
+
133
+ logger = get_logger("cli")
134
+ logger.debug(f"Failed to deploy bundled skills: {e}")
135
+ # Continue execution - skills deployment failure shouldn't block startup
136
+
137
+
138
+ def discover_and_link_runtime_skills():
139
+ """
140
+ Discover and link runtime skills from user/project directories.
141
+
142
+ WHY: Automatically discover and link skills added to .claude/skills/
143
+ without requiring manual configuration.
144
+
145
+ DESIGN DECISION: Failures are logged but don't block startup to ensure
146
+ claude-mpm remains functional even if skills discovery fails.
147
+ """
148
+ try:
149
+ from ..cli.interactive.skills_wizard import (
150
+ discover_and_link_runtime_skills as discover_skills,
151
+ )
152
+
153
+ discover_skills()
154
+ except Exception as e:
155
+ # Import logger here to avoid circular imports
156
+ from ..core.logger import get_logger
157
+
158
+ logger = get_logger("cli")
159
+ logger.debug(f"Failed to discover runtime skills: {e}")
160
+ # Continue execution - skills discovery failure shouldn't block startup
161
+
162
+
82
163
  def run_background_services():
83
164
  """
84
165
  Initialize all background services on startup.
@@ -89,6 +170,8 @@ def run_background_services():
89
170
  check_mcp_auto_configuration()
90
171
  verify_mcp_gateway_startup()
91
172
  check_for_updates_async()
173
+ deploy_bundled_skills()
174
+ discover_and_link_runtime_skills()
92
175
 
93
176
 
94
177
  def setup_mcp_server_logging(args):
@@ -201,6 +201,58 @@ Next steps:
201
201
  - docker-ops
202
202
  - local-ops-agent
203
203
 
204
+ ## Default Configuration Fallback
205
+
206
+ When auto-configuration cannot detect your project's toolchain (e.g., a new or uncommon language/framework), it automatically falls back to a sensible set of default general-purpose agents instead of leaving your project unconfigured.
207
+
208
+ ### When Defaults are Applied
209
+
210
+ Default agents are deployed when:
211
+ - Primary language is detected as "Unknown"
212
+ - No specific framework or toolchain can be identified
213
+ - No agent recommendations can be generated from detected technologies
214
+
215
+ ### Default Agents
216
+
217
+ The following general-purpose agents are recommended with moderate confidence (0.7):
218
+
219
+ - **engineer**: General-purpose engineer for code implementation
220
+ - **research**: Code exploration and analysis
221
+ - **qa**: Testing and quality assurance
222
+ - **ops**: Infrastructure and deployment operations
223
+ - **documentation**: Documentation and technical writing
224
+
225
+ All default recommendations will be marked with `is_default: True` in the metadata.
226
+
227
+ ### Disabling Default Fallback
228
+
229
+ To disable the default configuration fallback, edit `.claude-mpm/config/agent_capabilities.yaml`:
230
+
231
+ ```yaml
232
+ default_configuration:
233
+ enabled: false # Disable default fallback
234
+ ```
235
+
236
+ When disabled, auto-configuration will recommend zero agents if the toolchain cannot be detected.
237
+
238
+ ### Customizing Defaults
239
+
240
+ You can customize which agents are deployed by default by editing the `default_configuration.agents` section in `.claude-mpm/config/agent_capabilities.yaml`:
241
+
242
+ ```yaml
243
+ default_configuration:
244
+ enabled: true
245
+ min_confidence: 0.7 # Confidence score for default recommendations
246
+ agents:
247
+ - agent_id: engineer
248
+ reasoning: "General-purpose engineer for code implementation"
249
+ priority: 1
250
+ - agent_id: research
251
+ reasoning: "Code exploration and analysis"
252
+ priority: 2
253
+ # Add or remove agents as needed
254
+ ```
255
+
204
256
  ## Tips
205
257
 
206
258
  1. **Start with preview**: Always run with `--preview` first to see recommendations
@@ -90,6 +90,9 @@ Available Commands:
90
90
  /mpm-monitor [start|stop|restart|status|port]
91
91
  Manage Socket.IO monitoring server and dashboard
92
92
 
93
+ /mpm-version
94
+ Display comprehensive version information including project version, all agents with versions, and all skills with versions
95
+
93
96
  Use '/mpm-help <command>' for detailed help on a specific command.
94
97
  ```
95
98
 
@@ -9,6 +9,9 @@ Initialize or intelligently update your project for optimal use with Claude Code
9
9
  /mpm-init update # Lightweight update based on recent git activity
10
10
  /mpm-init context # Intelligent context analysis from git history
11
11
  /mpm-init context --days 14 # Analyze last 14 days of git history
12
+ /mpm-init resume # Resume from stop event logs (NEW)
13
+ /mpm-init resume --list # List all sessions from logs
14
+ /mpm-init resume --session-id ID # Resume specific session
12
15
  /mpm-init catchup # Quick commit history display (no analysis)
13
16
  /mpm-init --review # Review project state without changes
14
17
  /mpm-init --update # Full update of existing CLAUDE.md
@@ -24,7 +27,9 @@ This command has two primary modes:
24
27
  - **Project initialization/updates**: Delegates to the Agentic Coder Optimizer agent for documentation, tooling, and workflow setup
25
28
  - **Context analysis** (context/catchup): Provides intelligent project context from git history for resuming work
26
29
 
27
- **Note**: The `resume` subcommand is deprecated. Use `context` instead. The `resume` command still works for backward compatibility but will be removed in a future version.
30
+ **Resume Modes**: The command provides two resume capabilities:
31
+ - `/mpm-init resume`: Reads stop event logs from `.claude-mpm/responses/` to help resume work
32
+ - `/mpm-init context`: Analyzes git history for intelligent work resumption (delegates to Research agent)
28
33
 
29
34
  **Quick Update Mode**: Running `/mpm-init update` performs a lightweight update focused on recent git activity. It analyzes recent commits, generates an activity report, and updates documentation with minimal changes. Perfect for quick refreshes after development sprints.
30
35
 
@@ -87,8 +92,46 @@ Analyzes recent git commits to identify:
87
92
 
88
93
  **NOT session state**: This does NOT save/restore conversation state like Claude Code. Instead, it reconstructs project context from git history using conventional commits and commit message analysis.
89
94
 
90
- #### `/mpm-init resume` [DEPRECATED]
91
- Alias for `context`. Use `context` instead.
95
+ #### `/mpm-init resume` (Stop Event Logs)
96
+ ```bash
97
+ /mpm-init resume # Show latest session from logs
98
+ /mpm-init resume --list # List all sessions
99
+ /mpm-init resume --session-id ID # Resume specific session
100
+ /mpm-init resume --last 5 # Show last 5 sessions
101
+ ```
102
+
103
+ Reads from stop event logs to help resume work from previous sessions:
104
+
105
+ **Data Sources** (two-tier strategy):
106
+ 1. **Resume logs** (preferred): `.claude-mpm/resume-logs/*.md` - Structured 10k-token summaries
107
+ 2. **Response logs** (fallback): `.claude-mpm/responses/*.json` - Raw conversation stop events
108
+
109
+ **What it shows**:
110
+ - When session ended (time ago)
111
+ - What was being worked on (request)
112
+ - Tasks completed (from PM responses)
113
+ - Files modified (from PM tracking)
114
+ - Next steps (from PM recommendations)
115
+ - Stop reason (why session ended)
116
+ - Token usage (context consumption)
117
+ - Git context (branch, working directory)
118
+
119
+ **How it works**:
120
+ 1. Scans response logs in `.claude-mpm/responses/`
121
+ 2. Groups by `session_id`
122
+ 3. Parses PM response JSON for context
123
+ 4. Extracts tasks, files, next steps from PM summaries
124
+ 5. Displays comprehensive resume context
125
+
126
+ **Use Cases**:
127
+ - Resume work after context threshold pause
128
+ - Review what was accomplished in previous session
129
+ - Understand why session stopped (max_tokens, end_turn, etc.)
130
+ - See exact files and tasks from last session
131
+
132
+ **Difference from `context`**:
133
+ - **resume**: Reads actual stop event logs (what PM logged)
134
+ - **context**: Analyzes git commits (what was committed)
92
135
 
93
136
  ### `/mpm-init catchup` (Simple Git History)
94
137
  ```bash
@@ -225,6 +268,66 @@ This provides intelligent analysis including:
225
268
 
226
269
  The old `resume` command redirects to `context` with a deprecation warning.
227
270
 
271
+ ### Resume from Stop Event Logs
272
+
273
+ Display context from previous sessions using stop event logs:
274
+
275
+ ```bash
276
+ /mpm-init resume # Show latest session
277
+ /mpm-init resume --list # List all available sessions
278
+ /mpm-init resume --session-id abc123 # Resume specific session
279
+ /mpm-init resume --last 10 # Show last 10 sessions
280
+ ```
281
+
282
+ Shows comprehensive context including:
283
+ - What was being worked on
284
+ - Tasks completed (from PM tracking)
285
+ - Files modified
286
+ - Next steps recommended
287
+ - Stop reason (context limit, completion, etc.)
288
+ - Token usage
289
+ - Time elapsed since session
290
+
291
+ **Example Output:**
292
+ ```
293
+ ================================================================================
294
+ 📋 Resume Context - Session from 2 hours ago
295
+ ================================================================================
296
+
297
+ Session ID: 20251104_143000
298
+ Ended: 2024-11-04 14:30 (2 hours ago)
299
+ Stop Reason: Context threshold reached (70%)
300
+ Token Usage: 140,000 / 200,000 (70%)
301
+
302
+ Working on:
303
+ "Implementing auto-pause and resume functionality"
304
+
305
+ ✅ Completed:
306
+ • Researched stop event logging system
307
+ • Found response logs in .claude-mpm/responses/
308
+ • Identified two-tier resume strategy
309
+
310
+ 📝 Files Modified:
311
+ • src/claude_mpm/services/cli/resume_service.py (new)
312
+ • src/claude_mpm/cli/commands/mpm_init.py (updated)
313
+
314
+ 🎯 Next Steps:
315
+ • Implement ResumeService class
316
+ • Add resume subcommand to mpm-init
317
+ • Test with real response logs
318
+
319
+ Git Context:
320
+ Branch: main
321
+ Working Directory: /Users/masa/Projects/claude-mpm
322
+ ================================================================================
323
+ ```
324
+
325
+ **Use Cases:**
326
+ - Resume after hitting context limit
327
+ - Review what was accomplished in last session
328
+ - See exact next steps recommended by PM
329
+ - Understand why session stopped
330
+
228
331
  ### Quick Git History (Catchup)
229
332
 
230
333
  Display recent commit history without analysis:
@@ -388,9 +491,12 @@ The command delegates to the Agentic Coder Optimizer agent which:
388
491
  ## Notes
389
492
 
390
493
  - **Quick Update vs Full Update**: Use `/mpm-init update` for fast activity-based updates (30 days), or `/mpm-init --update` for comprehensive doc refresh
391
- - **Context Analysis**: Use `/mpm-init context` to analyze git history and get intelligent resumption context from Research agent
392
- - **Quick History**: Use `/mpm-init catchup` for instant commit history display without analysis
393
- - **Deprecation Notice**: The `resume` command is deprecated. Use `context` instead. The old command still works but shows a warning.
494
+ - **Resume Strategies**:
495
+ - **`/mpm-init resume`**: Read stop event logs (what PM tracked in last session)
496
+ - **`/mpm-init context`**: Analyze git history (intelligent work stream analysis via Research)
497
+ - **`/mpm-init catchup`**: Quick commit history display (no analysis)
498
+ - **Stop Event Logs**: Response logs in `.claude-mpm/responses/` contain PM summaries with tasks, files, and next steps
499
+ - **Two-Tier Resume**: Prefers structured resume logs (`.claude-mpm/resume-logs/`), falls back to response logs
394
500
  - **Smart Mode**: Automatically detects existing CLAUDE.md and offers update vs recreate
395
501
  - **Safe Updates**: Previous versions always archived before updating
396
502
  - **Custom Content**: Your project-specific sections are preserved by default
@@ -0,0 +1,113 @@
1
+ # Display Claude MPM Version Information
2
+
3
+ Show comprehensive version information for Claude MPM project, agents, and skills.
4
+
5
+ ## Usage
6
+
7
+ ```
8
+ /mpm-version
9
+ ```
10
+
11
+ ## Description
12
+
13
+ Display version information including:
14
+ - Project version and build number
15
+ - All deployed agents with their versions (grouped by tier: system/user/project)
16
+ - All available skills with their versions (grouped by source: bundled/user/project)
17
+ - Summary statistics
18
+
19
+ ## Implementation
20
+
21
+ When you run `/mpm-version`, the PM will:
22
+
23
+ 1. **Collect Version Information**
24
+ - Use VersionService to gather all version data
25
+ - Project version from pyproject.toml
26
+ - Build number from BUILD_NUMBER file
27
+ - Agent versions from AgentRegistry
28
+ - Skills versions from SkillRegistry
29
+
30
+ 2. **Format Output**
31
+ - Hierarchical display: Project → Agents → Skills
32
+ - Grouped by tier/source for clarity
33
+ - Sorted alphabetically within groups
34
+ - Summary statistics at the end
35
+
36
+ 3. **Display Results**
37
+ - Well-formatted tree structure
38
+ - Easy to scan and read
39
+ - Includes totals and counts
40
+
41
+ ## Example Output
42
+
43
+ ```
44
+ Claude MPM Version Information
45
+ ==============================
46
+
47
+ Project Version: 4.16.3
48
+ Build: 481
49
+
50
+ Agents (35 total)
51
+ -----------------
52
+
53
+ System Agents (30):
54
+ ├─ agent-manager (1.0.0)
55
+ ├─ engineer (3.9.1)
56
+ ├─ research-agent (4.5.1)
57
+ ├─ documentation (2.1.0)
58
+ ├─ qa (2.0.3)
59
+ └─ ... (25 more)
60
+
61
+ User Agents (3):
62
+ ├─ custom-agent (1.0.0)
63
+ ├─ testing-agent (0.5.0)
64
+ └─ prototype-agent (0.1.0)
65
+
66
+ Project Agents (2):
67
+ ├─ project-specific (2.0.0)
68
+ └─ domain-expert (1.1.0)
69
+
70
+ Skills (20 total)
71
+ -----------------
72
+
73
+ Bundled Skills (20):
74
+ ├─ test-driven-development (0.1.0)
75
+ ├─ systematic-debugging (0.1.0)
76
+ ├─ async-testing (0.1.0)
77
+ ├─ performance-profiling (0.1.0)
78
+ ├─ security-scanning (0.1.0)
79
+ └─ ... (15 more)
80
+
81
+ User Skills (0):
82
+ (none)
83
+
84
+ Project Skills (0):
85
+ (none)
86
+
87
+ Summary
88
+ -------
89
+ • Project: v4.16.3 (build 481)
90
+ • Agents: 35 total (30 system, 3 user, 2 project)
91
+ • Skills: 20 total (20 bundled, 0 user, 0 project)
92
+ ```
93
+
94
+ ## PM Implementation Instructions
95
+
96
+ To execute this command, PM should:
97
+
98
+ 1. Import and use VersionService:
99
+ ```python
100
+ from claude_mpm.services.version_service import VersionService
101
+
102
+ service = VersionService()
103
+ summary = service.get_version_summary()
104
+ ```
105
+
106
+ 2. Format output following the example structure above
107
+ 3. Handle missing data gracefully (show "unknown" for missing versions)
108
+ 4. Include all tiers/sources even if counts are zero
109
+
110
+ ## Related Commands
111
+
112
+ - `/mpm-help` - Show all available MPM commands
113
+ - `/mpm-status` - Show system status information
@@ -8,6 +8,7 @@ Available MPM commands:
8
8
  - /mpm-help - Show command help
9
9
  - /mpm-status - Show MPM status
10
10
  - /mpm-config - Manage configuration
11
+ - /mpm-version - Display version information for project, agents, and skills
11
12
 
12
13
  Claude MPM extends Claude Code with:
13
14
  - Multi-agent orchestration
@@ -242,7 +242,7 @@ class AgentConfig:
242
242
  Path.cwd() / get_path_manager().CONFIG_DIR / "agent_config.yaml"
243
243
  )
244
244
  if project_config.exists():
245
- logger.info(f"Loading project agent config from {project_config}")
245
+ logger.debug(f"Loading project agent config from {project_config}")
246
246
  file_config = cls.from_file(project_config)
247
247
  # Merge with environment config (env takes precedence)
248
248
  config = cls._merge_configs(config, file_config)
@@ -252,7 +252,7 @@ class AgentConfig:
252
252
  if user_config_dir:
253
253
  user_config = user_config_dir / "agent_config.yaml"
254
254
  if user_config.exists():
255
- logger.info(f"Loading user agent config from {user_config}")
255
+ logger.debug(f"Loading user agent config from {user_config}")
256
256
  file_config = cls.from_file(user_config)
257
257
  config = cls._merge_configs(config, file_config)
258
258
 
claude_mpm/constants.py CHANGED
@@ -45,6 +45,7 @@ class CLICommands(str, Enum):
45
45
  DOCTOR = "doctor"
46
46
  DASHBOARD = "dashboard"
47
47
  UPGRADE = "upgrade"
48
+ SKILLS = "skills"
48
49
 
49
50
  def with_prefix(self, prefix: CLIPrefix = CLIPrefix.MPM) -> str:
50
51
  """Get command with prefix."""
@@ -158,6 +159,17 @@ class TicketCommands(str, Enum):
158
159
  WORKFLOW = "workflow"
159
160
 
160
161
 
162
+ class SkillsCommands(str, Enum):
163
+ """Skills subcommand constants."""
164
+
165
+ LIST = "list"
166
+ DEPLOY = "deploy"
167
+ VALIDATE = "validate"
168
+ UPDATE = "update"
169
+ INFO = "info"
170
+ CONFIG = "config"
171
+
172
+
161
173
  class CLIFlags(str, Enum):
162
174
  """CLI flag constants (without prefix)."""
163
175
 
claude_mpm/core/config.py CHANGED
@@ -578,6 +578,11 @@ class Config:
578
578
  "[PM-REMINDER] Your role is coordination and management",
579
579
  ],
580
580
  },
581
+ # Session management configuration
582
+ "session": {
583
+ "auto_save": True, # Enable automatic session saving
584
+ "save_interval": 300, # Auto-save interval in seconds (5 minutes)
585
+ },
581
586
  }
582
587
 
583
588
  # Apply defaults for missing keys
@@ -588,6 +593,9 @@ class Config:
588
593
  # Validate health and recovery configuration
589
594
  self._validate_health_recovery_config()
590
595
 
596
+ # Validate session configuration
597
+ self._validate_session_config()
598
+
591
599
  def get(self, key: str, default: Any = None) -> Any:
592
600
  """Get configuration value."""
593
601
  # Support nested keys with dot notation
@@ -764,6 +772,40 @@ class Config:
764
772
  except Exception as e:
765
773
  logger.error(f"Error validating health/recovery configuration: {e}")
766
774
 
775
+ def _validate_session_config(self) -> None:
776
+ """Validate session management configuration."""
777
+ try:
778
+ session_config = self.get("session", {})
779
+
780
+ # Validate save_interval range (60-1800 seconds)
781
+ save_interval = session_config.get("save_interval", 300)
782
+ if not isinstance(save_interval, int):
783
+ logger.warning(
784
+ f"Session save_interval must be integer, got {type(save_interval).__name__}, using default 300"
785
+ )
786
+ self.set("session.save_interval", 300)
787
+ elif save_interval < 60:
788
+ logger.warning(
789
+ f"Session save_interval must be at least 60 seconds, got {save_interval}, using 60"
790
+ )
791
+ self.set("session.save_interval", 60)
792
+ elif save_interval > 1800:
793
+ logger.warning(
794
+ f"Session save_interval must be at most 1800 seconds (30 min), got {save_interval}, using 1800"
795
+ )
796
+ self.set("session.save_interval", 1800)
797
+
798
+ # Validate auto_save is boolean
799
+ auto_save = session_config.get("auto_save", True)
800
+ if not isinstance(auto_save, bool):
801
+ logger.warning(
802
+ f"Session auto_save must be boolean, got {type(auto_save).__name__}, using True"
803
+ )
804
+ self.set("session.auto_save", True)
805
+
806
+ except Exception as e:
807
+ logger.error(f"Error validating session configuration: {e}")
808
+
767
809
  def get_health_monitoring_config(self) -> Dict[str, Any]:
768
810
  """Get health monitoring configuration with defaults."""
769
811
  base_config = {
claude_mpm/core/enums.py CHANGED
@@ -251,6 +251,24 @@ class HealthStatus(StrEnum):
251
251
  TIMEOUT = "timeout"
252
252
  """Health check exceeded time limit."""
253
253
 
254
+ def is_operational(self) -> bool:
255
+ """
256
+ Check if health status indicates operational state.
257
+
258
+ Returns:
259
+ True if status is HEALTHY or DEGRADED
260
+ """
261
+ return self in (HealthStatus.HEALTHY, HealthStatus.DEGRADED)
262
+
263
+ def is_critical(self) -> bool:
264
+ """
265
+ Check if health status indicates critical failure.
266
+
267
+ Returns:
268
+ True if status is UNHEALTHY
269
+ """
270
+ return self == HealthStatus.UNHEALTHY
271
+
254
272
 
255
273
  class ModelTier(StrEnum):
256
274
  """
@@ -77,7 +77,7 @@ class AgentServiceFactory(ServiceFactory):
77
77
  if hasattr(service, "set_directories"):
78
78
  service.set_directories(framework_dir, project_dir)
79
79
 
80
- logger.info("Created agent deployment service")
80
+ logger.debug("Created agent deployment service")
81
81
  return service
82
82
 
83
83
 
@@ -236,7 +236,7 @@ class OptimizedAgentLoader:
236
236
 
237
237
  self.metrics.total_time = time.time() - start_time
238
238
 
239
- self.logger.info(
239
+ self.logger.debug(
240
240
  f"Loaded {self.metrics.loaded_agents}/{self.metrics.total_agents} agents "
241
241
  f"in {self.metrics.total_time:.2f}s "
242
242
  f"(cache hits: {self.metrics.cache_hits}, misses: {self.metrics.cache_misses})"
@@ -286,7 +286,7 @@ class OptimizedAgentLoader:
286
286
 
287
287
  self.metrics.total_time = time.time() - start_time
288
288
 
289
- self.logger.info(
289
+ self.logger.debug(
290
290
  f"Async loaded {self.metrics.loaded_agents}/{self.metrics.total_agents} agents "
291
291
  f"in {self.metrics.total_time:.2f}s"
292
292
  )
@@ -418,7 +418,7 @@ class OptimizedAgentLoader:
418
418
  Args:
419
419
  agent_dirs: List of directories containing agents
420
420
  """
421
- self.logger.info(f"Preloading agents from {len(agent_dirs)} directories")
421
+ self.logger.debug(f"Preloading agents from {len(agent_dirs)} directories")
422
422
 
423
423
  all_paths = []
424
424
  for dir_path in agent_dirs:
claude_mpm/core/types.py CHANGED
@@ -20,6 +20,8 @@ from datetime import datetime, timezone
20
20
  from enum import Enum
21
21
  from typing import Any, Dict, List, Optional, Tuple, Union
22
22
 
23
+ from .enums import HealthStatus
24
+
23
25
 
24
26
  # Service operation results
25
27
  @dataclass
@@ -230,15 +232,6 @@ class SocketMessage:
230
232
 
231
233
 
232
234
  # Health monitoring types
233
- class HealthStatus(Enum):
234
- """Service health status levels."""
235
-
236
- HEALTHY = "healthy"
237
- DEGRADED = "degraded"
238
- UNHEALTHY = "unhealthy"
239
- UNKNOWN = "unknown"
240
-
241
-
242
235
  @dataclass
243
236
  class HealthCheck:
244
237
  """Health check result."""
@@ -321,14 +321,6 @@ class Dashboard {
321
321
  // Process agent inference for new events
322
322
  this.agentInference.processAgentInference();
323
323
 
324
- // Notify CodeViewer that file operations have been updated
325
- // This ensures File Tree tab shows the same data as Files tab
326
- if (window.CodeViewer && typeof window.CodeViewer.refreshFromFileToolTracker === 'function') {
327
- setTimeout(() => {
328
- window.CodeViewer.refreshFromFileToolTracker();
329
- }, 50);
330
- }
331
-
332
324
  // Update agent hierarchy with new events
333
325
  this.agentHierarchy.updateWithNewEvents(events);
334
326
 
@@ -445,12 +437,6 @@ class Dashboard {
445
437
  case 'events':
446
438
  // Events tab is handled by EventViewer
447
439
  break;
448
- case 'claude-tree':
449
- // File Tree tab - trigger CodeViewer rendering
450
- if (window.CodeViewer && typeof window.CodeViewer.show === 'function') {
451
- window.CodeViewer.show();
452
- }
453
- break;
454
440
  case 'activity':
455
441
  // Trigger Activity tab rendering through the component
456
442
  // Check if ActivityTree class is available (from built module)