Repository navigation
feat(parser): capture Posit Assistant reasoning effort - #2505
Conversation
roborev: Combined Review (
|
8bf8762 to
42bb306
Compare
This comment has been minimized.
This comment has been minimized.
roborev: Combined Review (
|
|
yeah pr stacks are not across forks yet :( |
42bb306 to
8ed4858
Compare
roborev: Combined Review (
|
8ed4858 to
8660c65
Compare
roborev: Combined Review (
|
The Posit Assistant effort capture is data version 161 after the rebase onto main, because main used versions 158 to 160 for OMP and Antigravity CLI repairs. The upgrade test still started from version 157. It asked which providers the 157 to 158 step reparses, got OMP, and failed on every Go test job. The test now starts from version 160, so it checks the step that belongs to this change. The format note now names version 161 as well. The repository's mdformat hook also rewrapped some earlier paragraphs in that note; their wording is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
roborev: Combined Review (
|
Summary
Adds support to AgentsView for recording the reasoning effort of Posit Assistant sessions. The model effort shown next to each message in the UI, and stored in the SQLite archive and its mirrors, is now filled in for these sessions. Before this change, effort showed for Claude, Codex, Command Code and (in #2503) Pi, but Posit Assistant messages always showed none.
This follows the Pi work in #2503 and has the same shape: a parser change, a data-version scope, tests, and a format note. No schema, wire format, API or frontend change is needed, because
messages.reasoning_effortand its rendering already exist.What the format stores
Each assistant line in
lm-messages.jsonlcarries the effort the request used atmessage.providerOptions.providerMetadata.positai.thinkingEffort.off,minimal,low,medium,high,xhighandmax. Model-specific levels such asadaptiveare also honored.What changed
internal/parser/posit_assistant_provider.go: assistant messages copypositai.thinkingEffortintoReasoningEffort, verbatim.offis stored asoff. A missing field leaves it empty. User, system and tool messages never carry effort.internal/db/db.goandinternal/db/data_version_scope.go: data version 158, scoped toAgentPositAssistant. Existing archives reparse those sources in place; session and source identities do not change. Positron is a separate agent and is not affected.internal/parser/posit_assistant_provider_test.go:TestPositAssistantProviderReasoningEffort, a table test covering the inline value, verbatim storage (off,xhigh,adaptive), a mid-session change, an absent field, no carry-over from an earlier message, and non-string values.internal/sync/posit_assistant_effort_upgrade_test.go: an upgrade regression test. It stamps a Posit Assistant session at version 157 with empty effort, then checks that a sync fills in the effort in place, keeps the session ID, file path and file hash, and leaves another agent's session alone.docs/internal/session-format-sources.md: a "Reasoning effort" entry in the Posit Assistant section with the source paths, introduction commit and release, and the data-version note.Limits and tradeoffs
conversation.jsonstoresmetadata.model.thinkingEffort, but only as the latest preference for the whole conversation, and it was introduced in the same Posit Assistant change as the per-message field. Using it would add nothing for older sessions and would misreport mid-session changes. Older sessions keep an empty effort.Where to look
The extraction is three lines in
positAssistantFillAssistant. Most of the review effort belongs on the upgrade test and the format note.