Skip to content

Command line

The help of every braino command, generated from the code.

braino eval compare

 Usage: braino eval compare [OPTIONS] {before} {now}

 Compare two evaluation reports: pass rate, and tasks fixed or broken.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    before      <path>  Earlier report (JSON) [required]                    │
│ *    now         <path>  Later report (JSON) [required]                      │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino eval list

 Usage: braino eval list [OPTIONS]

 List the evaluation tasks.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --include-large          Also tasks that need large downloads                │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino eval run

 Usage: braino eval run [OPTIONS]

 Run the evaluation tasks with an agent and score them.

 Each task gets a fresh copy of its dataset and a scripted user who answers
 questions and
 decides on proposals. A task passes when all its required checks pass,
 including that every
 number in the answer comes from a tool result.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --agent                  <str>   oracle, null, or module:factory for your    │
│                                  own agent                                   │
│                                  [default: oracle]                           │
│ --tasks                  <str>   Comma-separated task ids; default all       │
│ --include-large                  Also tasks that need large downloads        │
│ --tier                   <str>   Hardware tier this run stands for, e.g.     │
│                                  minimum, gpu                                │
│ --model                  <str>   Model name, for the report                  │
│ --workdir                <path>  Keep each task's data and transcript here   │
│ --output         -o      <path>  Write the report (JSON) here                │
│ --help                           Show this message and exit.                 │
╰──────────────────────────────────────────────────────────────────────────────╯

braino import

 Usage: braino import [OPTIONS] [source]

 Import recordings into a BIDS dataset, removing personal details on the way.

 Give one recording with --subject-id and --task, or many with --mapping.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│   source      <path>  Recording to import (or use --mapping)                 │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset           <path>   BIDS dataset to import into [default: .]        │
│ --key               <path>   Subject key file (private; must be outside the  │
│                              dataset)                                        │
│ --subject-id        <str>    The person's original ID (kept in the key)      │
│ --task              <str>    Task label, e.g. rest                           │
│ --session           <str>    Session label                                   │
│ --run               <int>    Run number                                      │
│ --line-freq         <float>  Power-line frequency in Hz, if known            │
│ --mapping           <path>   CSV with                                        │
│                              source,subject_id,task[,session,run,line_freq]  │
│ --overwrite                  Replace recordings                              │
│ --help                       Show this message and exit.                     │
╰──────────────────────────────────────────────────────────────────────────────╯

braino inspect

 Usage: braino inspect [OPTIONS]

 Summarise a BIDS dataset: subjects, tasks, and each recording's channels and
 events.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset        <path>  Root of the BIDS dataset to work on [default: .]    │
│ --json                   Print the full summary as JSON                      │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model bench

 Usage: braino model bench [OPTIONS]

 Measure how fast the agent will be with the chosen model.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model hardware

 Usage: braino model hardware [OPTIONS]

 Show this computer's CPU, RAM and GPUs, and the model tier BrainO proposes.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --json          Print as JSON                                                │
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model list

 Usage: braino model list [OPTIONS]

 List the models BrainO can run, and which are downloaded or fit here.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model remove

 Usage: braino model remove [OPTIONS] [model]

 Delete a downloaded model or an installed llama.cpp build, to free disk space.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│   model      <str>  Model id to delete                                       │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --runtime        <str>  Delete an installed llama.cpp backend                │
│ --help                  Show this message and exit.                          │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model serve

 Usage: braino model serve [OPTIONS]

 Run the model server in the foreground until Ctrl+C (for development).

 Prints the OpenAI-compatible base URL and this session's API key.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --port        <int>  Port (default: a free one)                              │
│ --help               Show this message and exit.                             │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model setup

 Usage: braino model setup [OPTIONS]

 Install llama.cpp and download the model for this computer, once.

 Downloads are checked against pinned SHA-256 hashes and resume if interrupted.
 Afterwards a
 short benchmark tells you how fast the agent will be.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --model                      <str>  Model id (default: the proposed one)     │
│ --backend                    <str>  cpu, vulkan, cuda or metal (default:     │
│                                     auto)                                    │
│ --bench        --no-bench           Measure the speed [default: bench]       │
│ --yes      -y                       Do not ask before downloading            │
│ --help                              Show this message and exit.              │
╰──────────────────────────────────────────────────────────────────────────────╯

braino model status

 Usage: braino model status [OPTIONS]

 Show the chosen model, what is installed, and the last benchmark.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline export

 Usage: braino pipeline export [OPTIONS] {spec}

 Export a pipeline's current results as a standalone Python script that re-runs
 every step (including steps reused from earlier runs) and checks the results.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    spec      <str>  Spec file (.yaml/.json) or the name of a built-in spec │
│                       [required]                                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset          <path>  Root of the BIDS dataset to work on [default: .]  │
│ --output   -o      <path>  Write the script here instead of printing it      │
│ --help                     Show this message and exit.                       │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline list

 Usage: braino pipeline list [OPTIONS]

 List the pipeline specs that come with BrainO.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline run

 Usage: braino pipeline run [OPTIONS] {spec}

 Run a pipeline over a dataset. Steps whose inputs and settings are unchanged
 are skipped. Decision steps wait for your approval unless --auto-approve is
 given; approve with 'braino proposals approve' and run again to continue.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    spec      <str>  Spec file (.yaml/.json) or the name of a built-in spec │
