Hamdi Bouzidi
AI Systems Architect
Montreal, Canada
AI-Native EngineeringMulti-Agent SystemsSoftware Architecture

Documentation as an Intermediate Representation for AI-Native Software Engineering

A proposed workflow Idea, Conversation, Documentation, Knowledge Compilation, Creation and an honest test of whether it's actually new.

Published Aug 7, 2026 Updated Aug 8, 2026 16 min read hamdibouzidi.com/research-documentation-as-ir.html
Research status
Independent research conducted through software development, experimentation, and literature review. This work has not undergone formal peer review.
Research provenance
This work emerged from observations, hypotheses, and system designs developed during my independent software research and development. Generative AI tools are used as research and writing assistants for literature exploration, critique, synthesis, organization, and editorial refinement. They are not treated as authoritative sources or authors. The hypotheses, technical decisions, claims, and final work remain the responsibility of the author.
On This Page
  1. The missing layer
  2. The proposed pipeline
  3. The compiler analogy
  4. Related work
  5. How it compares
  6. A field that moved fast
  7. Is this actually novel?
  8. Limitations
  9. References

Most descriptions of AI-native software development still reduce to two steps: idea, then prompt, then code. That collapses a layer of thinking that matters, the layer where a person's intent gets worked out in enough detail that it can be executed reliably by something other than the person who had it.

This paper proposes a five-stage workflow, Idea → Conversation → Documentation → Knowledge Compilation → Creation, in which documentation is not the byproduct of building software but an intermediate representation of it: a structured, durable artifact that sits between human reasoning and AI execution, and that gets compiled, not just read.

Monowire, a continuity layer for AI-assisted work discussed elsewhere in this Research section (a Samiel product), is one implementation of this idea. It is not the point of this paper. The point is the workflow itself, checked against what the field has already built.

01The missing layer

Two shorthand descriptions dominate how people talk about building software with AI today: Idea → Prompt → Code, and its slightly more disciplined cousin, Idea → Requirements → Code. Both treat the prompt, or a short requirements note, as the entire interface between what a person wants and what gets built.

That interface is thin. A prompt captures intent at one moment, compressed to fit inside a context window, and mostly discarded once the code exists. It rarely survives the next session, the next contributor, or the next six months.

The claim of this paper is narrow: there is a cognitive layer that today lives briefly inside a chat window and then evaporates, and that layer deserves to be treated as a durable, structured artifact, because it is the thing future agents and future humans actually need to pick the work back up correctly.

02The proposed pipeline

The workflow has five stages. An idea starts as loosely as it always has. A conversation works that idea into shape. That conversation is captured as documentation, organized by domain. Once enough of that documentation exists and holds together, a distinct compilation step reads across all of it and produces deterministic, execution-ready artifacts. Only then does creation happen, driven by those compiled artifacts rather than by the original conversation.

Diagram: the five-stage proposed pipeline Idea flows into Conversation, which flows into Documentation organized by department, which flows into a Knowledge Compilation step, which produces Creation. Idea Conversation Documentation Product · Systems Backend · UX · Infra Knowledge Compilation reads everything, writes nothing new Creation builder agents execute DOCUMENTATION IS WRITTEN CONTINUOUSLY · COMPILATION HAPPENS ON DEMAND
Fig. 1 The proposed pipeline. Documentation is the durable layer; knowledge compilation is a distinct, repeatable step.

The compilation step is the part that actually does work. In the implementation this paper draws on, a single role, referred to internally as Coach, performs it: it reads the accumulated documentation across every domain and produces deterministic, department-scoped skill files that downstream builder agents execute against. Its job is synthesis, not authorship.

03The compiler analogy

The analogy to a traditional compiler pipeline is direct enough to be useful, and precise enough to be worth stating carefully.

Diagram: compiler pipeline compared to the proposed engineering workflow Traditional compilation moves from source code through an intermediate representation to machine code. The proposed workflow moves from founder conversation through organizational documentation and a knowledge compilation step to executable agent skills, which builder agents then run. TRADITIONAL COMPILATION Source (C++) LLVM IR MachineCode PROPOSED WORKFLOW Conversation Org. Documentation Knowledge Compiler Agent Skill Files Builder Agents
Fig. 2 Organizational documentation occupies the same structural position LLVM IR occupies in a traditional compiler: a stable, inspectable middle layer that decouples the front end from the back end.

The analogy is not original to this paper, section four covers that directly. What this paper adds is specificity about what plays the role of the front end, the IR, and the back end in an organizational rather than a single-file context, and an argument that the IR should be long-lived organizational memory rather than a spec authored once per feature and discarded.

None of the individual pieces of this workflow are new. What follows is a direct accounting of the closest prior work.

Multi-agent frameworks that encode process as documents

MetaGPT (Hong et al., 2023) is the closest and earliest prior art. It assigns software-engineering roles to distinct LLM agents and encodes Standardized Operating Procedures into their prompts, requiring each role to produce structured intermediate artifacts before code is generated. ChatDev (Qian et al., 2023) takes a similar premise, structured as a "chat chain" rather than SOPs.

Agile-flavored planning agents

BMAD-METHOD runs an agentic planning phase that produces PRDs and architecture documents as versioned, living artifacts, then a distinct "sharding" step breaks those documents into focused, execution-ready story files. That shard step is functionally close to the knowledge-compilation stage proposed here.

Spec-driven development

