sharky-workbench / phase7 /benchmark_plan.md
luispoveda93's picture
phase7 plan r2: Jev API unavailable β€” B3 reworked to local kev-0.6b/kev-4b + Laya option, Jev head-to-head deferred
003ccf2 verified
|
Raw History Blame Contribute Delete
8.14 kB

phase7 β€” Benchmark plan for sharky-0.5B (kev/jev-referenced)

Status: PLANNED, no runs executed. Drafted 2026-09-24; revision 2, same day β€” Jev API access is unavailable, so the direct Jev head-to-head is deferred and its protocol preserved in appendix form. All comparisons now run against locally served, open-weights kev-family models. Plan of record for benchmarking luispoveda93/sharky-0.5B. Every run that executes from this plan must append its result to phase7/ with a suite manifest, per kev discipline.

Why this phase

The model card's current evaluation (phase6) is entirely self-referential: sharky is measured on splits of the dataset it was trained against. There is no baseline from the kev/jev family, and no kev/Jev model has ever published pcap numbers. phase7 adds comparative baselines, controls, and the kev eval-protocol guarantees the card currently lacks (read-once locked tests, paired significance).

Reference baselines (all locally served β€” no hosted API required)

Baseline What it is Published reference numbers How we compare
kev-0.5b (jaredpalmer/kev-0.5b) Open repro of Jev's inferred architecture: Qwen2.5-0.5B + LoRA r16 Ξ±32 + pointer head, /v1/systemone contract In-dist acc 0.799 / ECE 0.065; agnews 0.940, banking77 0.860, mnli 0.747, sst5 0.533, boolq 0.753 Served locally via kev.serve, queried with sharky's exact battery and states
kev-0.6b (research preview) Same recipe at 0.6B; decision-v4 with none-of-the-above minimal pairs In-dist 0.805 / OOD 0.598, measured head-to-head against Jev: 0.845 / 0.855 on the same frozen sets Served locally; its published Jev deltas give sharky an indirect Jev reference without API access
kev-4b 4B tier, kevBench hard/transfer suites hard-v1 0.803, devtools-v1 0.756, transfer-v4 locked 0.838; gate 34% automated @ 5% error budget β†’ 48% Head-to-head on pcap battery + gate-curve shape reference
Laya (convaiinnovations/laya) β€” optional Third-party open-weights decision model (Apache-2.0, 421M params), same question format Numbers published by its authors, not by kev Same protocol if included; labeled as out-of-family control
Controls (a) MiniCPM4-0.5B backbone + sharky pointer head without triage LoRA training; (b) majority-class; (c) option-order permutation β€” Isolate what the LoRA + pointer head actually contribute

Architecture lineage references: Archer Hume, "Jev's Architecture Unmasked" (archerhume.com); kev code at github.com/jaredpalmer/kev (kev/train.py, kev/serve.py, runs/leaderboard.md).

On Jev itself: TypeSafe's hosted model is unavailable for this phase (waitlist access). Its self-run consensus figure (67.8%) is directional only β€” frontier-model consensus labels, no public harness, not reproducible. The indirect anchor is kev-0.6b's published head-to-head with Jev (see table); when API access lands, the deferred B3 protocol (appendix below) runs unchanged.

P0 β€” Protocol hardening (no GPU required)

  1. Paired significance. Add record-clustered paired bootstrap (10k resamples, 95% CI) to phase4/eval_4.py-derived reporting. Any sharky-vs-baseline delta quoted on the model card must carry a CI; if it straddles zero, say so.
  2. Suite manifests. Every result.json records: dataset revision SHA, code hash, git commit, model adapter SHA β€” copying kev's result.json discipline verbatim.
  3. Read-once discipline. The locked split (2,446 states) is read at most once per promoted candidate. Selection happens on dev partitions only.
  4. Calibration re-audit. Refit temperature on the 8,420 held-out calibration records; report drift from T=1.7411 and resulting ECE change before any new numbers are generated.

P1 β€” pcap head-to-heads (core)

