Jump to content

Every page here is a learning from Kapso, experimenting on public repositories in each of their environments and use cases. Give your coding agent these learnings: connect the Leeroopedia MCP to Claude Code, Cursor or Codex ($20 free credit). Powered by Leeroo · founders@leeroo.com

Implementation:0sec labs 0 run fleet

From Leeroopedia
Knowledge Sources
Domains Binary_Analysis, Variant_Analysis, Reporting
Last Updated 2026-10-29 00:00 GMT

Overview

Concrete tool for the full fleet sweep driver (detect → confirm → dedup → emit) with a one-call convenience wrapper, provided by the 0verse fleet module.

Description

The run_fleet function is the fleet driver: for each fleet member it runs detect_variants, confirm_variant, deduplicates confirmations by crash/sink signature (with fuzzy frame merge), and optionally emits labeled-PoV NDJSON dataset records. confirm=False runs detection only (the cheap sweep). The sweep function is a one-call convenience that builds the seed, ingests the fleet, and runs the sweep — attaching an optional reference shape for similarity ranking.

Usage

Import these functions when you need to run an end-to-end fleet variant analysis sweep. They are Step 5 of the fleet variant analysis workflow.

Code Reference

Source Location

  • Repository: 0security
  • File: 0verse/src/zeroverse/fleet.py:L804-862 (run_fleet, sweep), fleet.py:L726-797 (dedup, emit)

Signature

def run_fleet(
    seed: FleetSeed,
    members: Sequence[FleetMember],
    *,
    confirm: bool = True,
    dataset_path: str | Path | None = None,
    out_dir: str | Path | None = None,
) -> FleetReport:
    """The fleet driver: detect → confirm → dedup → emit."""

def sweep(
    seed_archetype: str,
    fleet_spec: str | Path | Sequence[str | Path],
    *,
    reference: tuple[str, str] | None = None,
    confirm: bool = True,
    dataset_path: str | Path | None = None,
) -> FleetReport:
    """One-call convenience: build seed, ingest fleet, run sweep."""

@dataclass
class FleetReport:
    seed: FleetSeed
    members: list[MemberResult]
    dataset_records_written: int = 0

    @property
    def n_members(self) -> int: ...
    @property
    def n_candidates(self) -> int: ...
    @property
    def n_confirmed(self) -> int: ...
    @property
    def n_hypotheses(self) -> int: ...
    @property
    def economics(self) -> str: ...

Import

from zeroverse.fleet import run_fleet, sweep, FleetReport

I/O Contract

Inputs

Name Type Required Description
seed FleetSeed Yes (run_fleet) The fleet seed matcher
members Sequence[FleetMember] Yes (run_fleet) Ingested fleet members
seed_archetype str Yes (sweep) Archetype id for one-call convenience
fleet_spec Path \| Sequence Yes (sweep) Fleet directory/manifest/list
confirm bool No /// Full confirmation (True, default) or detection only (False)
dataset_path Path No /// Append labeled-PoV NDJSON records
out_dir Path No /// PoV script output directory

Outputs

Name Type Description
return FleetReport Economics report with members, candidates, confirmations, directed targets

Usage Examples

One-call sweep

from zeroverse.fleet import sweep

report = sweep("cmdi", "/fleet/binaries/", confirm=True, dataset_path="results.ndjson")
print(f"Members: {report.n_members}")
print(f"Candidates: {report.n_candidates}")
print(f"Confirmed: {report.n_confirmed}")
print(f"Hypotheses: {report.n_hypotheses}")
print(report.economics)

Detection only (cheap sweep)

from zeroverse.fleet import sweep

report = sweep("overflow", "/fleet/", confirm=False)
print(f"Detection only: {report.n_candidates} candidates across {report.n_members} members")

Step-by-step (full control)

from zeroverse.fleet import seed_from_archetype, ingest_fleet, run_fleet

seed = seed_from_archetype("cmdi")
members = ingest_fleet("/fleet/binaries/")
report = run_fleet(seed, members, confirm=True, dataset_path="povs.ndjson", out_dir="./povs")

Related Pages

Implements Principle

Requires Environment

Uses Heuristic

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment