release: promote dev to main for v0.2.21 — forecast champion selector A–C#364
Conversation
chore(release): back-merge v0.2.20 into dev
…ful-skip-401 fix(api): skip showcase knowledge phase on embedding auth failure
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
…hots docs(docs): complete showcase dogfood screenshots
…tion fix(agents): persist pending_action for gated tool calls
fix(api): honor feature_frame_version >= 3 in ops + registry
fix(api): showcase agent step runs on local Ollama (no API key needed)
…lback fix(agents): non-streaming fallback for Ollama agent chat
Ollama's OpenAI-compatible /v1/chat/completions rejects any message whose content is JSON null and carries no tool_calls (400 'invalid message content type: <nil>'). A weak local model emits that shape for an empty assistant turn and PydanticAI replays it on retry, so every retry 400s and the run dies with FallbackExceptionGroup. Inject a sanitizing httpx transport into the OllamaProvider client that coerces outgoing content:null to content:"".
…344) A gated tool (create_alias/archive_run/save_scenario) records deps.pending_action the moment it fires, but does not halt the run. A weak model can ramble past the gate and exhaust its retry budget, so agent.run raises UnexpectedModelBehavior before returning and the post-run approval-surfacing path never runs. The captured approval is valid, so surface it: chat() and stream_chat()'s UnexpectedModelBehavior handlers now check deps.pending_action first and emit the approval (ChatResponse pending_approval / approval_required event) before falling back to the generic error.
) The chat Approve/Reject handlers awaited POST /approve but discarded the ApprovalResponse and only cleared the card, so a click produced no visible result — and a failed action execution (e.g. create_alias 'Run not found', returned as status=rejected + result.error) was silent. Capture the response and append a one-line report for every outcome (executed / approved-but-failed / rejected / expired) via a pure, unit-tested formatApprovalReport helper. Closes #346.
fix(agents,ui): Ollama chat HITL — null-content, pending-approval salvage, and approval report
fix(agents): constrain experiment read-only queries
fix(agents): stop experiment read-only tool-call loop
fix(agents): salvage experiment answer when weak model fails structured output
…or-backend feat(api,db): add forecast champion selector backend (#353)
…te-in-effect fix(ui): avoid setState-in-effect in RunHistoryStrip to unblock lint (#357)
feat(ui): add forecast champion selector foundation
feat(api,db,ui): forecast champion selector slice B — async comparison & results
feat(api,db,ui): forecast champion selector slice C — forecast decision, business summary & promotion (#362)
There was a problem hiding this comment.
Sorry @w7-mgfcode, your pull request is larger than the review limit of 150000 diff characters
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (5)
📒 Files selected for processing (118)
📝 WalkthroughWalkthroughAdds Champion Selector backend and frontend (Slices A–C): migrations, ORM, strict schemas, async runner, service, routes, UI, hooks, and types. Introduces config/env settings. Enhances agents HITL recovery and RAG embedding auth error handling. Updates docs and extensive unit/integration tests. ChangesChampion Selector End-to-End
Sequence Diagram(s)sequenceDiagram
participant UI (Champion Page)
participant Hooks
participant API
participant Service
participant DB
UI (Champion Page)->>Hooks: useSubmitSelectionRun(request)
Hooks->>API: POST /model-selection/runs
API->>Service: submit_run
Service->>DB: insert run+candidates (RUNNING/PENDING)
Service-->>API: 202 + monitor_url
API-->>Hooks: 202
Hooks-->>UI (Champion Page): selectionId
UI (Champion Page)->>Hooks: useSelectionRun(selectionId)
Hooks->>API: GET /model-selection/{id}
API->>Service: get_selection
Service->>DB: load run+children
Service-->>API: run with progress/ranking
API-->>Hooks: 200
Hooks-->>UI (Champion Page): render progress/results
Estimated code review effort🎯 5 (Critical) | ⏱️ ~120 minutes Possibly related issues
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
|
Release: promote
dev→mainfor v0.2.21Cuts the next pre-1.0 PATCH release (0.2.20 → 0.2.21). Merging this PR lets release-please open the
chore(main): release 0.2.21Release PR; merging that tagsv0.2.21.Headline — 🏆 Forecast Champion Selector (A → B → C)
model_selectionslice: candidate models, run lifecycle./visualize/champion.z·σ·√L), business summary, and champion promotion (registry run + alias with audit).Agents / Ollama hardening
pending_actionfor gated tool calls (fix(agents): persist pending_action for gated tool calls #336).RAG / Showcase
API / Ops / UI fixes
feature_frame_version >= 3in ops + registry (fix(ops,registry): honor feature_frame_version >= 3 (stop clamping to {1,2}) #338).RunHistoryStrip(fix(ui): RunHistoryStrip setState-in-effect lint failure blocks frontend lint gate #357).Validation
All five gates green on
devHEAD (ruff + format, mypy --strict, pyright --strict, pytest, migration-check). Alembic head:e4f5a6b7c8d9.Summary by CodeRabbit
New Features
Bug Fixes
Chores