dsh-vibe-math 2.0.14 → 2.0.15

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "dsh-vibe-math",
3
3
  "description": "Multi-agent mathematical problem-solving & verification frameworks for DeepSeek Harness — THREE agent presets in one install: vibe-math-v2 (probability-driven: qs.json + Propos knowledge base + explorer→solver→review/debate verdict), vibe-math-v3 (THIRD-generation, recommended: paper-style Markdown knowledge base with Problems/Progress/Propos/Methods/Verified + planner-agent scheduling that decides the next N actions + universal theory/method invention library + agents write their own Markdown directly via a per-file write lock), and vibe-math-v4 (FOURTH-generation: persistent self-organizing resident subagents that message & meet to decide all tasks, verify only by unanimous consensus, /compact at a context threshold, and stop only when all agree the problem is solved). Installing this bundle auto-installs all three presets (v1 was removed at v2.0.0).",
4
- "version": "2.0.14",
4
+ "version": "2.0.15",
5
5
  "type": "module",
6
6
  "engines": {
7
7
  "node": "^22.19.0 || >=24.0.0"
@@ -257,7 +257,7 @@ export function apply(ctx) {
257
257
  residents.set(r.rId,r); await saveAll(); logActivity('spawn',r.rId+' ('+(r.direction||'brainstorm')+')')
258
258
  }
259
259
  async function wakeResident(r, promptText, kind){
260
- if(!r || !r.childId) return false // a removed resident must never be woken (rune: crash on r.childId)
260
+ if(!r || !r.childId) return false // a removed resident must never be woken (else r.childId would crash)
261
261
  clearHeartbeat()
262
262
  busy.add(r.rId); wakeKind.set(r.rId,kind||'normal'); currentResident=r.rId
263
263
  r.lastActiveAt=now(); r.rounds+=1; r.roundsSinceCompact+=1
@@ -732,6 +732,10 @@ export function apply(ctx) {
732
732
  }
733
733
  async function resume(){
734
734
  currentProject=await readCurrentProject(); await ensureDirs(); await loadAll(); await loadSettings()
735
+ // After loadAll the residentSeq counter is still whatever THIS process had (0 on a fresh process),
736
+ // but persisted residents may already be r-1..r-N. Sync it to the max existing id so a later
737
+ // addMember never collides with an existing resident (it would silently overwrite it).
738
+ for(const key of residents.keys()){ const mm=/^r-(\d+)$/.exec(String(key)); if(mm) residentSeq=Math.max(residentSeq, Number(mm[1])) }
735
739
  lastActivityAt=now(); lastProgressAt=now() // pause must not count as stall time; a resumed run gets a fresh clock
736
740
  if(phase==='idle' && !running && residents.size===0) return {ok:false,message:'nothing to resume'}
737
741
  // If the persisted State came from a DIFFERENT process (crash/restart), the saved