Executive summary
The system holds an adequate overall standing of 66%, reflecting a small, well-architected asset that is currently carrying real operational risk. While the codebase is compact and inexpensive to rebuild, its readiness for production is insufficient, creating a gap between what the architecture supports and how safely it can be operated. This imbalance means that while the foundation is solid, the day-to-day reliability and security posture require immediate attention to prevent costly outages or security regressions.
The value at stake is relatively low, with a rebuild effort estimated at roughly 0.1 person-years or €17,000. This small footprint means that changes can be made quickly, but it also means that the cost of failure is concentrated in the operational layer rather than the code structure. The system is not fragile in terms of complexity, but it is vulnerable in terms of observability and deployment safety, which are critical for maintaining trust with users and minimizing downtime costs.
The primary risk lies in operational readiness, which scores only 56%. Without comprehensive structured logging, the team lacks the ability to diagnose issues in production, leading to longer resolution times and higher support costs. This weakness is compounded by incomplete security practices, where the absence of automated static analysis in the CI pipeline allows potential vulnerabilities to slip through. These gaps expose the business to unnecessary delays and security exposure, even though the underlying code health and architecture are strong.
On the positive side, the code health and architecture are excellent, with scores of 83% and 95% respectively. The system is clean, maintainable, and well-designed, which reduces long-term technical debt. Performance is also perfect, indicating that the system is efficient and scalable. These strengths provide a solid foundation for improvement, allowing the team to focus on operational enhancements without needing to refactor the core logic.
The first action should be to extend structured logging to all runnable modules. This single change offers the highest leverage by improving diagnosability and reducing mean time to resolution for incidents. Once logging is in place, the team can then implement automated security checks and verify deployment protections. This phased approach ensures that the most critical operational risks are addressed first, providing immediate value and setting the stage for further improvements.
Raise Readiness 56 → 70 (the Healthy floor) ⇒ headline 66 → ~72.
New since the last scan (10+)
- D4 · Edited copy of a member (25 corresponding lines) crates/code2prompt-core/src/git.rs
- D4 · Members sharing a duplicated core (4 members, 50+ identical tokens) crates/code2prompt/src/model/mod.rs
- D5 · Off the main sequence: code2prompt_core
- D8 · Coverage not measured — JavaScript/TypeScript suite
- D11 · Test suite declares a test script but contains no test files: website/
- D22 · Duplicate selection logic across Session and SelectionEngine. The Session type exposes low-level selection mutation methods (select_file, deselect_file, toggle_file_selection) that directly mirror the methods on the internal SelectionEngine. This violates encapsulation and creates two entry points for the same state change.
- D22 · Redundant Git operations. The Session type exposes specific Git loading methods that duplicate the functionality of the git module functions. This creates a confusing API where users can either call Session.load_git_diff() or git.get_git_diff(), leading to inconsistent usage patterns.
- D22 · Ambiguous prompt generation flow. 'generate_prompt' likely calls 'render_prompt' internally, but both are exposed. It is unclear if 'generate_prompt' does additional processing (e.g., token counting, validation) or if they are interchangeable. This creates confusion about the correct entry point for prompt generation.
- D22 · Inconsistent initialization paths. TemplateState can be initialized from either a Session or a Model. Since Model contains a Session, this creates redundant ways to achieve the same result. It is unclear why one would use one over the other, leading to potential state desynchronization if the underlying data differs.
- D22 · Fragmented template loading. 'utils.load_all_templates' suggests a general utility for loading templates, while 'BuiltinTemplates' is a specific type for built-in ones. It is unclear if 'utils.load_all_templates' loads both built-in and custom templates, or just built-in, creating confusion about the source of templates.
Rebuild cost & value ~ Modeled — €5,500–€28,000
| Cost to rebuild | €5,500–€28,000 |
|---|---|
| Domain complexity | Standard |
| Quality factor | 0.9× (at 66% quality) |
| Size & shape | Small · effort split not classified (source measured from disk; the effort-tier breakdown is a C#-only syntax walk) |
This codebase represents roughly ~0.1 person-years of build effort (about ~€17,000 to rebuild). Its weakest lens is Readiness at 56% — the part of that asset most exposed by the findings below.
Top priorities
Diagnosis — what's actually going on
Architecture — module dependency graph
Architecture — module dependency matrix
| depends on → | 1 code2prompt.model.commands | 2 code2prompt.model.statistics.types | 3 code2prompt.model.template.picker | 4 code2prompt.model.template.variable | 5 code2prompt_core.entity_map | 6 code2prompt_core.selection | 7 code2prompt.widgets.template.picker | 8 code2prompt.widgets.template.variable | 9 code2prompt_core.analysis | 10 code2prompt_core.file_processor | 11 code2prompt_core.template | 12 code2prompt_core.tokenizer | 13 code2prompt.model.template.editor | 14 code2prompt.token_map | 15 code2prompt_core.configuration | 16 code2prompt_core.file_processor.csv | 17 code2prompt.config_loader | 18 code2prompt.widgets.template.editor | 19 code2prompt_core.path | 20 code2prompt_core.session | 21 code2prompt.model.prompt_output | 22 code2prompt.model.settings | 23 code2prompt.model.statistics | 24 code2prompt.model.template | 25 code2prompt_python.python | 26 code2prompt.model | 27 code2prompt.view.formatters | 28 code2prompt_core.sort | 29 code2prompt.args | 30 code2prompt.tui | 31 code2prompt.utils | 32 code2prompt.widgets.file_selection | 33 code2prompt.widgets.output | 34 code2prompt.widgets.settings | 35 code2prompt.widgets.statistics_by_extension | 36 code2prompt.widgets.statistics_overview | 37 code2prompt.widgets.statistics_token_map | 38 code2prompt.widgets.template | 39 code2prompt.config | 40 code2prompt.main |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 code2prompt.model.commands | ||||||||||||||||||||||||||||||||||||||||
| 2 code2prompt.model.statistics.types | ||||||||||||||||||||||||||||||||||||||||
| 3 code2prompt.model.template.picker | ||||||||||||||||||||||||||||||||||||||||
| 4 code2prompt.model.template.variable | ||||||||||||||||||||||||||||||||||||||||
| 5 code2prompt_core.entity_map | ||||||||||||||||||||||||||||||||||||||||
| 6 code2prompt_core.selection | ||||||||||||||||||||||||||||||||||||||||
| 7 code2prompt.widgets.template.picker | 2 | |||||||||||||||||||||||||||||||||||||||
| 8 code2prompt.widgets.template.variable | 1 | |||||||||||||||||||||||||||||||||||||||
| 9 code2prompt_core.analysis | 1 | |||||||||||||||||||||||||||||||||||||||
| 10 code2prompt_core.file_processor | 2 | |||||||||||||||||||||||||||||||||||||||
| 11 code2prompt_core.template | 1 | |||||||||||||||||||||||||||||||||||||||
| 12 code2prompt_core.tokenizer | 2 | |||||||||||||||||||||||||||||||||||||||
| 13 code2prompt.model.template.editor | 1 | |||||||||||||||||||||||||||||||||||||||
| 14 code2prompt.token_map | 1 | 1 | ||||||||||||||||||||||||||||||||||||||
| 15 code2prompt_core.configuration | 2 | 2 | 4 | 1 | 2 | |||||||||||||||||||||||||||||||||||
| 16 code2prompt_core.file_processor.csv | 1 | |||||||||||||||||||||||||||||||||||||||
| 17 code2prompt.config_loader | 2 | |||||||||||||||||||||||||||||||||||||||
| 18 code2prompt.widgets.template.editor | 1 | |||||||||||||||||||||||||||||||||||||||
| 19 code2prompt_core.path | 1 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||||
| 20 code2prompt_core.session | 2 | 1 | 1 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||
| 21 code2prompt.model.prompt_output | 1 | 2 | ||||||||||||||||||||||||||||||||||||||
| 22 code2prompt.model.settings | 1 | |||||||||||||||||||||||||||||||||||||||
| 23 code2prompt.model.statistics | 1 | 2 | 1 | |||||||||||||||||||||||||||||||||||||
| 24 code2prompt.model.template | 1 | 2 | 1 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||
| 25 code2prompt_python.python | 3 | 2 | 1 | 2 | 1 | 2 | 3 | 1 | ||||||||||||||||||||||||||||||||
| 26 code2prompt.model | 2 | 1 | 2 | 1 | 1 | |||||||||||||||||||||||||||||||||||
| 27 code2prompt.view.formatters | 1 | 1 | ||||||||||||||||||||||||||||||||||||||
| 28 code2prompt_core.sort | 1 | |||||||||||||||||||||||||||||||||||||||
| 29 code2prompt.args | 1 | 2 | 1 | |||||||||||||||||||||||||||||||||||||
| 30 code2prompt.tui | 1 | 2 | 2 | |||||||||||||||||||||||||||||||||||||
| 31 code2prompt.utils | 1 | 1 | 2 | |||||||||||||||||||||||||||||||||||||
| 32 code2prompt.widgets.file_selection | 1 | |||||||||||||||||||||||||||||||||||||||
| 33 code2prompt.widgets.output | 1 | |||||||||||||||||||||||||||||||||||||||
| 34 code2prompt.widgets.settings | 1 | |||||||||||||||||||||||||||||||||||||||
| 35 code2prompt.widgets.statistics_by_extension | 1 | |||||||||||||||||||||||||||||||||||||||
| 36 code2prompt.widgets.statistics_overview | 1 | |||||||||||||||||||||||||||||||||||||||
| 37 code2prompt.widgets.statistics_token_map | 1 | |||||||||||||||||||||||||||||||||||||||
| 38 code2prompt.widgets.template | 1 | 1 | 1 | 1 | 1 | |||||||||||||||||||||||||||||||||||
| 39 code2prompt.config | 1 | 1 | 1 | |||||||||||||||||||||||||||||||||||||
| 40 code2prompt.main | 1 | 2 | 1 |
7→3 code2prompt.widgets.template.picker depends on code2prompt.model.template.picker✕
- Type pairs
- 2 distinct (type in code2prompt.widgets.template.picker → type in code2prompt.model.template.picker) references.
- Which types
code2prompt.widgets.template.picker.TemplatePickerWidget→code2prompt.model.template.picker.ActiveListcode2prompt.widgets.template.picker.TemplatePickerWidget→code2prompt.model.template.picker.PickerState
- Direction
- code2prompt.widgets.template.picker uses code2prompt.model.template.picker. Changing code2prompt.model.template.picker can break code2prompt.widgets.template.picker, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
8→4 code2prompt.widgets.template.variable depends on code2prompt.model.template.variable✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template.variable → type in code2prompt.model.template.variable) reference.
- Which types
code2prompt.widgets.template.variable.TemplateVariableWidget→code2prompt.model.template.variable.VariableState
- Direction
- code2prompt.widgets.template.variable uses code2prompt.model.template.variable. Changing code2prompt.model.template.variable can break code2prompt.widgets.template.variable, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
9→25 code2prompt_core.analysis depends on code2prompt_python.python cycle✕
- Type pairs
- 1 distinct (type in code2prompt_core.analysis → type in code2prompt_python.python) reference.
- Which types
code2prompt_core.analysis.TokenMapOptions→code2prompt_python.python.PyTokenMapOptions
- Direction
- code2prompt_core.analysis uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.analysis, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
10→25 code2prompt_core.file_processor depends on code2prompt_python.python cycle✕
- Type pairs
- 2 distinct (type in code2prompt_core.file_processor → type in code2prompt_python.python) references.
- Which types
code2prompt_core.file_processor.FileProcessorsConfig→code2prompt_python.python.PyFileProcessorsConfigcode2prompt_core.file_processor.IpynbProcessorConfig→code2prompt_python.python.PyIpynbProcessorConfig
- Direction
- code2prompt_core.file_processor uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.file_processor, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
11→25 code2prompt_core.template depends on code2prompt_python.python cycle✕
- Type pairs
- 1 distinct (type in code2prompt_core.template → type in code2prompt_python.python) reference.
- Which types
code2prompt_core.template.OutputFormat→code2prompt_python.python.PyOutputFormat
- Direction
- code2prompt_core.template uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.template, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
12→25 code2prompt_core.tokenizer depends on code2prompt_python.python cycle✕
- Type pairs
- 2 distinct (type in code2prompt_core.tokenizer → type in code2prompt_python.python) references.
- Which types
code2prompt_core.tokenizer.TokenFormat→code2prompt_python.python.PyTokenFormatcode2prompt_core.tokenizer.TokenizerType→code2prompt_python.python.PyTokenizerType
- Direction
- code2prompt_core.tokenizer uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.tokenizer, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
13→11 code2prompt.model.template.editor depends on code2prompt_core.template✕
- Type pairs
- 1 distinct (type in code2prompt.model.template.editor → type in code2prompt_core.template) reference.
- Which types
code2prompt.model.template.editor.EditorState→code2prompt_core.template.OutputFormat
- Direction
- code2prompt.model.template.editor uses code2prompt_core.template. Changing code2prompt_core.template can break code2prompt.model.template.editor, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
14→9 code2prompt.token_map depends on code2prompt_core.analysis✕
- Type pairs
- 1 distinct (type in code2prompt.token_map → type in code2prompt_core.analysis) reference.
- Which types
code2prompt.token_map.token_map$module→code2prompt_core.analysis.TokenMapEntry
- Direction
- code2prompt.token_map uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt.token_map, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
14→12 code2prompt.token_map depends on code2prompt_core.tokenizer✕
- Type pairs
- 1 distinct (type in code2prompt.token_map → type in code2prompt_core.tokenizer) reference.
- Which types
code2prompt.token_map.token_map$module→code2prompt_core.tokenizer.TokenFormat
- Direction
- code2prompt.token_map uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt.token_map, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
15→10 code2prompt_core.configuration depends on code2prompt_core.file_processor✕
- Type pairs
- 2 distinct (type in code2prompt_core.configuration → type in code2prompt_core.file_processor) references.
- Which types
code2prompt_core.configuration.Code2PromptConfig→code2prompt_core.file_processor.FileProcessorsConfigcode2prompt_core.configuration.TomlConfig→code2prompt_core.file_processor.FileProcessorsConfig
- Direction
- code2prompt_core.configuration uses code2prompt_core.file_processor. Changing code2prompt_core.file_processor can break code2prompt_core.configuration, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
15→11 code2prompt_core.configuration depends on code2prompt_core.template✕
- Type pairs
- 2 distinct (type in code2prompt_core.configuration → type in code2prompt_core.template) references.
- Which types
code2prompt_core.configuration.Code2PromptConfig→code2prompt_core.template.OutputFormatcode2prompt_core.configuration.TomlConfig→code2prompt_core.template.OutputFormat
- Direction
- code2prompt_core.configuration uses code2prompt_core.template. Changing code2prompt_core.template can break code2prompt_core.configuration, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
15→12 code2prompt_core.configuration depends on code2prompt_core.tokenizer✕
- Type pairs
- 4 distinct (type in code2prompt_core.configuration → type in code2prompt_core.tokenizer) references.
- Which types
code2prompt_core.configuration.Code2PromptConfig→code2prompt_core.tokenizer.TokenFormatcode2prompt_core.configuration.Code2PromptConfig→code2prompt_core.tokenizer.TokenizerTypecode2prompt_core.configuration.TomlConfig→code2prompt_core.tokenizer.TokenFormatcode2prompt_core.configuration.TomlConfig→code2prompt_core.tokenizer.TokenizerType
- Direction
- code2prompt_core.configuration uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt_core.configuration, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
15→25 code2prompt_core.configuration depends on code2prompt_python.python cycle✕
- Type pairs
- 1 distinct (type in code2prompt_core.configuration → type in code2prompt_python.python) reference.
- Which types
code2prompt_core.configuration.Code2PromptConfig→code2prompt_python.python.PyCode2PromptConfig
- Direction
- code2prompt_core.configuration uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.configuration, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
15→28 code2prompt_core.configuration depends on code2prompt_core.sort cycle✕
- Type pairs
- 2 distinct (type in code2prompt_core.configuration → type in code2prompt_core.sort) references.
- Which types
code2prompt_core.configuration.Code2PromptConfig→code2prompt_core.sort.FileSortMethodcode2prompt_core.configuration.TomlConfig→code2prompt_core.sort.FileSortMethod
- Direction
- code2prompt_core.configuration uses code2prompt_core.sort. Changing code2prompt_core.sort can break code2prompt_core.configuration, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
16→10 code2prompt_core.file_processor.csv depends on code2prompt_core.file_processor✕
- Type pairs
- 1 distinct (type in code2prompt_core.file_processor.csv → type in code2prompt_core.file_processor) reference.
- Which types
code2prompt_core.file_processor.csv.CsvProcessor→code2prompt_core.file_processor.FileProcessor
- Direction
- code2prompt_core.file_processor.csv uses code2prompt_core.file_processor. Changing code2prompt_core.file_processor can break code2prompt_core.file_processor.csv, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
17→15 code2prompt.config_loader depends on code2prompt_core.configuration✕
- Type pairs
- 2 distinct (type in code2prompt.config_loader → type in code2prompt_core.configuration) references.
- Which types
code2prompt.config_loader.ConfigSource→code2prompt_core.configuration.TomlConfigcode2prompt.config_loader.config_loader$module→code2prompt_core.configuration.OutputDestination
- Direction
- code2prompt.config_loader uses code2prompt_core.configuration. Changing code2prompt_core.configuration can break code2prompt.config_loader, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
18→13 code2prompt.widgets.template.editor depends on code2prompt.model.template.editor✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template.editor → type in code2prompt.model.template.editor) reference.
- Which types
code2prompt.widgets.template.editor.TemplateEditorWidget→code2prompt.model.template.editor.EditorState
- Direction
- code2prompt.widgets.template.editor uses code2prompt.model.template.editor. Changing code2prompt.model.template.editor can break code2prompt.widgets.template.editor, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
19→5 code2prompt_core.path depends on code2prompt_core.entity_map✕
- Type pairs
- 1 distinct (type in code2prompt_core.path → type in code2prompt_core.entity_map) reference.
- Which types
code2prompt_core.path.FileEntry→code2prompt_core.entity_map.EntitySummary
- Direction
- code2prompt_core.path uses code2prompt_core.entity_map. Changing code2prompt_core.entity_map can break code2prompt_core.path, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
19→6 code2prompt_core.path depends on code2prompt_core.selection✕
- Type pairs
- 1 distinct (type in code2prompt_core.path → type in code2prompt_core.selection) reference.
- Which types
code2prompt_core.path.path$module→code2prompt_core.selection.SelectionEngine
- Direction
- code2prompt_core.path uses code2prompt_core.selection. Changing code2prompt_core.selection can break code2prompt_core.path, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
19→9 code2prompt_core.path depends on code2prompt_core.analysis✕
- Type pairs
- 1 distinct (type in code2prompt_core.path → type in code2prompt_core.analysis) reference.
- Which types
code2prompt_core.path.FileEntry→code2prompt_core.analysis.EntryMetadata
- Direction
- code2prompt_core.path uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt_core.path, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
19→15 code2prompt_core.path depends on code2prompt_core.configuration✕
- Type pairs
- 1 distinct (type in code2prompt_core.path → type in code2prompt_core.configuration) reference.
- Which types
code2prompt_core.path.path$module→code2prompt_core.configuration.Code2PromptConfig
- Direction
- code2prompt_core.path uses code2prompt_core.configuration. Changing code2prompt_core.configuration can break code2prompt_core.path, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→5 code2prompt_core.session depends on code2prompt_core.entity_map✕
- Type pairs
- 2 distinct (type in code2prompt_core.session → type in code2prompt_core.entity_map) references.
- Which types
code2prompt_core.session.Code2PromptSession→code2prompt_core.entity_map.FileCodeMapcode2prompt_core.session.TemplateContext→code2prompt_core.entity_map.FileCodeMap
- Direction
- code2prompt_core.session uses code2prompt_core.entity_map. Changing code2prompt_core.entity_map can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→6 code2prompt_core.session depends on code2prompt_core.selection✕
- Type pairs
- 1 distinct (type in code2prompt_core.session → type in code2prompt_core.selection) reference.
- Which types
code2prompt_core.session.Code2PromptSession→code2prompt_core.selection.SelectionEngine
- Direction
- code2prompt_core.session uses code2prompt_core.selection. Changing code2prompt_core.selection can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→9 code2prompt_core.session depends on code2prompt_core.analysis✕
- Type pairs
- 1 distinct (type in code2prompt_core.session → type in code2prompt_core.analysis) reference.
- Which types
code2prompt_core.session.Code2PromptSession→code2prompt_core.analysis.CodebaseAnalysis
- Direction
- code2prompt_core.session uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→12 code2prompt_core.session depends on code2prompt_core.tokenizer✕
- Type pairs
- 1 distinct (type in code2prompt_core.session → type in code2prompt_core.tokenizer) reference.
- Which types
code2prompt_core.session.Code2PromptSession→code2prompt_core.tokenizer.TokenizerType
- Direction
- code2prompt_core.session uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→15 code2prompt_core.session depends on code2prompt_core.configuration✕
- Type pairs
- 1 distinct (type in code2prompt_core.session → type in code2prompt_core.configuration) reference.
- Which types
code2prompt_core.session.Code2PromptSession→code2prompt_core.configuration.Code2PromptConfig
- Direction
- code2prompt_core.session uses code2prompt_core.configuration. Changing code2prompt_core.configuration can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
20→19 code2prompt_core.session depends on code2prompt_core.path✕
- Type pairs
- 1 distinct (type in code2prompt_core.session → type in code2prompt_core.path) reference.
- Which types
code2prompt_core.session.SessionData→code2prompt_core.path.FileEntry
- Direction
- code2prompt_core.session uses code2prompt_core.path. Changing code2prompt_core.path can break code2prompt_core.session, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
21→9 code2prompt.model.prompt_output depends on code2prompt_core.analysis✕
- Type pairs
- 1 distinct (type in code2prompt.model.prompt_output → type in code2prompt_core.analysis) reference.
- Which types
code2prompt.model.prompt_output.AnalysisResults→code2prompt_core.analysis.TokenMapEntry
- Direction
- code2prompt.model.prompt_output uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt.model.prompt_output, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
21→20 code2prompt.model.prompt_output depends on code2prompt_core.session✕
- Type pairs
- 2 distinct (type in code2prompt.model.prompt_output → type in code2prompt_core.session) references.
- Which types
code2prompt.model.prompt_output.AnalysisResults→code2prompt_core.session.RenderedPromptcode2prompt.model.prompt_output.PromptOutputState→code2prompt_core.session.RenderedPrompt
- Direction
- code2prompt.model.prompt_output uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.model.prompt_output, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
22→20 code2prompt.model.settings depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.model.settings → type in code2prompt_core.session) reference.
- Which types
code2prompt.model.settings.SettingsState→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.model.settings uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.model.settings, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
23→2 code2prompt.model.statistics depends on code2prompt.model.statistics.types✕
- Type pairs
- 1 distinct (type in code2prompt.model.statistics → type in code2prompt.model.statistics.types) reference.
- Which types
code2prompt.model.statistics.StatisticsState→code2prompt.model.statistics.types.StatisticsView
- Direction
- code2prompt.model.statistics uses code2prompt.model.statistics.types. Changing code2prompt.model.statistics.types can break code2prompt.model.statistics, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
23→9 code2prompt.model.statistics depends on code2prompt_core.analysis✕
- Type pairs
- 2 distinct (type in code2prompt.model.statistics → type in code2prompt_core.analysis) references.
- Which types
code2prompt.model.statistics.StatisticsState→code2prompt_core.analysis.CodebaseAnalysiscode2prompt.model.statistics.StatisticsState→code2prompt_core.analysis.TokenMapEntry
- Direction
- code2prompt.model.statistics uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt.model.statistics, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
23→20 code2prompt.model.statistics depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.model.statistics → type in code2prompt_core.session) reference.
- Which types
code2prompt.model.statistics.StatisticsState→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.model.statistics uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.model.statistics, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→3 code2prompt.model.template depends on code2prompt.model.template.picker✕
- Type pairs
- 1 distinct (type in code2prompt.model.template → type in code2prompt.model.template.picker) reference.
- Which types
code2prompt.model.template.TemplateState→code2prompt.model.template.picker.PickerState
- Direction
- code2prompt.model.template uses code2prompt.model.template.picker. Changing code2prompt.model.template.picker can break code2prompt.model.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→4 code2prompt.model.template depends on code2prompt.model.template.variable✕
- Type pairs
- 2 distinct (type in code2prompt.model.template → type in code2prompt.model.template.variable) references.
- Which types
code2prompt.model.template.TemplateState→code2prompt.model.template.variable.VariableInfocode2prompt.model.template.TemplateState→code2prompt.model.template.variable.VariableState
- Direction
- code2prompt.model.template uses code2prompt.model.template.variable. Changing code2prompt.model.template.variable can break code2prompt.model.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→11 code2prompt.model.template depends on code2prompt_core.template✕
- Type pairs
- 1 distinct (type in code2prompt.model.template → type in code2prompt_core.template) reference.
- Which types
code2prompt.model.template.TemplateState→code2prompt_core.template.OutputFormat
- Direction
- code2prompt.model.template uses code2prompt_core.template. Changing code2prompt_core.template can break code2prompt.model.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→13 code2prompt.model.template depends on code2prompt.model.template.editor✕
- Type pairs
- 1 distinct (type in code2prompt.model.template → type in code2prompt.model.template.editor) reference.
- Which types
code2prompt.model.template.TemplateState→code2prompt.model.template.editor.EditorState
- Direction
- code2prompt.model.template uses code2prompt.model.template.editor. Changing code2prompt.model.template.editor can break code2prompt.model.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→20 code2prompt.model.template depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.model.template → type in code2prompt_core.session) reference.
- Which types
code2prompt.model.template.TemplateState→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.model.template uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.model.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
24→26 code2prompt.model.template depends on code2prompt.model cycle✕
- Type pairs
- 1 distinct (type in code2prompt.model.template → type in code2prompt.model) reference.
- Which types
code2prompt.model.template.TemplateState→code2prompt.model.Model
- Direction
- code2prompt.model.template uses code2prompt.model. Changing code2prompt.model can break code2prompt.model.template, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
25→9 code2prompt_python.python depends on code2prompt_core.analysis✕
- Type pairs
- 3 distinct (type in code2prompt_python.python → type in code2prompt_core.analysis) references.
- Which types
code2prompt_python.python.PyEntryMetadata→code2prompt_core.analysis.EntryMetadatacode2prompt_python.python.PyExtensionStat→code2prompt_core.analysis.ExtensionStatcode2prompt_python.python.PyTokenMapEntry→code2prompt_core.analysis.TokenMapEntry
- Direction
- code2prompt_python.python uses code2prompt_core.analysis. Changing code2prompt_core.analysis can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→10 code2prompt_python.python depends on code2prompt_core.file_processor✕
- Type pairs
- 2 distinct (type in code2prompt_python.python → type in code2prompt_core.file_processor) references.
- Which types
code2prompt_python.python.PyFileProcessorsConfig→code2prompt_core.file_processor.FileProcessorsConfigcode2prompt_python.python.PyIpynbProcessorConfig→code2prompt_core.file_processor.IpynbProcessorConfig
- Direction
- code2prompt_python.python uses code2prompt_core.file_processor. Changing code2prompt_core.file_processor can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→11 code2prompt_python.python depends on code2prompt_core.template✕
- Type pairs
- 1 distinct (type in code2prompt_python.python → type in code2prompt_core.template) reference.
- Which types
code2prompt_python.python.PyOutputFormat→code2prompt_core.template.OutputFormat
- Direction
- code2prompt_python.python uses code2prompt_core.template. Changing code2prompt_core.template can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→12 code2prompt_python.python depends on code2prompt_core.tokenizer✕
- Type pairs
- 2 distinct (type in code2prompt_python.python → type in code2prompt_core.tokenizer) references.
- Which types
code2prompt_python.python.PyTokenFormat→code2prompt_core.tokenizer.TokenFormatcode2prompt_python.python.PyTokenizerType→code2prompt_core.tokenizer.TokenizerType
- Direction
- code2prompt_python.python uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→15 code2prompt_python.python depends on code2prompt_core.configuration✕
- Type pairs
- 1 distinct (type in code2prompt_python.python → type in code2prompt_core.configuration) reference.
- Which types
code2prompt_python.python.PyCode2PromptConfig→code2prompt_core.configuration.Code2PromptConfig
- Direction
- code2prompt_python.python uses code2prompt_core.configuration. Changing code2prompt_core.configuration can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→19 code2prompt_python.python depends on code2prompt_core.path✕
- Type pairs
- 2 distinct (type in code2prompt_python.python → type in code2prompt_core.path) references.
- Which types
code2prompt_python.python.PyCodebaseAnalysis→code2prompt_core.path.FileEntrycode2prompt_python.python.PyFileEntry→code2prompt_core.path.FileEntry
- Direction
- code2prompt_python.python uses code2prompt_core.path. Changing code2prompt_core.path can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→20 code2prompt_python.python depends on code2prompt_core.session✕
- Type pairs
- 3 distinct (type in code2prompt_python.python → type in code2prompt_core.session) references.
- Which types
code2prompt_python.python.PyCode2PromptSession→code2prompt_core.session.Code2PromptSessioncode2prompt_python.python.PyRenderedPrompt→code2prompt_core.session.RenderedPromptcode2prompt_python.python.PySessionData→code2prompt_core.session.SessionData
- Direction
- code2prompt_python.python uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt_python.python, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
25→28 code2prompt_python.python depends on code2prompt_core.sort cycle✕
- Type pairs
- 1 distinct (type in code2prompt_python.python → type in code2prompt_core.sort) reference.
- Which types
code2prompt_python.python.PyFileSortMethod→code2prompt_core.sort.FileSortMethod
- Direction
- code2prompt_python.python uses code2prompt_core.sort. Changing code2prompt_core.sort can break code2prompt_python.python, not the reverse.
- Position
- Above the diagonal — a cycle. Neither module can be changed, tested or deployed independently until one of these dependencies goes.
26→20 code2prompt.model depends on code2prompt_core.session✕
- Type pairs
- 2 distinct (type in code2prompt.model → type in code2prompt_core.session) references.
- Which types
code2prompt.model.DisplayFileNode→code2prompt_core.session.Code2PromptSessioncode2prompt.model.Model→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.model uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.model, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
26→21 code2prompt.model depends on code2prompt.model.prompt_output✕
- Type pairs
- 1 distinct (type in code2prompt.model → type in code2prompt.model.prompt_output) reference.
- Which types
code2prompt.model.Model→code2prompt.model.prompt_output.PromptOutputState
- Direction
- code2prompt.model uses code2prompt.model.prompt_output. Changing code2prompt.model.prompt_output can break code2prompt.model, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
26→22 code2prompt.model depends on code2prompt.model.settings✕
- Type pairs
- 2 distinct (type in code2prompt.model → type in code2prompt.model.settings) references.
- Which types
code2prompt.model.Model→code2prompt.model.settings.SettingsGroupcode2prompt.model.Model→code2prompt.model.settings.SettingsState
- Direction
- code2prompt.model uses code2prompt.model.settings. Changing code2prompt.model.settings can break code2prompt.model, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
26→23 code2prompt.model depends on code2prompt.model.statistics✕
- Type pairs
- 1 distinct (type in code2prompt.model → type in code2prompt.model.statistics) reference.
- Which types
code2prompt.model.Model→code2prompt.model.statistics.StatisticsState
- Direction
- code2prompt.model uses code2prompt.model.statistics. Changing code2prompt.model.statistics can break code2prompt.model, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
26→24 code2prompt.model depends on code2prompt.model.template✕
- Type pairs
- 1 distinct (type in code2prompt.model → type in code2prompt.model.template) reference.
- Which types
code2prompt.model.Model→code2prompt.model.template.TemplateState
- Direction
- code2prompt.model uses code2prompt.model.template. Changing code2prompt.model.template can break code2prompt.model, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
27→20 code2prompt.view.formatters depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.view.formatters → type in code2prompt_core.session) reference.
- Which types
code2prompt.view.formatters.formatters$module→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.view.formatters uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.view.formatters, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
27→22 code2prompt.view.formatters depends on code2prompt.model.settings✕
- Type pairs
- 1 distinct (type in code2prompt.view.formatters → type in code2prompt.model.settings) reference.
- Which types
code2prompt.view.formatters.formatters$module→code2prompt.model.settings.SettingsGroup
- Direction
- code2prompt.view.formatters uses code2prompt.model.settings. Changing code2prompt.model.settings can break code2prompt.view.formatters, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
28→25 code2prompt_core.sort depends on code2prompt_python.python✕
- Type pairs
- 1 distinct (type in code2prompt_core.sort → type in code2prompt_python.python) reference.
- Which types
code2prompt_core.sort.FileSortMethod→code2prompt_python.python.PyFileSortMethod
- Direction
- code2prompt_core.sort uses code2prompt_python.python. Changing code2prompt_python.python can break code2prompt_core.sort, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
29→11 code2prompt.args depends on code2prompt_core.template✕
- Type pairs
- 1 distinct (type in code2prompt.args → type in code2prompt_core.template) reference.
- Which types
code2prompt.args.Cli→code2prompt_core.template.OutputFormat
- Direction
- code2prompt.args uses code2prompt_core.template. Changing code2prompt_core.template can break code2prompt.args, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
29→12 code2prompt.args depends on code2prompt_core.tokenizer✕
- Type pairs
- 2 distinct (type in code2prompt.args → type in code2prompt_core.tokenizer) references.
- Which types
code2prompt.args.Cli→code2prompt_core.tokenizer.TokenFormatcode2prompt.args.Cli→code2prompt_core.tokenizer.TokenizerType
- Direction
- code2prompt.args uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt.args, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
29→28 code2prompt.args depends on code2prompt_core.sort✕
- Type pairs
- 1 distinct (type in code2prompt.args → type in code2prompt_core.sort) reference.
- Which types
code2prompt.args.Cli→code2prompt_core.sort.FileSortMethod
- Direction
- code2prompt.args uses code2prompt_core.sort. Changing code2prompt_core.sort can break code2prompt.args, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
30→1 code2prompt.tui depends on code2prompt.model.commands✕
- Type pairs
- 1 distinct (type in code2prompt.tui → type in code2prompt.model.commands) reference.
- Which types
code2prompt.tui.TuiApp→code2prompt.model.commands.Cmd
- Direction
- code2prompt.tui uses code2prompt.model.commands. Changing code2prompt.model.commands can break code2prompt.tui, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
30→20 code2prompt.tui depends on code2prompt_core.session✕
- Type pairs
- 2 distinct (type in code2prompt.tui → type in code2prompt_core.session) references.
- Which types
code2prompt.tui.TuiApp→code2prompt_core.session.Code2PromptSessioncode2prompt.tui.tui$module→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.tui uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.tui, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
30→26 code2prompt.tui depends on code2prompt.model✕
- Type pairs
- 2 distinct (type in code2prompt.tui → type in code2prompt.model) references.
- Which types
code2prompt.tui.TuiApp→code2prompt.model.Messagecode2prompt.tui.TuiApp→code2prompt.model.Model
- Direction
- code2prompt.tui uses code2prompt.model. Changing code2prompt.model can break code2prompt.tui, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
31→12 code2prompt.utils depends on code2prompt_core.tokenizer✕
- Type pairs
- 1 distinct (type in code2prompt.utils → type in code2prompt_core.tokenizer) reference.
- Which types
code2prompt.utils.utils$module→code2prompt_core.tokenizer.TokenFormat
- Direction
- code2prompt.utils uses code2prompt_core.tokenizer. Changing code2prompt_core.tokenizer can break code2prompt.utils, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
31→20 code2prompt.utils depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.utils → type in code2prompt_core.session) reference.
- Which types
code2prompt.utils.utils$module→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.utils uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.utils, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
31→26 code2prompt.utils depends on code2prompt.model✕
- Type pairs
- 2 distinct (type in code2prompt.utils → type in code2prompt.model) references.
- Which types
code2prompt.utils.DisplayNodeWithSelection→code2prompt.model.DisplayFileNodecode2prompt.utils.utils$module→code2prompt.model.DisplayFileNode
- Direction
- code2prompt.utils uses code2prompt.model. Changing code2prompt.model can break code2prompt.utils, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
32→26 code2prompt.widgets.file_selection depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.file_selection → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.file_selection.FileSelectionWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.file_selection uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.file_selection, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
33→26 code2prompt.widgets.output depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.output → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.output.OutputWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.output uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.output, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
34→26 code2prompt.widgets.settings depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.settings → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.settings.SettingsWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.settings uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.settings, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
35→26 code2prompt.widgets.statistics_by_extension depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.statistics_by_extension → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.statistics_by_extension.StatisticsByExtensionWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.statistics_by_extension uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.statistics_by_extension, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
36→26 code2prompt.widgets.statistics_overview depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.statistics_overview → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.statistics_overview.StatisticsOverviewWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.statistics_overview uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.statistics_overview, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
37→26 code2prompt.widgets.statistics_token_map depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.statistics_token_map → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.statistics_token_map.StatisticsTokenMapWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.statistics_token_map uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.statistics_token_map, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
38→7 code2prompt.widgets.template depends on code2prompt.widgets.template.picker✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template → type in code2prompt.widgets.template.picker) reference.
- Which types
code2prompt.widgets.template.TemplateWidget→code2prompt.widgets.template.picker.TemplatePickerWidget
- Direction
- code2prompt.widgets.template uses code2prompt.widgets.template.picker. Changing code2prompt.widgets.template.picker can break code2prompt.widgets.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
38→8 code2prompt.widgets.template depends on code2prompt.widgets.template.variable✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template → type in code2prompt.widgets.template.variable) reference.
- Which types
code2prompt.widgets.template.TemplateWidget→code2prompt.widgets.template.variable.TemplateVariableWidget
- Direction
- code2prompt.widgets.template uses code2prompt.widgets.template.variable. Changing code2prompt.widgets.template.variable can break code2prompt.widgets.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
38→18 code2prompt.widgets.template depends on code2prompt.widgets.template.editor✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template → type in code2prompt.widgets.template.editor) reference.
- Which types
code2prompt.widgets.template.TemplateWidget→code2prompt.widgets.template.editor.TemplateEditorWidget
- Direction
- code2prompt.widgets.template uses code2prompt.widgets.template.editor. Changing code2prompt.widgets.template.editor can break code2prompt.widgets.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
38→24 code2prompt.widgets.template depends on code2prompt.model.template✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template → type in code2prompt.model.template) reference.
- Which types
code2prompt.widgets.template.TemplateWidget→code2prompt.model.template.TemplateState
- Direction
- code2prompt.widgets.template uses code2prompt.model.template. Changing code2prompt.model.template can break code2prompt.widgets.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
38→26 code2prompt.widgets.template depends on code2prompt.model✕
- Type pairs
- 1 distinct (type in code2prompt.widgets.template → type in code2prompt.model) reference.
- Which types
code2prompt.widgets.template.TemplateWidget→code2prompt.model.Model
- Direction
- code2prompt.widgets.template uses code2prompt.model. Changing code2prompt.model can break code2prompt.widgets.template, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
39→17 code2prompt.config depends on code2prompt.config_loader✕
- Type pairs
- 1 distinct (type in code2prompt.config → type in code2prompt.config_loader) reference.
- Which types
code2prompt.config.config$module→code2prompt.config_loader.ConfigSource
- Direction
- code2prompt.config uses code2prompt.config_loader. Changing code2prompt.config_loader can break code2prompt.config, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
39→20 code2prompt.config depends on code2prompt_core.session✕
- Type pairs
- 1 distinct (type in code2prompt.config → type in code2prompt_core.session) reference.
- Which types
code2prompt.config.config$module→code2prompt_core.session.Code2PromptSession
- Direction
- code2prompt.config uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.config, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
39→29 code2prompt.config depends on code2prompt.args✕
- Type pairs
- 1 distinct (type in code2prompt.config → type in code2prompt.args) reference.
- Which types
code2prompt.config.config$module→code2prompt.args.Cli
- Direction
- code2prompt.config uses code2prompt.args. Changing code2prompt.args can break code2prompt.config, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
40→15 code2prompt.main depends on code2prompt_core.configuration✕
- Type pairs
- 1 distinct (type in code2prompt.main → type in code2prompt_core.configuration) reference.
- Which types
code2prompt.main.main$module→code2prompt_core.configuration.OutputDestination
- Direction
- code2prompt.main uses code2prompt_core.configuration. Changing code2prompt_core.configuration can break code2prompt.main, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
40→20 code2prompt.main depends on code2prompt_core.session✕
- Type pairs
- 2 distinct (type in code2prompt.main → type in code2prompt_core.session) references.
- Which types
code2prompt.main.main$module→code2prompt_core.session.Code2PromptSessioncode2prompt.main.main$module→code2prompt_core.session.RenderedPrompt
- Direction
- code2prompt.main uses code2prompt_core.session. Changing code2prompt_core.session can break code2prompt.main, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
40→29 code2prompt.main depends on code2prompt.args✕
- Type pairs
- 1 distinct (type in code2prompt.main → type in code2prompt.args) reference.
- Which types
code2prompt.main.main$module→code2prompt.args.Cli
- Direction
- code2prompt.main uses code2prompt.args. Changing code2prompt.args can break code2prompt.main, not the reverse.
- Position
- Below the diagonal — points down the layering, which is what you want.
At a glance — Code Health
At a glance — Architecture
At a glance — Maturity
At a glance — Readiness
At a glance — Security
At a glance — Performance
Security & Compliance — OWASP Top-10 mapping
| OWASP category | Findings | Severity |
|---|---|---|
| A03:2021 — Injection | 16 | High / Critical |
| A06:2021 — Vulnerable & Outdated Components | 3 | Medium |
Roadmap
First, extend structured logging across all runnable modules to ensure full production diagnosability. Next, integrate static analysis into the CI pipeline to block security regressions before they land, and verify that deployment approvals are properly enforced to prevent bad builds from reaching users. Finally, maintain a changelog for release hygiene and resolve the missing architectural decision records to complete the documentation baseline.
| Do this | Helps | Effort | Dimension |
|---|---|---|---|
| Extend structured logging to the remaining runnable modules so everything you run is diagnosable in production. | +8.8 pts | Medium | Observability |
| Add a SAST step to CI running what this repository's stack ships: cargo-audit / cargo-deny (or clippy) — or `semgrep --config=auto`, which runs on any language — so a security regression fails the build instead of landing. | +8.8 pts | Medium | Security & performance tooling |
| The release job declares an environment, but its protection rules are not visible from the repository — confirm required reviewers are attached, or publish as a draft release so a bad build can be stopped before users can download it. | +8.8 pts | Medium | Deployment & Rollback |
| Keep a changelog (e.g. Keep-a-Changelog) recording what shipped in each release. | +8.8 pts | Medium | Release Hygiene |
| Resolve the 1 No ADRs found finding(s) in ADR Quality. | +3.6 pts | Low | ADR Quality |
| Resolve the 1 Inverted test pyramid finding(s) in Test Distribution. | +3.4 pts | Low | Test Distribution |
| Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form). | +3.6 pts | Medium | Architecture documentation |
| Add a 'Testing' section to the root README — how to run the test suite. | +3.0 pts | Medium | Documentation (README) |
File quality
| File | Score | Band | Worst signal |
|---|---|---|---|
| REDACTED | 2.3 | Slop | Static Analysis (SAST): High: REDACTED |
| REDACTED | 5.1 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 5.8 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 6.3 | Mixed | Dependency Vulnerabilities: Medium advisory (unmaintained): REDACTED |
| crates/code2prompt/src/model/settings.rs | 7.0 | Mixed | Cyclomatic Complexity: SettingsState::update_setting_by_key (cyclomatic 23) |
| crates/code2prompt/src/model/mod.rs | 7.0 | Mixed | Cyclomatic Complexity: Model::update (cyclomatic 79) |
| crates/code2prompt/src/widgets/statistics_by_extension.rs | 7.1 | Mixed | God Classes: MethodTooLong: StatisticsByExtensionWidget.render |
| crates/code2prompt-core/src/git.rs | 7.1 | Mixed | Code Duplication: Edited copy of a member (25 corresponding lines) |
| crates/code2prompt/src/tui.rs | 7.2 | Mixed | Cyclomatic Complexity: TuiApp::handle_key_event (cyclomatic 27) |
| crates/code2prompt/src/config.rs | 7.2 | Mixed | Cyclomatic Complexity: code2prompt::config::build_session (cyclomatic 25) |
| REDACTED | 7.2 | Mixed | Static Analysis (SAST): High: REDACTED |
| REDACTED | 7.2 | Mixed | Static Analysis (SAST): High: REDACTED |
| crates/code2prompt-python/src/python.rs | 7.4 | Mixed | God Classes: FileTooLong: src/python.rs |
| crates/code2prompt/src/utils.rs | 7.8 | Mixed | Cognitive Complexity: code2prompt::utils::collect_visible_nodes_recursive (cognitive 37) |
| crates/code2prompt/src/widgets/template/picker.rs | 7.8 | Mixed | Cognitive Complexity: TemplatePickerWidget::render (cognitive 30) |
| crates/code2prompt-core/src/file_processor/ipynb.rs | 7.8 | Mixed | Cognitive Complexity: JupyterNotebookProcessor::process (cognitive 23) |
| crates/code2prompt-core/src/analysis.rs | 7.8 | Mixed | Cognitive Complexity: code2prompt_core::analysis::select_nodes_to_display (cognitive 20) |
| crates/code2prompt/src/widgets/file_selection.rs | 7.8 | Mixed | Cognitive Complexity: FileSelectionWidget::render (cognitive 19) |
| crates/code2prompt/src/config_loader.rs | 7.8 | Mixed | Cognitive Complexity: code2prompt::config_loader::load_config (cognitive 17) |
| crates/code2prompt/src/widgets/statistics_overview.rs | 7.8 | Mixed | God Classes: MethodTooLong: StatisticsOverviewWidget.render |
How the grades work
A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.
Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.
Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.
Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.
Methodology & how to trust this report
Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 33 of 37 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 4 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.9 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.
What we checked — 37 dimensions across the health lenses
- Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 74 of 96 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line.
- Is there a tool behind the number? Every score below names the method that produced it — Roslyn, git, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
- Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
Tools & methods
| Method | Backs | Version | Evaluator |
|---|---|---|---|
| Roslyn static analysis | Complexity, cohesion, coupling, dead code, API surface, layering | 5.3.0 | ✓ deterministic |
| Native secret scanner | Hardcoded secrets / credentials | 1.0.0 | ✓ deterministic |
| Watchdog duplication detector (in-process) | Code duplication | 1.0.0 | ✓ deterministic |
| Coverage (coverlet / dotnet-coverage) | Line & branch coverage | 10.0.400 | ✓ deterministic |
| NuGet / dotnet | Outdated, vulnerable & deprecated dependencies | 10.0.400 | ✓ deterministic |
| git / LibGit2Sharp | Churn hotspots, knowledge concentration, history | 2.43.0 · 0.31.0 | ✓ deterministic |
| gitleaks · semgrep · trivy | Secrets in history, SAST, CVEs, IaC & container, PII / GDPR | 1.86.0 · 0.69.3 | ✓ deterministic |
| LLM (sampled · advisory) | Documentation quality, ADR conformance, naming — sampled over a bounded sample; advisory, never a deterministic measurement | Local LLM | ◐ LLM · sampled · advisory |
Run transparency — what happened this run
- D11 Test Reliability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test reliability not scored — the JavaScript/TypeScript suite (jest via `pnpm install --frozen-lockfile --ignore-scripts` in website/ (0 tests)) ran but surfaced no test cases to the runner, so flakiness couldn't be exercised.
- D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (36 contributor(s) across 705 commit(s) sampled, automation and bot accounts excluded). One of them holds 82% of the history; the other 35 hold 0.5% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
- D44 Platform End-of-Life — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This dimension reads a project's own statement about the platform it runs on: a TargetFramework in a .NET project file, a .nvmrc or .python-version, a capped requires-python, a Rust toolchain file or Cargo.toml rust-version, a .go-version, .java-version, .ruby-version, .tool-versions or .sdkmanrc, a go.mod go directive, a Maven or Gradle Java level or toolchain, a Gemfile's ruby directive, a mix.exs elixir requirement, a rebar.config minimum_otp_vsn, a pubspec.yaml SDK constraint, a build.sbt scalaVersion, or a framework major pinned by a dependency constraint. This repository carries none of them, so nothing about its platform was established. That is a gap in this analyzer's coverage, NOT a finding that the platform is supported — a language whose runtime is declared elsewhere (Package.swift, a Dockerfile) is simply not read here yet.
- AX1 Captive dependencies — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- AX2 Stateful singletons — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- AX6 Interface segregation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is computed over the public interfaces this run's compilations declare, and none was loaded, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- C1 Data Protection — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These personal data controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks personal data controls.
- C2 Access Controls — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These authorization controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks authorization controls.
- C3 Audit Trail — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These audit controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks audit controls.
- C4 Data Retention — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These retention controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks retention controls.
- C5 Data-Subject Rights — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These data-subject rights controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks data-subject rights controls.
- ED5 Idempotency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check finds retry-prone mutations by walking the repository's declared types, and NONE was loaded on this run, so it had nothing to look at. That is a limit of the analyzer's reach — it reads .NET projects — not a finding that this repository has no command handlers or message consumers.
- GD1 Unfinished & placeholder code — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- IC1 Incompleteness & stubs — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- P10 Library API & versioning — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads NuGet packaging and C# public API only, and no .NET project was loaded for this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- P5 DR & Backup — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. No backup/snapshot/replication config, RTO/RPO or restore-procedure documentation was found — and no production persistence was detected either (no data-access packages, no data-store services, no database resources), so there is nothing in this repository whose loss a DR control would recover. If this system's data lives in a platform or ops repo we can't see, that's where the DR evidence belongs.
- PF1 Benchmark discipline — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- PF2 Allocation hygiene — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- S1 Web-Security Posture — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These web-security controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks web-security controls.
- X1 Async correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X10 Duplicated predicate — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X12 Unreachable branch — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X13 Undrained process stream — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X14 Bypassable address classification — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X15 Unvalidated length from an untrusted reader — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X16 Unfloored truncation loop — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X17 Uncapped recursion over a caller-supplied document — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X18 Disposal-pattern correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X19 Unrestored process-global state — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X2 Cancellation propagation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X20 Mistyped argument guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X21 Side-effecting pattern guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X22 Contradicted release guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X23 Unguarded diagnostic materialisation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X24 Document value interpolated into markup unescaped — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X25 Inert configuration knob — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X26 Unsynchronised callback handoff — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X27 Collection changed while being enumerated — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X28 Index access outside its own emptiness guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X29 Per-element action decided by a fixed element — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X3 Exception handling — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X30 Support guard that admits what it rejects — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X32 Type resolved by simple name across every loaded assembly — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X4 Structured logging — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X5 Nullable reference types — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X6 Hand-rolled structured-format parsing — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X7 Silent fallback defaults — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
Limitations & what we did not check
Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
- D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
- D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
- D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
- D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
- D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
- D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
- D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
- D12 Dependency Hygiene: Dependency health reads manifests and lockfiles — a vulnerability in a vendored/copied dependency, or risk from how a dependency is actually used, is outside this view.
- D13 Secret Scanning: Secret detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
- D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
- D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
- D19 Documentation Quality: Documentation quality is judged by an LLM over a bounded sample of docs — it reads what is written, not whether the docs match the running system, and it is advisory, not a measurement. Its critique rows are drawn from a closed category vocabulary and each row means the same thing in every run, so two scans can be compared row by row; the SET that fires is still a sample, and does not repeat exactly. Measured on one frozen input, six scans at one engine SHA: 2-5 critique rows per scan, 8 distinct rows across the six, 3 of those 8 seen in only one scan. So a D19 row is evidence about the documentation, but a COUNT of D19 rows is not a quantity — never read a change in it as an improvement or a regression.
- D20 ADR Quality: ADR quality is an LLM read of the decision records present — it cannot know about decisions made and never recorded, and its verdict is sampled and advisory.
- D21 Naming Consistency: Naming quality is an LLM judgement over a bounded sample — it assesses clarity/consistency of the names it sees, not domain-correctness, and is advisory.
- D22 Internal API Consistency: API-surface coherence is an LLM judgement over a sample of the public surface — consistency of intent across the whole API is approximated, not exhaustively verified.
- D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
- D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
- D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
- D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
- D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
- D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
- D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
- AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
- AX9 CQS / query purity: Handlers are found by interface/name convention — a query handler using neither is not seen. Mutation is a resolved write/publish invocation (SaveChanges/repository/bus), so a write hidden behind a hand-rolled wrapper, reflection, or a string-keyed service locator resolves to a non-persistence type and isn't flagged; it detects that a query writes state, not whether the write is a legitimate read-side cache update. Clean means "no resolved write/publish in a query body", not a proof of CQS purity.
- M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
- P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
- P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.
The LLM boundary
Dimensions
D1 · Cyclomatic Complexity
5 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was Model::update at 79. A further 3 method(s) were over the threshold but excluded as flat dispatchers (a long switch/match over independent cases: many branches, almost no nesting), the largest being TuiApp::convert_crossterm_key at 21 — they are counted neither in the figure above nor in this dimension's score. 1 file carries no cyclomatic complexity row at all for this reason — every one of its over-threshold functions was excluded, so the exclusion is disclosed nowhere in the file itself: crates/code2prompt/src/widgets/statistics_token_map.rs (StatisticsTokenMapWidget::render at 17). They are named here because the per-file figures other dimensions report are taken BEFORE this exclusion, so such a file can show a high maximum complexity elsewhere in this report and nothing here, with nothing to reconcile the two.
What to do
- Resolve the 2 TuiApp finding(s) in Cyclomatic Complexity — start with tui.rs (2). — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 1 Model finding(s) in Cyclomatic Complexity — start with mod.rs. — One of this dimension's main actionable groups (1 warning-level).
- Resolve the 1 code2prompt finding(s) in Cyclomatic Complexity — start with config.rs. — One of this dimension's main actionable groups (1 warning-level).
- Enforce Cyclomatic Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D2 · Cognitive Complexity
17 method(s) exceeded the cognitive complexity threshold of 15; the worst was Model::update at 121.
What to do
- Resolve the 6 code2prompt finding(s) in Cognitive Complexity — start with utils.rs (2), config.rs, main.rs. — One of this dimension's main actionable groups (6 warning-level).
- Resolve the 2 code2prompt_core finding(s) in Cognitive Complexity — start with path.rs, analysis.rs. — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 2 TuiApp finding(s) in Cognitive Complexity — start with tui.rs (2). — One of this dimension's main actionable groups (2 warning-level).
- Enforce Cognitive Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D3 · God Classes
7 over-large unit(s) detected — types, modules or files that carry too much.
What to do
- Resolve the 4 MethodTooLong finding(s) in God Classes — start with mod.rs, statistics_by_extension.rs, statistics_overview.rs. — One of this dimension's main actionable groups (4 warning-level).
- Resolve the 2 FunctionTooLong finding(s) in God Classes — start with formatters.rs, config.rs. — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 1 FileTooLong finding(s) in God Classes — start with python.rs. — One of this dimension's main actionable groups (1 warning-level).
- Enforce God Classes in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D4 · Code Duplication
21 duplicated block group(s) detected. A further 2 rows report members as variants of one another; they aggregate block groups already counted above and are not themselves counted.
What to do
- Resolve the 3 Duplicated block (9 lines × 2) finding(s) in Code Duplication — start with python.rs (2), config.rs. — One of this dimension's main actionable groups (3 warning-level).
- Resolve the 3 Duplicated block (8 lines × 2) finding(s) in Code Duplication — start with git.rs (2), picker.rs. — One of this dimension's main actionable groups (3 warning-level).
- Resolve the 2 Duplicated block (18 lines × 2) finding(s) in Code Duplication — start with statistics_by_extension.rs, git.rs. — One of this dimension's main actionable groups (2 warning-level).
- Enforce Code Duplication in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
D5 · Coupling
3 production modules (Cargo), 0 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations; 1 module(s) off the main sequence.
What to do
- Resolve the 1 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).
- Enforce Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D6 · Cohesion (LCOM4)
0 of 18 classes have LCOM4 above 3.
D9 · Test Distribution
168 test methods: 26 unit, 142 integration, 0 BDD, 0 e2e. The Rust suite contributes 148 `#[test]` function(s) across 18 file(s) declaring at least one; its unit/integration split is Cargo's own — 16 of those file(s) are integration-test targets under a crate's tests/ directory, and the rest are #[test] functions compiled into the crate they test. The Python suite contributes 20 test function(s) across 6 file(s) declaring at least one — every `def test…` in a file pytest or unittest would collect, which is those frameworks' own definition of a case; a parametrize table counts once, so this is a floor. Its tier split is read from file names and paths only.
D12 · Dependency Hygiene
0 outdated, 0 yanked direct Cargo dependencies. Only DIRECT edges are graded: a transitive crate cannot be moved past what its parent's requirement admits, so reporting one would be advice its owner cannot take. A newer release is reported only where this repository's OWN requirement already admits it, so the remedy is `cargo update` and never a manifest edit — which means a release outside the declared range is deliberately NOT charged, because a written-down constraint is a decision rather than a defect. Note that a bare requirement is a CARET, and for a 0.x crate its ceiling is the minor. Whether any crate is UNMAINTAINED is not graded — crates.io publishes no maintenance status, and release age does not stand in for one. Known CVEs in this dependency graph are D30's question, read from REDACTED there.
D13 · Secret Scanning
Secret scan ran and found no leaked secrets.
D15 · Churn × Complexity Hotspots
Top hotspots: crates/code2prompt/src/main.rs (6×15=90)
What to do
- Resolve the 1 Hotspot finding(s) in Churn × Complexity Hotspots — start with main.rs. — One of this dimension's main actionable groups (1 warning-level).
D17 · Explicit Debt
0 deducted task-comment markers across 9690 LoC (0.0/KLoC) → score 10.0. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.
D19 · Documentation Quality
The repository's root README (Code2Prompt) is excellent: it states the project clearly and links to a live demo, an overview of the website/ directory READMEs, and a complete list of documentation sources. The website/src/content/docs directories are well-structured with a consistent heading outline for each document, covering installation, usage, configuration, and contribution guidance across multiple files (e.g., glob_patterns.md, tokenizers.md, how_to_filter_files.md). This Code2Prompt documentation set is excellent. It consists of four README-style directory-level documents (glob_patterns.md, tokenizers.md, how_to_filter_files.md, ssh.md) plus architecture/Docs markdown files covering explanations, a command-line-options reference, and a default-template guide, totaling 42 documents with an outline showing every section present in the visible content. The set is comprehensive: it explains glob patterns (wildcards, **, { }, examples), tokenization (tiktoken, encoding options, supported models), file-filtering commands (--include/--exclude, --line-numbers, --git-diff-branch), and SSH usage with a troubleshooting note; it also has an overview of the project for each directory. The only unshown element is a root-level README covering installation, usage, contribution, and licensing.
D20 · ADR Quality
No architecture decision records were found.
What to do
- Resolve the 1 No ADRs found finding(s) in ADR Quality. — One of this dimension's main actionable groups (1 recommendation-level).
D21 · Naming Consistency
0 naming inconsistencies across 0 sampled symbols.
D22 · Internal API Consistency
5 API inconsistencies across 73 exposed types.
What to do
- Resolve the 1 Duplicate selection logic across Session and SelectionEngine. The… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
- Resolve the 1 Redundant Git operations. The Session type exposes specific Git loading… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
- Resolve the 1 Ambiguous prompt generation flow. 'generate_prompt' likely calls… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
D26 · Project Cohesion
0 of 3 build units (Cargo) flagged as possibly oversized/incoherent.
D28 · Secrets (history)
gitleaks scanned the full history AND the current working tree and found no secrets.
D29 · Static Analysis (SAST)
16 finding(s): 0 critical, 15 high, 1 medium, 0 low. 12 unpinned-GitHub-Actions row(s) are reported here but scored by D36 (supply-chain provenance), which measures that posture as `pinned_actions` — one pinning decision is charged once, not once per lens. Separately, one or more rules could not re-parse an embedded snippet in 1 file(s) (e.g. a workflow `run:` block read as shell). Those files WERE scanned and their other rows are unaffected; only those rules' view of those snippets is missing.
What to do
- Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
- Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
- No action in Static Analysis (SAST) — all 12 REDACTED finding(s) are reported here at file:line but scored by D36 (supply-chain provenance), so none is charged to this dimension. — One of this dimension's main actionable groups (12 issue-level, 0 of them charged here).
D30 · Dependency Vulnerabilities
3 finding(s): 0 critical, 0 high, 3 medium, 0 low.
What to do
- Resolve the 2 Medium advisory (unsound) finding(s) in Dependency Vulnerabilities — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 1 Medium advisory (unmaintained) finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
D34 · Knowledge Freshness
Every significant source file has living knowledge — recently and meaningfully worked. Counted over 42 of the 54 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
D35 · Change Coupling
Strongest change-coupling: settings.rs↔tui.rs 67%
What to do
- Resolve the 1 Change coupling finding(s) in Change Coupling — start with settings.rs. — One of this dimension's main actionable groups (1 warning-level).
D36 · Supply-chain Provenance & Signing
0/4 supply-chain integrity signals present (provenance, signing, SBOM, pinned actions).
What to do
- Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
- Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
- Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
D43 · Malicious Dependencies
No dependency in any ecosystem this repository declares is published as malicious.
Frontend & cross-cutting dimensions
AX10 · Code composition
What to do
- The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
AX3 · Project dependency cycles
AX4 · Dependency direction
AX9 · CQS / query purity
M1 · Documentation (README)
What to do
- Add a 'Testing' section to the root README — how to run the test suite.
- Add an 'Architecture' / 'How it works' section to the root README — the high-level shape.
- Add a README to the 2 of 4 project(s) that lack one — worth up to 1 pts.
M2 · Architecture documentation
- No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
What to do
- Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).
M3 · Folder & project structure
M4 · Documentation accuracy
- README advertises a RAG / ML engine, but no ML/RAG code or dependency exists — searched for: `rag`, `langchain`, `llamaindex`, `pinecone`, `weaviate`, `qdrant`, `embeddings`. Each was matched case- and separator-insensitively against file and directory NAMES anywhere in the tree, and against the CONTENTS of manifest files (package.json, *.csproj, *.props, *.slnx, *.yml, Dockerfile); the README's own prose never counts, so a claim is never refuted by merely being made. Nothing outside that search was read — a footprint living only in a submodule, in a file type not listed here, or under a name none of those terms matches is not seen, and this row is then wrong.
What to do
- Reconcile the README with reality: README advertises a RAG / ML engine, but no ML/RAG code or dependency exists.
P1 · CI/CD gates
P2 · Observability
- Only 2/4 runnable modules use logging (modules with no entry point or server are excluded — they are libraries a runnable module hosts). Silent: `crates/code2prompt-python`, `website`.
What to do
- Extend structured logging to the remaining runnable modules so everything you run is diagnosable in production.
- Consider OpenTelemetry tracing/metrics (opentelemetry with tracing-opentelemetry) and a health-check endpoint (a /health route on your axum/actix router) for operability.
P3 · Security & performance tooling
- No static application security testing detected. For this repository's stack, add cargo-audit / cargo-deny (or clippy) (or `semgrep --config=auto`, which runs on any language) as a CI step. What was searched, so you can tell an absence from a miss: the 6613 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
What to do
- Add a SAST step to CI running what this repository's stack ships: cargo-audit / cargo-deny (or clippy) — or `semgrep --config=auto`, which runs on any language — so a security regression fails the build instead of landing.
- Dependabot is configured but does not watch `pip` — add that `package-ecosystem` entry to REDACTED so those dependencies get the same automatic update and advisory pressure as the ones it already covers.
- Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback
What to do
- The release job declares an environment, but its protection rules are not visible from the repository — confirm required reviewers are attached, or publish as a draft release so a bad build can be stopped before users can download it.
P6 · Release Hygiene
- No CHANGELOG/HISTORY/RELEASES file — what shipped when isn't easy to reconstruct for support or audit. (Versioning/tagging makes releases traceable, but a changelog records the what.)
What to do
- Keep a changelog (e.g. Keep-a-Changelog) recording what shipped in each release.
PF3 · Async & latency hygiene
Reference — by lens
| Lens | Score | Rating | Impact |
|---|---|---|---|
| Code Health | 83% | Adequate — gated by D2 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Architecture | 95% | Exemplary | Solid. |
| Maturity | 68% | Adequate — gated by M2 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Readiness | 56% | Adequate — gated by P3 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Security | 70% | Adequate — gated by D36 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Performance | 100% | Exemplary | Strongest area. |
Not evidenced — 4 control(s) we could not find positive evidence for
- C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 80 check(s) not relevant to this codebase
- AC1 Text alternatives — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC2 Forms & labels — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC3 Page structure — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC4 Keyboard semantics — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC5 ARIA correctness — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC6 Visual & motion safety — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AC7 A11y enforcement — Frontend below the scale floor (5 DOM element(s) < 25) — too little surface to assess accessibility.
- AX1 Captive dependencies — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX2 Stateful singletons — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX6 Interface segregation — not assessed — interface segregation is computed over a type surface that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX7 Slice cohesion — not applicable — not a vertical-slice architecture
- AX8 Test isolation — no test/production split to check
- AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- AXR1 Runtime accessibility — the dev server did not expose a crawlable HTTP endpoint in time — no runtime evidence This is a statement about this run, not a statement about your application: nothing here says the surface is inaccessible, only that it was never rendered.
- C1 Data Protection — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- D10 Test Quality — ~4162 lines of test source are present (.rs, .py) but no test cases reached the test census for this repository — no test root we could resolve declared them, or the files we read declare no cases in a test framework we recognise — so skipped/assertion-free tests couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
- D11 Test Reliability — No tests discovered
- D14 License Compliance — Not scored — this repository's 436 shipped crate(s) were read from its REDACTED, but crates.io could not be asked for the licence of 56 of them (HTTP 429 Unknown Error), and a licence verdict over part of a dependency graph is not a licence verdict. Nothing is asserted about this repository's licensing in either direction.
- D16 Bus Factor — single-maintainer repository — bus factor is not applicable
- D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
- D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout nor 2+ sibling source directories each declaring an aggregate root. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
- D24 Comment Value — No inline comments to assess — comment value is not applicable here.
- D25 ADR Conformance — no ADRs to check
- D27 Navigability — symbol resolution incomplete — navigability not assessed
- D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
- D32 Data Compliance (PII/GDPR) — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that.
- D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
- D39 IL Efficiency — D39 measures the IL emitted by a .NET build; this repository has no .NET solution or project files, so the dimension does not apply.
- D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
- D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
- D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
- D44 Platform End-of-Life — Platform end-of-life not assessed — this repository declares no platform this pass reads
- D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
- D8 Code Coverage — Coverage NOT MEASURED: the JavaScript/TypeScript half could not be measured — the jest suite in website/ ran and not one test passed (No tests found, exiting with code 1), so the coverage would describe the failed run, not the code. Coverage is excluded from the score rather than counted as a near-zero. The named suite step is one the repository's maintainers can perform; once it passes, the real number is measured on the next scan. Alternatively, commit the lcov/Cobertura report your CI produces and it is read without a re-run.
- DM1 Domain Modelling — not scored — this repository shows only 1 of the 3 signals this lens looks for (1 value object(s))
- ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and a call made through an inferred or generic receiver has no resolvable owner in the source. Reported as guidance rather than measured
- ED5 Idempotency — This check finds retry-prone mutations (command handlers and message/event consumers) by walking the repository's declared types, and none was loaded here, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
- GD1 Unfinished & placeholder code — no source files were read — this check reads C# syntax, and none was loaded for this repository. That is a limit of the analyzer, not a finding about your code.
- IC1 Incompleteness & stubs — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- P10 Library API & versioning — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
- P7 Outbound HTTP resilience — not applicable — no HTTP server, API framework or worker entry point was found in the JavaScript/TypeScript, Rust source, so there is no service whose uptime a failing dependency could take down
- P8 Schema migrations — no ORM, schema-migration tool or schema auto-create was found in this repository's dependency manifests or source, so there is no database schema for this check to judge
- P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (lcov — `cargo install cargo-llvm-cov`, then `cargo llvm-cov --lcov --output-path lcov.info`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures, or wire coverage collection into CI, to enable this cross-layer check
- PF1 Benchmark discipline — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- PF2 Allocation hygiene — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
- SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X1 Async correctness — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X10 Duplicated predicate — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X12 Unreachable branch — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X13 Undrained process stream — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X14 Bypassable address classification — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X15 Unvalidated length from an untrusted reader — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X16 Unfloored truncation loop — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X17 Uncapped recursion over a caller-supplied document — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X18 Disposal-pattern correctness — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X19 Unrestored process-global state — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X2 Cancellation propagation — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X20 Mistyped argument guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X21 Side-effecting pattern guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X22 Contradicted release guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X23 Unguarded diagnostic materialisation — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X24 Document value interpolated into markup unescaped — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X25 Inert configuration knob — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X26 Unsynchronised callback handoff — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X27 Collection changed while being enumerated — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X28 Index access outside its own emptiness guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X29 Per-element action decided by a fixed element — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X3 Exception handling — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X30 Support guard that admits what it rejects — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X32 Type resolved by simple name across every loaded assembly — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
- X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X5 Nullable reference types — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X6 Hand-rolled structured-format parsing — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X7 Silent fallback defaults — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
Appendix A — Findings (grouped)
Critical — 16 finding(s)
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Test suite declares a test script but contains no test files: website/
- REDACTED
- REDACTED
- REDACTED
Serious — 68 finding(s)
- code2prompt::utils::collect_visible_nodes_recursive (cognitive 37) crates/code2prompt/src/utils.rs:153
- code2prompt::config::build_session (cognitive 35) crates/code2prompt/src/config.rs:25
- code2prompt::emit_cli_results (cognitive 21) crates/code2prompt/src/main.rs:142
- code2prompt::token_map::format_token_map_for_tui (cognitive 21) crates/code2prompt/src/token_map.rs:67
- code2prompt::utils::ensure_path_exists_in_tree (cognitive 17) crates/code2prompt/src/utils.rs:399
- code2prompt::config_loader::load_config (cognitive 17) crates/code2prompt/src/config_loader.rs:19
- MethodTooLong: Model.update crates/code2prompt/src/model/mod.rs:249
- MethodTooLong: StatisticsByExtensionWidget.render crates/code2prompt/src/widgets/statistics_by_extension.rs:27
- MethodTooLong: StatisticsOverviewWidget.render crates/code2prompt/src/widgets/statistics_overview.rs:21
- MethodTooLong: FileSelectionWidget.render crates/code2prompt/src/widgets/file_selection.rs:26
- Duplicated block (9 lines × 2) crates/code2prompt/src/config.rs:141
- Duplicated block (9 lines × 2) crates/code2prompt-python/src/python.rs:341
- Duplicated block (9 lines × 2) crates/code2prompt-python/src/python.rs:351
- Duplicated block (8 lines × 2) crates/code2prompt-core/src/git.rs:47
- Duplicated block (8 lines × 2) crates/code2prompt-core/src/git.rs:51
- Duplicated block (8 lines × 2) crates/code2prompt/src/widgets/template/picker.rs:58
- TuiApp::handle_key_event (cyclomatic 27) crates/code2prompt/src/tui.rs:203
- TuiApp::handle_template_keys (cyclomatic 27) crates/code2prompt/src/tui.rs:336
- code2prompt_core::path::discover_files (cognitive 29) crates/code2prompt-core/src/path.rs:98
- code2prompt_core::analysis::select_nodes_to_display (cognitive 20) crates/code2prompt-core/src/analysis.rs:314
- TuiApp::handle_template_keys (cognitive 27) crates/code2prompt/src/tui.rs:336
- TuiApp::run (cognitive 23) crates/code2prompt/src/tui.rs:64
- JupyterNotebookProcessor::process (cognitive 23) crates/code2prompt-core/src/file_processor/ipynb.rs:87
- JupyterNotebookProcessor::append_outputs (cognitive 20) crates/code2prompt-core/src/file_processor/ipynb.rs:39
- FunctionTooLong: code2prompt::view::formatters::format_settings_groups crates/code2prompt/src/view/formatters.rs:14
- FunctionTooLong: code2prompt::config::build_session crates/code2prompt/src/config.rs:25
- REDACTED
- REDACTED
- Duplicated block (18 lines × 2) crates/code2prompt/src/widgets/statistics_by_extension.rs:43
- Duplicated block (18 lines × 2) crates/code2prompt-core/src/git.rs:109
- Duplicated block (11 lines × 2) crates/code2prompt/src/model/mod.rs:206
- Duplicated block (11 lines × 2) crates/code2prompt/src/model/mod.rs:360
- Duplicated block (5 lines × 2) crates/code2prompt/src/widgets/statistics_by_extension.rs:227
- Duplicated block (5 lines × 2) crates/code2prompt/src/widgets/statistics_overview.rs:44
- Model::update (cyclomatic 79) crates/code2prompt/src/model/mod.rs:249
- code2prompt::config::build_session (cyclomatic 25) crates/code2prompt/src/config.rs:25
- SettingsState::update_setting_by_key (cyclomatic 23) crates/code2prompt/src/model/settings.rs:75
- Hotspot: crates/code2prompt/src/main.rs crates/code2prompt/src/main.rs:142
- Model::update (cognitive 121) crates/code2prompt/src/model/mod.rs:249
- TemplatePickerWidget::render (cognitive 30) crates/code2prompt/src/widgets/template/picker.rs:20
- FileSelectionWidget::render (cognitive 19) crates/code2prompt/src/widgets/file_selection.rs:26
- TemplateVariableWidget::render (cognitive 19) crates/code2prompt/src/widgets/template/variable.rs:20
- SettingsWidget::render (cognitive 17) crates/code2prompt/src/widgets/settings.rs:26
- Duplicate selection logic across Session and SelectionEngine. The Session type exposes low-level selection mutation methods (select_file, deselect_file, toggle_file_selection) that directly mirror the methods on the internal SelectionEngine. This violates encapsulation and creates two entry points for the same state change.
- Redundant Git operations. The Session type exposes specific Git loading methods that duplicate the functionality of the git module functions. This creates a confusing API where users can either call Session.load_git_diff() or git.get_git_diff(), leading to inconsistent usage patterns.
- Ambiguous prompt generation flow. 'generate_prompt' likely calls 'render_prompt' internally, but both are exposed. It is unclear if 'generate_prompt' does additional processing (e.g., token counting, validation) or if they are interchangeable. This creates confusion about the correct entry point for prompt generation.
- Inconsistent initialization paths. TemplateState can be initialized from either a Session or a Model. Since Model contains a Session, this creates redundant ways to achieve the same result. It is unclear why one would use one over the other, leading to potential state desynchronization if the underlying data differs.
- Fragmented template loading. 'utils.load_all_templates' suggests a general utility for loading templates, while 'BuiltinTemplates' is a specific type for built-in ones. It is unclear if 'utils.load_all_templates' loads both built-in and custom templates, or just built-in, creating confusion about the source of templates.
- REDACTED
- FileTooLong: src/python.rs crates/code2prompt-python/src/python.rs
- REDACTED
- Change coupling: settings.rs ↔ tui.rs crates/code2prompt/src/model/settings.rs
- REDACTED
- REDACTED
- REDACTED
- Edited copy of a member (25 corresponding lines) crates/code2prompt-core/src/git.rs:104
- Members sharing a duplicated core (4 members, 50+ identical tokens) crates/code2prompt/src/model/mod.rs:91
- Duplicated block (12–13 lines × 2) crates/code2prompt/src/config_loader.rs:22
- Duplicated block (11 lines × 3) crates/code2prompt-core/src/git.rs:105
- Duplicated block (10 lines × 2) crates/code2prompt-core/src/analysis.rs:251
- Duplicated block (7–8 lines × 3) crates/code2prompt/src/widgets/template/editor.rs:37
- Duplicated block (4–7 lines × 4) crates/code2prompt/src/model/mod.rs:123
- Duplicated block (6 lines × 2) crates/code2prompt/src/model/mod.rs:447
- Duplicated block (13 lines × 2) crates/code2prompt/src/widgets/statistics_by_extension.rs:29
- Duplicated block (12 lines × 2) crates/code2prompt/src/model/mod.rs:454
- Duplicated block (8 lines × 3) crates/code2prompt/src/widgets/statistics_by_extension.rs:47
- Off the main sequence: code2prompt_core
- Coverage not measured — JavaScript/TypeScript suite
Minor — 12 finding(s)
- Documentation: no project overview README.md
- No ADRs found
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Inverted test pyramid
- No ADRs
- README/code drift
- Logging is not universal
- No SAST
- No changelog
Appendix B — Reproduction & audit trail
| Dimension | Tool | Version | Command | Findings | Raw output |
|---|---|---|---|---|---|
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-080fd89f9b384d23b48b333df8a29ae6/history.json --exit-code 0 --source . | 0 | artifacts/raw/gitleaks-history.json |
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-080fd89f9b384d23b48b333df8a29ae6/tree.json --exit-code 0 --source . | 0 | artifacts/raw/gitleaks-tree.json |
| D29 · Static Analysis (SAST) | semgrep | — | semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/watchdog-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off . | 16 | artifacts/raw/semgrep.json |
| D30 · Dependency Vulnerabilities | trivy | — | trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update | 3 | artifacts/raw/trivy-fs.json |
| D31 · IaC & Container Security | trivy | — | trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan. | 0 | — |
| D32 · Data Compliance (PII/GDPR) | semgrep | — | semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. | 0 | — |
| D37 · Vulnerability-disclosure Policy | disclosure | — | disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed. | 0 | — |
| D40 · Network Egress Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here. | 0 | — |
| D41 · Kernel & Syscall Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here. | 0 | — |
| D42 · Runtime Threat Enforcement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here. | 0 | — |
| D43 · Malicious Dependencies | trivy | — | trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update | 0 | artifacts/raw/trivy-fs.json |