← All decisions jacob@stephens.page
Decision Record

A scoped system user over a shared service account for an autonomous agent

ADR 0005 · Accepted ยท in production · ~262 words

Context

An autonomous coding agent runs on a coordination host and acts across several internal servers - reading databases, running deploys, inspecting services. It needs credentials, but handing it broad, shared credentials (or letting each engineer's own credentials flow through it) muddies two things at once: authority (what is the agent allowed to do?) and attribution (who did a given action - the agent, or the human who launched it?).

Decision

Run the agent as its own dedicated, least-privilege system user, distinct from any human:

Consequences

When I'd revisit

If the agent only ever ran read-only against a single system, a narrowly-scoped service account would be enough and simpler. The scoped-system-user model earns its keep precisely because the agent's reach is broad and includes writes.

Narrative writeup: Sandboxing AI Agents per Business Role. One of a set of architecture decision records. Source markdown lives in the infrastructure-patterns repo, which is the canonical copy.