Closes the structural gap from issue #557: AQE could only bill the paid
Anthropic API even for Pro/Max subscribers, and its budget caps were never
enforced.
- claude-code provider: run QE via `claude -p` on the user's subscription;
child env strips API-billing keys so it can't revert to API billing
- Enforced cross-process spend caps (--max-budget-usd / AQE_MAX_BUDGET_USD),
persisted to memory.db (llm_spend); enforced on the ProviderManager AND
HybridRouter paths; over-budget aborts with COST_LIMIT_EXCEEDED
- cognitum provider: OpenAI/Anthropic-compatible gateway with per-request
cost receipts, embeddings, and a server-side hard cap
- Billing-mode taxonomy + startup notice + `aqe health` LLM Billing section
- config-store: honor explicit `enabled: false` over env key presence;
AQE_LLM_PROVIDER selector
- Fix: `aqe eval run` no longer scores fabricated mock responses — real
provider by default, hard-error when none configured, `--mock` opt-in
- Consensus verification path prints a billing warning (deferred full port)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Commit 5 of 6 for ADR-093 (Commit 4 skipped — no thinking-config
callers to shim; documented in the implementation plan).
* src/routing/advisor/multi-model-executor.ts: DEFAULT_ADVISOR_MODEL
upgraded from 'anthropic/claude-opus-4' to 'anthropic/claude-opus-4.7'.
When TinyDancerRouter sets triggerMultiModel=true (confidence < 0.80,
or < 0.85 for security tasks), MultiModelExecutor.consult() now
dispatches to Opus 4.7 by default via HybridRouter.chat() +
OpenRouter provider.
* tests/routing/advisor/multi-model-executor.test.ts,
tiny-dancer-router-advisor.test.ts: update expected provider model IDs.
SWE-bench Verified 87.6% (vs 80.8% Opus 4.6), SWE-bench Pro 64.3%
(vs 53.4%), CursorBench 70% (vs 58%). Vendor-independence preserved —
consultations still flow through HybridRouter's 7 providers per
ADR-043.
Verification:
* 0 tsc errors
* 65/65 advisor unit tests pass
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>