Skip to content

Command line

Every flide command and its options, as --help prints them. The pages under Serving explain them with examples.

flide

usage: flide [-h] {run,serve,kernels,verify,formats} ...

positional arguments:
  {run,serve,kernels,verify,formats}
    run                 answer a file of requests offline
    serve               start the System One API server
    kernels             kernel bundles: compile once, start without compiling
                        elsewhere
    verify              check exact forking, load invariance and the session
                        cache on your requests
    formats             list installed model families

options:
  -h, --help            show this help message and exit

flide serve

usage: flide serve [-h] --model MODEL [--format FORMAT]
                   [--format-arg KEY=VALUE] [--name NAME] [--lora NAME=PATH]
                   [--calibration CALIBRATION] [--device DEVICE]
                   [--dtype DTYPE] [--media-root MEDIA_ROOT]
                   [--allow-media-urls] [--max-media-mb MAX_MEDIA_MB]
                   [--no-cuda-graphs] [--batch-invariant]
                   [--quantize {fp8,int8}] [--tp TP] [--budget BUDGET]
                   [--max-branch-tokens MAX_BRANCH_TOKENS]
                   [--max-request-tokens MAX_REQUEST_TOKENS]
                   [--session-cache-gb SESSION_CACHE_GB]
                   [--session-min-tokens SESSION_MIN_TOKENS] [--vllm-kv DIR]
                   [--planners PLANNERS] [--frontends FRONTENDS]
                   [--max-running-requests MAX_RUNNING_REQUESTS]
                   [--max-queued-requests MAX_QUEUED_REQUESTS]
                   [--batch-window-ms BATCH_WINDOW_MS] [--gather-ms GATHER_MS]
                   [--api-key API_KEY] [--no-meta] [--host HOST] [--port PORT]
                   [--access-log]

`flide serve`: load a checkpoint and serve the System One API. Options a
family does not use are left out of its constructor, so one command line
serves every family.

options:
  -h, --help            show this help message and exit
  --model MODEL         local directory or Hub repository id
  --format FORMAT       model family (default: detected from the checkpoint)
  --format-arg KEY=VALUE
                        family option
  --name NAME           model name reported by the API (default: from --model)
  --lora NAME=PATH      also serve this LoRA adapter (peft, on --model's
                        checkpoint) as model NAME; repeat for several. The
                        base weights are read once and the adapters take
                        turns: a GPU round runs one of them
  --calibration CALIBRATION
                        calibration.json (default: the one next to the
                        weights)
  --device DEVICE       cuda:N, or mlx: the GPU of a Mac with Apple silicon
                        through MLX (the default there)
  --dtype DTYPE         default: bfloat16; float16 on a Mac with --quantize
                        int8
  --media-root MEDIA_ROOT
                        directory that local media paths in requests resolve
                        against (without it, only base64)
  --allow-media-urls    fetch media that requests give as http(s) URLs; the
                        server then reaches any address it can
  --max-media-mb MAX_MEDIA_MB
                        largest image or video a request may carry, in MiB
                        once decoded (default 64)
  --no-cuda-graphs      run every request eagerly
  --batch-invariant     batch-invariant products: every request gets the same
                        bits at any load (slower)
  --quantize {fp8,int8}
                        decoder weights in 8 bits with per-row scales, inputs
                        scaled per token: fp8 (compute capability 8.9+) or
                        int8 (8.0+); on a Mac, int8 is 8-bit weights in groups
                        of 64; changes the numbers a little
  --tp TP               tensor parallel over this many GPUs, --device and the
                        ones after it (Qwen2, Qwen3 and Qwen3.5 dense models)
  --budget BUDGET       tokens per micro-batch (default 65536, or 16384 on a
                        card of 24 GB or less)
  --max-branch-tokens MAX_BRANCH_TOKENS
  --max-request-tokens MAX_REQUEST_TOKENS
  --session-cache-gb SESSION_CACHE_GB
                        GPU memory for saved prefix states; a request that
                        extends an earlier prefix resumes from it; auto: the
                        memory left once the model is up
  --session-min-tokens SESSION_MIN_TOKENS
                        shortest prefix the session cache saves (default: by
                        model size, 2048 to 256)
  --vllm-kv DIR         the directory of a vLLM server's FlideConnector on
                        this GPU: a request's vllm_ref asks its questions
                        after that vLLM request's conversation, from vLLM's
                        keys and values; Qwen2.5 and Qwen3 also run on vLLM's
                        copy of the weights
  --planners PLANNERS   CPU threads that render and tokenize requests
  --frontends FRONTENDS
                        HTTP front-end processes (each plans and finishes
                        requests with its own planners); 0 serves from the GPU
                        process itself
  --max-running-requests MAX_RUNNING_REQUESTS
                        maximum admitted states from planning through
                        finishing, shared by all HTTP front ends
  --max-queued-requests MAX_QUEUED_REQUESTS
                        maximum states waiting for a running slot; return HTTP
                        429 when full; requires --max-running-requests (zero
                        disables waiting)
  --batch-window-ms BATCH_WINDOW_MS
                        wait this long after the first waiting request for
                        more to join its GPU round
  --gather-ms GATHER_MS
                        wait up to this long for requests still being planned
                        to join a round (default 2)
  --api-key API_KEY     require 'Authorization: Bearer KEY' on every route but
                        /health (or set FLIDE_API_KEY)
  --no-meta             answers without the family's metadata and timings
  --host HOST
  --port PORT
  --access-log          log every request (off by default: at hundreds of
                        requests a second the lines cost CPU)

flide run

