@yemi33/minions 0.1.589 → 0.1.591

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.
package/CHANGELOG.md CHANGED
@@ -1,8 +1,14 @@
1
1
  # Changelog
2
2
 
3
- ## 0.1.589 (2026-04-08)
3
+ ## 0.1.591 (2026-04-08)
4
+
5
+ ### Fixes
6
+ - per-type maxTurns bypassed when config has default maxTurns=100
7
+
8
+ ## 0.1.590 (2026-04-08)
4
9
 
5
10
  ### Other
11
+ - docs: update CLAUDE.md and README with current architecture
6
12
  - refactor: extract shared playbook rules to shared-rules.md
7
13
 
8
14
  ## 0.1.586 (2026-04-08)
package/README.md CHANGED
@@ -141,7 +141,7 @@ minions work "Explore the codebase and document the architecture"
141
141
  | `minions spawn <agent> <prompt>` | Manually spawn an agent |
142
142
  | `minions plan <file\|text> [proj]` | Run a plan |
143
143
  | `minions cleanup` | Run cleanup manually (temp files, worktrees, zombies) |
144
- | `minions dash` | Start web dashboard (default port 7331) |
144
+ | `minions dash` | Open dashboard (starts if not already running, port 7331) |
145
145
 
146
146
  You can also run scripts directly: `node ~/.minions/engine.js start`, `node ~/.minions/dashboard.js`, etc.
147
147
 
@@ -209,7 +209,7 @@ You can also run scripts directly: `node ~/.minions/engine.js start`, `node ~/.m
209
209
  - **Routes intelligently** — fixes first, then reviews, then implementation, matched to agent strengths
210
210
  - **LLM-powered consolidation** — Claude Haiku summarizes notes (threshold: 5 files). Regex fallback. Source references required.
211
211
  - **Knowledge base** — `knowledge/` with categories: architecture, conventions, project-notes, build-reports, reviews. Full notes preserved. Dashboard browsable with inline Q&A.
212
- - **Token tracking** — per-agent and per-day usage. Dashboard Token Usage panel.
212
+ - **Token tracking** — per-agent and per-day usage with runtime tracking. Dashboard Token Usage panel + LLM Call Performance tile (avg runtime by call type: agent-dispatch, command-center, doc-chat, consolidation).
213
213
  - **Engine watchdog** — dashboard auto-restarts dead engine.
214
214
  - **Agent re-attachment** — on restart, finds surviving agent processes via PID files.
215
215
  - **Learns from itself** — agents write findings, engine consolidates into institutional knowledge
@@ -246,7 +246,7 @@ The web dashboard at `http://localhost:7331` provides:
246
246
  - **Notes & KB** — inbox (paginated, 15/page), team notes (editable), knowledge base by category (paginated, 30/page) with inline Q&A. Pinned notes for critical context.
247
247
  - **Schedules** — create/edit/delete scheduled tasks with visual cron builder and natural language parsing. Paginated (15/page).
248
248
  - **Skills & MCP** — agent-created reusable workflows (minions-wide + project-specific), click to view full content. MCP server listing.
249
- - **Engine** — dispatch queue (completed paginated, 20/page), engine log (paginated, 50/page), agent metrics, token usage, context pressure.
249
+ - **Engine** — dispatch queue (completed paginated, 20/page), engine log (paginated, 50/page), LLM call performance (avg runtime by call type), agent metrics (with avg runtime), token usage.
250
250
  - **Settings** — engine config, eval loop, agent management, routing editor.
251
251
  - **Document modals** — inline Q&A on any document modal. Auto-polls for live updates with scroll preservation.
252
252
 
@@ -369,15 +369,28 @@ Each item passes through: dedup (checks pending, active, AND recently completed)
369
369
 
370
370
  ### Spawn Chain
371
371
 
372
+ **Agent dispatch** (engine agents):
372
373
  ```
373
- engine.js
374
+ engine.js spawnAgent()
375
+ → builds prompt BEFORE worktree (parallel — no dependency on worktree path)
376
+ → git worktree add (write tasks only, 20-60s)
374
377
  → spawn node spawn-agent.js <prompt.md> <sysprompt.md> <args...>
375
- spawn-agent.js resolves claude-code cli.js path
376
- → spawn node cli.js -p --system-prompt <content> <args...>
377
- → prompt piped via stdin (avoids shell metacharacter issues)
378
+ → resolves claude binary path (cached in claude-caps.json)
379
+ → spawn node cli.js -p --system-prompt-file <file> <args...>
380
+ → prompt piped via stdin
378
381
  ```
379
382
 
380
- No bash or shell involved Node spawns Node directly. Prompts with special characters (parentheses, backticks, etc.) are safe.
383
+ **CC/doc-chat** (direct spawnbypasses spawn-agent.js):
384
+ ```
385
+ dashboard.js ccCall()
386
+ → llm.js callLLM({ direct: true })
387
+ → reads cached binary from claude-caps.json
388
+ → writes system prompt to temp file
389
+ → spawns claude CLI directly (1 process, 3 syscalls)
390
+ → prompt piped via stdin
391
+ ```
392
+
393
+ No bash or shell involved — Node spawns Node directly. Dependency branches are fetched in parallel via `Promise.allSettled`.
381
394
 
382
395
  ### What Each Agent Gets
383
396
 
package/engine.js CHANGED
@@ -155,8 +155,9 @@ const _MAX_TURNS_BY_TYPE = {
155
155
  [WORK_TYPE.TEST]: 50, [WORK_TYPE.VERIFY]: 100, [WORK_TYPE.DOCS]: 30,
156
156
  };
157
157
  function _maxTurnsForType(type, engineConfig) {
158
- // User override takes precedence, then per-type default, then global default
159
- return engineConfig.maxTurns || _MAX_TURNS_BY_TYPE[type] || DEFAULTS.maxTurns;
158
+ // Per-type defaults apply unless user explicitly set a custom maxTurns (different from engine default)
159
+ const userOverride = engineConfig.maxTurns && engineConfig.maxTurns !== DEFAULTS.maxTurns ? engineConfig.maxTurns : null;
160
+ return userOverride || _MAX_TURNS_BY_TYPE[type] || DEFAULTS.maxTurns;
160
161
  }
161
162
 
162
163
  // Resolve dependency plan item IDs to their PR branches
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yemi33/minions",
3
- "version": "0.1.589",
3
+ "version": "0.1.591",
4
4
  "description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
5
5
  "bin": {
6
6
  "minions": "bin/minions.js"