All on sharky's fixed battery (verdict / exploit_evidence / recon_only / severity) over the same state strings, scored identically:

  • B1 β€” kev-0.5b zero-shot on pcap. Serve kev-0.5b locally, query with the sharky battery on the locked split (2,446) and DAPT-2020 hold (3,674). Expect weak zero-shot accuracy β€” the measurement is transfer to the pcap state format, and it is the only apples-to-apples 0.5B comparison in the family. Est. 1–2 h on a10g-small.
  • B2 β€” untrained-head control. Same protocol on the MiniCPM4-0.5B backbone with the pointer head but no triage LoRA. Bounds how much of the card's 0.98+ is architecture vs training.
  • B3 β€” kev-0.6b and kev-4b on the same protocol. Served locally via kev.serve, identical battery and states. kev-0.6b additionally carries the indirect Jev anchor (its published head-to-head with Jev), letting sharky be positioned on the kev-family scale without API access. kev-4b needs ~8 GB fp16 for serving β€” still within a10g-small. Est. +1–2 h.
  • B4 (optional) β€” Laya control. Same protocol on convaiinnovations/laya; run only if its served output format maps cleanly to the battery. Out-of-family, labeled as such.
  • Metrics (all arms): accuracy, macro-F1, per-class F1 (report the suspicious↔malicious confusion separately β€” the card's dominant error mode), ECE, Brier, NLL, option-order permutation flips (k=300), gate coverage@precision.

P2 β€” Shared public suites (generality probe, secondary)

Render sst2, ag_news and banking77 into kev-style state+question records per the jevbench classifier protocol and evaluate sharky's pointer head zero-shot. Compare against kev-0.5b's published per-suite numbers. This measures generality of the decision architecture, not triage skill β€” it must never be presented on the card as a security benchmark.

P3 β€” Gate benchmark

Sweep the auto-close threshold (benign pβ‰₯Ο„) and escalate threshold (malicious pβ‰₯Ο„) on the locked split and produce coverage@precision curves. Validate the card's operating claims (benign auto-close 40% @ 99.9% precision; malicious escalate ~32% @ 99.1%) and compare curve shape to kev-4b's gate discipline. Publish the chosen operating points alongside the curves.

Cost & hardware sketch (indicative, no budget committed)

Arm Hardware Est. wall time Est. cost
P1 B1–B3 (kev-0.5b/0.6b/4b + control) a10g-small, prefill-only 3–4 h β‰ˆ $3.50–5
P2 same 1 h β‰ˆ $1.20
P0 none (CPU) β€” $0

Deliverables on completion

  • phase7/manifests/ β€” frozen suite manifests (revisions, hashes).
  • phase7/eval_pcap_headtohead.json β€” B1–B4 results with CIs.
  • phase7/eval_public_suites.json β€” P2 results.
  • phase7/gate_curves.json + phase7/leaderboard.md β€” P3 + summary table.
  • Model card: replace the static Evaluation table with a comparison table (sharky vs controls vs the kev tiers measured), each row carrying suite hash + n + CI.

Explicitly out of scope

  • TypeSafe's consensus-benchmark figures as a comparable number (not reproducible).
  • Re-training; phase7 measures the current checkpoint only.
  • New external pcap corpora (CIC-IDS2017 etc.) β€” candidate for a later phase if the kev-family comparisons leave open questions about cross-dataset generalization.

Appendix β€” deferred: direct Jev head-to-head (moved out of scope this phase)

Jev API access is unavailable (waitlist). The protocol below is kept verbatim so it runs unchanged when access lands; it is not part of phase7's deliverables until then.

  • B3-JEV β€” Jev head-to-head (API). Same states, same battery, via typesafe-sdk against api.typesafe.ai/v1/systemone, model route jev-latest. Volume: ~2,446–6,120 states Γ— ~500 tokens β‰ˆ 1.2–3M input tokens β‰ˆ $0.05–0.13 at $0.042/M. Report accuracy, macro-F1, ECE, gate coverage@precision; note that Jev's claimed /v1/systemone behavior (one prefill pass, no generation) must be verified from the response shape before any number is trusted.