1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
//! Configuration for the unified quality system
#![cfg_attr(coverage_nightly, coverage(off))]
use serde::{Deserialize, Serialize};
use std::path::PathBuf;
use crate::unified_quality::QualityMode;
/// Complete configuration for the unified quality system
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct UnifiedConfig {
/// Current quality mode
pub mode: QualityMode,
/// Auto-progress through modes
pub auto_progress: bool,
/// Days before auto-progression
pub progress_after_days: u32,
/// Budget configuration
pub budget: BudgetConfig,
/// Monitoring configuration
pub monitoring: MonitoringConfig,
/// Automation configuration
pub automation: AutomationConfig,
/// Research features (disabled by default)
pub research: ResearchConfig,
}
/// Budget configuration
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct BudgetConfig {
/// Complexity points allowed
pub complexity_points: i32,
/// SATD allowance
pub satd_allowance: u32,
/// Coverage floor percentage
pub coverage_floor: f64,
/// Daily regeneration rate
pub regeneration_daily: f64,
}
/// Monitoring configuration
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct MonitoringConfig {
/// Enable monitoring
pub enabled: bool,
/// Use incremental parsing
pub incremental: bool,
/// Cache ASTs for performance
pub cache_ast: bool,
/// Dashboard port
pub dashboard_port: u16,
/// Update interval in seconds
pub update_interval: u64,
/// File patterns to watch
pub watch_patterns: Vec<String>,
}
/// Automation configuration
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct AutomationConfig {
/// Enable automation
pub enabled: bool,
/// Require human review
pub require_review: bool,
/// Only apply safe fixes
pub safe_only: bool,
/// Create branches for fixes
pub create_branches: bool,
}
/// Research features configuration
#[derive(Debug, Clone, Serialize, Deserialize, Default)]
pub struct ResearchConfig {
/// Enable property synthesis
pub property_synthesis: bool,
/// Enable formal verification
pub formal_verification: bool,
/// Enable ML suggestions
pub ml_suggestions: bool,
/// Enable autonomous mode
pub autonomous_mode: bool,
}
// Default implementations and UnifiedConfig methods
include!("config_defaults.rs");
// Adoption playbook types and defaults
include!("config_adoption.rs");
// Tests
include!("config_tests.rs");