Skip to content

refactor: unify request and conversation history items and simplify compaction ownership - #465

Merged
maralbahari merged 5 commits into
mainfrom
refactor/clean-item-api
Oct 20, 2026
Merged

maralbahari merged 5 commits into
mainfrom
refactor/clean-item-api

Conversation

@maralbahari

Copy link
Copy Markdown
Collaborator

Summary

Responses requests, conversation APIs, and storage used overlapping item
types and separate conversion paths. Consolidate them around a shared
InOutItem in types::io, removing the redundant ConversationItem.

  • Use typed deserialization to reject unsupported input items instead of
    silently discarding them.
  • Preserve web-search and MCP call payloads in canonical history.
  • Move message-content validation onto ResponsesInput, applying it during
    typed execution and upstream request construction.
  • Consolidate history conversion and append behavior on existing types.
  • Preserve compaction estimates and reject invalid multi-agent continuation
    items without silently filtering them out.

Test Plan

  • Rust workspace tests and complete core rerun: 2,586 passed; 18 explicitly
    ignored tests remain unexecuted.
  • Workspace Clippy across all targets with warnings denied.
  • Rust formatting, production file-size checks, and git diff --check.
  • Fresh Python wheel build and package tests: 130 passed.
  • Script tests: 64 passed.
  • Launcher tests and source-install CLI end-to-end tests passed.
  • Regression coverage for continuation rejection and consistent token
    estimates between request and checkpoint history.

@haoshan98 haoshan98 left a comment •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks for the refactoring work, lgtm.

@maralbahari maralbahari changed the title refactor: unify request and conversation history items refactor: unify request and conversation history items and simplify compaction ownership Oct 20, 2026
@maralbahari
maralbahari merged commit 80e15ba into main Oct 20, 2026
15 checks passed
@maralbahari
maralbahari deleted the refactor/clean-item-api branch October 20, 2026 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants