premium-model-budget-governor
Allows planning premium-model work executed by Astra, including task previews, estimated credit costs, explicit approval for read-only runs, and usage receipts with token-rate cost estimates.
Premium Model Budget Governor
Astra does the work. You see the budget.
A local workbench, CLI, and MCP server for planning premium-model work, approving estimated spend, and inspecting usage afterward.
Explore the product tour / Install the beta / Connect MCP / Become a tester

Real development capture in a product-tour layout. Playback is optional on the website; no model runs in the tour or planner demo.
Public beta, not a stable release. The downloadable version is
0.4.0rc6. Execution is currently read-only and requires your explicit approval. This does not change the active model in existing Codex chats, make tokens cheaper, or guarantee the same quality at lower cost.
New Evidence, Same Astra
In a 12-call context pilot, both Astra profiles passed all frozen checks on three authored tasks. The focused catalog used 18.1% fewer input tokens and 26.8% fewer estimated credits, with unequal cache hits contributing to the credit difference. This is a small pilot, not a savings promise or proof of equal capability on every task.
A four-call extension checked read-only tool use and access to one named local skill. See the validation gate register for what passed and what still needs independent people and broader tasks.
Built for: Codex users who want Astra participation with explicit task budgets, and developers connecting governed tools through MCP. Not a fit yet: automatic control of every existing chat, write-enabled execution, or guaranteed weekly savings.
Idea, research guidance, and product management: Sulabh Dubey. Research synthesis and build execution: Codex by OpenAI, under his direction.
One weekly Codex allowance was consumed in roughly a day of Astra-heavy work. After a reset, only about 16% of the second allowance remained the following day. These were Sulabh Dubey's observed account readings, not a controlled benchmark.
The goal was not to stop using Astra. It was to keep its capabilities available without spending unnecessarily on repeated context, oversized evidence, and extra model handoffs.
That distinction shapes this project: direct Astra is the default. A cheaper model is an option, not the product's answer to every task. Hybrid workflows must account for all their stages, not just their cheapest step.
Idea, research guidance, and product management: Sulabh Dubey. Research synthesis, design, engineering, testing, documentation, and release execution: Codex by OpenAI, under his direction. Origin and credits.
What You Can Do
Your question | What the governor provides |
Can Astra handle this directly? | Astra-preferred planning with capability checks; no mandatory Sol-first attempt |
What am I approving? | A task preview with selected evidence, workflow stages, and estimated credits |
Would a hybrid actually help? | Whole-workflow estimates including preparation, execution, verification, and contingency |
What did the run consume? | Recorded input, cached-input, and output counts where available, plus token-rate cost estimates |
What happens if usage is unknown? | Unresolved spend stays reserved; it is not silently refunded or treated as zero |
Can my agent use it? | An optional local MCP server and a Codex plugin bundle |
One Task, One Visible Decision
Choose a project and describe a small task. Add the relevant files or images.
Preview a direct Astra run, or explicitly select a supported multi-stage workflow.
Approve the proposed read-only execution after checking the estimate.
Inspect the result and usage receipt. Compare the complete cost, not a capsule alone.
The Workbench supports project management, evidence selection, stop/reconnect, and receipt inspection without writing JSON. Initial installation still uses a terminal. Human usability testing is open; we are not claiming anyone can install it effortlessly yet. Workbench guide.
Related MCP server: l6e-mcp
Install
You need: Python 3.10+ and, for real execution, an installed and authenticated Codex CLI with access to the requested model. Model calls use your account's capacity. The web demo is illustrative and does not run models.
1. Download The Beta
Get these files from the rc.6 release:
Keep the installer and wheel in the same folder. Check the downloaded files against the release checksums before installing; only install code you trust.
2. Preview, Then Install
Open a terminal in that folder. The first command previews; the second installs:
python install_governor.py install --wheel premium_model_budget_governor-0.4.0rc6-py3-none-any.whl
python install_governor.py install --wheel premium_model_budget_governor-0.4.0rc6-py3-none-any.whl --yesThis creates a dedicated environment at ~/.pm-bg/runtime. It does not change
your Codex settings, PATH, or other Python environments, and does not run a model.
If that folder already exists, follow the upgrade/removal guidance
instead of overwriting it. Keep projects and ledgers outside the runtime folder.
3. Check Setup And Open The Workbench
Windows PowerShell (replace the example project folder):
& "$HOME/.pm-bg/runtime/Scripts/pm-bg.exe" doctor
& "$HOME/.pm-bg/runtime/Scripts/pm-bg.exe" serve --project "C:\path\to\project"Linux / macOS shell (replace the example project folder):
"$HOME/.pm-bg/runtime/bin/pm-bg" doctor
"$HOME/.pm-bg/runtime/bin/pm-bg" serve --project "/absolute/path/to/project"The server opens a private local browser link. Do not share that session link.
doctor checks setup without starting a model call; it does not prove model
access or remaining capacity. The released wheel has local Windows and Ubuntu/WSL
qualification; native macOS interactive usability is not established.
Need help? Installation and recovery / FAQ
Use a dedicated environment for development:
git clone --branch v0.4.0-rc.6 https://github.com/sulabhdubey/premium-model-budget-governor.git
cd premium-model-budget-governor
python -m venv .venvActivate it with .venv\Scripts\Activate.ps1 on Windows PowerShell, or
source .venv/bin/activate on Linux/macOS, then:
python -m pip install -e ".[dev]"
pm-bg plan --input examples/astra_preferred.json
python -m pytestThe example is illustrative: it plans but does not execute a model. Replace its estimates and approval state with real task inputs before using it for a decision. See the planning contract and CLI quickstart.
Use It With Codex Or MCP
The Workbench is one entry point. Compatible agents can also call local tools
such as plan_model_workflow, manage_task_budget, and build_capsule_from_files.
Integration | Start here |
Local MCP server | |
Codex plugin | |
Governed read-only execution |
Adding MCP exposes tools; it does not force an agent to use them or automatically govern every existing chat. The integration guide uses an explicit runtime path so the client does not accidentally launch a different Python installation.
What The Tests Actually Show
We publish the cases that did not save money, too.
Evidence | Observation | Boundary |
rc.5 installed-wheel qualification | 334 tests passed, one skipped on both Windows and Ubuntu/WSL; real MCP stdio checks and owned uninstall passed | Software regression evidence, not human usability or model-quality proof |
One real Astra Workbench run | 24,076 input tokens, 386 output tokens, 21.3 seconds | Demonstrates execution; not a matched savings comparison |
Expanded pilot: 39 worker calls | Five task families across four workflows; extra handoffs usually cost more than direct Astra | Limited development experiments, graded by Codex rather than independent evaluators |
Four-call focused-catalog experiment | About 17% lower mean token-rate-estimated cost on one repeated visual task | May omit useful skill guidance; not general quality equivalence or weekly savings |
Read the evidence: Release qualification / Real execution receipt / Pilot, methods, and negative findings / Focused-catalog tradeoffs.
Token-rate-estimated credits are not provider billing records or weekly-limit percentages. Independent held-out task evaluation and technical/nontechnical onboarding sessions remain open. We will not convert these early observations into a blanket "same Astra quality for less" claim.
Controls, Not Magic
Whole-task budgets: persistent reservations, expiring leases, and replay protection for cooperating runners.
Evidence preparation: explicit file selection, capsule scoring, and graph summaries; required evidence must not silently disappear.
Usage recovery: reconcile a recorded terminal receipt without rerunning a paid task; missing usage remains unknown.
Reviewed preferences: inspect evidence-based proposals, activate manually, and roll back. No automatic policy promotion is claimed.
Publication checks: bounded pattern scanning for secrets and private terms, with hash-bound reports and manual-review states.
See capability controls, architecture, and publication privacy for the contracts.
Know The Boundaries
Read-only execution does not revoke inherited connector permissions.
Estimates and local admission checks are not a provider-enforced in-flight spending cap.
Secret and prompt-injection scans are supplementary checks, not antivirus or a security guarantee.
Desktop-only actions and unsupported capabilities must be reported, not silently replaced.
Smaller context can remove useful guidance; focused discovery stays opt-in.
Nothing here bypasses provider limits or guarantees identical output quality.
Report sensitive findings through SECURITY.md, not a public issue. Cloned before the privacy cleanup? Read history migration before contributing; do not merge the old history back.
Help Test The Beta
We are looking for technical and nontechnical testers, and creators who want to evaluate it independently. No endorsement or positive result is expected.
Try installation and one small, non-sensitive, read-only task.
Record where you got stuck, what worked, and whether the answer was useful.
Never post credentials, private project files, prompts, or local session links. Review any attachments before sharing. A failed installation or a more expensive workflow is useful feedback, not a result to hide.
For a cost comparison, use the independent validation protocol: freeze the task and quality criteria first, assess answers before revealing costs, and count every stage, failure, and retry. Model calls consume your own capacity; no paid comparison is required just to report onboarding feedback.
Onboarding protocol / Contributing / Creator testing brief
Free, Open Source, Independently Built
The published code is available under Apache-2.0. There is no paid unlock required for the features in this repository; your model-provider usage remains separate. Possible future paid additions are a roadmap discussion, not a currently shipping Pro product.
This is an independent project, not an OpenAI product or endorsed by OpenAI.
Try the beta. Share what happened. Help us measure where it really helps.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Agentic workflow budget approvals with usage receipts.
Give your AI agent a spending limit: approval controls and single-use virtual cards.
Runtime permission, approval, and audit layer for AI agent tool execution.
Budget & cost control for AI agents — per-agent spend caps + rate limits before each call.
Related MCP Servers
- AlicenseAqualityAmaintenanceRuntime budget authority for autonomous agents - a set of tools to check, reserve, spend, and release budget before and after every costly, risky operation. The agent asks "can I afford this?" before acting, and reports what it actually used afterward.938Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables AI coding agents to set budgets per task, check costs before expensive operations, and halt when budget is exhausted, with support for calibration and cloud sync.4MIT
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to track LLM costs, enforce budgets, compare models, and estimate expenses through simple tool calls.-
- FlicenseNot gradedqualityDmaintenanceManages agentic workflow spend through budget quotes, policy gates, approvals, receipts, and cost evidence exports.-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/sulabhdubey/premium-model-budget-governor'
If you have feedback or need assistance with the MCP directory API, please join our Discord server