one flow.
one request.
one verdict.

An intrusion detection system that shows TypeSafe's Jev labeled flows it has already seen, asks two typed questions about the next flow and joins the answer with a nearest-neighbour vote, with no text to parse.

Tested on CIC-IDS2017 and TRUSTLab against Random Forest, Isolation Forest, two kNN and Claude Sonnet 5.5.

read the paper · arXiv 2610.01079

input
flow         one CICFlowMeter record, every feature, compact
examples     chosen by the Selector, ceil(k) per category

request: two typed questions to jev
is_attack    noul     Is the flow an intrusion attempt?
category     choice   Which category does it belong to?

output
is_attack    → 0.81
category     → DoS, confidence 0.92
matched kNN  → 0.83   share of attack neighbours
fused        → 0.60   mean of the two percentiles
verdict      → attack   fused ≥ 0.26, the cut taken before the test

how it works

JevIDS runs two detectors over the same stream of flows and joins their answers. The first is Jev, a System One Model from TypeSafe. It reads a block of text with the categories, k labeled flows per category (the examples) and the flow to judge, and answers typed questions with probabilities, so there is no text to parse.

  1. input

    one flow

    The CICFlowMeter record of a single flow, plus the examples the Selector chose.

  2. jev

    one request

    State: the instructions, the categories, the examples and the flow. Questions: is_attack and category.

  3. output

    one answer

    attack · p_attack 0.81
    DoS · confidence 0.92

The KController sets k per category, starting at 1, raising it when Jev names the wrong category and lowering it when Jev is right. The Selector picks which examples, preferring flows close to the one under test, recent ones and ones Jev doubted, and the compact record cuts each number to 4 significant digits. The matched kNN lets as many nearest flows vote as the Selector gives Jev at k = 4, at no cost. The full JevIDS turns each answer into its percentile on a development stream, because the two detectors catch different attacks, and raises the alarm when their mean reaches the cut, 0.2608 on CIC-IDS2017 and 0.377 on TRUSTLab.

Solid arrows judge one flow. Dashed arrows are the feedback, which brings each true label back to the memory after a delay of D flows and lets the KController compare it with the category Jev gave.

A flow enters jev_ids and splits in two. On top, the Selector takes examples from the memory and k per category from the KController, then the compact record goes to jev and jev's p_attack to its percentile. Below, the matched kNN takes its neighbours from the memory, and its p_attack goes to its percentile. The alarm takes the mean of the two percentiles and compares it with the cut, giving the verdict. Dashed feedback arrows bring the true label to the memory D flows later, and the memory and jev's category to the KController. jev_ids flow Selector compact record jev jev percentile memory KController alarm mean ≥ cut verdict examples k per category matched kNN kNN percentile neighbours p_attack true label, D flows later true category jev's category

how it was tested

Both datasets are public lab traffic. Each attack name's flows of each day were cut in half in time, the earlier half feeding the pool, the memory at the start of the test, and the later half the test. A zero-day flow carries an attack name absent from the pool. CIC-IDS2017's three zero-day names leave the pool while their categories keep other names. TRUSTLab's five zero-day families leave it whole, so they have no example until their first labels come back. The 2,000 test flows of each dataset are judged in the order they ended, each true label comes back D = 200 flows later, and the results count a zero-day flow at first contact, judged before any flow of its attack name has come back.

the two datasets · 2,000 test flows each
dataset captured pool benign zero-day at first contact zero-day attack names
CIC-IDS2017, relabelled by Liu et al. (IEEE CNS 2022) July 2017 88,066 1,046 309 SSH-Patator, DoS Slowhttptest, Infiltration Portscan
TRUSTLab, Villafranca, Tasic and Cano (Frontiers in Computer Science, 2026) May and June 2025 150,000 798 338 C2Beaconing, DDoS, DoS, MITM, WebBased

The rivals are a Random Forest, an Isolation Forest trained on benign traffic, a kNN with 4 neighbours and the matched kNN, each refitted at every step on the memory JevIDS sees, and Claude Sonnet 5.5 with the same Selector and KController. Jev alone, the full JevIDS and Sonnet ran with three seeds, the classical detectors once.

