read-eval-logs
БесплатноБез исполняемых скриптовНе проверенView and analyse Inspect evaluation log files using the Python API. Trigger whenever you need to look at a .eval file yourself without using pre-written…
от UKGovernmentBEIS★ 763 звезды на GitHubОб этом скилле
Analysing Eval Log Files
This skill covers how to view and analyse Inspect evaluation log files using the Python API and CLI commands.
Quick Reference
CLI Commands
# List all logs in the default log directory (./logs or INSPECT_LOG_DIR)
uv run inspect log list --json
# List logs with specific status
uv run inspect log list --json --status success
uv run inspect log list --json --status error
# List retryable logs (error/cancelled without subsequent success)
uv run inspect log list --json --retryable
# Dump a log file as JSON (works with any format: .eval or .json)
uv run inspect log dump <log_file_path>
# Convert between log formats
uv run inspect log convert source.json --to eval --output-dir log-output
uv run inspect log convert logs/ --to eval --output-dir logs-eval
# Get JSON schema for log files
uv run inspect log schema
Interactive Log Viewer
# Start the interactive log viewer (updates automatically)
uv run inspect view
Python API
Key Imports
from inspect_ai.log import (
# Listing and reading
list_eval_logs,
read_eval_log,
read_eval_log_sample,
read_eval_log_samples,
read_eval_log_sample_summaries,
# Writing
write_eval_log,
# Utilities
retryable_eval_logs,
recompute_metrics,
resolve_sample_attachments,
# Types
EvalLog,
EvalLogInfo,
EvalSample,
EvalSampleSummary,
)
Listing Logs
# List all logs in default directory
logs = list_eval_logs()
# List logs in a specific directory
logs = list_eval_logs(log_dir="./experiment-logs")
# Filter by format
logs = list_eval_logs(formats=["eval"]) # Only .eval files
# Filter with a custom function (receives header-only EvalLog)
logs = list_eval_logs(filter=lambda log: log.status == "success")
# Non-recursive listing
logs = list_eval_logs(recursive=False)
Reading Logs
# Read full log
log = read_eval_log("path/to/logfile.eval")
# Read header only (fast, excludes samples)
log = read_eval_log("path/to/logfile.eval", header_only=True)
# Read with attachments resolved
log = read_eval_log("path/to/logfile.eval", resolve_attachments=True)
Reading Samples
# Read a single sample by ID and epoch
sample = read_eval_log_sample("path/to/logfile.eval", id=42, epoch=1)
# Read a single sample by UUID
sample = read_eval_log_sample("path/to/logfile.eval", uuid="sample-uuid")
# Stream all samples (memory efficient - one at a time)
for sample in read_eval_log_samples("path/to/logfile.eval"):
process(sample)
# Stream samples from incomplete logs
for sample in read_eval_log_samples("path/to/logfile.eval", all_samples_required=False):
process(sample)
# Read sample summaries (fast, includes scoring info)
summaries = read_eval_log_sample_summaries("path/to/logfile.eval")
Filtering Samples
# Read only samples with errors using summaries for filtering
errors = []
for summary in read_eval_log_sample_summaries(log_file):
if summary.error is not None:
errors.append(
read_eval_log_sample(log_file, summary.id, summary.epoch)
)
EvalLog Structure
The EvalLog object contains:
| Field | Type | Description |
|---|---|---|
version |
int |
File format version (currently 2) |
status |
str |
"started", "success", "cancelled", or "error" |
eval |
EvalSpec |
Task, model, creation time, config |
plan |
EvalPlan |
Solvers and generation config |
results |
EvalResults |
Aggregate scores and metrics |
stats |
EvalStats |
Runtime, model usage statistics |
error |
EvalError |
Error info if status == "error" |
samples |
list[EvalSample] |
Individual samples (if not header_only) |
reductions |
list[EvalSampleReductions] |
Multi-epoch reductions |
location |
str |
URI where log was read from |
Always Check Status
log = read_eval_log("path/to/logfile.eval")
if log.status == "success":
# Safe to analyse results
for score in log.results.scores:
print(f"{score.name}: {score.metrics}")
EvalSample Structure
Each sample contains:
| Field | Type | Description |
|---|---|---|
id |
int | str |
Unique sample ID |
epoch |
int |
Установить read-eval-logs в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл read-eval-logs?
View and analyse Inspect evaluation log files using the Python API. Trigger whenever you need to look at a .eval file yourself without using pre-written scripts.
Как установить скилл read-eval-logs?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл read-eval-logs запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic