Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,9 @@
!src/
!src/eval_tools/
!src/eval_tools/**
# The TileLens image's startup control runs the lane's concrete bounds check.
!src/tools/
!src/tools/arena_eval/
!src/tools/arena_eval/sanitize.py
**/__pycache__/
**/*.py[cod]
9 changes: 6 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,12 @@ prompt/post-processing routing, configuration, docs, and tests. A
`src/module_registration.py` as the registry source of truth.

Evaluation tools belong to the trusted evaluator control plane, not to agent
skills or prompts. Keep them opt-in, isolated, capability-checked, attested, and
fail-closed as described in `docs/how-to/use-evaluation-tools.md`. Do not claim
that a candidate was analyzed merely because a tool exists or its sidecar ran.
skills or prompts. Keep them isolated, capability-checked, attested, and
fail-closed as described in `docs/how-to/use-evaluation-tools.md`. Schema-v3
runs enable the default set in `src/eval_tools/defaults.py`; a tool joins it
only after its positive controls and a baseline campaign pass on hardware, and
anything else stays opt-in. Do not claim that a candidate was analyzed merely
because a tool exists or its sidecar ran.

## Verification guide

Expand Down
13 changes: 13 additions & 0 deletions docker/eval-tools/csan/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
ARG BASE_IMAGE=lmsysorg/sglang:v0.5.20-rocm10-mi35x@sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69
FROM ${BASE_IMAGE}

LABEL org.opencontainers.image.title="AgentKernelArena PyTorch CUDA Sanitizer tool runtime" \
org.opencontainers.image.base.digest="sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69"

# CSAN ships with the base image's PyTorch (torch.cuda._sanitizer).
RUN python -c "import torch.cuda._sanitizer as s; assert callable(s.enable_cuda_sanitizer)"

COPY src/eval_tools /opt/aka-eval-tools/src/eval_tools

ENV AKA_EVAL_TOOL_FRAMEWORK_ROOT=/opt/aka-eval-tools \
PYTHONPATH=/opt/aka-eval-tools
12 changes: 12 additions & 0 deletions docker/eval-tools/page-fault-guard/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ARG BASE_IMAGE=lmsysorg/sglang:v0.5.20-rocm10-mi35x@sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69
FROM ${BASE_IMAGE}

LABEL org.opencontainers.image.title="AgentKernelArena page-fault guard tool runtime" \
org.opencontainers.image.base.digest="sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69"

# The guard needs nothing beyond the scoring base: it reruns correctness with
# PyTorch's caching allocator and ROCr's fragment allocator turned off.
COPY src/eval_tools /opt/aka-eval-tools/src/eval_tools

ENV AKA_EVAL_TOOL_FRAMEWORK_ROOT=/opt/aka-eval-tools \
PYTHONPATH=/opt/aka-eval-tools
24 changes: 24 additions & 0 deletions docker/eval-tools/tilelens/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
ARG BASE_IMAGE=lmsysorg/sglang:v0.5.20-rocm10-mi35x@sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69
FROM ${BASE_IMAGE}

LABEL org.opencontainers.image.title="AgentKernelArena TileLens tool runtime" \
org.opencontainers.image.base.digest="sha256:e20849665c105d389ef91d23c0dc73931aaa6f02056dd10e7b43e4f16c79df69" \
org.opencontainers.image.version="tilelens-3.1.1"

# TileLens lives beside, not inside, the base environment: only the sanitizer
# lane puts /opt/tilelens/site-packages on its import path.
COPY docker/eval-tools/tilelens/requirements.lock /opt/tilelens/requirements.lock
RUN /opt/venv/bin/python -m pip install --no-cache-dir --no-deps --require-hashes --only-binary=:all: \
--target /opt/tilelens/site-packages -r /opt/tilelens/requirements.lock \
&& PYTHONPATH=/opt/tilelens/site-packages /opt/venv/bin/python -c \
"import tilelens, z3; from tilelens.clients import Sanitizer; print('tilelens', z3.get_version_string())"

COPY src/eval_tools /opt/aka-eval-tools/src/eval_tools
# The startup control exercises the lane's concrete bounds check, which
# confirms a TileLens finding before it counts.
COPY src/tools/arena_eval/sanitize.py /opt/aka-eval-tools/src/tools/arena_eval/sanitize.py

ENV AKA_EVAL_TOOL_FRAMEWORK_ROOT=/opt/aka-eval-tools \
PYTHONPATH=/opt/aka-eval-tools \
AKA_TILELENS_ROOT=/opt/tilelens/site-packages \
AKA_TILELENS_VERSION=3.1.1
10 changes: 10 additions & 0 deletions docker/eval-tools/tilelens/requirements.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# TileLens and the modules its sanitizer imports, installed with --no-deps
# into /opt/tilelens/site-packages: the base image's PyTorch, Triton and NumPy
# stay authoritative. Hashes are the PyPI wheels for CPython 3.12 / x86_64.
tilelens==3.1.1 --hash=sha256:25f281f3fd7df260fe0689162d550a747b8cbb264b0e6107ce415b746a9bc9a7
z3-solver==4.15.3.0 --hash=sha256:a9afd9ceb290482097474d43f08415bcc1874f433189d1449f6c1508e9c68384
anytree==2.13.0 --hash=sha256:4cbcf10df36b1f1cba131b7e487ff3edafc9d6e932a3c70071b5b768bab901ff
tqdm==4.70.1 --hash=sha256:c293e525e6fef9c20e8728fd4612df02a0aa31bb5fe91ecd93e123b1b7bffa73
ml-dtypes==0.6.0 --hash=sha256:3b4a480aa8fd54a1805b8ac10f3f91763926a74f73c0c364c10f9231854f4170
pyarrow==26.0.1 --hash=sha256:c718bf97a92a6dea97fd1062c3b9f9e2e83cb9cc926e752289fa4ffff41738f9
flask==3.1.3 --hash=sha256:f4bcbefc124291925f1a26446da31a5178f9483862233b23c0c96a20701f670c
8 changes: 8 additions & 0 deletions docs/how-to/add-task.md
Original file line number Diff line number Diff line change
Expand Up @@ -359,6 +359,14 @@ python3 -m _aka_eval.evaluate candidate {compile|correctness|performance}
- **Scoring.** The per-case speedup is baseline time over candidate time; the
task's speedup is their geometric mean. Any failed correctness case scores 0.
The final evaluation remeasures the baseline next to the candidate.
- **Sanitizers.** On MI355X the final evaluation also runs the default
sanitizers between correctness and performance (see
[Default sanitizers for schema-v3 tasks](use-evaluation-tools.md#default-sanitizers-for-schema-v3-tasks)).
A gate's definite finding stops performance, so the candidate scores 0,
unless the baseline shares it. Keep the baseline clean in every lane: a
finding the baseline shares leaves that lane unable to protect the task.
The framework runs `python3 -m _aka_eval.evaluate {baseline|candidate}
sanitize LANE` itself.

## Run configuration

Expand Down
12 changes: 7 additions & 5 deletions docs/how-to/run-evaluation.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ ships quickstarts and specialized examples, including:
| `example_configs/quickstart_claude_mi300a.yaml` | Claude Code RMSNorm task with the MI300A hardware profile (`gfx942`). |
| `example_configs/quickstart_claude_mi355x.yaml` | One Claude Code RMSNorm task on MI355X (`gfx950`). |
| `example_configs/benchmark_cursor_mi355x.yaml` | Cursor Agent over a whole task category on MI355X; use only after installing and authenticating Cursor Agent. |
| `example_configs/evaluation_tools_advisory_mi355x.yaml` | Default-disabled template for experimental `gfx950` evaluation-tool sidecars. It still requires task-specific adapters before opt-in. |
| `example_configs/evaluation_tools_advisory_mi355x.yaml` | Template with an explicit, disabled `evaluation_tools` section for task-declared adapters on `gfx950`. Schema-v3 runs need no section: the default sanitizers run without one. |
| `example_configs/qa_audit_all_mi355x.yaml` | [QA audit](qa-auditor.md) of every task on MI355X. |
| `example_configs/e2e_*_qa_mi355x.yaml` | QA audit of an end-to-end serving task. |

Expand Down Expand Up @@ -128,10 +128,12 @@ is missing fails the run before it starts. See the
See [Configuration and API reference](../reference/api-reference.md) for the full
set of run-configuration fields.

Optional sanitizer and analysis sidecars run after ordinary correctness and
before performance. They are disabled by default, verified only on `gfx950`,
and require language/task-specific adapters. See [Check kernels with evaluation
tools](use-evaluation-tools.md) before enabling them.
Sanitizer sidecars run after ordinary correctness and before performance. On
MI355X (`gfx950`) a run configuration without an `evaluation_tools` section
runs the default schema-v3 set; the runner builds any missing sidecar image on
first use, which needs network access, and stops the run if a build fails.
Set `evaluation_tools: false` to turn it off. See [Check kernels
with evaluation tools](use-evaluation-tools.md#default-sanitizers-for-schema-v3-tasks).

## Start a run

Expand Down
Loading
Loading