Xybrid

xybrid run

Execute a hybrid pipeline

Execute a hybrid pipeline on the current device.

Usage

xybrid run --config <path>
xybrid run --pipeline <name>
xybrid run --pipeline <name> --dry-run

Options

OptionShortDescription
--config-cLoad a pipeline YAML file directly
--pipeline-pLook up <name>.yml under examples/
--bundle-bRun a .xyb bundle file directly
--input-textText input for text-based models (LLM, TTS)
--input-audioPath to an audio file for audio-based models (ASR) — WAV, MP3, OGG, or FLAC
--targetForce model format (onnx, coreml, tflite); auto-detected if omitted
--dry-runSimulate routing without execution
--policyLoad an additional policy bundle
--traceEnable execution tracing with flame graph + LLM metrics output
--trace-exportExport the trace to a JSON file (Chrome trace format)

Behavior

  1. Parses YAML into PipelineConfig
  2. Runs policy → routing → execution loop
  3. Prints stage latency and routing summaries

In dry-run mode, the CLI prints routing decisions and simulated outputs without invoking adapters.

Examples

Run from config file

xybrid run --config ./pipelines/voice-assistant.yaml

Run named pipeline

xybrid run --pipeline hiiipe

Looks for hiiipe.yml or hiiipe.yaml in:

  • xybrid-cli/examples/
  • ./examples/

Dry run (simulate only)

xybrid run --pipeline hiiipe --dry-run

Output shows routing decisions without actual execution:

▶️ Stage: whisper-tiny@1.2 → would route to: local
▶️ Stage: gpt-4o-mini → would route to: integration
▶️ Stage: kokoro-82m@0.1 → would route to: local

With custom policy

xybrid run --pipeline hiiipe --policy ./policies/strict-privacy.yaml

Sample Output

▶️ Stage: whisper-tiny@1.2 → local
🎯 Routing: local (fast path)
⚙️ Execution complete (52ms)

▶️ Stage: gpt-4o-mini → integration
🎯 Routing: integration (OpenAI)
⚙️ Execution complete (340ms)

▶️ Stage: kokoro-82m@0.1 → local
🎯 Routing: local (fast path)
⚙️ Execution complete (89ms)

🎉 Pipeline complete (total 481ms)

Pipeline Format

The run command expects YAML pipelines:

name: "voice-assistant"
stages:
  - whisper-tiny@1.0
  - target: integration
    provider: openai
    model: gpt-4o-mini
  - kokoro-82m@0.1

Tracing LLM Inference

When --trace is passed and the pipeline includes an LLM stage, the CLI prints an additional metrics block after the output:

📊 LLM Trace:
------------------------------------------------------------
  TTFT                  : 412 ms
  Decode TPS            : 42.80 tok/s
  Prefill TPS           : 184.20 tok/s
  Wallclock TPS         : 38.10 tok/s
  Mean ITL              : 14.30 ms
  p95 ITL               : 28 ms
  Emitted chunks        : 64
  Tokens generated      : 64
  Finish reason         : stop
------------------------------------------------------------

These values are read from the output envelope's metadata, populated by the LLM adapter's streaming path. Non-LLM stages (ASR, TTS, embedding) do not emit these fields and the block is skipped.

On this page