Add Autopilot objective state RPC across all SDKs - #2506
Draft
aymenfurter wants to merge 4 commits into
Draft
Conversation
Generate the experimental session.autopilotObjective.getState API for all SDK languages and add focused contract coverage for nullable state, lifecycle statuses, optional fields, and exact nano-AIU strings. Keep runtime pins unchanged until the upstream change is published in a CLI release. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Consolidate generated RPC tests into the established language-specific suites, align credit fixtures, and verify required and optional fields plus session-scoped dispatch. Use the shared Rust replay context and correct its invocation count. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
jbayardo
approved these changes
Sep 3, 2026
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.
Important
Draft: Merge is blocked until the containing Copilot CLI release is pinned and the generated sources are refreshed.
Summary
Add generated bindings for the experimental
session.autopilotObjective.getStateRPC across TypeScript, Python, Go, .NET, Rust, and Java.The result contains the objective text, lifecycle status, turn count, optional pause or completion details, and credit consumption. Exact nano-AIU values use decimal strings to prevent precision loss. A
nullstate means that the session has no objective.This follows the existing direct generated session-RPC pattern used by the agent, compaction, and history APIs. It does not add a handwritten workflow wrapper.
Test coverage
Compatibility
Older CLI versions return JSON-RPC error
-32601. The SDK propagates this error and does not convert it to an empty state.This PR does not add an objective setter or wrap the built-in Autopilot command because no typed public RPC exists for that operation.
Before merge