LoLBench / TypeScript_1 /README.md
lolbench26's picture
Publish LoLBench Harbor tasks from artifact branch
d0faac4 verified
|
Raw History Blame Contribute Delete
2.63 kB

LoLBench Harbor Task: TypeScript_1

This is a Harbor-format LoLBench task generated from TypeScript_Issue-47920_satisfies-operator-to-ensure-an-expression-matches-some-type-safe-upcast_PR-46827.

Selected source instance:

  • Harbor ID: TypeScript_1
  • PR: microsoft/TypeScript#46827
  • Base commit: 07157914eb26a6e9abdcda7255c4094c9efff4cd
  • Test modes: orig, aug, union
  • Default/canonical mode: union
  • Harbor image: smartdub26/lolbench-linux:TypeScript_1-1.0.0
  • Docker Hub image: smartdub26/lolbench-linux:TypeScript_1-1.0.0

Image Setup

Prefer the published Docker Hub image when it is available. Harbor refers to the image as smartdub26/lolbench-linux:TypeScript_1-1.0.0, so Docker can pull it directly when it is not present locally:

docker pull smartdub26/lolbench-linux:TypeScript_1-1.0.0

Only if the Docker Hub image is unavailable, build the single task image locally:

docker build -t lolbench/typescript_1:1.0.0 harbor_tasks/TypeScript_1/environment
docker tag lolbench/typescript_1:1.0.0 smartdub26/lolbench-linux:TypeScript_1-1.0.0

The image contains the processed source tree at the base commit under /workspace/typescript. Harbor must not mount a host source checkout for the agent.

Run an Agent

.harbor-venv/bin/harbor run \
  -p harbor_tasks/TypeScript_1 \
  -a codex \
  -m "<model>" \
  --job-name TypeScript_1_agent_union \
  --jobs-dir harbor_runs/TypeScript_1 \
  --no-delete \
  --n-concurrent 1 \
  --ve LOLBENCH_SUITE=union

After implementing the requirement, the agent must clean any test-file edits and run:

lolbench-submit

Evaluate a Patch

Choose one mode with LOLBENCH_SUITE=orig, aug, or union; if unset, the task defaults to union.

PATCH="$(pwd)/path/to/solution.patch"

.harbor-venv/bin/harbor run \
  -p harbor_tasks/TypeScript_1 \
  -a oracle \
  --job-name TypeScript_1_eval_union \
  --jobs-dir harbor_runs/TypeScript_1 \
  --no-delete \
  --n-concurrent 1 \
  --mounts '[{"type":"bind","source":"'"$PATCH"'","target":"/candidate/solution.patch","read_only":true}]' \
  --ae LOLBENCH_ORACLE_PATCH=/candidate/solution.patch \
  --ve LOLBENCH_SUITE=union

Outputs:

find harbor_runs/TypeScript_1/TypeScript_1_eval_union -path '*/verifier/agent_report.json' -print
find harbor_runs/TypeScript_1/TypeScript_1_eval_union -path '*/verifier/reward.json' -print

tests/docker-compose.yaml is a verifier-only Harbor overlay. It mounts tests/, tests/private/, and solution/ into the separate verifier container; none of those paths are mounted into the agent container.