vtcode_config/defaults/
mod.rs1use std::time::Duration;
2
3pub mod provider;
4pub mod syntax_highlighting;
5
6pub use provider::{
7 ConfigDefaultsProvider, WorkspacePathsDefaults, current_config_defaults,
8 install_config_defaults_provider, reset_to_default_config_defaults, with_config_defaults,
9};
10pub use syntax_highlighting::SyntaxHighlightingDefaults;
11
12pub struct ContextStoreDefaults;
14
15impl ContextStoreDefaults {
16 pub fn max_size() -> usize {
17 100000
18 }
19 pub fn compression() -> bool {
20 true
21 }
22
23 pub const MAX_CONTEXTS: usize = 1000;
25 pub const AUTO_CLEANUP_DAYS: u32 = 7;
26 pub const ENABLE_PERSISTENCE: bool = true;
27 pub const COMPRESSION_ENABLED: bool = true;
28 pub const STORAGE_DIR: &'static str = ".vtcode/context";
29}
30
31pub struct PerformanceDefaults;
33
34impl PerformanceDefaults {
35 pub fn max_concurrent_operations() -> usize {
36 10
37 }
38 pub fn timeout_seconds() -> u64 {
39 30
40 }
41}
42
43pub struct ScenarioDefaults;
45
46impl ScenarioDefaults {
47 pub fn max_scenarios() -> usize {
48 10
49 }
50 pub fn default_timeout() -> u64 {
51 300
52 }
53
54 pub const HIGH_PERF_MAX_AGENTS: usize = 5;
56 pub const HIGH_PERF_CONTEXT_WINDOW: usize = 200000;
57 pub const HIGH_PERF_MAX_CONTEXTS: usize = 2000;
58
59 pub const HIGH_QUALITY_MAX_AGENTS: usize = 3;
61 pub const HIGH_QUALITY_CONTEXT_WINDOW: usize = 150000;
62 pub const HIGH_QUALITY_MAX_CONTEXTS: usize = 1500;
63
64 pub const BALANCED_MAX_AGENTS: usize = 4;
66 pub const BALANCED_CONTEXT_WINDOW: usize = 125000;
67 pub const BALANCED_MAX_CONTEXTS: usize = 1250;
68
69 pub fn high_perf_timeout() -> Duration {
70 Duration::from_secs(180)
71 }
72 pub fn high_quality_timeout() -> Duration {
73 Duration::from_secs(600)
74 }
75 pub fn balanced_timeout() -> Duration {
76 Duration::from_secs(300)
77 }
78}