Skip to content

feat(harness): continuous conversation execution across providers - #110

Merged
erinepshovel-code merged 29 commits into
mainfrom
feat/continuous-a0-harness
Sep 23, 2026
Merged

erinepshovel-code merged 29 commits into
mainfrom
feat/continuous-a0-harness

Conversation

@erinepshovel-code

@erinepshovel-code erinepshovel-code commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

Purpose

Complete the A0 conversation harness so the user does not have to carry provider switching or long-context continuity manually.

The conversation remains the durable identity. Provider/model changes are internal execution transformations with provenance.

Behavior

  • persists bounded harness_state on the owning conversation
  • preserves the first task anchor and latest 24 exact messages
  • compacts older turns into a bounded historical checkpoint while retaining the full persisted transcript as authority
  • routes ordinary single turns through work_harness.run_single_turn
  • preserves explicit model pins exactly
  • introduces string-compatible typed provider-failure markers so legacy callers still receive sanitized display text while the harness can distinguish a real provider failure from ordinary model prose
  • in auto mode, falls back only while the run-scoped registry-tool execution count is zero
  • records the first registry-tool dispatch as the replay boundary
  • refuses automatic provider replay after that boundary; unresolved continuation is surfaced as hmmm instead of risking duplicate mutation
  • records attempted models, fallback count, actual provider, and tool-execution count in usage provenance
  • repairs Python ORM drift for max_tool_rounds and inference_mode
  • adds harness_state to both declared schemas and the still-active production startup-DDL path

Architectural boundary

METAPAT gate: no root/canon change. Identity (conversation), state (harness_state), relation (provider routing), and transformation (provider execution change) remain separate.

The migration foundation has not yet cut production over to Alembic, so this PR uses the current idempotent startup-DDL authority for harness_state rather than pretending that migration cutover is complete.

Exact-head evidence

Head: aa0ed96108f6858d6a60b81fabb863f63c9c930a

  • provider adapter contracts: PASS
  • full Python test suite: PASS
  • Python backend boot: PASS
  • console-tab regression guard: PASS
  • production container build: PASS
  • clean frontend build / no @replit bundle references: PASS
  • PR deployment jobs: skipped by workflow policy

hmmm

Provider quota APIs are not uniformly queryable before a call. Safe automatic continuation is therefore evidence-based: before the first registry-tool dispatch, provider failure may switch providers; after that boundary, A0 preserves the conversation and refuses automatic replay because the preceding tool may have mutated external state.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@erinepshovel-code
erinepshovel-code merged commit ad958a4 into main Sep 23, 2026
14 checks passed
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.

1 participant