Nexus · Agent-run development← Coordination

How Agents Build and Ship Nexus

Several Claude Code sessions build, test, review, and release Nexus, and one more session, the conexus instance, runs the cloud side. They work on the same repository and the same engine at the same time without colliding, because every claim, test slot, push, and deploy is a record that the other sessions see as soon as it is written. They coordinate through records in the tuple space of the managed Nexus engine, and they keep longer notes in Nexus memory. The owner makes the decisions that agents do not make: every tag, every cloud deploy, and every change of direction.

Terms used on this page
TermMeaning
tuple spaceThe part of the Nexus engine where sessions and agents leave short records for each other. The Nexus Tuple Space explains it.
boardA topic in the tuple space. Every subscribed session receives every post, and nobody removes one.
mailboxThe part of the tuple space that holds the messages for one session or one agent.
subscription, pingA session subscribes to a board once. After that, each new post or message arrives as a ping, which names the record and does not contain it.
worktreeA second working directory of the same git repository, with its own branch.
beadOne work item in the project's shared issue tracker.

The system at a glance

writes records pings Laptop sessions and subagents one worktree per session primary checkout on develop push, PR GitHub CI on develop and PRs release workflows on tags package and binaries webhooks webhook adapter hosted by conexus posts Managed engine run by conexus tuple space team boards CI board push lock mailboxes and names agent ledger branches over ssh Second machine local network full suites and gates runner for mac release builds deploys, gates mailbox conexus instance a peer session Owner tags, deploys, direction go decisions
Sessions, CI, and the conexus instance coordinate through the tuple space in the managed engine.
  • Sessions and subagents. Each working session is one Claude Code session in its own worktree and branch on the laptop. It dispatches subagents: developers for implementation, and two standing reviewers (a code reviewer and a critic). Sessions choose their own beads. When the owner asks, one session coordinates: it assigns work, collects results, and prepares a release.
  • The conexus instance. A separate Claude Code session in the conexus repository runs the managed engine, and so it hosts the tuple space that every other session coordinates through. It also hosts the adapter that turns GitHub events into CI board posts, deploys each engine release, and runs the cloud gates. It is a peer of the other sessions: it receives requests in its mailbox and answers there.
  • GitHub runs CI on every push to develop and on every pull request, and it runs the release workflows on tags.
  • A second machine on the local network runs full test suites and gates for the sessions. It is also a self-hosted GitHub runner for the mac release builds.
  • The owner pushes every release tag, approves every cloud deploy, and decides changes of scope or direction.

Shared records

The sessions share state through two kinds of record: short signals in the tuple space, and longer notes in Nexus memory.

A tuple is a small record with a schema. It lives in the engine, outside every conversation, so it outlives the session that wrote it and every session reads the same row. The Nexus Tuple Space describes the operations, and Coordination describes messages between sessions and agents.

Each session holds a short name in a directory in the tuple space, and a message addressed to a name reaches the session that holds it. Each session and each subagent has a mailbox. A session subscribes to the boards it cares about, and its own Nexus server then pings it for each new post and each new message in its mailbox. No session polls, whether it waits for CI, for a peer, or for a reply.

A post or a message carries a short signal and names a memory entry for anything longer, such as a measurement or a list of affected documents. Work items are beads in a shared tracker.

Agents, skills and tools

The conexus plugin gives every session the same agents, skills, and hooks, so the sessions work the same way without instructing each other. A session hands most work to background subagents: developers, the two standing reviewers, a debugger, planners. Skills carry the checklists, such as the two release procedures. Hooks enforce the practice that nobody should have to remember: they brief each subagent when it starts, refuse to close a bead without both reviews, and record every dispatch.

The agent types
AgentUsed for
worktree-developerImplementation in a worktree that Claude Code creates for the dispatch. The agent runs its own Serena server rooted in that worktree, so parallel implementers never share a tree. A preflight check first updates the worktree to develop. If it cannot, the agent stops.
developerTest-first implementation in the session's own worktree.
code-review-expert, substantive-criticThe two standing reviewers. A bead closes only after both have reviewed its change.
test-validatorTest coverage and suite runs.
debuggerInvestigation of a failure, one hypothesis at a time.
strategic-planner, architect-plannerPlans that split work into beads, and architecture before a large change.
deep-research-synthesizerResearch across the knowledge store, memory, the web, and code.
ExploreRead-only sweeps across many files. Claude Code provides it.

One change, end to end

Claim and announce

A session claims a bead and posts the claim on the team boards, with the worktree it uses and the files the change touches. Other sessions receive the post, so two sessions do not start the same work. The team boards also carry advance warnings when a change affects files that other sessions work on.

Build and review

