Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions rust/contracts/application-boundary.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ this lifecycle protection; actual symbol computation remains upstream-owned.
| Git | workspace commit plans with optional immutable ChangeList path scopes, dependency ordering, guarded steps and partial-success retry, changes, commits, branches, diffs, reviewed history actions and recovery, worktree listing and safe management, worktree-aware PR publication context, validation, and mutation results | Git executable discovery, credentials, process environment, opening checkout paths, local ChangeList selection and preference persistence |
| GitHub | remote parsing, trusted request plans, normalized branch comparisons and pull requests/reviews/comments, deterministic ordering, and stable errors | OAuth configuration, HTTPS, browser opening, and operating-system credential storage |
| [AI commit messages](ai-commit.md) | provider configuration parsing, commit rules, bounded diff evidence, request plans, and response text | local configuration discovery, credentials, HTTP, cancellation, and draft UI |
| Agent sessions | bounded FIFO, current-turn steering reservations, stop/pause transitions, structured-question validation and delivery confirmations, projected action availability | tool/environment discovery, event presentation, input and answer drafts; CLI protocol translation belongs to each plugin |
| [IDE capability API / MCP](ide-api/v1.md) | canonical tool schemas, narrowing host selection, permission/argument validation, stable execution IDs, bounded output cursors and errors | implemented workflow inventory, explicit project authorization, live environment/Build/Run application actions, helper discovery and writable connection storage |
| Runtime | tool requirements, normalized candidates, effective toolchain references, pinned managed-runtime plans and bounded resolver answers | tool probing, executable paths, approved HTTPS downloads, safe archive extraction, native integrity, interprocess cache locks and atomic set publication |
| Language tooling | provider catalog, local fallback results, complete LSP process/session runtime, capabilities, diagnostics, UTF-16 edits, and normalized feature results | executable/environment discovery and UI provider routing |
Expand All @@ -87,6 +88,25 @@ that its editor snapshots still match those versions before touching files or
buffers, and stops pending work when Core revokes a delivered request. The
[Core commands reference](rust-core-api.md#commands) specifies the event and reply shapes.

### Agent turn interaction

Core owns live session action eligibility. Sending, steering and queueing are
distinct user actions; a stopped turn cannot resume queued work even if its
completion races the stop. A rejected or unacknowledged running-turn input
returns its original content, and failed answer delivery retains the question
for retry. CLI support comes from explicit interaction capabilities, never a
tool name. Hosts render `interactionState` and retain presentation drafts;
plugins translate opaque turn, question and option IDs into their CLI's real
protocol. No input content is logged or persisted by this interaction layer.
Replay has both count and byte bounds; only the latest interaction snapshot of
each live session is retained. Rejected drafts use separately reserved recovery
storage and explicit sequence acknowledgements, so replay eviction cannot lose
them. Hosts deduplicate recoveries independently of the replay cursor and flush
acknowledgements even after session exit. A valid late question of the stopping
turn is suppressed, allowing a same-batch terminal result to finish Stop.
See [the native session contract](../../shared/plugins/contract/v1/README.md#native-sessions)
and [the shared fixture](../fixtures/agents/turn-interaction-v1.json).

### Dev Container configuration and execution environment

The same explicit runtime target follows discovery, configuration lookup, build,
Expand Down
6 changes: 4 additions & 2 deletions rust/contracts/rust-core-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,10 @@ or removing a command fails until the table changes in the same commit.
| `agents.catalog` | List the configured agents |
| `agents.sessions` | List the live agent sessions |
| `agents.start` | Start a native agent session the user asked for |
| `agents.prompt` | Send the user's prompt, with the files, folders and images the user attached, to a live agent session |
| `agents.cancel` | Ask the agent backend to cancel the turn in progress |
| `agents.prompt` | Send, queue or steer the user's prompt and attachments, retaining queued or unconfirmed input until its outcome |
| `agents.cancel` | Mark the current turn stopping and pause the queue until a real turn-end event |
| `agents.updateQueue` | Remove a queued input or resume the user's paused FIFO |
| `agents.respondQuestion` | Validate and reserve an answer or cancellation to a pending structured question |
| `agents.respondPermission` | Answer a pending agent permission request |
| `agents.setConfigOption` | Pick a value of a session setting the agent backend reported |
| `agents.close` | End a live agent session |
Expand Down
2 changes: 1 addition & 1 deletion rust/crates/agent-runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ lithe-protocol = { path = "../protocol" }
lithe-request-context = { path = "../request-context" }
lithe-workspace = { path = "../workspace" }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
serde_json = { version = "1.0", features = ["raw_value"] }
sha2 = "0.10"
url = "2.5"

Expand Down
Loading
Loading