Skip to content

refactor: remove stale continuation semantics from Python examples - #67

Merged
rlippmann merged 1 commit into
mainfrom
audit_sweep
Aug 10, 2026
Merged

refactor: remove stale continuation semantics from Python examples#67
rlippmann merged 1 commit into
mainfrom
audit_sweep

Conversation

@rlippmann

Copy link
Copy Markdown
Owner

Summary

Remove stale continuation-era scaffolding and align Python examples/documentation with the current Context Compiler architecture.

This change:

  • removes obsolete LiteLLM prompt-construction confirmation/session continuation code;
  • removes the unused session_key flow and confirmation-token branch from the basic LiteLLM example;
  • removes stale tests for the deleted confirmation helper;
  • updates example-facing rejection terminology from clarify to error where the behavior represents compiler rejection rather than a human clarification workflow;
  • updates documentation to describe current checkpoint, persistence, rollback, and error behavior.

Intentional checkpoint persistence and rollback behavior remain unchanged.

Why

Several examples still reflected older confirmation/continuation assumptions after the architecture moved toward explicit authoritative state transitions.

The previous terminology and helper flows implied:

  • pending confirmation state;
  • resumable clarification workflows;
  • checkpoint-backed continuation semantics.

The current architecture distinguishes:

  • compiler errors/rejected transitions;
  • authoritative state persistence;
  • future human-in-the-loop approval workflows.

This cleanup removes stale example behavior so the repository surface matches the current enforcement model.

Example metadata

  • Enforcement point: Repository/example architecture maintenance; compiler error handling and state lifecycle clarity
  • Domain: General Context Compiler examples and integrations
  • Technology/runtime: Python examples, LiteLLM examples, FastAPI examples, reference integrations, documentation
  • Example type: repository maintenance
  • Does this use directive drafter? should normally be no: No
  • Does this derive state from model output? must be no for primary examples: No

Checklist

  • Repository scaffolding / governance change
  • One primary enforcement point
  • Explicit authoritative state
  • No model-derived state mutation
  • Adversarial stub or equivalent test
  • Observable runtime behavior change
  • Domain vocabulary is natural
  • Framework is secondary to the enforcement point
  • Docs updated
  • Tests/smoke checks added where practical

Notes

Preserved:

  • intentional checkpoint persistence examples;
  • LiteLLM proxy state restoration/persistence;
  • OpenWebUI transactional rollback behavior;
  • compiler error handling semantics.

Removed:

  • obsolete LiteLLM confirmation helper;
  • unused confirmation/session continuation plumbing;
  • stale documentation describing pending confirmation and resume flows.

Validation:

  • ./scripts/validate_python.sh passed (204 passed, 6 skipped)
  • Focused Python example test suites passed
  • Markdown lint passed for updated documentation

@rlippmann
rlippmann merged commit 34c4e72 into main Aug 10, 2026
6 checks passed
@rlippmann
rlippmann deleted the audit_sweep branch August 10, 2026 06:23
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