The session creates a worktree on a feature branch and dispatches a developer subagent, which writes the failing test and then the fix. Hooks record every dispatch in a ledger, so a subagent that started and never reported shows up as missing. The two reviewers then read the change, the session fixes their findings, and it records a review marker that names both reviewers.

Test

Each machine runs one engine build or engine test suite at a time, and a lease enforces it. Every worktree on the machine sees the lease, and it ends by itself if its holder stops. Each machine also runs one full test suite at a time. The session posts on the team boards when it takes the full-suite slot and again when it releases the slot. For heavy runs, the session moves its branch to the second machine over ssh. That machine has its own clone and its own lease, so it runs a suite while the laptop builds.

Push

Before it pushes, the session reads the CI board for the latest develop commit, because a push cancels the CI run of that commit. Another session can be waiting for that run. The push script then sends only the commits and files that the session names, so a peer's work never goes out with the push. The script holds the push lock only while it pushes. The session posts the push on the team boards and fast-forwards the primary checkout, which stays on develop as the shared reference and which nobody edits.

GitHub then runs CI. For each state change of each run and job, GitHub sends a webhook to the adapter, which verifies it and writes one post to the CI board. The session receives the pings and reads the verdict for its commit with the status reader. A red commit gets a fix as a new commit, and other sessions read the verdict before they build on a commit. The bead closes when the close gate finds the review marker.

Verdicts and exit status of the status reader

The status reader folds the posts for one commit into one verdict for each run and job. Within one attempt the most advanced state wins, and across reruns the newest attempt wins. Its exit status gives the overall verdict.

ExitMeaning
0Every run and job finished green.
1At least one run or job failed.
2Nothing failed, and something is still queued or running.
3The board has no post for this commit.
4Nothing failed or is pending, and a run was cancelled, usually because a newer push replaced it.
The CI jobs
  • A predicate job decides whether a change touches code. A documentation-only change skips the tests.
  • One job builds the engine's service jar once for all test jobs, and caches it on the service source.
  • The unit suite runs in parallel shards against a real engine. Separate jobs run the repository-structure tests and a check over the whole collected suite.
  • A change under the engine source also builds the engine's native image, and a separate workflow runs the Java tests.
  • A pull request to main also checks the wire-contract ledger.
  • One required check collects every result, and it fails on any failed, cancelled, or missing part.
  • A newer push to the same branch cancels the older CI run. A newer run never cancels a release workflow, and a release workflow publishes what CI already tested without testing it again.

Release the client

The coordinating session creates a release worktree, which a push to develop cannot move. Then it bumps the version and runs the release battery. The battery builds the artifacts once, runs the end-to-end gates in parallel, and prints one verdict table. A gate that finishes without its verdict line counts as missing, never as passed. A red gate is fixed on the release branch, and the battery runs again. The session opens a pull request to main. The owner merges it and pushes the release tag. The release workflow checks the tag against the version and against the tagged commit's CI results, publishes the package to PyPI, and creates the GitHub release. Each client release pins exactly one engine version.

Release and deploy the engine

Before an engine tag, the coordinating session builds the candidate native binary and runs the shakeout, an end-to-end test of that binary. The owner pushes the engine tag. The engine workflow builds and smoke-tests native binaries for Linux and macOS, signs every asset, and publishes the GitHub release only when every asset is present. A failed build job leaves the release as a draft until a rerun completes it. A gate then installs the published binary on a bare machine and tests it.

The deploy request is a relay, not an approval. The coordinating session sends the tag and its gate evidence to the conexus instance's mailbox. The owner types the approval in the conexus instance itself, and the conexus instance refuses an approval that another session relays. The conexus instance then deploys the engine and runs its cloud gates. While those gates run, the coordinating session posts a freeze on the team boards. The freeze names the step that the session waits for, and the other sessions hold their pushes. Afterwards, a session on a cloud-mode machine checks that the engine's contracts reach real client code through the public edge.

The wire-contract ledger decides the order. It lists each engine change whose client half has not shipped, and marks whether an old client still works against the new engine. When every entry is safe for old clients, the engine deploys before the client release. Otherwise, the conexus instance must record that the redeploy is armed before the client tag, and the release gate checks for that record.

Who decides what

StepDone by
Change, tests, reviews, suites, push to developAgents
Release preparation: version bump, battery, release pull request, shakeoutAgents
Merge of the release pull request, release tags, engine tagsThe owner
Build, sign, and publish after a tagGitHub workflows
Deploy relay with gate evidenceThe coordinating session
Approval of each cloud deploy, typed in the conexus instanceThe owner
Cloud deploy and cloud gatesThe conexus instance
Decisions that change scope or directionThe owner