apr-cli 0.2.6

CLI tool for APR model inspection, debugging, and operations
Documentation
[package]
name = "apr-cli"
version = "0.2.6"
edition = "2021"
rust-version = "1.70"
authors = ["Noah Gift <noah@paiml.com>"]
license = "MIT"
description = "CLI tool for APR model inspection, debugging, and operations"
repository = "https://github.com/paiml/aprender"
documentation = "https://docs.rs/apr-cli"
readme = "README.md"
keywords = ["machine-learning", "model-inspection", "cli", "debugging"]
categories = ["command-line-utilities", "science"]

[lints.rust]
# Safety
unsafe_code = "deny"

[lints.clippy]
# Base level
all = { level = "warn", priority = -1 }
pedantic = { level = "warn", priority = -1 }

# CLI-specific allows (relaxed for development velocity)
too_many_lines = "allow"
unnecessary_wraps = "allow"
uninlined_format_args = "allow"
needless_raw_string_hashes = "allow"
format_in_format_args = "allow"
cast_lossless = "allow"
cast_precision_loss = "allow"
cast_possible_truncation = "allow"
cast_possible_wrap = "allow"
cast_sign_loss = "allow"
fn_params_excessive_bools = "allow"
match_same_arms = "allow"
used_underscore_binding = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
doc_markdown = "allow"
missing_errors_doc = "allow"
missing_panics_doc = "allow"
items_after_statements = "allow"
similar_names = "allow"
too_many_arguments = "allow"
struct_excessive_bools = "allow"
single_match_else = "allow"
wildcard_imports = "allow"
enum_glob_use = "allow"
unreadable_literal = "allow"
no_effect_underscore_binding = "allow"

[lib]
name = "apr_cli"
path = "src/lib.rs"

[[bin]]
name = "apr"
path = "src/main.rs"

[features]
default = ["hf-hub", "safetensors-compare", "inference", "cuda", "visualization", "zram"]
hf-hub = ["aprender/hf-hub-integration"]
safetensors-compare = ["aprender/safetensors-compare"]
inference = ["realizar", "trueno", "tokio", "axum", "futures-util"]
cuda = ["inference", "realizar/cuda"]
visualization = ["renacer", "trueno-viz"]
zram = ["trueno-zram-core"]

[dependencies]
# Core aprender library
aprender = { path = "../..", version = "0.24.1", default-features = true, features = ["format-compression"] }

# Inference engine (crates.io version, with local path for dev)
# Note: cuda feature enables GPU-accelerated inference via trueno-gpu
realizar = { version = "0.6.4", optional = true, default-features = false, features = ["server", "aprender-serve", "gpu", "cuda"] }

# SIMD compute library (for BrickProfiler in ยง12.11 unified profiling)
# MUST use crates.io version to match aprender's trueno dependency
trueno = { version = "0.13.0", optional = true }

# Async runtime for server
tokio = { version = "1", features = ["rt-multi-thread", "macros", "signal"], optional = true }

# HTTP server (for serve command with inference feature)
axum = { version = "0.7", optional = true }

# Async streams for SSE
futures-util = { version = "0.3", optional = true }

# CLI framework
clap = { version = "4.5", features = ["derive", "env", "wrap_help"] }

# Output formatting
colored = "2.1"
tabled = "0.16"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
rmp-serde = "1.3"

# Error handling
thiserror = "2.0"

# Time formatting
chrono = { version = "0.4", default-features = false, features = ["std", "clock"] }

# Human-readable sizes
humansize = "2.1"

# File/directory utilities
glob = "0.3"
dirs = "5.0"

# HTTP client for downloads
ureq = "2.10"

# TUI
ratatui = { version = "0.29", default-features = true }
crossterm = "0.28"

# Visualization (syscall tracing and charts)
renacer = { version = "0.9.7", path = "/home/noah/src/renacer", optional = true, default-features = false }
trueno-viz = { version = "0.1.19", optional = true, default-features = false, features = ["svg"] }

# ZRAM compression (SIMD-accelerated LZ4/ZSTD)
trueno-zram-core = { version = "0.2", optional = true }

# Model registry and caching (Ollama-like model management)
pacha = { version = "0.2.3", path = "/home/noah/src/pacha", default-features = false, features = ["remote"] }

[[example]]
name = "probar_tui_testing"
required-features = ["inference"]

[[example]]
name = "federation_tui_demo"
required-features = ["inference"]

[dev-dependencies]
assert_cmd = "2.0"
predicates = "3.1"
tempfile = "3.14"
proptest = "1.6"
jugar-probar = { version = "0.4", features = ["tui"] }
regex = "1.10"
tokio = { version = "1", features = ["rt-multi-thread", "macros", "time"] }
axum-test = "16"
tower = "0.5"