tokf 0.2.33

Config-driven CLI tool that compresses command output before it reaches an LLM context
Documentation
1
2
3
4
5
6
7
/// Print a Serialize value as pretty JSON, logging errors to stderr.
pub fn print_json(value: &(impl serde::Serialize + ?Sized)) {
    match serde_json::to_string_pretty(value) {
        Ok(json) => println!("{json}"),
        Err(e) => eprintln!("[tokf] JSON serialization error: {e}"),
    }
}