Skip to main content

beaker

Beaker SDK and CLI package.

beaker gives developers the tools to define optimization specs, validate them locally, upload datasets, configure hosted run environments, launch optimization runs, and inspect results from code or the CLI.

Customer specs import contract types directly from beaker:

from beaker import Case, CaseDataLoader, CaseResult, CaseScore, Spec, spec

Hosted model-selection rollouts also expose a generic OpenAI-compatible target:

from beaker import RolloutContext, inference_target


def build_eval_client(runtime: RolloutContext):
    target = inference_target(runtime)
    return YourFrameworkClient(
        base_url=target.base_url,
        api_key=target.api_key,
        model=target.model,
    )

Call inference_target only in the evaluation path when runtime.model is set. Production application calls should retain the application's existing model and client defaults. The structural beaker run smoke check does not invoke this path.

CLI run lifecycle

Every command, the endpoint it calls, and who can run it are documented in docs/cli-reference.md.

The CLI is intentionally noninteractive: choose the remote GitHub branch, dataset, run type, and models before invoking it. Runs use the repository's GitHub default branch when --ref is omitted. --ref resolves a remote GitHub ref, so unpushed local changes are not included.

# Discover launch inputs.
beaker github branches --repo owner/repository
beaker model list --available-only

# Ordinary prompt optimization.
beaker run trigger --ref feature/prompts --dataset invoices@production

# Optimize the production system without an initial benchmark.
beaker run trigger --ref feature/prompts --dataset invoices \
  --execution-mode optimize_only

# Benchmark and optimize selected models.
beaker run trigger --ref feature/prompts --dataset invoices \
  --optimization-model openai:gpt-4o \
  --optimization-model anthropic:claude-sonnet-4-5 \
  --execution-mode benchmark_and_optimize --benchmark-split TEST

# Discover, inspect, and cancel runs.
beaker run list
beaker run status RUN_ID
beaker run status RUN_ID --watch
beaker run cancel RUN_ID

Lifecycle commands support stable JSON for automation:

beaker model list --json
beaker github branches --repo owner/repository --json
beaker run trigger --ref feature/prompts --dataset invoices --json
beaker run list --json
beaker run status RUN_ID --json
beaker run cancel RUN_ID --json

Release files for beaker-sdk 0.4.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for beaker-sdk 0.4.4
File Size Uploaded
beaker_sdk-0.4.4.tar.gz 194.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for beaker-sdk 0.4.4
File Interpreter ABI Platform
beaker_sdk-0.4.4-py3-none-any.whl Python 3 none any Details

Total release size: 421.8 kB

Release files / beaker_sdk-0.4.4.tar.gz

Download URL beaker_sdk-0.4.4.tar.gz
Size 194.6 kB
Tags Source
SHA-256 checksum
How to use checksums
1e1ba6997a658339711e7bb41aadc6db0587d93f1e7062fa6936c56f36d4e71d
BLAKE2b-256 checksum
How to use checksums
5bc9aa75b76187a1c71219c4d4491535934c8b962d7dd86b63041773246f3bd5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.9.4

Release files / beaker_sdk-0.4.4-py3-none-any.whl

Download URL beaker_sdk-0.4.4-py3-none-any.whl
Size 227.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
de3ba424f96efc01346b1bce5dbc0a42646f0f953568559ca852548943395f06
BLAKE2b-256 checksum
How to use checksums
5d37f6d3e1df7d857888863d685c308c6558d8b6022889737590900db75396f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.9.4

Release history Release notifications | RSS feed

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.9

2 release files

0.4.8

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

This release

0.4.4 This release

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.6

2 release files

0.3.5

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page