By 2026, a "spec-driven development" movement, GitHub's Spec Kit, AWS's Kiro, OpenSpec, Tessl, treats a written specification as the source of truth, with implementation generated from and validated against it. This is the same core inversion this paper argues for.

The compiler and IR analogy, stated explicitly elsewhere

The comparison between agent planning artifacts and compiler intermediate representations has already been drawn explicitly and independently of this paper. Commentary on emerging "deterministic agent runtimes" in mid-2026 describes agents as functioning like a compiler front end. Separately, an open-source project offers a language-agnostic textual intermediate representation specifically designed for LLM agents to target instead of generating code directly.

Anthropic's reusable skill format

The specific compilation target this paper's implementation uses is Anthropic's Agent Skills, a folder-based, filesystem-native format with staged, on-demand loading. That framing, reusable organizational knowledge as a discrete, loadable artifact, is close to how this paper treats compiled department skill files.

Formal process and governance specification

A 2026 formal-methods paper proposes a domain-specific protocol language for specifying human-agent responsibility boundaries, explicitly critiquing MetaGPT and similar frameworks for encoding process only inside agent prompts, which drift. That critique applies with equal force to this proposal.

05How it compares

Laid out side by side, the honest picture is one of convergent evolution, not one lineage with a single missing piece.

ApproachUnit of workCompilation targetStatus
MetaGPT (2023)Single feature / taskCode, via structured role promptsEstablished
BMAD-METHODFeature or epicSharded story files → codeEstablished
Spec-Driven Dev. (Kiro, Spec Kit)FeatureCode + generated testsEstablished
Anthropic Agent SkillsReusable capabilityN/A skills are the targetEstablished
This proposalThe organization, continuouslySkill files, not code directlyPartial synthesis

Two differences hold up under that comparison. First, the unit of work: existing frameworks scope documentation to a feature that is largely retired once it ships; this proposal scopes it to the organization as a standing structure. Second, the compilation target: rather than compiling into code or tests directly, this proposal compiles into a reusable-capability format that downstream agents load on demand.

06A field that moved fast

Worth seeing plainly: almost every element of this proposal was independently arrived at by others within a roughly three-year window.

Aug 2023
MetaGPT
Standardized Operating Procedures encoded into role-based agent prompts.
2024
BMAD-METHOD
Living planning docs plus a distinct "shard" step into execution-ready story files.
Late 2025
Anthropic Agent Skills
Open, filesystem-native format for reusable, on-demand agent capabilities.
2025–2026
Spec-driven development goes mainstream
GitHub Spec Kit and AWS Kiro popularize specs as the source of truth.
Mid 2026
The compiler analogy made explicit
Independent commentary and open-source projects describe agent artifacts as compiler IR.
Fig. 3 A rough timeline of the closest prior work. This proposal sits at the end of this sequence, not before it.
Key finding

The general paradigm is not novel. A narrower synthesis is.

Treating structured documentation as the real interface between human intent and AI execution, and compiling it into something downstream agents run against, is well-established by 2026, visible independently in MetaGPT's SOPs, BMAD's shard step, and the spec-driven-development ecosystem. The compiler/IR framing has also already been stated explicitly elsewhere.

What is not already established is the combination of (1) scoping the source documentation to a persistent, department-organized organization rather than a per-feature spec, and (2) compiling that memory specifically into a reusable agent-skill format rather than into code, tests, or a task DAG. That combination is a legitimate, modest contribution: a specific point in an existing design space, not a new paradigm.

07Limitations

A note on why the "Coach" role exists at all

A natural objection: if department agents already produce good documentation, why add a separate compilation role instead of letting builder agents read it directly?

The reason is the same reason compilers exist instead of interpreters reading source directly for every execution: repeated, ad-hoc interpretation of a large, evolving document set is slow and inconsistent between runs. A dedicated compilation step does that synthesis once and produces a stable artifact.

The compiler analogy is correct. It just isn't new, and neither is most of the pipeline it describes. What's left after checking is smaller, and more honest, than the pitch.

08References

  1. Hong, S. et al. "MetaGPT: Meta Programming for a Multi-Agent Collaborative Framework." arXiv:2308.00352, 2023.Standardized Operating Procedures encoded into role-based agent prompts; the closest and earliest prior art to this paper's pipeline.
  2. Prifti, Y. "Specifying AI-SDLC Processes: A Protocol Language for Human-Agent Boundaries." arXiv:2606.20615, 2026.Formal critique of prompt-encoded process as subject to drift; motivates this paper's limitations section.
  3. BMAD-METHOD: Breakthrough Method for Agile AI-Driven Development. GitHub, bmad-code-org.Agentic planning + document-sharding pipeline; the closest analog to the proposed knowledge-compilation step.
  4. GitHub Spec Kit open-source spec-driven development toolkit.Specification treated as source of truth; part of the broader spec-driven development movement.
  5. Anthropic. "Agent Skills" Claude Platform Docs.The reusable, filesystem-native compilation-target format referenced throughout this paper.
  6. "Spec: A language-agnostic Intermediate Representation for autonomous agent-driven software development." GitHub, mronus.Independent project drawing the same compiler/IR analogy explicitly.
  7. "Agentic AI in the Software Development Lifecycle." arXiv:2604.26275, 2026.Survey covering MetaGPT, ChatDev, AgileCoder, and the broader agentic-SWE literature.

How to cite this work

Bouzidi, H. (2026). Documentation as an Intermediate Representation for AI-Native Software Engineering. HB Research.
https://hamdibouzidi.com/research-documentation-as-ir.html