soft3/glia/run/cli/main.rs

//! run CLI entry point.

mod cmd;
mod util;

fn main() {
    env_logger::init();
    let mut args: Vec<String> = std::env::args().collect();
    if args.len() < 2 {
        help();
        return;
    }
    let cmd = args[1].clone();
    args.drain(..2);

    match cmd.as_str() {
        "backends" => cmd::backends::run(),
        "graph"   => cmd::graph::run(args),
        "run"     => cmd::run::run(args),
        "status"  => cmd::status::run(),
        "bench"   => cmd::bench::run(args),
        "profile" => cmd::profile::run(args),
        "help" | "--help" | "-h" => help(),
        other => {
            eprintln!("unknown command: {other}");
            help();
            std::process::exit(2);
        }
    }
}

fn help() {
    println!("mr โ€” modelruntime");
    println!();
    println!("usage: mr <command> [args]");
    println!();
    println!("commands:");
    println!("  backends                         list available backends");
    println!("  status                           honest report on manifest models");
    println!("  bench <model> [--steps N] [--max-secs N]   phase breakdown + tok/s per backend");
    println!("  profile <model> [--steps N] [--backend X]  per-op time breakdown");
    println!("  graph <model> [--verify]         embed IR graph section into .model file");
    println!("  run <model> --prompt <text>      generate text from a model");
    println!("    options:");
    println!("      --max-tokens N               (default: unlimited โ€” stops at EOS / turn boundary)");
    println!("      --temperature T              (default 0 = greedy)");
    println!("      --backend NAME               cpu|wgpu+rs|honeycrisp");
    println!("      --no-chat                    skip chat template, use raw prompt");
    println!("      --path=graph                 force graph executor path (slower, for testing)");
}

Homonyms

cyberia/src/main.rs
cyb/src-tauri/src/main.rs
soft3/tru/cli/main.rs
neural/rune/cli/main.rs
cyb/cyb-boot/src/main.rs
soft3/glia/import/main.rs
warriors/trisha/cli/main.rs
neural/trident/src/main.rs
cyb/optica/src/main.rs
soft3/nox/cli/main.rs
neural/rs/link/src/main.rs
neural/rs/macho-linker/src/main.rs
soft3/zheng/cli/src/main.rs
cyb/cyb/cyb-portal/src/main.rs
neural/rs/pure-rust-check/src/main.rs
cyb/cyb/cyb-ui/src/main.rs
soft3/foculus/src/bin/main.rs
neural/eidos/cli/src/main.rs
soft3/radio/iroh-relay/src/main.rs
cyb/cyb/cyb-shell/src/main.rs
neural/rs/rsc/src/main.rs
soft3/cybergraph/cli/src/main.rs
soft3/bbg/cli/src/main.rs
soft3/radio/radio-cli/src/main.rs
soft3/radio/particle/src/main.rs
soft3/hemera/cli/src/main.rs
soft3/radio/iroh-dns-server/src/main.rs
soft3/strata/trop/cli/src/main.rs
cyb/honeycrisp/rane/src/probe/main.rs
soft3/strata/kuro/cli/src/main.rs
soft3/strata/genies/cli/src/main.rs
bootloader/go-cyber/mcp/rust/src/main.rs
cyb/wysm/crates/cli/src/main.rs
soft3/strata/nebu/cli/src/main.rs
cyb/honeycrisp/acpu/src/probe/main.rs
neural/inf/rs/cli/src/main.rs
soft3/strata/jali/cli/src/main.rs
cyb/honeycrisp/unimem/experiments/hyp_probe/src/main.rs
cyb/honeycrisp/unimem/experiments/iosurface_probe/src/main.rs
cyb/honeycrisp/unimem/experiments/dext_iosurface_pa/client/src/main.rs
cyb/honeycrisp/unimem/experiments/dext_contiguous_alloc/client/src/main.rs

Graph