Coding Agents & Sessions
A coding agent is one of your agents that can work on code: it clones a repository, reads it, makes a change, runs the tests and opens a pull request for you to review. Each piece of work runs as a coding session in a safe, isolated sandbox. You describe the task in plain English, watch the work happen phase by phase, and approve the steps that matter. When the session ends, you get a PR link and a full audit log, and the sandbox is torn down.
Use coding sessions to:
- Fix a bug surfaced by on-call without pulling an engineer off other work
- Implement a small feature from a written spec
- Refactor a function flagged in code review
- Apply a repetitive change across many files (dependency bumps, API renames, lint cleanup)
Coding agents run on the model you choose. Any coding-capable model you hold a key for works, including a model you host yourself.
Make an agent a coding agent
- Connect your git host under Tools → Connections (GitHub, GitLab and others).
- When you create or edit the agent, turn on Coding agent. This gives the agent the coding skill (read, write, edit files and run commands), and the model list then shows only coding-capable models.
- Give the agent access to the repository on the Authorization page (see Agent Authorization). If an agent tries to change a repository it can't write to, you get an approval request and can grant access in one click.
"Give my Platform agent the coding skill." Loyd equips the agent; you still grant it access to the repositories it should work on.
Start a session
From the Coding page
Open Work → Coding and click Start Session:
| Field | What to pick |
|---|---|
| Agent | One of your coding agents |
| Framework | The coding tool that drives the work: Loyd Code, Claude Code, Codex or Gemini CLI |
| Model (optional) | The LLM that drives the session |
| Sandbox Provider | Where the sandbox runs (see Sandbox Providers) |
| Repository | owner/repo, or the repository URL |
| Branch Name / Base Branch | The branch the agent works on and the branch the PR targets |
| Task Description | Plain English: "fix the login redirect bug", "add a --dry-run flag to the CLI" |
| Autonomy Level | Proactive (default), Autonomous or Reactive |
Click Start Session. A session panel opens so you can follow the progress.
From a conversation
When you chat with a coding agent, its toolbar shows a Start session button. It opens the launcher pre-filled with the repository and model selected in the toolbar. This is useful once the agent has helped you scope the work in conversation.
What you see while it runs
The session moves through phases: Provisioning (the sandbox starts), Cloning, coding (the agent reads files, makes changes, runs tests), committing, Pushing, and Creating PR.
Alongside the phases you see:
- A live cost counter showing the LLM spend so far.
- A plan card before the agent starts changing code. Read the plan, then click Approve to let it proceed or Reject to stop it. The same choice appears before a commit or a push when your autonomy level asks for a human decision.
- Approval prompts when the agent wants to do something sensitive, such as running an unfamiliar command. At Proactive, you decide; at Autonomous, the agent proceeds on its own; at Reactive, it waits for you at each step.
- A Stop button at any time. The work in progress is preserved on the branch.
The work runs inside the sandbox, not in your browser. You can close the panel or navigate away and come back later: the agent keeps working, and the progress picks up where it left off. Sessions started by a project or an automation also continue on their own through platform updates, resuming from the last committed work.
Watch several sessions at once: the Workbench
Click Open Workbench at the top of the Coding page to see every live session on a repository in one place:
- Open the live terminal of any session and watch the agent work in a real shell. Terminals come four to a page, sessions waiting for you are listed first, and one terminal can go full screen. Hiding or closing a terminal never stops its shell.
- Take the keyboard and type into a terminal yourself, for example to unblock the agent.
- On a phone, swipe from one session to the next and switch to the session view to read a plan and approve it.
- Use Launch lanes to start several coding agents on the same repository at once, one per framework, and compare their approaches.
- Let the agents coordinate, whatever tool or model each one runs: they see who is working on what, claim the files they are about to change, message each other, hand work over, and take turns to commit and push.
- Read the signed coordination timeline: every handoff between agents, every change to the files an agent has claimed, and every human decision at a plan, commit or push step.
Use your own coding subscription
Under Work → Coding → My subscriptions, you can connect your personal subscription to a coding tool (where that tool supports it; the others show Coming soon). It is used only when you are the live driver of a session. Agents and automations working on your behalf always use your organisation's keys, never your personal subscription. Disconnecting removes the credential immediately.
What you get at the end
- A pull request link: review, comment and merge as usual.
- The full session log: every file read, every command run, every approval decision and the tokens spent.
- A torn-down sandbox: nothing left running, nothing left billing.
If the session fails (tests broken, the task was ambiguous), the log shows where it stopped. Start a follow-up session, or take over from the branch the agent pushed.
Built-in safety
- Isolated sandbox. Each session runs in its own sandbox. File access is confined to the project, sensitive files (such as
.env) are off limits, and destructive commands are blocked. - Restricted network. Sandboxes reach only an allowlist of hosts (your git host and package registries). Inbound connections are always blocked.
- Least privilege. The agent can only push to repositories it has been granted.
- Full audit. Every operation is logged with what was attempted and whether it was allowed.
When the agent first opens a repository, it writes a short project brief (LOYD.md) describing the stack, commands and conventions. If your repository already has a LOYD.md or CLAUDE.md, the agent uses yours.
Governance for admins
Open Work → Coding → Policy to set the rules for every session in your organisation:
| Control | What it does |
|---|---|
| Coding sessions enabled | Turn coding sessions on or off for the organisation |
| Allowed repos | Agents can only work on these repositories (owner/* patterns supported) |
| Allowed models | Only these models may drive sessions, for example self-hosted models only |
| Allowed sandbox providers | Lock sessions to specific providers, for example your own Kubernetes cluster |
| Max cost per session | A hard ceiling on LLM spend per session |
| Require human reviewer before merge | The PR opens as a draft, so a person must review it |
| Agent-initiated repo creation | Whether agents may create new repositories, in which organisations, and how many per day |
Troubleshooting
| Button on the error | What it means | What to do |
|---|---|---|
| Connect GitHub | Your git connection is missing or lacks repository access | Connect GitHub under Tools → Connections and accept repository access |
| Sandbox Providers | No sandbox provider could start the session | Ask your admin to check Coding → Sandbox Providers and Coding → Policy |
| Open Authorization | The agent isn't allowed to access the repository | Grant repository access to the agent on the Authorization page |
If a repository is refused because it is outside your organisation's allowlist, ask your admin to add it under Coding → Policy.
Related
- Sandbox Providers: where sandboxes run, including your own infrastructure
- Agent Authorization: granting repository and tool access
- Human-in-the-Loop: approvals across the platform