Skip to content

docs: agent-config-editing design workspace (stack bottom) - #5733

Merged
mmabrouk merged 40 commits into
release/v0.110.0from
agent-config-editing-plan
Aug 7, 2026
Merged

docs: agent-config-editing design workspace (stack bottom)#5733
mmabrouk merged 40 commits into
release/v0.110.0from
agent-config-editing-plan

Conversation

@mmabrouk

@mmabrouk mmabrouk commented Aug 4, 2026

Copy link
Copy Markdown
Member

Context

This is the bottom PR of the agent-config-editing stack. The feature: a playground agent can read and edit its own stored configuration through targeted operations, with human approval gating anything that imports content from its workspace. This PR carries no product code. It holds the design workspace the other seventeen PRs implement, so reviewers can read intent before diffs, and inline-comment on decisions rather than on code.

What is in here

  • BRIEFING.md: the reviewer document. Start here. Written in simple technical English; every decision carries its context.
  • decisions.md: every product and engineering ruling with its rationale, including the rotation ruling and the scope-enforcement seam.
  • contracts/: the six behavior contracts (change-set, commit-transaction, read-config, workspace-import, execution-authorization, adapter-matrix), synced to shipped behavior after the final review round.
  • plan.md, status.md, open-issues.md: execution plan, final state, and the recorded follow-ups.
  • spikes/: the three spike reports (engine, runner, model usability) with their raw data and the reusable instruction-testing harness.
  • notes/: the dao-lock impact analysis and the final external review findings, verbatim.

Reading order for the stack

Bottom up: s5, s4 (runner safety, description field), s1a, s6, s1b-lock, s1b (engine, coordinator, lock, commit wrapper), s7a, s2 (lifecycle units, read_config and commit hardening), s7b, s3a, s7c (context acquisition, imports, facets), s3b-core, s7d, s7e (authorization core, reopen, credentials), then the three wiring PRs (runner, SDK, web). Each PR's base is the lane below it, so each shows only its own diff.

Notes

  • Everything ships behind AGENTA_WORKFLOWS_ORDERED_OPERATIONS_ENABLED; the flag off keeps today's behavior and the legacy delta form keeps working in both states.
  • The final external review (BLOCK verdict, then fixed) and the fix round are summarized in status.md; findings verbatim in notes/final-review-findings.md.
  • The stack targets release/v0.109.0, never main.

Planning docs (context, plan, status, research index) plus the accepted
research inputs: the RFC, the change-set interface spec, and the runner
lifecycle architecture.
@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agenta-documentation Ready Ready Preview Aug 6, 2026 5:13pm

Request Review

@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • Documentation
    • Added comprehensive design documentation for agent configuration editing.
    • Documented targeted, atomic configuration changes, revision conflict handling, partial reads, workspace file imports, validation, and security safeguards.
    • Added runner lifecycle, harness reconciliation, execution authorization, and commit transaction contracts.
    • Included research findings, usability experiments, implementation plans, decisions, open issues, and review status.
    • Added prototype tools and self-tests supporting configuration-editing workflows.

Walkthrough

This PR adds a complete design workspace for agent configuration editing. It documents editing contracts, revision transactions, reads, workspace imports, authorization, runner lifecycle reconciliation, model-usability spikes, design reviews, rollout planning, and project status.

Changes

Agent configuration editing

Layer / File(s) Summary
Design foundation
docs/design/agent-config-editing/README.md, context.md, research/rfc.html, research.md
Defines project scope, terminology, requirements, research findings, user stories, and design alternatives.
Editing and persistence contracts
docs/design/agent-config-editing/contracts/*, research/change-set-interface-codex.md, decisions.md
Defines ordered change sets, atomic revision commits, configuration reads, workspace imports, execution authorization, validation, conflicts, and scope rules.
Runner reconciliation and harness capabilities
docs/design/agent-config-editing/research/runner-lifecycle-codex.md, contracts/adapter-matrix.md, spikes/runner-spike.md
Defines desired/applied state, lifecycle adapters, generation acknowledgements, provider-specific behavior, session handling, and workspace reconciliation.
Engine and model evaluation spikes
docs/design/agent-config-editing/spikes/engine-spike.md, spikes/model-usability/*
Adds the simulated editing harness, ordered-operation engine specification, model trial runner, task suite, self-tests, and result reports.
Reviews and delivery planning
docs/design/agent-config-editing/BRIEFING.md, plan.md, status.md, notes/*, open-issues.md, research/design-gate*-codex.md
Records implementation slices, gate findings, lock and credential notes, open issues, verification results, and remaining work.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 24.14% which is insufficient. The required threshold is 60.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly identifies this PR as the documentation workspace for the agent-config-editing design.
Description check ✅ Passed The description accurately explains the design workspace, its contents, feature scope, stack position, feature flag, and target release.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch agent-config-editing-plan

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Both spikes are green. The decisions log records what was accepted from
each spike and the seven product calls still open.
change-set, commit-transaction, read-config (engine-spike);
execution-authorization, workspace-import, adapter-matrix (runner-spike).
The value_from schema conflict is arbitrated; twelve product calls open.
…orded

Strict canonical serializer, multi-source atomicity, honest TOCTOU model,
descendant confinement, harmless-forgery acknowledgement design, canonical
generation payload, text-file import into text fields with diff approval,
four-layer executable permission split.
…ctions; inline marker validated; harness included
… errors, path normalization, selector forgiveness, optional free-text on all tools
…ditions; message derived server-side; invalid_operation split; v3 spike results

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 16

🧹 Nitpick comments (2)
docs/design/agent-config-editing/spikes/model-usability/harness.py (1)

16-16: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Remove the two unused imports. Flake8 reports F401 for both spike scripts; neither module is referenced.

  • docs/design/agent-config-editing/spikes/model-usability/harness.py#L16: delete import os.
  • docs/design/agent-config-editing/spikes/model-usability/run.py#L12: delete import copy.

Source: Linters/SAST tools

docs/design/agent-config-editing/spikes/model-usability/run.py (1)

379-413: 🩺 Stability & Availability | 🔵 Trivial | 💤 Low value

Close the output file with a context manager.

If pool.map raises, line 413 is never reached and the buffered records stay unflushed. Wrap the pool run in a with out.open("w") as handle: block so partial results survive a failed run.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 2b018c86-a927-402b-8092-90786eaf6c7d

📥 Commits

Reviewing files that changed from the base of the PR and between 4aa9a26 and cdc6c1d.

⛔ Files ignored due to path filters (1)
  • docs/design/agent-config-editing/spikes/model-usability/results.tar.gz is excluded by !**/*.gz
