Skip to content
RehearsalDocs

Configuration

Every setting that Rehearsal reads from the environment, with its default and what it changes.

Rehearsal reads its settings from environment variables. A server also reads a file named .env in the folder it starts in, and a value in the real environment wins over the file. With Docker Compose, the settings are in infra/deploy.env: see Install with Docker Compose.

A person who only uses a server needs the first section. The rest is for the person who runs one.

Client

SettingDefaultWhat it changes
REHEARSAL_URLhttps://rehearsalkit.xyzThe server that the CLI, the Python client and the MCP server talk to. It takes precedence over a saved sign-in.
REHEARSAL_API_KEYThe key they use. It takes precedence over a saved sign-in.
REHEARSAL_CONFIG~/.config/rehearsal/config.jsonWhere rehearsal login saves the sign-in.
REHEARSAL_DEBUGSet it to anything to make the CLI log each HTTP request.

Database and files

SettingDefaultWhat it changes
REHEARSAL_DATABASE_URLa local PostgreSQL on port 5433The PostgreSQL database, as postgresql+psycopg://user:password@host:port/database.
REHEARSAL_DB_POOL_SIZE10Connections that each process keeps open.
REHEARSAL_DB_MAX_OVERFLOW20Extra connections that each process may open under load. A managed database limits the total of all processes.
REHEARSAL_DATA_DIR./varThe folder for application sources, world snapshots and exported files. The API and every worker must see the same folder.
REHEARSAL_SOURCE_ROOTS./examplesFolders, separated by commas, that an application may name as a local source.
REHEARSAL_DOWNLOADS_DIRdownloads in the data folderA folder that the server offers at /downloads, for the client package.
REHEARSAL_ENV_FILE.envA file of settings to read at start. A value in the real environment wins over the file.
REHEARSAL_LIBRARY_PROJECTA project whose published worlds form the world library: every workspace can rehearse agents on them and make agents for them, without building. Their held-out jobs are shown by title only.

Sign-in

SettingDefaultWhat it changes
REHEARSAL_SESSION_SECRETa development valueSigns browser sessions. Set a long random value on any server that others can reach.
REHEARSAL_SIGNUPopenAny visitor can create an account and an organisation. closed turns that off.
GOOGLE_CLIENT_IDA Google OAuth web client id. With it, the console offers "Sign in with Google".
REHEARSAL_ADMIN_EMAILSOperator admins, separated by commas. They see every workspace and can set any plan. Only a sign-in with Google counts.
REHEARSAL_PUBLIC_URLhttp://localhost:7800Where browsers reach the server. Payment pages return here.
REHEARSAL_DOCS_URLThe documentation site. /docs on the server redirects there; without it, /docs opens the API reference at /api/docs.

Models

SettingDefaultWhat it changes
REHEARSAL_MODEL_COMPILERNemotron 3 Super, thinking on, then UltraThe model chain for the World Compiler's tool-heavy roles: inspecting the source, building the runtime, seeding data, writing tools.
REHEARSAL_MODEL_REASONERNemotron 3 Ultra, thinking on, then SuperThe model chain for the World Compiler's hardest roles: designing jobs, judging failed validations, and repairing a runtime that will not start.
REHEARSAL_MODEL_AGENTNemotron 3 Super, thinking on, then UltraThe model chain for agents that have no model of their own.
REHEARSAL_MODEL_PARTICIPANTNemotron 3 Nano, thinking off, then SuperThe model chain that plays the simulated customer.
REHEARSAL_MODEL_IMPROVERthe reasoner's chainThe model chain that proposes a better agent.
REHEARSAL_PRICES{}Prices for models whose provider reports none: JSON of provider:model to [input, output] in US dollars for a million tokens.
REHEARSAL_PRICING_FILEpricing.yamlA file of the same prices, each with its source and date.

Model chains

A chain is a list of provider:model, separated by commas. The server tries them in order, and moves to the next when a provider fails or has no key. An empty setting means the default. An entry may end in #think or #nothink to switch a reasoning model's thinking on or off for that entry only; NVIDIA Nemotron models read it.

REHEARSAL_MODEL_PARTICIPANT=nebius:nvidia/NVIDIA-Nemotron-3-Nano-30B-A3B#nothink,groq:openai/gpt-oss-20b

Providers

A provider works when its key is set. Every provider is reached through an OpenAI-compatible API. A job starts only when the server knows the price of its models, so that spending limits hold.

