Glossary

What is an RL environment?

An RL environment is the practice space a reinforcement learning agent works in: a task, the actions allowed and a score.

By

Updated

Definition

An RL environment (reinforcement learning environment) is a program that gives an AI agent a task, accepts its actions, reports what changed and returns a reward scoring how well it did. The agent improves by repeating tasks and favouring actions that earned more reward.

How an RL environment works

Reinforcement learning trains by trial and error. The agent sees the current situation, chooses an action and receives a reward. The environment is everything on the other side of that exchange.

Gymnasium, the standard Python library for classic RL, captures it in two calls: reset starts an episode and returns the first observation, and step takes an action and returns the next observation, the reward, whether the task ended or was cut off, and diagnostic information.

Training repeats this loop over many episodes.

Actions, observations, episodes

Each environment also declares what actions are valid and what observations look like. In a simple game the actions might be left or right; for a language model agent they are tool calls, keystrokes or messages. An episode runs from reset until the task ends, and training repeats episodes many times.

RL environments for language model agents

Labs now use environments to teach models multistep work rather than games. TechCrunch described them in September 2025 as simulated workspaces, giving the example of an agent in a simulated Chrome browser rewarded for buying a suitable pair of socks on Amazon. One founder quoted there compared building them to making a very boring video game.

Taskset, runtime and harness

Prime Intellect defines an environment as the executable definition of a task: where each attempt starts, what the agent can do, when it stops and how the result is scored.

Its documentation separates the taskset (tasks, tools and scoring), the runtime where actions execute, such as a container or remote sandbox, and the harness that sets how the model sees its tools. It also stresses that the agent should not be able to see or change the scorer while it works.

Parts of an RL environment

Our breakdown, following the structure in Gymnasium and Prime Intellect's documentation.
PartWhat it isExample in a coding environmentWhat makes it worth paying for
TasksThe set of problems the agent is asked to solveBug reports or feature requests on a real projectRealistic, varied and hard enough that current models fail some
Starting stateThe world as it is when an attempt beginsA repository checked out at the commit before the fixFaithful to real conditions, reset cleanly every time
Actions and toolsWhat the agent may doRead files, edit code, run commands and testsClose to the tools a real worker would use
ScorerThe check that turns the end state into a rewardHidden tests that pass only if the bug is fixedHard to game: the reward should mean the task was really done
RuntimeWhere the actions are executedA container image with the project's dependenciesRuns reliably and in parallel at training scale

The scorer is the part that fails most often. A reward that can be earned without doing the task teaches the model to cheat, which researchers call reward hacking.

What AI labs buy, and how it's delivered

According to the TechCrunch report, the big labs build environments in-house and also buy them. Startups such as Mechanize, focused at first on coding environments, and established data firms including Surge, Mercor and Scale AI were all pitching them, while Prime Intellect launched a public hub for sharing them.

The same article cited The Information reporting that Anthropic leaders had discussed spending more than $1 billion on RL environments over the following year, and it quoted sceptics too, including warnings that environments are hard to scale and prone to reward hacking.

How it is delivered

Because an environment is software rather than a file, it is delivered as code: a package or module that loads tasks, a container image for the runtime, and the scoring logic, with documentation of how rewards are computed. A seller is licensing something closer to a test suite than a spreadsheet.

Where company data comes in

Environment builders need realistic tasks with checkable answers, and companies often hold the raw material: a retired product's code history with issues and the commits that fixed them, or records of business processes with known correct outcomes.

That material can be licensed to a builder or a lab who turns it into tasks and scorers. If you are thinking of selling a codebase for this purpose, estimate what the code itself is worth first, and keep a held-out portion as an evaluation dataset if the buyer wants one.

Where DataBroker fits

DataBroker doesn't build RL environments; that is specialist engineering. The academy covers finding companies that hold material environment builders want, such as codebases and task records, valuing it and licensing it to labs or builders, and the tools help with code valuation and privacy checks.

Sources

3 sources · checked Nov 9, 2026

  1. Gymnasium documentation: Envreset and step, the values step returns, action and observation spaces · Checked
  2. Prime Intellect: RL environmentsEnvironment as executable task definition; taskset, runtime and harness; hidden scorer · Checked
  3. TechCrunch: Silicon Valley bets big on environments to train AI agents (September 2025)Simulated workspaces, browser example, builders and buyers, reported $1 billion discussion, reward hacking concerns · Checked

RL environment FAQ

What is the difference between an RL environment and a dataset?

A dataset is a fixed set of examples the model reads. An environment is a program the model acts in: it reacts to each action and scores the result, so the model can try, fail and try again.

What is reward hacking?

When an agent finds a way to earn the reward without doing the intended task, such as editing a test so it passes. It is the main reason a well-built scorer matters more than the number of tasks.

What format are RL environments delivered in?

As code: typically a Python package that loads the tasks and scores results, plus a container image or sandbox setup for running the agent's actions, and documentation of the reward.

Can an RL environment also be used for evaluation?

Yes. The same tasks and scorer can test a model instead of training it, which is why builders often keep some tasks back for testing only.

Related

  • How to sell software you have built

    How to sell software you have built, whether that means the whole product, the IP, or licensing the codebase as training data.

  • Evaluation dataset

    An evaluation dataset tests a model on examples it has never seen, which is why good ones are scarce and labs pay for them.

  • LLM training data

    LLM training data comes in three kinds, for three stages of building a language model, and each raises different rights questions for sellers.

  • How AI companies get training data

    How do AI companies get training data? From five sources: web crawls, licensed archives, paid human work, synthetic data and their own users.

  • The codebase value calculator with 50,000 lines of code typed in at $100 an hour: an estimated rebuild cost of $2,218,060, 145.9 person-months of effort over 16.6 months with an average team of 8.8 people.
    Codebase value calculator

    A codebase value calculator that reads a public GitHub repository in your browser and estimates rebuild effort and cost with basic COCOMO.

Free tool

Try the codebase value calculator

A codebase value calculator estimates what it would cost to write a piece of software again, from its size in lines of code, an effort model such as COCOMO, and an hourly engineering cost.

  • Free
  • No sign-up
  • Runs in your browser