← Back to Leaderboard
OOptim-Agent

Optim-Agent/optim-agent

A Python framework that uses coding-agent CLIs to tune bounded parameters

Engineering Health (Methodology)
B · 58/100
Maintenance Activity
● Updated 3mo ago
Latest Release
0.1.1
Commercial License Check
MIT · Commercial Friendly

Automated SPDX check for reference only — not legal advice. Disclaimer

Maintenance12/35
Fork Adoption12/25
Release Cadence14/20
License Clarity20/20
MCPCLI
Total Stars
★ 798
24h Growth
+0
7d Growth
+0
Forks
44

GitHub Star History

Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.

Optim-Agent/optim-agent Star History (2026-07-12 - 2026-12-04) ALL-TIME STAR HISTORY (2026-07 – 2026-12) +797 in 145d · avg +5/day 843 422 0 2026-07-12: ★ 12026-07-25: ★ 3602026-08-08: ★ 6932026-08-22: ★ 7792026-09-05: ★ 7822026-09-19: ★ 7852026-10-03: ★ 7882026-10-17: ★ 7912026-10-31: ★ 7952026-11-09: ★ 7962026-11-18: ★ 7962026-11-27: ★ 7982026-12-04: ★ 798 ★ 798 07-12 09-22 12-04

Evidence-Backed Technical Brief

AI Deep Review

Architecture & Core Mechanics

optim-agent is a Python framework for black-box optimization. A caller defines a scalar objective and declares parameter bounds through trial.suggest_* calls. AgentSampler uses parameter descriptions, study context, and measured trial history to ask a coding-agent CLI for the next configuration. The harness checks values against the declared space and falls back to sampling if the response is invalid. The evaluator's measured result, not the agent's explanation, determines the best trial.

create_study configures direction, sampler, optional persistence, and optional summarization; study.optimize runs the evaluations. JSON and SQLite store trial configurations, outcomes, states, context, and optional rationale. The package uses setuptools.build_meta with setuptools>=77.0.3 as its build backend. The concrete integration path is through CLI backends and host plugins or skills; an MCP deployment should not be assumed without a documented server entrypoint or transport.

Key Capabilities & Differentiators

The sampler supports bounded continuous, integer, and categorical parameters, with study-wide and per-parameter context. Claude Code, Codex, and OpenCode are supported backends. effort is forwarded to the backend CLI, while the history window and optional rationale and notes shape the prompt and response. history=None exposes all completed or pruned trials rather than limiting the history window.

In the 10-trial, five-seed classification benchmark, contextual GPT-5.5 reached a cumulative best-so-far error of 5.668 on MNIST versus 7.166 for Optuna TPE, and 220.994 on CIFAR-10 versus 278.920 for random sampling. Without context, GPT-5.5 scored 8.910 and 281.466, respectively. The benchmark notes that the contextual comparison also includes earlier access to agent-guided proposals, so the gap does not isolate the effect of parameter descriptions alone.

Trade-offs & Limitations

Choose this over an ordinary sampler when parameters have useful semantics and each evaluation is expensive enough to justify an additional agent call. Optuna TPE and random search are better starting points when evaluations are cheap, the parameter names convey little, or you want to avoid model latency, cost, and version drift. A fair comparison should report both best objective at a fixed trial budget and wall time and model spend; fewer evaluations are not necessarily cheaper overall.

Treat the benchmarks as adoption signals, not a universal ranking. In the credit benchmark, contextual GPT-5.5 and TPE both show test log loss of 0.422 at the reported precision; the retained configuration was selected using both validation and test loss, so this is not an untouched estimate of generalization. Bounds checking protects the declared search space, not the host or confidential inputs. Review CLI permissions and data handling separately from the package's MIT license.

Hardware & Deployment Guide

The package requires Python 3.9 or newer. Install it with python -m pip install optim-agent, or use the GitHub source install to test a newer revision. For AgentSampler, put one authenticated claude, codex, or opencode executable on PATH. The objective runs in your Python environment; whether agent calls leave your infrastructure depends on the CLI and model configuration. Local study storage does not make the full workflow offline. Size CPU, GPU, and memory for the evaluator, any local inference, and the planned concurrency.

Release 0.1.1 added ready-to-install Claude Code and Codex integrations, sampler prompt controls, and explicit development and optional vision dependency groups. The supplied source manifest lists 0.2.0 and classifies the project as alpha, while the listed release is 0.1.1. Pin a tested package version or source revision, and check that the matching integration exposes the options you intend to use.