usage: flide run [-h] --model MODEL --rows ROWS [ROWS ...] --out OUT
                 [--format FORMAT] [--format-arg KEY=VALUE]
                 [--plan-arg KEY=VALUE] [--calibration CALIBRATION]
                 [--max-branch-tokens MAX_BRANCH_TOKENS]
                 [--max-request-tokens MAX_REQUEST_TOKENS]
                 [--media-root MEDIA_ROOT] [--allow-media-urls]
                 [--max-media-mb MAX_MEDIA_MB] [--name NAME] [--every EVERY]
                 [--limit LIMIT] [--budget BUDGET]
                 [--session-cache-gb SESSION_CACHE_GB]
                 [--session-min-tokens SESSION_MIN_TOKENS] [--workers WORKERS]
                 [--dtype DTYPE] [--device DEVICE] [--batch-invariant]
                 [--quantize {fp8,int8}] [--warmup WARMUP]
                 [--stream-block STREAM_BLOCK]

Offline run over a file of System One requests. flide run --model M --rows
R.jsonl[.gz] ... --out DIR Three phases, timed separately: plan (CPU workers
render and tokenize with the family's own code), forward (packed micro-batches
on the GPU), finish (the family turns head outputs into answers). A row is a
request (`state`, `questions`) or a results row that carries one under
`payload`. Every other key of the row is kept and written back next to the
answer, so evaluation kits (Decision Index: `_evaluation`) can score the
output file as it is.

options:
  -h, --help            show this help message and exit
  --model MODEL
  --rows ROWS [ROWS ...]
  --out OUT
  --format FORMAT       model family (default: detected from the checkpoint)
  --format-arg KEY=VALUE
                        family option, e.g. max_branch_tokens=131072
  --plan-arg KEY=VALUE  per-request option, e.g. debias=1
  --calibration CALIBRATION
                        calibration.json (default: the one next to the
                        weights)
  --max-branch-tokens MAX_BRANCH_TOKENS
  --max-request-tokens MAX_REQUEST_TOKENS
  --media-root MEDIA_ROOT
                        directory that local media paths in a row resolve
                        against (without it, only base64)
  --allow-media-urls    fetch media that rows give as http(s) URLs; the run
                        then reaches any address it can
  --max-media-mb MAX_MEDIA_MB
                        largest image or video a row may carry, in MiB once
                        decoded (default 64)
  --name NAME           model name written into each response
  --every EVERY         keep every n-th row
  --limit LIMIT
  --budget BUDGET       tokens per micro-batch (default 65536, or 16384 on a
                        card of 24 GB or less)
  --session-cache-gb SESSION_CACHE_GB
                        GPU memory for saved prefix states; a row that extends
                        an earlier one resumes from it (a block is scheduled
                        whole, so --stream-block decides how often that can
                        happen)
  --session-min-tokens SESSION_MIN_TOKENS
                        shortest prefix the session cache saves (default: by
                        model size, 2048 to 256)
  --workers WORKERS     processes that render and tokenize (default: usable
                        CPUs less two, within free memory)
  --dtype DTYPE         default: bfloat16; float16 on a Mac with --quantize
                        int8
  --device DEVICE       cuda:N, or mlx on a Mac (the default there)
  --batch-invariant     batch-invariant products: every request gets the same
                        bits whatever it is batched with
  --quantize {fp8,int8}
                        decoder weights in 8 bits with per-row scales, inputs
                        scaled per token: fp8 (compute capability 8.9+) or
                        int8 (8.0+)
  --warmup WARMUP       micro-batches run once before the timed forward
  --stream-block STREAM_BLOCK
                        rows per GPU block while planning continues (0: plan
                        everything, then forward, then finish)

flide verify

usage: flide verify [-h] --model MODEL --requests REQUESTS [--format FORMAT]
                    [--format-arg KEY=VALUE] [--limit LIMIT] [--device DEVICE]
                    [--quantize {fp8,int8}] [--batch-invariant]
                    [--session-cache-gb SESSION_CACHE_GB]

`flide verify`: the guarantees of exact state forking checked on your model,
your requests and this GPU. fork every question of every request against the
same question asked alone (the state and that question only), each in a round
of its own: the largest gap between their probabilities, the top answers that
agree, and the questions whose head outputs are the same bits load every
request alone against the same requests shuffled into rounds of 2, 8 and 32,
as a loaded server batches them: the requests whose head outputs keep their
bits, and the largest gap session (with --session-cache-gb) each state grown
in four steps, every step answered with the session cache on, resuming from
the step before, and off: the tokens resumed, the largest gap, the top answers
that agree A top answer that moves counts against a check only where the
reference's top two options are at least 0.05 apart. With --batch-invariant,
any bit that moves in load fails it too: that mode promises the same bits at
any load. flide verify --model M --requests requests.jsonl [--limit 32]
[--batch-invariant] [--session-cache-gb 4]

options:
  -h, --help            show this help message and exit
  --model MODEL         local directory or Hub repository id
  --requests REQUESTS   JSON lines, one System One request each
  --format FORMAT       model family (default: detected from the checkpoint)
  --format-arg KEY=VALUE
                        family option
  --limit LIMIT         requests to read
  --device DEVICE
  --quantize {fp8,int8}
                        check the quantized model the server runs, as serve
                        --quantize does
  --batch-invariant     check the batch-invariant mode, bit for bit
  --session-cache-gb SESSION_CACHE_GB
                        also check the session cache, this large (GiB or auto)

flide kernels

usage: flide kernels [-h] {export,seed,merge,pack,info} ...

positional arguments:
  {export,seed,merge,pack,info}
    export              warm models in a fresh cache and pack the compiled
                        kernels
    seed                file a bundle's kernels into this machine's kernel
                        cache
    merge               unite bundles made with the same Triton on the same
                        GPU
    pack                one archive from the bundles of several GPUs and
                        Triton versions
    info                what a bundle holds

options:
  -h, --help            show this help message and exit