Skip to main content

Crate llm_optimizer_decision

Crate llm_optimizer_decision 

Source
Expand description

Optimization decision engine for LLM Auto-Optimizer

This crate provides the decision-making logic for optimizing LLM configurations, including A/B testing, Thompson Sampling, statistical significance testing, contextual bandits for reinforcement learning, Pareto optimization, adaptive parameter tuning, drift & anomaly detection, and a comprehensive model registry for all major LLM providers.

Re-exports§

pub use ab_testing::ABTestEngine;
pub use thompson_sampling::ThompsonSampling;
pub use statistical::StatisticalTest;
pub use statistical::ZTest;
pub use variant_generator::VariantGenerator;
pub use experiment_manager::ExperimentManager;
pub use contextual_bandit::LinUCB;
pub use contextual_bandit::ContextualThompson;
pub use context::RequestContext;
pub use context::OutputLengthCategory;
pub use reward::RewardCalculator;
pub use reward::RewardWeights;
pub use reward::UserFeedback;
pub use reward::ResponseMetrics;
pub use reinforcement_feedback::ReinforcementEngine;
pub use reinforcement_feedback::BanditAlgorithm;
pub use reinforcement_feedback::VariantStats;
pub use pareto::ModelCandidate;
pub use pareto::Objectives;
pub use pareto::ObjectiveWeights;
pub use pareto::ParetoFrontier;
pub use pareto::CostCalculator;
pub use pareto::QualityMetrics;
pub use model_registry::ModelRegistry;
pub use model_registry::ModelDefinition;
pub use model_registry::ModelPricing;
pub use model_registry::ModelPerformance;
pub use model_registry::ModelCapabilities;
pub use model_registry::Provider;
pub use model_registry::ModelTier;
pub use adaptive_params::AdaptiveParameterTuner;
pub use adaptive_params::ParameterConfig;
pub use adaptive_params::ParameterRange;
pub use adaptive_params::ParameterStats;
pub use parameter_search::GridSearch;
pub use parameter_search::GridSearchConfig;
pub use parameter_search::RandomSearch;
pub use parameter_search::LatinHypercubeSampling;
pub use parameter_search::ParameterSearchManager;
pub use parameter_search::SearchStrategy;
pub use parameter_optimizer::ParameterOptimizer;
pub use parameter_optimizer::OptimizationPolicy;
pub use parameter_optimizer::OptimizationMode;
pub use drift_detection::DriftStatus;
pub use drift_detection::DriftAlgorithm;
pub use drift_detection::ADWIN;
pub use drift_detection::PageHinkley;
pub use drift_detection::CUSUM;
pub use drift_detection::StatisticalDriftDetector;
pub use anomaly_detection::AnomalyResult;
pub use anomaly_detection::ZScoreDetector;
pub use anomaly_detection::IQRDetector;
pub use anomaly_detection::MADDetector;
pub use anomaly_detection::MahalanobisDetector;
pub use threshold_monitor::ThresholdMonitoringSystem;
pub use threshold_monitor::ThresholdConfig;
pub use threshold_monitor::Alert;
pub use threshold_monitor::AlertType;
pub use threshold_monitor::AlertSeverity;
pub use errors::DecisionError;
pub use errors::Result;

Modules§

ab_testing
A/B testing engine with Thompson Sampling
adaptive_params
Adaptive Parameter Tuning for LLM configurations
anomaly_detection
Anomaly Detection
context
Context feature extraction for contextual bandits
contextual_bandit
Contextual bandit algorithms for adaptive model selection
drift_detection
Drift Detection
errors
Error types for decision engine
experiment_manager
Experiment lifecycle management
model_registry
LLM Model Registry and Catalog
parameter_optimizer
Parameter Optimizer
parameter_search
Parameter Search Strategies
pareto
Pareto optimization for multi-objective decision making
reinforcement_feedback
Reinforcement Feedback Engine
reward
Reward signal calculation for reinforcement learning
statistical
Statistical significance testing for A/B experiments
thompson_sampling
Thompson Sampling implementation for multi-armed bandit optimization
threshold_monitor
Threshold-Based Monitoring
variant_generator
Variant generation strategies for A/B testing