The ROC-AUC, the primary metric, is the chance that a detector scores a random zero-day flow above a random benign one, 0.5 for a random score. The PR-AUC, the secondary one, weighs each false alarm by how much it dilutes the share of alarms that are real attacks. Neither needs a cut. The F1 reads every detector at one alarm cut per dataset, calibrated before the test. A bootstrap over 2,000 redraws gives 95 % ranges, and McNemar's exact test compares the flows two detectors disagree on.

evidence

The tables give, at D = 200, each detector's ROC-AUC and PR-AUC. At the cut they give its F1 on zero-day flows at first contact, the zero-day flows caught and the false alarms among the benign flows. Where three numbers appear, they are seeds 0/1/2.

CIC-IDS2017 · paper split · 309 zero-day flows, 1,046 benign
detector ROC-AUC PR-AUC F1 on zero-day flows caught false alarms
full JevIDS 0.995/0.995/0.994 0.976/0.978/0.975 0.946/0.943/0.937 291/289/288 15/15/18
Jev alone 0.994/0.994/0.993 0.969/0.970/0.964 0.836/0.833/0.827 309/309/309 121/124/129
Random Forest 0.836 0.732 0.365 69 0
matched kNN 0.648 0.457 0.434 86 1
Isolation Forest 0.871 0.517 0.371 309 1,046
Claude Sonnet 5.5 0.978/0.982/0.991 0.971/0.980/0.980 0.932/0.935/0.939 274/274/278 5/3/5
TRUSTLab · paper split · 338 zero-day flows, 798 benign
detector ROC-AUC PR-AUC F1 on zero-day flows caught false alarms
full JevIDS 0.930/0.933/0.932 0.908/0.911/0.909 0.838/0.840/0.837 264/266/265 28/29/30
Jev alone 0.925/0.925/0.924 0.861/0.855/0.854 0.785/0.776/0.780 263/258/257 69/69/64
Random Forest 0.867 0.796 0.833 256 21
matched kNN 0.860 0.818 0.801 254 42
Isolation Forest 0.697 0.414 0.539 320 529
Claude Sonnet 5.5 0.872/0.883/0.879 0.797/0.803/0.793 0.706/0.726/0.709 192/200/197 14/13/21

The full JevIDS has the highest ROC-AUC on both datasets. In F1 it ties with Sonnet on CIC-IDS2017 and with the Random Forest on TRUSTLab, and the bootstrap interval of each difference contains 0 in every seed. On TRUSTLab it beats Sonnet in F1, ROC-AUC and PR-AUC in every seed. Complete tests checked each part of JevIDS, removed or swapped one at a time.

read the paper · arXiv 2610.01079

try it

git clone https://github.com/jev-sec/jev-ids.git
cd jev-ids
uv sync
.env holds TYPESAFE_API_KEY for Jev and ANTHROPIC_API_KEY for the Sonnet 5.5 baseline.

Download CICIDS2017_improved.zip from the relabelled version of Liu et al. into data/raw/cicids2017/, or the TRUSTLab files, and prepare them once. The test splits are committed, so only the pool needs the raw data.

uv run python -m scripts.prepare_cicids2017
uv run python -m scripts.prepare_trustlab --raw <folder holding the 16 *.csv.gz>
uv run jev-ids run --dataset data/cicids2017/dataset.json --detector jev --split paper --delay 200 --k 1 --control aimd --selection score+nearest --seeds 0

The run writes results/<timestamp>-cicids2017-jev-paper/ with config.json, one JSON row per flow in predictions.jsonl and Jev's raw answers in responses.jsonl. The README shows how to run the baselines and reproduce every number on this page.

bring your own flows

JevIDS is an independent research prototype, and its numbers belong to these two datasets. Beside a commercial IDS it sits off the packet path, fed from the flow exporter through a queue, because a call takes about a quarter of a second and the API is rate-limited.

Sensor, exporter, signatures, alerts and SIEM in one line, and a side channel that leaves the exporter, goes through a queue to jev_ids and returns into the SIEM. sensor exporter signatures alerts SIEM queue jev_ids side channel

To try it on your flows, copy a dataset card such as data/cicids2017/dataset.json and the request prompts/cicids2017/jev.json, seed the memory with one labeled flow per category and measure on a labeled split of your own before trusting any number. Only flow features leave your network, never payloads, and every request goes to TypeSafe's API.

the team