Repository navigation
Prepare each Executor from one request - #533
Merged
Merged
Conversation
A Runtime frame that projects to no Item, such as a delta without an item_id, failed the Turn with event_persistence_failed. items.Project now wraps every failure in ErrInvalidObservation, and delivery reports a journal write that fails with it as invalid_executor_result at every flush. Storage failures stay event_persistence_failed.
Session creation added model_provider_configured to the stored configuration whenever a provider bundle was frozen, and nothing reads it: the execution Snapshot field was set only by test fixtures. The marker, the field and the fixtures go, and the retry identity hashes the configuration as requested.
Core reads only supported_agent_kinds and home_removal from a heartbeat, and nothing reads DonePayload.Transcript. The heartbeat's ts, active_requests and daemon_version and the transcript go. The connect option that carries the wire version stays.
The Core-Runtime wire carries only what Core decides. Delete AgentStateKey, LocalEnvironment's Capabilities, NetworkAccess and AllowedDomains, the prepared configuration's RunID and Input, and every json:"-" field. The Runtime derives the state key from the Session ID, the Environment owner knows its installed capabilities, and Core admits only an enabled workspace network. ExecutorFactory and ViewExecutorFactory take agent.PrepareRequest: the wire configuration, the model configuration the Registry prepares once, the state key, the assignment, and the Environment's workspace and installed Capabilities that its owner fills. Adapters no longer prepare or re-parse the model configuration, and MiniMax Code keeps each Turn's Run ID in its own state. Codex runs the shared text lifecycle contract.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Core–Runtime wire carries only what Core decides, and each Executor is prepared from one request.
Wire (
internal/agentdaemon/proto,docs/runtime-protocol.md)AgentStateKey(the Runtime derives the state key from the Session ID),LocalEnvironment.Capabilities,NetworkAccessandAllowedDomains(the owner knows its installed capabilities; the workspace network isenabledby construction), the prepared configuration'sRunIDandInput(they arrive inexecution_start), the unread heartbeat fieldsTimestamp,ActiveRequestsandDaemonVersion,DonePayload.Transcript, and everyjson:"-"field.proto.Versionis unchanged; the final merge bumps it once.Runtime–Harness (
apps/daemon/internal/agent/harness.go,harness-onboarding.md)agent.PrepareRequestcarries the wire configuration, the Runtime-resolved workspace and capability roots, Skills and MCP, the state key, the assignment and theharnessconfig.PreparedConfigurationthe registry prepares once.ExecutorFactoryandViewExecutorFactorytake it; the adapters' ownPreparecalls and raw re-parsing ofmodelandmodel_providerare gone.Core
model_provider_configuredmarker goes.invalid_executor_result; storage failures stayevent_persistence_failed.Checks
agenthost,cli,dispatch,localworkspace,transport,proto,harnessconfig, and Core'sexecution,items,sessionpg,runtimegatewayandsessions;services/core/tests/integration;-race -count=50on the new concurrent tests; the gated agent-host suite; darwin and windows builds;make check-names check-docs check-ci.contracttest.TextLifecycle. MiniMax Code does not yet: it retires its owner on every cancel, a follow-up.Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.