Skip to main content

_diffctx/config/
graph_filtering.rs

1use once_cell::sync::Lazy;
2
3pub struct GraphFilteringConfig {
4    pub hub_out_degree_threshold: usize,
5    pub fallback_max_files: usize,
6    pub min_lines_for_signature: u32,
7    pub max_cache_bytes: usize,
8    pub git_rename_similarity_threshold: u32,
9}
10
11impl Default for GraphFilteringConfig {
12    fn default() -> Self {
13        Self {
14            hub_out_degree_threshold: 3,
15            fallback_max_files: 10_000,
16            min_lines_for_signature: 5,
17            max_cache_bytes: 200 * 1024 * 1024,
18            git_rename_similarity_threshold: 100,
19        }
20    }
21}
22
23pub static GRAPH_FILTERING: Lazy<GraphFilteringConfig> = Lazy::new(GraphFilteringConfig::default);