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 BoardTotals {
    /// tokens the models answered with
    #[serde(rename = "completionTokens", skip_serializing_if = "Option::is_none")]
    pub completion_tokens: Option<i32>,
    /// what the window cost, in cents
    #[serde(rename = "costCents", skip_serializing_if = "Option::is_none")]
    pub cost_cents: Option<i32>,
    /// calls that did not succeed
    #[serde(rename = "errors", skip_serializing_if = "Option::is_none")]
    pub errors: Option<i32>,
    /// how many model calls the window holds
    #[serde(rename = "generations", skip_serializing_if = "Option::is_none")]
    pub generations: Option<i32>,
    /// how many distinct models were called
    #[serde(rename = "models", skip_serializing_if = "Option::is_none")]
    pub models: Option<i32>,
    /// tokens sent to the models
    #[serde(rename = "promptTokens", skip_serializing_if = "Option::is_none")]
    pub prompt_tokens: Option<i32>,
    /// share of calls that succeeded, 0..1
    #[serde(rename = "successRate", skip_serializing_if = "Option::is_none")]
    pub success_rate: Option<f64>,
    /// prompt plus completion
    #[serde(rename = "totalTokens", skip_serializing_if = "Option::is_none")]
    pub total_tokens: Option<i32>,
    /// how many distinct users called them
    #[serde(rename = "users", skip_serializing_if = "Option::is_none")]
    pub users: Option<i32>,
}

impl BoardTotals {
    pub fn new() -> BoardTotals {
        BoardTotals {
            completion_tokens: None,
            cost_cents: None,
            errors: None,
            generations: None,
            models: None,
            prompt_tokens: None,
            success_rate: None,
            total_tokens: None,
            users: None,
        }
    }
}