MCPcopy Create free account
hub / github.com/CommonstackAI/UncommonRoute / RouteRecord

Class RouteRecord

uncommon_route/stats.py:41–112  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39
40@dataclass
41class RouteRecord:
42 timestamp: float
43 model: str
44 tier: str
45 confidence: float
46 method: RouteMethod
47 estimated_cost: float
48 raw_confidence: float = 0.0
49 confidence_source: str = ""
50 calibration_version: str = ""
51 calibration_sample_count: int = 0
52 calibration_temperature: float = 1.0
53 calibration_applied_tags: tuple[str, ...] | list[str] | None = None
54 baseline_cost: float = 0.0
55 requested_model: str = ""
56 mode: str = "auto"
57 decision_tier: str = ""
58 served_quality: str = ""
59 served_quality_target: str = ""
60 served_quality_floor: str = ""
61 capability_lane: str = ""
62 actual_cost: float | None = None
63 savings: float = 0.0
64 latency_us: float = 0.0
65 usage_input_tokens: int = 0
66 usage_output_tokens: int = 0
67 cache_read_input_tokens: int = 0
68 cache_write_input_tokens: int = 0
69 cache_hit_ratio: float = 0.0
70 transport: str = "openai-chat"
71 cache_mode: str = "none"
72 cache_family: str = "generic"
73 cache_breakpoints: int = 0
74 input_tokens_before: int = 0
75 input_tokens_after: int = 0
76 artifacts_created: int = 0
77 compacted_messages: int = 0
78 semantic_summaries: int = 0
79 semantic_calls: int = 0
80 semantic_failures: int = 0
81 semantic_quality_fallbacks: int = 0
82 checkpoint_created: bool = False
83 rehydrated_artifacts: int = 0
84 sidechannel_estimated_cost: float = 0.0
85 sidechannel_actual_cost: float | None = None
86 session_id: str | None = None
87 turn_id: str = ""
88 step_type: str = "general"
89 fallback_reason: str = ""
90 streaming: bool = False
91 request_id: str = ""
92 prompt_preview: str = ""
93 complexity: float = 0.33
94 route_reasoning: str = ""
95 constraint_tags: list[str] | None = None
96 hint_tags: list[str] | None = None
97 feature_tags: list[str] | None = None
98 answer_depth: str = "standard"

Calls

no outgoing calls