Konrad Kowalski (rootsher)Principal Platform & Reliability Architect111011000100011001001110011101110011101011110000

Agent repo and workspace

date
category
AI Agents
also in
Infrastructure · Engineering Practices
reading
1 min / 293 words

In a local environment a lot of things were invisible because they already existed.

The developer had:

text
repo cloned
git configured
SDK installed
dependencies installed
credentials working

A managed Implementer Agent does not get any of that automatically.

Someone has to describe how to prepare its working environment.

Agent repo

The simplest layout:

text
engineering-agents/
└── implementer/
    ├── agent.py
    ├── workflow.py
    ├── workspace.py
    ├── tools.py
    └── evals/

This repo defines the Implementer Agent role.

For example:

text
1. receive the task
2. fetch the ticket
3. prepare the workspace
4. clone repo
5. checkout branch
6. read the repo instructions
7. implement
8. test
9. push
10. open a PR

How the agent knows the repo

Better not to guess.

The Jira payload can contain:

json
{
  "issueKey": "PAY-123",
  "repository": "org/payments-service",
  "baseBranch": "main"
}

or repository can be a field on the ticket.

Workspace

The agent repo does roughly this:

text
create workspace
|
v
git clone org/payments-service
|
v
checkout main
|
v
create branch agent/PAY-123
|
v
run project setup

Product repo

After the clone the agent finds:

text
payments-service/
├── AGENTS.md
├── src/
├── tests/
└── docs/

And here comes an important split:

text
agent repo
-> how to carry out the task

product repo
-> how to work on this particular code

AGENTS.md can say:

text
- setup: ./scripts/setup.sh
- test: ./scripts/test.sh
- do not modify generated/
- ADRs live in docs/adr/

Where credentials live

Not in the agent repo and not in the product repo.

GitHub access should be provided by the platform:

text
Agent identity
|
v
GitHub App / OAuth / managed secret
|
v
GitHub

Tools and runtimes

OptionCloudRole
Foundry Hosted AgentsAzureruns your own agent code as a managed workload
Bedrock AgentCore RuntimeAWSmanaged runtime for your own agents
Vertex AI Agent EngineGCPmanaged deployment and runtime for agents
Kubernetes / container runtimeanyfull control, but more platform work

What the organization standardizes

At a larger scale it is worth providing:

  • an agent repo template,
  • a standard workspace path,
  • a shared way to clone/checkout,
  • a standard branch naming scheme,
  • ready-made GitHub access,
  • standard runtime images with the required SDKs.

Then no team has to invent the bootstrap from scratch.

Materials

top