📒 Files selected for processing (38)
  • docs/design/agent-config-editing/BRIEFING.md
  • docs/design/agent-config-editing/README.md
  • docs/design/agent-config-editing/context.md
  • docs/design/agent-config-editing/contracts/adapter-matrix.md
  • docs/design/agent-config-editing/contracts/change-set.md
  • docs/design/agent-config-editing/contracts/commit-transaction.md
  • docs/design/agent-config-editing/contracts/execution-authorization.md
  • docs/design/agent-config-editing/contracts/read-config.md
  • docs/design/agent-config-editing/contracts/workspace-import.md
  • docs/design/agent-config-editing/decisions.md
  • docs/design/agent-config-editing/notes/dao-lock-impact.md
  • docs/design/agent-config-editing/notes/final-review-findings.md
  • docs/design/agent-config-editing/notes/s7e-credential-handoff.md
  • docs/design/agent-config-editing/open-issues.md
  • docs/design/agent-config-editing/plan.md
  • docs/design/agent-config-editing/research.md
  • docs/design/agent-config-editing/research/change-set-interface-codex.md
  • docs/design/agent-config-editing/research/design-gate-review-codex.md
  • docs/design/agent-config-editing/research/design-gate2-review-codex.md
  • docs/design/agent-config-editing/research/design-gate3-review-codex.md
  • docs/design/agent-config-editing/research/rfc.html
  • docs/design/agent-config-editing/research/runner-lifecycle-codex.md
  • docs/design/agent-config-editing/spikes/engine-spike.md
  • docs/design/agent-config-editing/spikes/model-usability-spike.md
  • docs/design/agent-config-editing/spikes/model-usability/analyze.py
  • docs/design/agent-config-editing/spikes/model-usability/harness.py
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v0.md
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v1.md
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v2.md
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v3.md
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v4a.md
  • docs/design/agent-config-editing/spikes/model-usability/instructions/v4b.md
  • docs/design/agent-config-editing/spikes/model-usability/run.py
  • docs/design/agent-config-editing/spikes/model-usability/selftest.py
  • docs/design/agent-config-editing/spikes/model-usability/table.py
  • docs/design/agent-config-editing/spikes/model-usability/tasks.py
  • docs/design/agent-config-editing/spikes/runner-spike.md
  • docs/design/agent-config-editing/status.md

Comment thread docs/design/agent-config-editing/contracts/adapter-matrix.md
Comment on lines +488 to +490
- **There is no folder source and no folder-to-skill codec in v1.** The agent authors the
skill structure itself and references each file's content per field. It already knows the
structure; it does not need a codec to infer it.

@coderabbitai coderabbitai Bot Aug 5, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | 🏗️ Heavy lift

Resolve the US-3 folder-import regression.

US-3 promises that an agent imports a downloaded skill by naming its folder. The decided change-set removes the folder codec and requires one marker per file. The authorization contract then limits a call to eight markers. A downloaded skill with more than eight referenced text files cannot complete in one atomic import.

  • docs/design/agent-config-editing/contracts/change-set.md#L488-L490: restore a folder representation, or record an explicit product decision that changes US-3.
  • docs/design/agent-config-editing/BRIEFING.md#L19-L22: align the stated user story with the selected import model.
  • docs/design/agent-config-editing/context.md#L33-L36: align the stated goal with the selected import model.
  • docs/design/agent-config-editing/contracts/execution-authorization.md#L435-L443: if marker imports remain, set limits that permit a complete skill import or define a safe multi-commit workflow.
