latch-core 0.1.0

Neutral shared types and configuration for the Latch gateway SDK
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use crate::{CompressionStrategy, Message};
use serde::{Deserialize, Serialize};

#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct CompressionResult {
    pub messages: Vec<Message>,
    pub tokens_before: usize,
    pub tokens_after: usize,
    pub strategy_used: CompressionStrategy,
}

#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct RoutingDecision {
    pub provider: String,
    pub reason: String,
    pub confidence: f32,
}