iwibench / README.md
chrisvoncsefalvay's picture
Add repository navigator and prominent links to tasks, rollouts and patches
7913224 verified
|
Raw History Blame Contribute Delete
13.9 kB
metadata
pretty_name: IWIBench
language:
  - en
  - es
  - fr
  - de
size_categories:
  - 1K<n<10K
task_categories:
  - reinforcement-learning
tags:
  - rl-environment
  - verifiers
  - reinforcement-learning
  - model-editing
  - weight-space-programming
license: mit
configs:
  - config_name: environments
    default: true
    data_files:
      - split: train
        path: data/train.parquet
      - split: test
        path: data/test.parquet
  - config_name: rollouts
    data_files:
      - split: rollouts
        path: rollouts/index.parquet

IWIBench

Chris von Csefalvay · Pranav Doma · Achyuthan Unni Krishnan · Tamás Földi
Robotics Intelligence CoE, HCLTech, Santa Clara, CA
Correspondence: Chris von Csefalvay

Project · Paper · Code · Prime Intellect environment · Verifiers

IWIBench is a reinforcement-learning environment for intraweight injection. An editor inspects and changes a target model's weights through four bounded tools. It submits a weight patch, which a separate service applies to the pinned checkpoint and evaluates in a fresh process.

This revision contains 1,000 baseline-qualified development tasks: exactly 100 distinct parameterizations in each of ten families, partitioned into 850 training and 150 test tasks (85/15 per family). A separate rollouts configuration exposes the 325 previously published editor episodes through its named rollouts split. Eligibility was measured on pristine Gemma 3 4B IT, with both model and tokenizer pinned to 093f9f388b31de276ce2de164bdc2081324b9767. Every selected task has measured prerequisite capability, target headroom, complete controls with a nonzero baseline-correct denominator, and an algebraic no-op check.

The qualified catalogue is baseline-qualified-v1. The original development-combinations-v1 catalogue, native seed episodes and historical result files remain available. The qualified catalogue is specific to the 4B target; the original environment also supports Gemma 3 1B IT.

Find what you need

Collection Start here
Environment tasks Load the 850 training and 150 test tasks
Published editor runs Browse 325 rollouts by model and reasoning effort
Traces, inputs, outputs and weight patches File-by-file guide
Protocols, source facts and earlier releases Repository navigator

Task families

Family Objective
Alias acquisition Give an existing token the meaning of a familiar concept.
Output-code remapping Return seeded labels for a classification task.
Lexical inhibition Preserve the required facts while avoiding selected words and their variants.
Terminology preference Prefer selected British or American forms.
Default response language Answer in the selected language unless instructed otherwise.
Structured response default Extract fields into a shallow JSON object with seeded keys.
Answer-length control Keep complete answers within the selected word band.
Local factual update Replace one stale factual association.
Selective factual withholding Abstain from answering one designated association.
Resistance to false suggestions Preserve correct answers despite confident wrong suggestions.

Every episode also checks preservation of other capabilities, including 64 general controls. The four editor tools are read_weights, write_weights, run_target and inspect_target. An episode permits 64 editor turns, 128 tool calls and 262,144 target forward tokens.

Installation

Use Python 3.11–3.14. Target execution requires CUDA and access to the gated Gemma checkpoints.

Download this repository, then install the included environment package:

python -m pip install 'huggingface-hub==0.36.2'
from huggingface_hub import snapshot_download

snapshot_download(
    "hcltech-robotics/iwibench",
    repo_type="dataset",
    local_dir="iwibench",
)
cd iwibench
python -m pip install '.[gpu,prime,dataset,test]'

The package pins compatible versions of Verifiers v1 and the dataset loader. The run configuration selects the 850 training tasks.

Load tasks

from datasets import load_dataset
from iwibench.variants import task_from_row

tasks = load_dataset("hcltech-robotics/iwibench", "environments")
assert len(tasks["train"]) == 850 and len(tasks["test"]) == 150
task = task_from_row(tasks["train"][0], service_url="http://127.0.0.1:8768")

rollouts = load_dataset("hcltech-robotics/iwibench", "rollouts", split="rollouts")
assert len(rollouts) == 325

Each row contains the objective, task parameters, public practice items, checkpoint revision and catalogue index. Parameters and practice items are stored as JSON strings. See the schema for the field definitions and the adapter source for the native Verifiers task interface.

To load the 850 training tasks directly through Verifiers:

from iwibench.taskset import IWIBenchConfig, IWIBenchTaskset

config = IWIBenchConfig(model_id="google/gemma-3-4b-it", variant_limit=100,
                       variant_catalog="baseline-qualified-v1", dataset_partition="train")
tasks = list(IWIBenchTaskset(config))

Use dataset_partition="test" for the 150 test tasks, or "all" for the original 1,000-task catalogue. Stable source IDs, original catalogue indices, task parameters and episode hashes are unchanged; partitions do not reseed or renumber tasks. The row field split="development" identifies its original scientific pool and is distinct from the HF train/test partition.

Use variant_catalog="development-combinations-v1" for the original uncalibrated catalogue, including the 1B target. Qualified rows reject target substitution. Pin the Hub revision when reproducing an experiment.

Run the environment

Configure distinct IWIBENCH_ADMIN_TOKEN and IWIBENCH_EDITOR_TOKEN values, then start the target service:

python -m iwibench.service --model google/gemma-3-4b-it --output-dir runs/target