📍 Affects 4 files
  • docs/design/agent-config-editing/contracts/change-set.md#L488-L490 (this comment)
  • docs/design/agent-config-editing/BRIEFING.md#L19-L22
  • docs/design/agent-config-editing/context.md#L33-L36
  • docs/design/agent-config-editing/contracts/execution-authorization.md#L435-L443

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Acknowledged, fix queued. BRIEFING.md and context.md still state US-3 as "point at its folder," but the decided change-set removed the folder codec (change-set.md 6.2) and execution-authorization.md 6.2 caps a call at 8 sources / a turn at 32. A downloaded skill with more referenced text files than that cannot land in one atomic import. This needs a product decision (raise the limit, or restate US-3 as a multi-commit workflow), not a doc tweak, so leaving open for that decision rather than resolving.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mmabrouk, agreed. The finding remains open.

The selected marker model cannot guarantee a one-commit import for every folder-based US-3 skill under the current 8-source limit. The product decision must either:

  1. Increase the authorization limit to support the defined skill size, or
  2. Change US-3 to define a safe multi-commit import workflow.

After that decision, the contracts and user-story documents can align.

🐇

You are interacting with an AI system.

Comment on lines +231 to +232
The runner then substitutes the frozen value into the call body. It replaces `value_from` with
`value`. It never rereads the folder.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Substitute the marker at valuePointer.

@ag.file is nested inside an operation value. It is not an operation-level value_from field. Replace the marker at each authorized {operationIndex, valuePointer} with its frozen string on a copied call body.

Do not describe this step as replacing value_from with value. That obsolete transformation can leave markers unresolved or construct an invalid operation body.

Also applies to: 334-335

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Acknowledged, fix queued. Section 3.3 ("It replaces value_from with value") and 3.4.4 ("The runner replaces value_from with value for every required index") still use the pre-consolidation phrasing, even though 3.4's own banner says the source moved from an operation-level value_from field to an inline @ag.file marker anywhere in value. Needs a wording pass to describe substitution at the marker's valuePointer, not value_from replacement, so leaving open.

Comment thread docs/design/agent-config-editing/contracts/workspace-import.md Outdated
Comment thread docs/design/agent-config-editing/notes/dao-lock-impact.md
Comment thread docs/design/agent-config-editing/spikes/model-usability/instructions/v2.md Outdated
Comment thread docs/design/agent-config-editing/spikes/model-usability/run.py
Comment thread docs/design/agent-config-editing/spikes/model-usability/table.py Outdated
Comment thread docs/design/agent-config-editing/spikes/runner-spike.md
Comment thread docs/design/agent-config-editing/status.md

@mmabrouk mmabrouk left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mmabrouk mmabrouk added the lgtm This PR has been approved by a maintainer label Aug 6, 2026
@mmabrouk
mmabrouk marked this pull request as ready for review August 6, 2026 10:56
@dosubot dosubot Bot added size:XXL This PR changes 1000+ lines, ignoring generated files. documentation Improvements or additions to documentation labels Aug 6, 2026
The spike harness could not run: it imported its engine from a worktree that no
longer exists. Its hand-written schema had also drifted from the shipped one, and
the field whose placement a live model got wrong did not exist in it at all.

real_surface.py imports both surfaces instead of copying them: the engine from
api/oss/src/core/workflows/change_set.py and the commit schema from op_catalog.py
with ordered operations on. It also reports the divergences, so a run states what
changed rather than assuming.

Adds two scored envelope tasks, a schema check at the point a harness would make
it, and 371 trials across four models in two arms. The result: the placement
sentence has no measured effect, because three of four models never make the
mistake and the fourth is not helped by it.

selftest.py used the pre-v3 'field' selector key and refused every golden delta;
it passes against the shipped engine now.
…oposal, three shippable layers) and the denied-sibling seam; AGENTS.md gains today's GitButler dropped-hunk, attribution, and cliId lessons
… is whether the running harness OBSERVED the change); open-issues gains the refresh-then-reopen follow-up with its two prerequisites
…tack; ask which lane tip first contains every symbol it touches (three in-isolation CI reds in one day before this rule)
… 750ms poll for an out-of-order frame; a stack slow enough to miss it degrades to a gate that mints nothing)
@mmabrouk
mmabrouk changed the base branch from release/v0.109.0 to release/v0.110.0 August 7, 2026 09:28
@mmabrouk
mmabrouk merged commit a171556 into release/v0.110.0 Aug 7, 2026
6 checks passed
@mmabrouk
mmabrouk deleted the agent-config-editing-plan branch August 7, 2026 09:32
@mmabrouk
mmabrouk restored the agent-config-editing-plan branch August 7, 2026 09:36
@mmabrouk
mmabrouk deleted the agent-config-editing-plan branch August 7, 2026 09:38
mmabrouk added a commit that referenced this pull request Aug 7, 2026
docs: agent-config-editing design workspace (stack bottom)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation lgtm This PR has been approved by a maintainer size:XXL This PR changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant