llm-rs 0.1.1

A library, with a command line interface, to exploit Large Language Models
Documentation
use std::collections::HashMap;

#[derive(Debug)]
pub struct ApiResult<T> {
    pub headers: HashMap<String, String>,
    pub body: T,
}

impl ApiResult<String> {
    pub fn new(body: String, headers: HashMap<String, String>) -> Self {
        Self { headers, body }
    }
}
impl ApiResult<Vec<(String, String)>> {
    pub fn new_v(body: Vec<(String, String)>, headers: HashMap<String, String>) -> Self {
        Self { headers, body }
    }
}
impl ApiResult<()> {
    pub fn new_e(headers: HashMap<String, String>) -> Self {
        Self { headers, body: () }
    }
}