PyRank
  • Search
  • PyPI
  • GitHub
  • Insights
  • Compare
  • Advisories
  • Ecosystem
  • About

Cost Control Python Packages

Python packages with the GitHub topic cost-control. Sorted by monthly downloads, with stars and forks.
domondi1
inferrail

Self-hosted OpenAI/Anthropic-compatible gateway: give each AI agent run a dollar budget, enforced before the provider, with a payload-free per-run cost record.

10K 1 0
bmdhodl
agentguard47

Python runtime checks for AI agents: budgets, loops, retries, and local traces. Zero runtime dependencies. MIT.

3K 4 3
kazenai-ai
kazenai

Runtime budget enforcement and execution telemetry for OpenAI and Anthropic clients.

3K 0 0
theagentplane
agent-tokenops

Run-aware token governance for multi-agent systems.

2K 82 23
krivonosoff161
agentic-llm-router

Small cost-aware LLM router for role-tiered OpenAI-compatible and Yandex calls with per-call usage logging.

2K 0 0
amabito
veronica-core

Runtime containment kernel for LLM agents. Enforces budget, step, retry, and circuit-breaker limits before the model call.

1K 5 0
loopgain-ai
loopgain

An open-source cost controller for AI agent loops — stops a loop when it's actually converged and rolls back before it degrades, instead of running to a fixed max_iterations cap. Real-time loop-gain (Aβ) bands + best-so-far rollback. Adapters for LangGraph, CrewAI, AutoGen, LangChain, OpenAI Agents, and Claude Agent SDK; raw API for custom stacks.

1K 126 11
krivonosoff161
llm-cheap-filter

Deterministic prefilter and cheap-to-chief escalation pipeline for reducing expensive LLM calls in agentic workflows.

987 0 0
ENDEVSOLS
longguard

In-flight circuit breaker & loop recovery for LangGraph, LangChain, OpenAI & Anthropic agents. Catches reasoning loops, prevents runaway LLM costs with budget hard caps, and auto-injects Reflect & Pivot prompts.

653 7 1
rocketlang
xshieldai-crewai

The kill-switch between your AI agents and your credit card. Agentic spend governance for Claude Code, OpenAI Codex, and any JSONL-logging agent.

595 0 0
alicelik-games
opshield

AI agent safety platform: rollback, cost control, circuit breakers, tracing, compliance, and chaos testing. Zero dependencies.

592 3 0
rocketlang
xshieldai-langchain

The kill-switch between your AI agents and your credit card. Agentic spend governance for Claude Code, OpenAI Codex, and any JSONL-logging agent.

577 0 0
runcycles
langchain-runcycles

LangChain agent middleware for Cycles — pre-tool-call authorization and per-tenant budget enforcement for Python agents using create_agent

552 0 0
abhijitgunjal
llm-token-guard

Track LLM token usage, enforce rate limit & budget policies, and trigger alerts across OpenAI, Groq, OpenRouter, and AWS Bedrock.

525 20 2
mariadb-RupeshBiswas
bq-readonly-mcp

Read-only BigQuery MCP server for Claude, Cursor, Windsurf, Copilot and other MCP clients. Auto-LIMIT, dry-run cost guard, Application Default Credentials. Run with uvx.

502 1 0
arieradle
shekel

LLM budget control and cost governance for AI agents. Python library for token budgets, usage limits and guardrails for OpenAI, Anthropic, LangChain, LangGraph and agentic systems.

461 18 1
figuard
figuard

Pre-flight spend authorization for AI agents. Reserve-confirm lifecycle, concurrency-safe, append-only audit ledger.

438 2 0
Efithor
podtrack

Ownership-aware RunPod pod registry and autonomous reaper for shared accounts

437 0 0
flytohub
flyto-pro-core

Validate agent workflows and check cost and token budgets before execution.

427 0 0
vishal-dehurdle
state-harness

Runtime safety net for LLM agents. Detects token spirals, kills doomed tasks early, tells you exactly why. Rust core, Python SDK. pip install state-harness

402 18 2
runcycles
runcycles

Python SDK for Cycles — reserve, commit, release budget and risk for AI agents

402 0 1
runcycles
runcycles-openai-agents

Budget governance for OpenAI Agents SDK — enforce cost limits before tools execute

382 0 0
520atp
hengroute

OpenAI 兼容的 AI 大模型网关:一个 API Key 调用所有大模型,智能路由降本,实时可观测,故障自动降级。

296 2 0
520atp
hengroute-cli

OpenAI 兼容的 AI 大模型网关:一个 API Key 调用所有大模型,智能路由降本,实时可观测,故障自动降级。

283 2 0
    • Original data from PyPI, GitHub, and OSV; downloads served through ClickHouse
    • Sources & methodology