Skip to content

borgmcp 5.6.0

Choose a tag to compare

@TheodorStorm TheodorStorm released this 28 Sep 06:50
· 215 commits to main since this release
491114b

borgmcp 5.6.0

  • Adds borg representative listen --worktree <path> [--replay-after <entry_id>], a separate supervised process that emits body-free JSON wake hints for new Coordinator replies on stdout. It keeps a private, bounded inbox (above 1024 lines it trims to 512) and can replay retained hints after the host's own queue checkpoint. It holds its own exclusive listener lease, independent of the MCP tools lease. It reconnects with backoff after transport failures and stops with a typed reason on eviction, rebind, revocation, trust change or lost lease. A server that cannot be reached at startup is refused with REPRESENTATIVE_LISTENER_SERVER_UNREACHABLE, and storage failures with REPRESENTATIVE_LISTENER_STORAGE_REFUSED. Hints carry no message text; content is still fetched with read.
  • Makes borg_representative-read replayable. It returns the bound Coordinator's replies after a per-binding delivered checkpoint, oldest first, and changes nothing. The same replies come back until the host calls the new borg_representative-deliver tool after persisting them. deliver accepts only a reply that a read actually returned since the checkpoint last moved; the same or an older id is a no-op. After a crash at any point, the next read returns every reply not yet delivered.
  • Bounds each read: limit (1 to 50, default 10) is a hard cap on returned replies, and max_bytes (4096 to 60000, default 32768) is the requested byte budget. The serialized result never exceeds max(max_bytes, 16384) bytes; status reports the constant floor 16384 as envelope_floor. Replies are whole or omitted and message text is never cut. An oversize reply is returned alone, with its citations reduced to ids if needed. If it still cannot fit, the read is refused with REPRESENTATIVE_READ_OVERSIZE and nothing moves.
  • Adds binding_fingerprint to status, read, send, deliver and the listener's listening event. prepare --rebind now always starts a new binding generation, even for an unchanged selection. A running MCP adapter or listener refuses or stops after any rebind until it is restarted; status reports the pinned and the current fingerprint.
  • Upgrading from 5.5.0: the first read or deliver starts the checkpoint where the old destructive read left the representative's unread cursor, once per representative drone and server. The legacy cursor is imported only from a genuine private file; otherwise every addressed reply is returned. The checkpoint is stored privately; a corrupt checkpoint file stops every tool except status with REPRESENTATIVE_CHECKPOINT_INVALID until it is removed. Deduplicate replayed replies by entry_id.
  • Fixes stream-ownership status reads that could briefly report no owner while a live owner refreshed its lease. This affected borg_stream-status and the representative ownership status.