feat: v0.7.1 — policy engine, time-windowed budgets, Hermes/CrewAI integrations, litellm CVE fix#32
Closed
orvi2014 wants to merge 5 commits into
Closed
feat: v0.7.1 — policy engine, time-windowed budgets, Hermes/CrewAI integrations, litellm CVE fix#32orvi2014 wants to merge 5 commits into
orvi2014 wants to merge 5 commits into
Conversation
Hermes Agent (baar/integrations/hermes.py): - BaarHermesProxy: runs baar as a local OpenAI-compatible HTTP proxy - BaarHermesSession: context manager that wires a budget-capped Hermes session via a temp HERMES_HOME, leaving the user's real ~/.hermes untouched - setup_baar_provider: one-time permanent Hermes config writer - 100% test coverage (tests/test_hermes_integration.py, 27 tests) CrewAI (baar/integrations/crewai.py): - BaarCrewLLM: subclasses crewai.LLM; routes call()/acall() through BAARRouter for semantic routing + pre-flight budget kill-switch on every agent turn - BaarStepCallback: step_callback= drop-in for existing crews; checks budget between steps without touching the crew's LLM configuration - 100% test coverage (tests/test_crewai_integration.py, 30 tests) Also: router.py race-condition guards marked pragma no cover; coverage gap tests added to test_router.py and test_baar_router_coverage.py. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ert hooks — v0.7.0 - Policy engine (baar.core.policy): declarative Rule/Policy evaluation before every LLM call; supports block, force_small, force_big, allow actions; raises PolicyViolation on block - Time-windowed budgets (BudgetWindow): HOURLY/DAILY/MONTHLY spend resets via WindowedBudgetStore; works with Memory, File, and SQLite backends - Alert hooks (Alert): threshold callbacks with once=True/False; auto re-arm on window rollover and BudgetTracker.reset() - PolicyViolation treated like TaskRejected in run()/arun() — no consecutive-error penalty - record_manual() emits UserWarning on pricing failure instead of silently recording $0 - 606 tests passing; all 7 independent review findings verified as false positives Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…E-2026-33634 Adds !=1.82.7,!=1.82.8 to the litellm dependency constraint so pip never resolves to the supply-chain-compromised versions. The existing runtime block in _check_litellm_version() is preserved as defence-in-depth. Bumps version to 0.7.1. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Merges all v0.6.0 and v0.7.0 work into main, releasing as v0.7.1.
What's included
v0.7.0 — Policy engine + alert hooks
Policy/Rule/PolicyAction— declarative spend policies with configurable actions (block, warn, log)BudgetWindow) — daily, weekly, monthly rolling caps per userv0.6.0 — New integrations
v0.7.1 — Security fix
litellm>=1.30.0,!=1.82.7,!=1.82.8to block the compromised PyPI packages (CVE-2026-33634, March 24 2026)Test results
All 606 tests passing across router, budget, policy, stores, integrations (LangChain, LangGraph, CrewAI, Hermes, MCP, Vercel), and telemetry.
Checklist
🤖 Generated with Claude Code