ProviderKeyAddressPrices
nebiusNEBIUS_API_KEYhttps://api.tokenfactory.nebius.com/v1its own price list
openrouterOPENROUTER_API_KEYhttps://openrouter.ai/api/v1its own price list
groqGROQ_API_KEYhttps://api.groq.com/openai/v1this host's price, from OpenRouter's host listing
googleGOOGLE_API_KEYhttps://generativelanguage.googleapis.com/v1beta/openai/the vendor's price, as OpenRouter lists it
openaiOPENAI_API_KEYhttps://api.openai.com/v1the vendor's price, as OpenRouter lists it
anthropicANTHROPIC_API_KEYhttps://api.anthropic.com/v1/the vendor's price, as OpenRouter lists it
mistralMISTRAL_API_KEYhttps://api.mistral.ai/v1the vendor's price, as OpenRouter lists it
xaiXAI_API_KEYhttps://api.x.ai/v1the vendor's price, as OpenRouter lists it
deepseekDEEPSEEK_API_KEYhttps://api.deepseek.com/v1the vendor's price, as OpenRouter lists it
togetherTOGETHER_API_KEYhttps://api.together.xyz/v1this host's price, from OpenRouter's host listing
fireworksFIREWORKS_API_KEYhttps://api.fireworks.ai/inference/v1this host's price, from OpenRouter's host listing
cerebrasCEREBRAS_API_KEYhttps://api.cerebras.ai/v1this host's price, from OpenRouter's host listing
nvidiaNVIDIA_API_KEYhttps://integrate.api.nvidia.com/v1pricing.yaml or REHEARSAL_PRICES
litellmLITELLM_API_KEYLITELLM_BASE_URLits own price list
modalMODAL_PROXY_TOKEN_ID and MODAL_PROXY_TOKEN_SECRETMODAL_BASE_URLpricing.yaml or REHEARSAL_PRICES
localREHEARSAL_LOCAL_API_KEYREHEARSAL_LOCAL_BASE_URLpricing.yaml or REHEARSAL_PRICES
customREHEARSAL_CUSTOM_API_KEYREHEARSAL_CUSTOM_BASE_URLpricing.yaml or REHEARSAL_PRICES

local is for a model server on your own machine, such as vLLM. custom is for any other OpenAI-compatible address. When a provider's source has no price for a model, add one to pricing.yaml or REHEARSAL_PRICES. rehearsal prices shows the price the server uses for each configured model.

Web research

SettingDefaultWhat it changes
TAVILY_API_KEYA Tavily key. With it, each world build first researches how real people use the application (its documentation, forums and issue trackers) and bases at least half its jobs on what it finds, citing the pages. Without it, that step is skipped. See Build a practice world.

Workers and sandboxes

SettingDefaultWhat it changes
REHEARSAL_ALLOW_PRIVATE_AGENT_URLSoffon lets agent profiles name an endpoint on a private network or over plain http. Leave it off on any server others use: workers would call whatever address a profile names.
REHEARSAL_RUN_PARALLEL4Into how many parts a run is cut. Each part needs one free worker and one sandbox.
REHEARSAL_BUILD_PARALLEL4How many jobs a build writes and validates at once. Each one being validated runs its own copy of the world.
REHEARSAL_MAX_ACTIVE_BUILDS0, no limitBuilds that one project may have in progress.
REHEARSAL_MAX_ACTIVE_RUNS0, no limitRuns that one project may have in progress.
REHEARSAL_CONTAINER_MEMORY1gThe memory limit of each container in a sandbox.
REHEARSAL_CONTAINER_CPUS1.0The processor limit of each container in a sandbox.
REHEARSAL_CONTAINER_PIDS256The process limit of each container in a sandbox.
REHEARSAL_LEASE_SECONDS60How long a worker's claim on a server job lasts without a renewal. After that, another worker takes the job.
REHEARSAL_WORKER_CONTAINERThe worker's own container id, when the worker runs in a container. The Compose file sets it.

Spend and plans

SettingDefaultWhat it changes
REHEARSAL_MONTHLY_ALLOWANCE_USD0, no limitA model spend limit for the whole server, for a calendar month. It applies when plans are off.
REHEARSAL_PLANSoffon puts every workspace on a plan and enforces its limits. Leave it off on a private server.
REHEARSAL_QUIET_HOURS_UTC18:00-02:00When evaluations of the Free plan may start, as HH:MM-HH:MM in UTC. It may cross midnight.
DODO_PAYMENTS_API_KEYThe payment provider's key. Only with plans on.
DODO_PAYMENTS_WEBHOOK_KEYThe secret that signs the payment provider's notifications.
DODO_PAYMENTS_ENVIRONMENTtest_modetest_mode or live_mode.
DODO_PRODUCT_*The payment provider's product id for each thing that can be bought: PRO_MONTHLY, PRO_YEARLY, TEAM_MONTHLY, TEAM_YEARLY, EPISODES_1000, BUILD_1.

Training

SettingDefaultWhat it changes
KAGGLE_API_TOKENFor training, which is not built yet.
Generated from the code of rehearsal-kit 0.1.4.

Was this page helpful?

On this page

Was this page helpful?