hanzo-client 8.5.156

Generated client for the Hanzo API — every service, one crate.
Documentation
/*
 * Hanzo Cloud API
 *
 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Llm {
    /// Available is false when the warehouse was not connected or a query blipped. The totals below are then honest zeros, NOT measured ones.
    #[serde(rename = "available", skip_serializing_if = "Option::is_none")]
    pub available: Option<bool>,
    /// CompletionTokens is the output half.
    #[serde(rename = "completionTokens", skip_serializing_if = "Option::is_none")]
    pub completion_tokens: Option<i32>,
    /// CostCents is what they cost the org, in US cents. This IS a Hanzo charge.
    #[serde(rename = "costCents", skip_serializing_if = "Option::is_none")]
    pub cost_cents: Option<i32>,
    /// Models is how many distinct models were used.
    #[serde(rename = "models", skip_serializing_if = "Option::is_none")]
    pub models: Option<i32>,
    /// PromptTokens is the input half of that total.
    #[serde(rename = "promptTokens", skip_serializing_if = "Option::is_none")]
    pub prompt_tokens: Option<i32>,
    /// Requests is how many completions the org made in the window.
    #[serde(rename = "requests", skip_serializing_if = "Option::is_none")]
    pub requests: Option<i32>,
    /// Source names the warehouse table the totals came from.
    #[serde(rename = "source", skip_serializing_if = "Option::is_none")]
    pub source: Option<String>,
    /// Tokens is the total tokens those completions consumed.
    #[serde(rename = "tokens", skip_serializing_if = "Option::is_none")]
    pub tokens: Option<i32>,
}

impl Llm {
    pub fn new() -> Llm {
        Llm {
            available: None,
            completion_tokens: None,
            cost_cents: None,
            models: None,
            prompt_tokens: None,
            requests: None,
            source: None,
            tokens: None,
        }
    }
}