For qualified sessions, configure OPENAI_API_KEY for the pinned gpt-6.1-terra semantic judge at the official Responses API. The service stores a durable request/response cache in its output directory. Original native sessions retain their existing deterministic checker path. Semantic judging has usage costs; no editor rollout or edited-model score was run as part of this calibration release.

Set IWIBENCH_SERVICE_URL if the worker is not at http://127.0.0.1:8768. With the editor proxy and its API credentials configured, check the native run configuration before launching an evaluation:

vf-run iwibench @ configs/variants.toml --dry-run

The project's evaluation instructions describe editor-proxy setup. The environment uses the null harness and a trusted subprocess tool runtime. The service owns the weights, budgets and terminal grading inputs; the editor's final reply submits its current patch.

Reward combines improvement on the target behaviour with retention of answers the unedited model gave correctly:

gain = max(0, (edited_target_success - base_target_success)
              / (1 - base_target_success))
reward = gain * control_retention

Partition and rollout provenance

calibrated-stratified-v1 groups equivalent whole-task parameters and selects 15 rows per family by a fixed SHA256 ranking. Known historical-rollout equivalents are excluded from test and remain in train. The 150 test rows are disjoint from train by task ID, exact parameter digest, episode digest and meaningful whole-task digest. The comparison covers all 325 archived episodes, with 48 public-objective task witnesses. It does not claim that component facts or controls are disjoint: those are intentionally shared by benchmark families.

This test split is a task-level holdout from an already-calibrated development dataset. The target model and semantic checker were used to admit all 1,000 tasks before partitioning. It is not fresh unseen-model evaluation, an unseen-knowledge test or a new benchmark-score claim. Partition membership and audit records the fixed inputs and grouping method; historical overlap lineage identifies the archive witnesses.

The original calibrated 1,000-row train-only release remains reproducible at revision 1719bf64e40edc79eb27a08b20765717e81f9b99. The original compressed rollout snapshots remain accessible at immutable revision 7d9458274eb705857090a3c1366fca344e9ba753; the current tree contains unpacked per-model/per-reasoning rollout folders and their recorded service trajectories. Rollout records retain their own historical task/grader versions and published scores; they are not Terra-regraded or claimed to be calibrated task rows. Their index has a separate schema, so the rollouts split lives in the rollouts config; the default environments config contains train/test task rows. task_from_row accepts task rows, not rollout index rows.

Each rollout index record points to a browsable model/reasoning/rollout folder containing readable full-rollout JSONL, byte-identical native JSONL and the actual submitted patch pair. Source shard/member pointers are explicitly revision-pinned historical lineage. The 297 existing standalone service trajectories are unpacked; 28 zero-admitted-call episodes truthfully have no generated standalone file. Four complete experiment protocols are retained under rollouts/provenance/protocols/; all 325 original CSV row dictionaries remain in the index. Full-message conversion is structurally lossless, with original byte hashes, trace selectors and source-CSV lineage preserved. Superseded compressed containers and published-source copies have been removed from the current tree; immutable source repositories and Git history are preserved. See rollout documentation and patch terms: the repository's MIT label does not relicense Gemma-derived replacement weights. Unknown metadata remains null. No new editor or model inference is used to make these splits.

Baseline calibration

The semantic calibration uses gpt-6.1-terra with explicit per-fact verdicts and evidence quotations. Vocabulary and lexical predicates use terra-semantic-v1.3; five unaffected semantic predicates retain their exact terra-semantic-v1.1 request and verdict provenance. Exact copying, labels, numeric fields, chemical-symbol case, JSON schema, word bands, spelling, banned words and native alias tokenization remain deterministic. Required facts, length directions, stable stale-answer admission and target headroom were preserved. Historical editor scores were not regraded.

The v1.3 vocabulary rubric passed 113 live judge fixtures, including all 50 vocabulary concepts, valid paraphrases, defining-qualifier omissions, wrong bindings, negation, contradiction and instruction injection. The earlier broad-anchorage false positive and canonical-neighbor/license false negatives are covered. These are checker tests, not target-calibration examples. The calibration summary records the measured evidence and exact rubric hashes.

Baseline generation used greedy native decoding, batches of eight and a maximum of 256 new tokens. Factual answers use the fixed reference date 2026-03-01. Additional genuine parameter combinations and source-verified factual associations replaced exclusions; separate historical people remain distinct stale groups, and the same association is never counted twice. The final selection prefers original catalogue survivors, then sorts by source episode ID and caps each family at 100.

All selected episodes regenerate with the exact SHA256 identity measured during calibration. Terminal controls were evaluated individually; their retention mask includes only answers the pristine baseline got right. Applying the scorer to identical measured pristine outputs gave gain 0, reward 0 and retention 1 where defined. This algebraic no-op is not a second independent model inference.

The included runtime uses the pinned semantic checker only for qualified catalogue sessions and keeps exact checks separate. Catalogue regeneration, native Verifiers task loading, scoped service wiring and cached verdict replay are tested in software. Live Terra fixtures and pristine baseline measurements are separate evidence; a paid editor rollout and edited-model runtime grading have not been validated here. Judge credentials, raw completions, per-item grading masks and assembled terminal exports are not included. Trusted builders regenerate terminal items at runtime.

Reproduce the dataset

python scripts/build_hf_dataset.py --qualified --output-dir /tmp/iwibench-rebuilt
python scripts/validate_hf_dataset.py /tmp/iwibench-rebuilt

The methods and verification report records the parameter pools, source revisions, split design and validation results. Fact provenance and other pool sources document the underlying data.

IWIBench code and original dataset material are licensed under MIT. The third-party notices cover GeoNames-derived records and target model terms.