/agent-core:fused-verifyfrom agent-core
Static scanning, spec conformance checks, testing, and audit log for code run with fused. Covers `fused code verify`, `fused code test`, and `fused audit log` commands, including what the verify layer does and no longer does.
Ships in agent-core. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Part of the Fused skill set — don't work from it alone. Fused is
workspace ⊃ project ⊃ UDF. If you're validating code that belongs to a project, loadfused-projectsfor the end-to-end flow (specs, run, deploy) andfused-executefor how code runs. Seefused-guidefor the full set.
| Layer | Command | What it checks |
|---|---|---|
| Static scan | fused code verify | Code patterns, dependency CVEs/typosquats, input-file names and zip bombs |
| Spec conformance | fused code verify --spec "..." | LLM check: does the code match the stated intent? |
| Test suite | fused code test --test-file … | Pytest + line/branch coverage in the real execution environment |
| Audit | fused audit log | Reads the local audit store (see below for what is still recorded) |
Verify does not run automatically.
fused code runandfused code testexecute code without any pre- or post-execution scan. Nothing blocks a run, no output firewall inspects results, and noexecute_code/verify_codeaudit events are written. The environment's verify settings (--verify,--require-spec,--audit-bucket,verify.enabled,block_on_warn,typecheck,expectations) do not gate or check executions. If you want a scan, runfused code verifyyourself beforecode run.There is also no CLI replacement for the old data-quality
expectationscontract (schema / null-rate / row-count / bounds checks on a result). Check those in your own code or in acode testtest file.
fused code verify)code verify scans code and input files without executing anything. Use it
before code run to catch problems early, or as a gate in CI — it exits 1 when
any BLOCK finding is produced.
fused code verify my_udf.py
fused code verify -c "import os; result = os.listdir('/')"
cat my_udf.py | fused code verify
fused code verify my_udf.py --project my-project # scan the project's deps (local)
fused code verify my_udf.py --input-file ./data.zip # also check an input archive
Output is one line per finding — [WARN] code/dangerous-import: … — then a
N block N warn N info summary, or No findings..
What it runs, in order:
--input-file) — path traversal in the filename
and zip-bomb detection. The filename checked is the file's basename, so in
practice the zip-bomb check is the one that fires.code/* rules).--spec) — the LLM review below.scripts/pyproject.toml deps with --project /
--project-dir (local), otherwise the environment image's packages (AWS). No
requirements means nothing to scan.What it does not run: the type checker (code/type-error), input-file PII
detection (input/pii), the spec/required policy, and anything
post-execution. It writes no audit event.
The environment's verify config still supplies two things to code verify:
per-rule severity overrides (rules) and the OSV endpoint.
Advisory, not a sandbox. The code scan is static (AST) pattern matching. It catches honest mistakes and low-effort misuse, but it is not a containment boundary — a dynamic lookup such as
importlib.import_module("subprocess")orgetattr(builtins, "exec")slips past it, and a BLOCK finding only means this scanner refused. The real isolation for executed code is the per-call subprocess plus the execution role's IAM scope (AWS); the local backend has no isolation boundary at all. Scope the IAM role tightly; do not rely on verify findings as your security perimeter.
| Rule ID | Severity | Emitted by code verify? | What triggers it |
|---|---|---|---|
code/dangerous-import | WARN | yes | import os, import sys, import subprocess, import socket, etc. |
code/exec-eval | BLOCK | yes | exec(...) or eval(...) calls |
code/__import__ | BLOCK | yes | __import__(...) call |
code/network-import | WARN | yes | urllib, requests, httpx, boto3, aiohttp, etc. |
code/credential-string | BLOCK | yes | Hard-coded credential string detected |
code/path-traversal | WARN | yes | Path traversal pattern in a string literal |
code/sql-injection | WARN | yes | String concatenation inside a SQL call |
code/syntax-error | BLOCK | yes | Code fails to parse |
dep/cve | WARN | yes | Known CVE in a scanned package |
dep/typosquatting | WARN | yes | Package name resembles a well-known package (e.g. numppy) |
dep/osv-unavailable | INFO | yes | OSV vulnerability database unreachable |
input/path-traversal | BLOCK | yes (--input-file) | Input filename contains .. sequences |
input/zip-bomb | BLOCK | yes (--input-file) | Input archive expands to an unsafe size |
spec/mismatch | BLOCK | yes (--spec) | LLM judges the code doesn't match the spec |
spec/review-error | WARN | yes (--spec) | LLM call failed (missing key, missing ai extra, API error) |
input/pii | WARN | no | — |
code/type-error | WARN | no | — |
spec/required | BLOCK | no | — |
output/*, correctness/* | — | no | Post-execution checks; nothing runs them now |
--spec)Pass --spec to have Claude review whether the code matches a natural-language
description of intent:
fused code verify my_udf.py --spec "return the number of rows in the dataset"
# [BLOCK] spec/mismatch: … → exit 1
For a project UDF, pass the contents of its scripts/<udf>/spec.md:
fused code verify my-proj/scripts/taxi-analysis/main.py \
--spec "$(cat my-proj/scripts/taxi-analysis/spec.md)"
When to use spec checks:
Requirements:
ai extra on the host (fused[ai], which installs anthropic).
Without it the check emits a spec/review-error warning instead of a verdict.ANTHROPIC_API_KEY (or
ANTHROPIC_AUTH_TOKEN) in the shell, then the anthropic-api-key secret in the
resolved environment. Store it with fused secrets put anthropic-api-key (it
prompts — never pass the key on the command line). On AWS the name must carry the
env's prefix, e.g. openfused-anthropic-api-key. With no key, you get a
spec/review-error warning.fused code test)code test runs a pytest file against user code inside the real execution
environment (Lambda on AWS, the project venv on local). This catches import
errors, missing packages, and runtime behaviour static analysis misses.
cat > test_add.py <<'EOF'
from user_code import add
def test_add_integers():
assert add(1, 2) == 3
def test_add_floats():
assert abs(add(1.1, 2.2) - 3.3) < 1e-9
EOF
fused code test -c "def add(a, b): return a + b" --test-file test_add.py
fused code test my-proj/scripts/adder/main.py --test-file test_add.py --project my-proj
Output: the run's stdout/stderr and warning: lines, then
N passed N failed N errors N skipped and coverage: NN% lines NN% branches.
Exits 1 if any test fails.
Rules for the test file:
from user_code import <name> — the module is always named
user_code.test_ functions, assert, fixtures.fused project add-dep <project> pytest coverage --dev.--input-file PATH (repeatable) stages extra files next to the code.Use code verify for a fast security pre-screen (no cold start) and code test
for behavioural confidence. They are complementary: verify first, then test.
fused audit log)fused audit log reads the local SQLite store at ~/.openfused/audit.db:
fused audit log --limit 20
fused audit log --event-type cache_clear
fused audit log --status blocked --project my-proj
Flags: --limit (default 50), --event-type, --status allowed|blocked|warned,
--project. There is no date-range filter and no S3 merge.
What is still recorded: cache_clear events (from fused share cache-clear)
and share-mount lifecycle events (create / revoke / recreate / repoint).
code run, code test and code verify write nothing, so filtering by
--event-type execute_code or verify_code only returns events from older
installs.
fused code verify <file> --spec "…" — pre-screen for security issues and
spec conformance. Treat a non-zero exit as a stop.fused code test <file> --test-file <tests> — run the test suite, including
any schema / row-count / bounds assertions you care about; require a zero exit
before deploying.fused code run <file> — execute.fused udf deploy / fused project deploy — see fused-projects.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
8 skills in this plugin
/fused-cliReference for the fused CLI — environment management, file storage, secrets, code execution, and infrastructure commands. Use when writing or explaining shell commands that invoke `fused`, or when helping users set up, switch between, or provision environments. If the commands are part of building or running a project, load `fused-projects` first for the end-to-end model./fused-executeBest practices for running code with `fused code run`. Use when writing or reviewing code you will execute through the fused CLI — covers how to structure user code, choose a data library, handle results, write outputs to the file store, pick a project venv, fan out, and what caching `code run` applies. For static scanning, spec checks, and testing see fused-verify. If this is part of building or running a project, load `fused-projects` first for the end-to-end model./fused-Other plugins' skills for the same job
npx claudepluginhub fusedio/skills --plugin agent-core