│                       [required]                                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset             <path>  Root of the BIDS dataset to work on            │
│                               [default: .]                                   │
│ --subjects            <str>   Comma-separated subset of the subjects         │
│ --from                <str>   Run this step and the ones after it again      │
│ --auto-approve                Approve every proposal as made, in your name   │
│                               (e.g. for validation runs)                     │
│ --help                        Show this message and exit.                    │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline show

 Usage: braino pipeline show [OPTIONS] {spec}

 Print a spec (e.g. a built-in one, to copy and adapt).

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    spec      <str>  Spec file (.yaml/.json) or the name of a built-in spec │
│                       [required]                                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline status

 Usage: braino pipeline status [OPTIONS] {spec}

 Show, for each subject, which steps have a current result.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    spec      <str>  Spec file (.yaml/.json) or the name of a built-in spec │
│                       [required]                                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset        <path>  Root of the BIDS dataset to work on [default: .]    │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino pipeline validate

 Usage: braino pipeline validate [OPTIONS] {spec}

 Check a spec: its tools exist and accept the arguments given.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    spec      <str>  Spec file (.yaml/.json) or the name of a built-in spec │
│                       [required]                                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino proposals approve

 Usage: braino proposals approve [OPTIONS] {proposal_id}

 Approve a proposal (optionally edited) and apply it.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    proposal_id      <str>  Proposal ID [required]                          │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --edit           <str>   JSON object of proposal fields to change before  │
│                             applying                                         │
│    --note           <str>   Reason for the decision                          │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino proposals list

 Usage: braino proposals list [OPTIONS]

 List proposals made by decision tools, oldest first.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --pending                Only undecided proposals                         │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino proposals reject

 Usage: braino proposals reject [OPTIONS] {proposal_id}

 Reject a proposal; nothing is applied.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    proposal_id      <str>  Proposal ID [required]                          │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --note           <str>   Reason for the decision                          │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino proposals show

 Usage: braino proposals show [OPTIONS] {proposal_id}

 Print a proposal and its decision, if any, as JSON.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    proposal_id      <str>  Proposal ID [required]                          │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino qc

 Usage: braino qc [OPTIONS]

 Check data quality: flat and noisy channels, line noise, and time with large
 artifacts.

 Changes nothing; per-channel tables are written to derivatives/braino/.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --dataset        <path>  Root of the BIDS dataset to work on [default: .]    │
│ --subject        <str>   Subject label; omit to check every recording        │
│ --task           <str>   Task label                                          │
│ --session        <str>   Session label                                       │
│ --run            <str>   Run number                                          │
│ --json                   Print the summaries as JSON                         │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino runs export

 Usage: braino runs export [OPTIONS] {run_id}

 Export a run as a standalone Python script that re-runs it and checks its
 results.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    run_id      <str>  Run ID, as printed by 'braino runs list' [required]  │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset          <path>  Root of the BIDS dataset to work on [required] │
│    --output   -o      <path>  Write the script here instead of printing it   │
│    --help                     Show this message and exit.                    │
╰──────────────────────────────────────────────────────────────────────────────╯

braino runs list

 Usage: braino runs list [OPTIONS]

 List recorded runs, oldest first, with the tools each one called.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino runs show

 Usage: braino runs show [OPTIONS] {run_id}

 Print the full provenance record of a run as JSON.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    run_id      <str>  Run ID, as printed by 'braino runs list' [required]  │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ *  --dataset        <path>  Root of the BIDS dataset to work on [required]   │
│    --help                   Show this message and exit.                      │
╰──────────────────────────────────────────────────────────────────────────────╯

braino tools list

 Usage: braino tools list [OPTIONS]

 List the registered tools.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino tools run

 Usage: braino tools run [OPTIONS] {name}

 Run a tool and print its result as JSON.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    name      <str>  Tool name, e.g. system.info [required]                 │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --args           <str>   Tool arguments as JSON [default: {}]                │
│ --dataset        <path>  Root of the BIDS dataset to work on                 │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino tools schema

 Usage: braino tools schema [OPTIONS] [name]

 Print the LLM-facing JSON schema of one tool, or of all tools.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│   name      <str>  Tool name; omit for all tools                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯

braino validate erpcore

 Usage: braino validate erpcore [OPTIONS] {component}

 Run the built-in ERP CORE pipeline and compare with the published scores.

 Downloads the data on first use (P3 2.2 GB, N170 3.4 GB for all 40
 participants) into
 $BRAINO_DATA (default ~/.cache/braino). Decisions are auto-approved in your
 name.

╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    component      <str>  P3 or N170 [required]                             │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --subjects        <str>  Comma-separated participants, e.g. 001,002; default │
│                          all                                                 │
│ --json                   Print the full result as JSON                       │
│ --help                   Show this message and exit.                         │
╰──────────────────────────────────────────────────────────────────────────────╯

braino version

 Usage: braino version [OPTIONS]

 Print the BrainO version.

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                  │
╰──────────────────────────────────────────────────────────────────────────────╯