Inspiration
I was managing two services within the same application while using coding agents to implement changes. The agents worked quickly, but I often had to spend significant time debugging incompatible changes and untangling merge requests when one service changed an API used by another. This motivated me to build Code Claim—a coordination layer that helps agents understand service contracts and resolve compatibility problems before they become merge-time surprises.
What it does
Code Claim monitors versioned HTTP contracts between internal services. When one service publishes a breaking API change, Code Claim identifies the confirmed consumers, creates compatibility work, and dispatches it to the appropriate coding harness through MCP. The downstream agent can inspect the updated contract, modify its client code, run tests, and submit evidence. Contract revisions, dependencies, checkpoints, work items, and agent actions are preserved in a complete audit trail.
How we built it
The coordinator is built with Python, FastAPI, and Pydantic. Service contracts are extracted from FastAPI OpenAPI schemas and normalized into a deterministic HTTP contract model. CockroachDB acts as the durable source of truth and transactional event spine. It stores service registrations, contract revisions, confirmed dependencies, compatibility work, agent tasks, checkpoints, audit records, and outbox events. CockroachDB changefeeds notify the coordinator about committed contract changes. MCP allows different coding harnesses, such as Codex and Antigravity, to identify themselves, claim work, checkpoint progress, and submit test evidence.
Challenges we ran into
The main challenge was coordinating agents without introducing source-code locking. Agents should be able to work in parallel, but the system must still detect when their assumptions become invalid. We also had to handle immutable contract revisions, confirmed dependency enforcement, endpoint retirement, transactional outbox delivery, checkpoint-aware replanning, and failures in asynchronous event processing.
Accomplishments that we're proud of
We built a working cross-service compatibility workflow using Billing Service and Orders Service. When Billing Service adds a required token_id field, Code Claim detects the breaking contract revision and creates compatibility work for Orders Service. The Orders coding agent can then read the updated contract, update its Billing client, include the existing TOKEN_ID, run its tests, and submit compatibility evidence. The complete sequence is visible through the dashboard, including contract differences, agent work, compatibility obligations, audit lineage, and transactional events.
What we learned
We learned that agent coordination requires more than a generic task queue. The coordinator must understand contracts, dependencies, checkpoints, revisions, and the reason an agent needs to change its code. We also learned that CockroachDB is useful not only for storing application data, but also for providing transactional state, durable events, changefeeds, and a reliable audit history for agentic workflows.
What's next for Code Claim
The next step is CI/CD integration so services can automatically publish contract revisions during pull requests or deployments. We also plan to add support for more languages and frameworks, stronger human approval workflows, Slack notifications, richer dependency visualization, and hosted multi-team deployments. Our long-term goal is to make Code Claim a harness-neutral compatibility control plane for organizations using multiple AI coding agents across large service architectures.
Built With
- amazon-web-services
- cockroachdb-changefeeds
- cockroachdb-cloud
- fastapi
- mcp
- openapi
- postgresql
- pydantic
- python
Log in or sign up for Devpost to join the conversation.