Execution boundary: AgentSampler proposes parameter values; the harness validates them and falls back to sampling on invalid replies.
Search space: Define-by-run trials support continuous, integer, and categorical parameters; the quickstart demonstrates log-scaled integer sampling.
Backend controls: Claude Code, Codex, and OpenCode are CLI backends; reasoning effort, visible trial history, explicit reasoning, and qualitative notes are configurable.
Study records: JSON or SQLite persistence retains configurations, scores, states, context, and optional rationale for inspection and resumption.
Benchmark design: The image-classification study compares contextual and no-context GPT-5.5 runs against random sampling and Optuna TPE over 10 trials and five seeds.
Distribution: PyPI package, Claude Code plugin, and Codex skill; release 0.1.1 added ready-to-install integrations and prompt controls.
Best For

Teams with an existing evaluator, meaningful parameter descriptions, and a tight trial budget for training, serving, or simulation experiments.

Skip If

You need deterministic offline proposals, your evaluations are too cheap to justify a model call, or your security policy rules out the available agent backends.

Reviewed on 2026-12-04 · Grounded in GitHub README, root file tree & releasesMethodology

Quick Start & Installation

MCPCLI
pip install -e ".[examples]"
pytest                     # runs tests/test_optim_agent.py

Comparison vs. Top Agents & Frameworks Alternatives

Full comparison →
RepositoryStars7d TrendStackLicenseCore Positioning
optim-agent ★798—PythonMITA Python framework that uses coding-agent CLIs to tune bounded parameters
agno43.4k+66PythonApache-2.0Python framework and runtime for durable agent services over REST and MCP
browser-use122.7k+477PythonMITPython REPL and CDP for adaptive browser automation
langgraph45.8k+293PythonMITPython graph orchestration for stateful, resumable agents and workflows

AI Context Briefing (for Claude / Cursor / Windsurf)

Standardized architecture summary & quickstart commands ready to paste into coding agents.

Raw .md ↗
curl -sL https://repoforai.com/repo/Optim-Agent/optim-agent.md

Embed Star History Chart & Badges in README.md

Full-history Star History SVGs and velocity cards on GitHub Camo: drop-in replacement for OSSInsight and Star History widgets.

Optim-Agent/optim-agent Star History on RepoForAI

Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).

Frequently Asked Questions about optim-agent

How do I integrate optim-agent with an existing evaluator?

Wrap your evaluator in an objective function, declare parameters with trial.suggest_float or trial.suggest_int, and return a measured score. Set the optimization direction in create_study and call study.optimize. Add study or per-parameter context when it explains a real constraint or interaction. AgentSampler proposes configurations; your evaluator still runs the workload and determines the score.

What hardware do I need, and where does runtime overhead come from?

The Python harness has no documented fixed GPU or VRAM requirement. Size the machine for the objective workload and any model you choose to run locally. The Q-learning and gradient-boosting benchmarks are CPU-only; that does not establish sizing for vision training or local model inference. Track proposal latency separately from evaluation time, and measure both before increasing concurrency.

Can I use this commercially and keep experiment data on my own infrastructure?

The package is MIT-licensed, which permits commercial use subject to preserving the applicable copyright and license notices. You can run the Python evaluator and study storage on your own infrastructure, but that does not make model inference local. Verify the backend's terms, data handling, and permissions before sending code context or trial records to it.

When should I choose this over Optuna TPE or random search?

Start with Optuna TPE and random sampling as controls. Add optim-agent when evaluations are expensive and you can explain meaningful parameter relationships. Use the same search space, evaluator, and trial budget across methods, then report wall time and model costs as well. The image-classification results show why context matters: the contextual agent led both comparisons, while the no-context arm lost to the strongest baseline on cumulative error in each dataset.

Upstream README & Documentation

This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.

Maintaining Optim-Agent/optim-agent? Pin to Homepage + competitor /alternatives pages with a custom Cloud/Demo CTA.Feature Optim-Agent/optim-agent on Homepage & Alternatives ($19)
WEEKLY BREAKOUT DIGEST

Top 10 Breakout Open-Source AI Repos, Every Thursday

Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.

Zero spam · 1-click unsubscribe · Privacy Policy

Saved in your browser · Export Markdown RFC tables or jump into /vs compare