Summary
Assimilate Aider into the Ouroboros plugin ecosystem as a first-class AgentOS capability while preserving the Aider user experience as much as possible.
This epic extends the intent of #27: plugins are not merely command wrappers. They are the capability-assimilation layer that turns external tools and open-source workflows into permissioned, auditable, Seed-compatible, handoff-capable Ouroboros capabilities.
Aider is a strong candidate because it already behaves like an AI pair-programmer in the terminal:
- repo-grounded coding assistance,
- file selection and read-only context,
- code editing,
- architect / ask / code modes,
- repo map context,
- git integration,
- lint/test repair loops,
- model-provider configuration,
- optional web / browser / voice / GUI features,
- and a mature CLI-centered workflow.
The goal is not to hide Aider behind a thin subprocess("aider") wrapper. The goal is to let Ouroboros run Aider smoothly as an AgentOS-native capability while preserving the feel of using Aider directly.
Preserve Aider's user experience; assimilate Aider's authority, side effects, evidence, and lifecycle into Ouroboros.
AgentOS Thesis
Ouroboros should be able to execute powerful external agent tools without dissolving its OS boundary.
For Aider, the desired flow is:
Aider UX / command semantics / repo editing workflow
↓
Ouroboros plugin firewall and manifest contract
↓
permissions + capabilities + trust + audit
↓
Seed / Ledger / State / Provenance / Handoff artifacts
↓
Ouroboros AgentOS execution surface
This should make Aider feel native inside Ouroboros while keeping the external capability bounded, inspectable, resumable, and auditable.
In other words:
- Aider should remain recognizably Aider.
- Ouroboros should remain recognizably Ouroboros.
- The integration point is the plugin contract, not unbounded shell execution.
Why Aider Is a Good Capability-Assimilation Case
Aider is not a narrow SDK. It is a broad coding-agent surface with real authority over the local development environment.
Based on the Aider repository and docs:
- The Python package exposes the
aider CLI via aider.main:main.
- It supports Python
>=3.10,<3.15.
- It has a rich CLI configuration surface for models, providers, files, repo map, git behavior, lint/test behavior, terminal UX, and one-shot messages.
- It includes slash-command semantics such as ask/code/architect/context, commit, diff, lint, test, run, add/drop/read-only files, map, settings, load/save, editor, etc.
- It uses repo maps to provide codebase-wide context.
- It can edit files, run tests, run commands, commit changes, and interact with model-provider APIs.
That makes it an ideal reference for the hard case this repository must eventually support:
external AI coding agent
+ local filesystem authority
+ shell authority
+ network/model-provider authority
+ git authority
+ long-running user workflow
+ UX users already know
→ Ouroboros-native capability
If Ouroboros can assimilate Aider cleanly, it proves the plugin layer can handle serious real-world agent tools rather than only narrow API integrations.
Non-Goals
This epic should avoid the following outcomes:
- Do not add a bare manifest whose entrypoint is only
aider with no policy, evidence, or handoff semantics.
- Do not treat this repository as a marketplace for Aider plugins.
- Do not fork Aider unless there is no viable adapter path.
- Do not depend on Aider internals as the first implementation strategy if the public CLI can satisfy the contract.
- Do not give Aider blanket destructive authority by default.
- Do not make
ooo auto absorb Aider-specific branches.
- Do not require users to abandon familiar Aider workflows to use the integration.
- Do not store API keys, provider secrets, or raw sensitive environment values in audit artifacts.
Desired User Experience
The integration should preserve Aider's usage model while making Ouroboros the surrounding OS.
1. CLI-first experience
Users should be able to invoke Aider-like workflows through Ouroboros commands:
ooo aider ask --message "Explain how this module works" --file src/foo.py
ooo aider edit --message "Refactor this parser without changing behavior" --file src/parser.py --test-cmd "pytest tests/test_parser.py"
ooo aider architect --message "Design the migration path for this subsystem" --file src/service.py --read docs/architecture.md
ooo aider fix --test-cmd "pytest tests/test_regression.py" --file src/foo.py
These commands should feel close to Aider's own mental model:
- add files to context,
- mark read-only files,
- send a message,
- optionally run lint/test,
- inspect edits/diffs,
- continue from a generated handoff.
2. Familiar Aider concepts should remain visible
The plugin should preserve or translate these concepts:
- main model,
- weak model,
- editor model,
- reasoning effort / thinking-token style knobs where supported,
- edit format / architect mode,
- files to edit,
- read-only context files,
- repo map settings,
- lint command,
- test command,
- auto-lint / auto-test behavior,
- git commit behavior,
- chat/message mode,
- config/env behavior,
- model-provider API settings.
Where exact parity is unsafe or impractical, the plugin should document the difference and prefer a bounded AgentOS-native substitute.
3. Interactive experience should be preserved carefully
Aider's interactive terminal session is a major part of the product experience. The plugin should eventually support it, but not at the cost of bypassing the Ouroboros firewall.
Suggested staged target:
- v0: one-shot, bounded commands with structured handoff artifacts.
- v1: resumable session metadata and continuation commands.
- v2: controlled interactive passthrough mode with explicit trust boundary, transcript capture, and post-session diff/handoff emission.
Interactive support should be treated as an AgentOS session, not as an opaque subprocess.
Proposed Plugin Package
Suggested name:
Suggested command namespace:
Suggested package layout:
plugins/aider-assist/
ouroboros.plugin.json
README.md
aider_assist/
__main__.py
cli.py
runner.py
policy.py
git_state.py
artifacts.py
handoff.py
audit.py
config.py
tests/
The adapter should initially call the Aider CLI as a subprocess rather than importing unstable internal modules. Importing Aider internals can be evaluated later if the CLI cannot provide enough control.
Proposed Command Surface
ooo aider ask
Read-only repo-grounded question answering.
Example:
ooo aider ask --message "What owns retry behavior?" --file src/client.py --read docs/networking.md
Expected behavior:
- Invoke Aider in a no-edit path.
- Pass selected files/read-only context.
- Capture answer as an artifact.
- Emit provenance with Aider version, model settings, repo ref, and selected context.
- Require no filesystem write except Ouroboros artifact/state writes.
Risk:
Primary value:
- Proves Aider can be assimilated as an analysis capability before write authority is granted.
ooo aider edit
Bounded editing task.
Example:
ooo aider edit \
--message "Simplify this function without changing behavior" \
--file src/parser.py \
--test-cmd "pytest tests/test_parser.py"
Expected behavior:
- Require at least one explicit editable file unless a future policy allows broader scope.
- Capture pre-run git state.
- Invoke Aider with bounded file arguments.
- Prefer
--no-auto-commits by default so Ouroboros owns provenance.
- Capture post-run git state and diff.
- Capture touched files.
- Run optional verification command.
- Emit handoff artifact summarizing edits, evidence, tests, and next steps.
Risk:
Primary value:
- Proves Aider can perform real edits while Ouroboros retains audit, provenance, and continuation semantics.
ooo aider architect
Architecture/planning mode with optional implementation handoff.
Example:
ooo aider architect \
--message "Design a migration from this adapter to the new plugin contract" \
--file src/plugin_loader.py \
--read docs/contract.md
Expected behavior:
- Preserve Aider's architect-style workflow as much as possible.
- Produce an architecture or change-plan artifact.
- Optionally hand off to
ooo aider edit or a later ooo auto flow.
- Avoid uncontrolled edits unless explicitly enabled.
Risk:
read_only or write depending on selected mode
Primary value:
- Preserves one of Aider's key UX modes while allowing Ouroboros to decide whether planning and editing are separate lifecycle phases.
ooo aider fix
Test/lint repair loop.
Example:
ooo aider fix \
--test-cmd "pytest tests/test_regression.py" \
--file src/foo.py
Expected behavior:
- Capture failing command and output.
- Invoke Aider with the failure context.
- Apply bounded edits.
- Re-run the verification command.
- Emit structured success/failure/blocked artifact.
Risk:
Primary value:
- Connects Aider's repair loop to Ouroboros verification evidence.
Deferred: ooo aider session
Controlled interactive session mode.
Example target UX:
ooo aider session --file src/foo.py --read docs/spec.md
This should eventually preserve the direct Aider experience, but it must not bypass AgentOS requirements.
Minimum requirements before enabling:
- explicit trust boundary,
- transcript capture or summary artifact,
- pre/post git state capture,
- touched-file detection,
- final diff artifact,
- permission-use events,
- clear blocked/failed/completed status,
- no secret leakage in artifacts.
Risk:
Potentially destructive if shell/git behaviors are enabled broadly.
Draft Manifest Direction
A first implementation can start with a conservative manifest similar to:
{
"schema_version": "0.1",
"name": "aider-assist",
"version": "0.1.0",
"description": "Assimilates Aider as a bounded, auditable AI pair-programming capability for Ouroboros AgentOS.",
"source": {
"type": "local_path",
"path": "plugins/aider-assist"
},
"commands": [
{
"namespace": "aider",
"name": "ask",
"summary": "Ask Aider about the repository without editing files.",
"usage": "ooo aider ask --message <question> [--file path...] [--read path...]",
"risk": "read_only",
"requires_confirmation": false
},
{
"namespace": "aider",
"name": "edit",
"summary": "Run a bounded Aider edit task and emit diff, verification, and handoff evidence.",
"usage": "ooo aider edit --message <goal> --file path... [--test-cmd cmd]",
"risk": "write",
"requires_confirmation": true
},
{
"namespace": "aider",
"name": "architect",
"summary": "Use Aider architect mode to produce a plan or bounded implementation handoff.",
"usage": "ooo aider architect --message <goal> [--file path...] [--read path...]",
"risk": "read_only",
"requires_confirmation": false
},
{
"namespace": "aider",
"name": "fix",
"summary": "Use Aider to repair a failing lint/test command within bounded files.",
"usage": "ooo aider fix --test-cmd <cmd> --file path...",
"risk": "write",
"requires_confirmation": true
}
],
"capabilities": [
{
"name": "ledger",
"access": "write",
"reason": "Record task inputs, selected context, diffs, verification, and decisions."
},
{
"name": "provenance",
"access": "write",
"reason": "Record Aider version, invocation arguments, model settings, repo ref, and produced artifacts."
},
{
"name": "state",
"access": "write",
"reason": "Persist Aider run/session status for resumable workflows."
},
{
"name": "handoff",
"access": "attach",
"reason": "Attach answer, diff, touched files, test output, and next-step guidance."
},
{
"name": "progress",
"access": "write",
"reason": "Report long-running coding-agent progress."
}
],
"permissions": [
{
"scope": "filesystem:read",
"risk": "read_only",
"required": true,
"reason": "Read selected repository files and context."
},
{
"scope": "filesystem:write",
"risk": "write",
"required": false,
"reason": "Apply bounded code edits for write-capable commands."
},
{
"scope": "shell:execute",
"risk": "write",
"required": true,
"reason": "Invoke the Aider CLI and optional verification commands."
},
{
"scope": "network:write",
"risk": "write",
"required": true,
"reason": "Call configured model-provider APIs through Aider."
}
],
"entrypoint": {
"type": "command",
"command": "python -m aider_assist"
}
}
This is intentionally a starting point. Implementation may need additional argument metadata as the manifest schema evolves.
Permission and Trust Requirements
Aider has broad potential authority. The plugin must make that authority explicit.
Required or likely permissions
| Permission |
Risk |
Notes |
filesystem:read |
read_only |
Needed for repo context and selected files. |
filesystem:write |
write |
Needed for edit/fix/session modes. Should not be required for ask-only usage. |
shell:execute |
write |
Needed to invoke Aider and run lint/test commands. Needs careful policy. |
network:write |
write |
Needed for model-provider API calls. |
network:read |
read_only |
Needed only if web/URL scraping modes are enabled. |
github:read / other VCS-host permissions |
read_only or write |
Only if future integration directly reads/writes GitHub metadata. |
Trust policy
ask should be available with read-only file context plus model-provider network permission.
edit and fix should require explicit write trust.
- Commands that run arbitrary user-supplied shell commands should require confirmation and strong audit capture.
- Auto-commit should be disabled by default until commit provenance policy is explicitly designed.
- Destructive shell or git operations should not be enabled implicitly.
Artifact and Handoff Contract
Each invocation should produce an Ouroboros-readable artifact.
Suggested artifact location pattern:
.omx/artifacts/plugins/aider-assist/<run-id>/
invocation.json
stdout.txt
stderr.txt
answer.md
diff.patch
touched-files.txt
verification.json
handoff.md
Suggested handoff contents:
# Aider Assist Handoff
## Command
## User Goal
## Repo State Before
## Repo State After
## Selected Editable Files
## Selected Read-only Context
## Aider Version
## Model / Provider Metadata
## Permissions Used
## Summary of Result
## Diff Summary
## Verification
## Known Gaps
## Recommended Next Step
The handoff should be consumable by:
- a human developer,
ooo auto,
- a future workflow harness,
- or a plugin verification command.
Implementation Plan
Phase 0: RFC / design lock
Phase 1: Read-only POC
Phase 2: Bounded write mode
Phase 3: Verification integration
Phase 4: Architect mode
Phase 5: Session parity
UX Parity Checklist
This epic should be considered successful only if the integration preserves the core Aider experience in an Ouroboros-safe way.
Safety and Policy Checklist
Acceptance Criteria
This epic is complete when:
Open Questions
- Should
aider-assist live in this repository as a reference plugin, or should this repo host only the contract/RFC while the implementation lives in a dedicated third-party plugin repository?
- Should v0 require
aider to already be installed on PATH, use uvx aider-chat, or vendor a Python dependency path?
- How should Ouroboros expose Aider model/provider configuration while preserving secret hygiene?
- Should architect mode be read-only by default, or should it mirror Aider's native architect edit flow more closely?
- What is the minimum acceptable transcript capture for future interactive session mode?
- Should Aider's auto-commit feature remain disabled by default so Ouroboros owns provenance?
- How much of Aider's slash-command surface should be allowed in controlled session mode?
References
Summary
Assimilate Aider into the Ouroboros plugin ecosystem as a first-class AgentOS capability while preserving the Aider user experience as much as possible.
This epic extends the intent of #27: plugins are not merely command wrappers. They are the capability-assimilation layer that turns external tools and open-source workflows into permissioned, auditable, Seed-compatible, handoff-capable Ouroboros capabilities.
Aider is a strong candidate because it already behaves like an AI pair-programmer in the terminal:
The goal is not to hide Aider behind a thin
subprocess("aider")wrapper. The goal is to let Ouroboros run Aider smoothly as an AgentOS-native capability while preserving the feel of using Aider directly.AgentOS Thesis
Ouroboros should be able to execute powerful external agent tools without dissolving its OS boundary.
For Aider, the desired flow is:
This should make Aider feel native inside Ouroboros while keeping the external capability bounded, inspectable, resumable, and auditable.
In other words:
Why Aider Is a Good Capability-Assimilation Case
Aider is not a narrow SDK. It is a broad coding-agent surface with real authority over the local development environment.
Based on the Aider repository and docs:
aiderCLI viaaider.main:main.>=3.10,<3.15.That makes it an ideal reference for the hard case this repository must eventually support:
If Ouroboros can assimilate Aider cleanly, it proves the plugin layer can handle serious real-world agent tools rather than only narrow API integrations.
Non-Goals
This epic should avoid the following outcomes:
aiderwith no policy, evidence, or handoff semantics.ooo autoabsorb Aider-specific branches.Desired User Experience
The integration should preserve Aider's usage model while making Ouroboros the surrounding OS.
1. CLI-first experience
Users should be able to invoke Aider-like workflows through Ouroboros commands:
These commands should feel close to Aider's own mental model:
2. Familiar Aider concepts should remain visible
The plugin should preserve or translate these concepts:
Where exact parity is unsafe or impractical, the plugin should document the difference and prefer a bounded AgentOS-native substitute.
3. Interactive experience should be preserved carefully
Aider's interactive terminal session is a major part of the product experience. The plugin should eventually support it, but not at the cost of bypassing the Ouroboros firewall.
Suggested staged target:
Interactive support should be treated as an AgentOS session, not as an opaque subprocess.
Proposed Plugin Package
Suggested name:
Suggested command namespace:
Suggested package layout:
The adapter should initially call the Aider CLI as a subprocess rather than importing unstable internal modules. Importing Aider internals can be evaluated later if the CLI cannot provide enough control.
Proposed Command Surface
ooo aider askRead-only repo-grounded question answering.
Example:
ooo aider ask --message "What owns retry behavior?" --file src/client.py --read docs/networking.mdExpected behavior:
Risk:
Primary value:
ooo aider editBounded editing task.
Example:
Expected behavior:
--no-auto-commitsby default so Ouroboros owns provenance.Risk:
Primary value:
ooo aider architectArchitecture/planning mode with optional implementation handoff.
Example:
ooo aider architect \ --message "Design a migration from this adapter to the new plugin contract" \ --file src/plugin_loader.py \ --read docs/contract.mdExpected behavior:
ooo aider editor a laterooo autoflow.Risk:
Primary value:
ooo aider fixTest/lint repair loop.
Example:
ooo aider fix \ --test-cmd "pytest tests/test_regression.py" \ --file src/foo.pyExpected behavior:
Risk:
Primary value:
Deferred:
ooo aider sessionControlled interactive session mode.
Example target UX:
This should eventually preserve the direct Aider experience, but it must not bypass AgentOS requirements.
Minimum requirements before enabling:
Risk:
Potentially destructive if shell/git behaviors are enabled broadly.
Draft Manifest Direction
A first implementation can start with a conservative manifest similar to:
{ "schema_version": "0.1", "name": "aider-assist", "version": "0.1.0", "description": "Assimilates Aider as a bounded, auditable AI pair-programming capability for Ouroboros AgentOS.", "source": { "type": "local_path", "path": "plugins/aider-assist" }, "commands": [ { "namespace": "aider", "name": "ask", "summary": "Ask Aider about the repository without editing files.", "usage": "ooo aider ask --message <question> [--file path...] [--read path...]", "risk": "read_only", "requires_confirmation": false }, { "namespace": "aider", "name": "edit", "summary": "Run a bounded Aider edit task and emit diff, verification, and handoff evidence.", "usage": "ooo aider edit --message <goal> --file path... [--test-cmd cmd]", "risk": "write", "requires_confirmation": true }, { "namespace": "aider", "name": "architect", "summary": "Use Aider architect mode to produce a plan or bounded implementation handoff.", "usage": "ooo aider architect --message <goal> [--file path...] [--read path...]", "risk": "read_only", "requires_confirmation": false }, { "namespace": "aider", "name": "fix", "summary": "Use Aider to repair a failing lint/test command within bounded files.", "usage": "ooo aider fix --test-cmd <cmd> --file path...", "risk": "write", "requires_confirmation": true } ], "capabilities": [ { "name": "ledger", "access": "write", "reason": "Record task inputs, selected context, diffs, verification, and decisions." }, { "name": "provenance", "access": "write", "reason": "Record Aider version, invocation arguments, model settings, repo ref, and produced artifacts." }, { "name": "state", "access": "write", "reason": "Persist Aider run/session status for resumable workflows." }, { "name": "handoff", "access": "attach", "reason": "Attach answer, diff, touched files, test output, and next-step guidance." }, { "name": "progress", "access": "write", "reason": "Report long-running coding-agent progress." } ], "permissions": [ { "scope": "filesystem:read", "risk": "read_only", "required": true, "reason": "Read selected repository files and context." }, { "scope": "filesystem:write", "risk": "write", "required": false, "reason": "Apply bounded code edits for write-capable commands." }, { "scope": "shell:execute", "risk": "write", "required": true, "reason": "Invoke the Aider CLI and optional verification commands." }, { "scope": "network:write", "risk": "write", "required": true, "reason": "Call configured model-provider APIs through Aider." } ], "entrypoint": { "type": "command", "command": "python -m aider_assist" } }This is intentionally a starting point. Implementation may need additional argument metadata as the manifest schema evolves.
Permission and Trust Requirements
Aider has broad potential authority. The plugin must make that authority explicit.
Required or likely permissions
filesystem:readread_onlyfilesystem:writewriteshell:executewritenetwork:writewritenetwork:readread_onlygithub:read/ other VCS-host permissionsread_onlyorwriteTrust policy
askshould be available with read-only file context plus model-provider network permission.editandfixshould require explicit write trust.Artifact and Handoff Contract
Each invocation should produce an Ouroboros-readable artifact.
Suggested artifact location pattern:
Suggested handoff contents:
The handoff should be consumable by:
ooo auto,Implementation Plan
Phase 0: RFC / design lock
aider-assistbelongs in this repository as a reference plugin or in a separate experimental plugin repository.aideron PATH vs Python dependency vsuvx aider-chat.Phase 1: Read-only POC
plugins/aider-assist/ouroboros.plugin.jsonwithaskonly orask+ future command declarations.python -m aider_assist ask.--message,--file, and--readarguments.scripts/validate_contract.py.Phase 2: Bounded write mode
editwith explicit--fileallowlist.--message.Phase 3: Verification integration
--test-cmdand/or--lint-cmdsupport.Phase 4: Architect mode
Phase 5: Session parity
UX Parity Checklist
This epic should be considered successful only if the integration preserves the core Aider experience in an Ouroboros-safe way.
Safety and Policy Checklist
Acceptance Criteria
This epic is complete when:
aider-assistplugin manifest exists or a separate plugin repository is linked.--test-cmdor--lint-cmdis supplied.Open Questions
aider-assistlive in this repository as a reference plugin, or should this repo host only the contract/RFC while the implementation lives in a dedicated third-party plugin repository?aiderto already be installed on PATH, useuvx aider-chat, or vendor a Python dependency path?References
docs/contract.mddocs/lifecycle.mddocs/permissions.mddocs/audit.md