OpenAI publishes an account of an internal methodology called "harness engineering" applied to agent-first development with Codex. Over five months, a team of three engineers (later expanded to seven) produced an internal beta product containing approximately one million lines of code, with zero lines written manually. Codex agents opened, evaluated, and merged approximately 1,500 pull requests, an average of 3.5 PRs per engineer per day.

The harness is defined as the complete environment of scaffolding, constraints, and feedback loops surrounding an AI agent: repository structure, CI configuration, formatting rules, application frameworks, project instructions, external tool integration, and linters. The first commit into an empty repository was generated by Codex CLI with GPT-5, guided by templates.

The approach rests on three pillars. Context engineering relies on structured documentation within the repository, organized into directories containing system maps, execution plans, and design specifications. Architecture decisions made in Slack must be encoded as versioned artifacts accessible within the repo, since from the agent's point of view, what is not in context does not exist.

Architectural constraints are enforced mechanically through a strict dependency-layer model (Types → Config → Repo → Service → Runtime → UI), custom linters generated by Codex, and ArchUnit-style Tests structurels run in CI. Linter error messages are designed to inject correction instructions directly into the agent's context, turning constraints into active guidance.

Entropy management (garbage collection) consists of recurring Codex tasks that scan the code for deviations from established principles, update quality grades, and open auto-merged refactoring PRs.

The article asserts a fundamental shift in the engineer's role: the engineer no longer codes but designs environments, specifies intent, and builds feedback loops for agents. The greatest challenge identified concerns the design of these environments, feedback loops, and control systems. The bottleneck in agent performance often lies in environment design rather than model intelligence. Martin Fowler described this approach as a "valuable framing" for AI-assisted development.