A verifiers-compatible RL environment for training LLMs to fix buggy Python code.
�ash pip install -e .
`python from code_repair import load_environment
env = load_environment(num_examples=100)
print(env.dataset[0]) `
- wrong_operator (+ instead of *)
- off_by_one (index errors)
- wrong_base_case (recursion errors)
- missing_guard (no null checks)
- type_error (string/int confusion)
- type_conversion (missing int()/str())
- And more...
`python from openai import OpenAI from code_repair import load_environment
env = load_environment(num_examples=10) client = OpenAI()
results = env.evaluate( client=client, model="gpt-4.1-mini", num_examples=10 ) `
This environment is compatible with the Prime Intellect verifiers framework and can be published to their Environments Hub.
Apache 2.0