Auto-generated codebase orientation. Use this as a map to choose what to inspect; verify against source before editing.
- Git: branch
feat/per-cluster-retrieval, commit53a7e84, tracked working tree dirty at generation time. - Symbol skeleton budget: ~2000 tokens after this header.
- Read project instructions and handoff/status files first.
- Use this map to identify likely files and boundaries.
- Read the actual source, tests, and nearby docs before editing.
- Trace behavior across UI/entry point → domain/service → persistence/platform → tests.
- Run the narrowest useful verification first, then broader checks when practical.
- Update durable docs or memory only for source-backed learnings.
AGENTS.mdSTATUS.mdREADME.mdCONTRIBUTING.md
- No package.json verification scripts detected; inspect project docs/configs.
- Generated/vendor/cache dirs present or excluded: .git, .pytest_cache, .venv
- Lockfiles are dependency-contract surfaces: uv.lock
- Secret-like paths require care: .env, .env.*, *.pem, *.key, id_rsa, id_ed25519, .npmrc, .pypirc
- Never trust this map alone; read source files before editing.
- Never print or paste secret file contents; source env vars instead.
tmp/headroom/crates/headroom-py/src/lib.rs: ⋮... │fn hello() -> &'static str { ⋮... │fn type_name(v: &serde_json::Value) -> &'static str { ⋮... │fn build_crush_array_dict<'py>( ⋮... │struct PyDiffCompressorConfig { ⋮... │ fn new( ⋮... │ fn max_context_lines(&self) -> usize { ⋮... │ fn max_hunks_per_file(&self) -> usize { ⋮... │ fn max_files(&self) -> usize { ⋮... │ fn always_keep_additions(&self) -> bool { ⋮... │ fn always_keep_deletions(&self) -> bool { ⋮... │ fn enable_ccr(&self) -> bool { ⋮... │ fn min_lines_for_ccr(&self) -> usize { ⋮... │ fn min_compression_ratio_for_ccr(&self) -> f64 { ⋮... │ fn repr(&self) -> String { ⋮... │struct PyDiffCompressionResult { ⋮... │ fn compressed(&self) -> &str { ⋮... │ fn original_line_count(&self) -> usize { ⋮... │ fn compressed_line_count(&self) -> usize { ⋮... │ fn files_affected(&self) -> usize { ⋮... │ fn additions(&self) -> usize { ⋮... │ fn deletions(&self) -> usize { ⋮... │ fn hunks_kept(&self) -> usize { ⋮... │ fn hunks_removed(&self) -> usize { ⋮... │ fn cache_key(&self) -> Option { ⋮... │ fn compression_ratio(&self) -> f64 { ⋮... │ fn tokens_saved_estimate(&self) -> usize { ⋮... │ fn repr(&self) -> String { ⋮... │struct PyDiffCompressorStats { ⋮... │ fn input_lines(&self) -> usize { ⋮... │ fn output_lines(&self) -> usize { ⋮... │ fn compression_ratio(&self) -> f64 { ⋮... │ fn files_total(&self) -> usize { ⋮... │ fn files_kept(&self) -> usize { ⋮... │ fn files_dropped(&self) -> Vec { ⋮... │ fn hunks_total(&self) -> usize { ⋮... │ fn hunks_kept(&self) -> usize { ⋮... │ fn hunks_dropped(&self) -> usize { ⋮... │ fn hunks_dropped_per_file(&self) -> BTreeMap<String, usize> { ⋮... │ fn context_lines_input(&self) -> usize { ⋮... │ fn context_lines_kept(&self) -> usize { ⋮... │ fn context_lines_trimmed(&self) -> usize { ⋮... │ fn largest_hunk_kept_lines(&self) -> usize { ⋮... │ fn largest_hunk_dropped_lines(&self) -> usize { ⋮... │ fn parse_warnings(&self) -> Vec { ⋮... │ fn processing_duration_us(&self) -> u64 { ⋮... │ fn cache_key_emitted(&self) -> bool { ⋮... │ fn ccr_skipped_reason(&self) -> Option { ⋮... │ fn file_mode_normalizations(&self) -> Vec<(String, String)> { ⋮... │ fn binary_files_simplified(&self) -> Vec { ⋮... │struct PyDiffCompressor { ⋮... │ fn new(config: Option<&PyDiffCompressorConfig>) -> Self { ⋮... │ fn compress(&self, py: Python<'>, content: &str, context: &str) -> PyDiffCompressionResult { ⋮... │ fn compress_with_stats( ⋮... │struct PySmartCrusherConfig { ⋮... │ fn new( ⋮... │ fn enabled(&self) -> bool { ⋮... │ fn min_items_to_analyze(&self) -> usize { ⋮... │ fn min_tokens_to_crush(&self) -> usize { ⋮... │ fn variance_threshold(&self) -> f64 { ⋮... │ fn uniqueness_threshold(&self) -> f64 { ⋮... │ fn similarity_threshold(&self) -> f64 { ⋮... │ fn max_items_after_crush(&self) -> usize { ⋮... │ fn preserve_change_points(&self) -> bool { ⋮... │ fn factor_out_constants(&self) -> bool { ⋮... │ fn include_summaries(&self) -> bool { ⋮... │ fn use_feedback_hints(&self) -> bool { ⋮... │ fn toin_confidence_threshold(&self) -> f64 { ⋮... │ fn dedup_identical_items(&self) -> bool { ⋮... │ fn first_fraction(&self) -> f64 { ⋮... │ fn last_fraction(&self) -> f64 { ⋮... │ fn relevance_threshold(&self) -> f64 { ⋮... │ fn enable_ccr_marker(&self) -> bool { ⋮... │ fn repr(&self) -> String { ⋮... │struct PyCrushResult { ⋮... │ fn compressed(&self) -> &str { ⋮... │ fn original(&self) -> &str { ⋮... │ fn was_modified(&self) -> bool { ⋮... │ fn strategy(&self) -> &str { ⋮... │ fn repr(&self) -> String { ⋮... │struct PySmartCrusher { ⋮... │ fn new(config: Option<&PySmartCrusherConfig>) -> Self { ⋮... │ fn without_compaction(config: Option<&PySmartCrusherConfig>) -> Self { ⋮... │ fn crush(&self, py: Python<'>, content: &str, query: &str, bias: f64) -> PyCrushResult { ⋮... │ fn smart_crush_content( ⋮... │ fn crush_array_json<'py>( ⋮... │ fn compact_document_json(&self, py: Python<'>, doc_json: &str) -> String { ⋮... │ fn ccr_get(&self, hash: &str) -> Option { ⋮... │ fn ccr_len(&self) -> usize { ⋮... │struct PyDetectionResult { ⋮... │ fn content_type(&self) -> &'static str { ⋮... │ fn confidence(&self) -> f64 { ⋮... │ fn metadata<'py>(&self, py: Python<'py>) -> PyResult<Bound<'py, PyDict>> { ⋮... │ fn repr(&self) -> String { ⋮... │fn detect_content_type(py: Python<'>, content: &str) -> PyDetectionResult { ⋮... │fn is_json_array_of_dicts(py: Python<'>, content: &str) -> bool { ⋮... │fn shared_keyword_detector() -> &'static KeywordDetector { ⋮... │fn ctx_from_str(name: &str) -> Option { ⋮... │fn category_to_str(cat: ImportanceCategory) -> &'static str { ⋮... │fn score_line(line: &str, context: &str) -> Option<(Option<&'static str>, f32, f32)> { ⋮... │fn content_has_error_indicators(text: &str) -> bool { ⋮... │fn keyword_registry_snapshot(py: Python<'>) -> Py { ⋮... │struct PySearchCompressorConfig { ⋮... │ fn new( ⋮... │struct PySearchCompressionResult { ⋮... │ fn compressed(&self) -> &str { ⋮... │ fn original(&self) -> &str { ⋮... │ fn original_match_count(&self) -> usize { ⋮... │ fn compressed_match_count(&self) -> usize { ⋮... │ fn files_affected(&self) -> usize { ⋮... │ fn compression_ratio(&self) -> f64 { ⋮... │ fn cache_key(&self) -> Option<&str> { ⋮... │ fn summaries<'py>(&self, py: Python<'py>) -> Bound<'py, PyDict> { ⋮... │ fn lines_unparsed(&self) -> usize { ⋮... │ fn files_dropped(&self) -> usize { ⋮... │ fn ccr_emitted(&self) -> bool { ⋮... │ fn ccr_skip_reason(&self) -> Option<&str> { ⋮... │struct PySearchCompressor { ⋮... │ fn new(config: Option) -> Self { ⋮... │ fn compress( ⋮... │fn parse_search_lines(content: &str) -> Vec<(String, u64, String)> { ⋮... │struct PyLogCompressorConfig { ⋮... │ fn new( ⋮... │struct PyLogCompressionResult { ⋮... │ fn compressed(&self) -> &str { ⋮... │ fn original(&self) -> &str { ⋮... │ fn original_line_count(&self) -> usize { ⋮... │ fn compressed_line_count(&self) -> usize { ⋮... │ fn format_detected(&self) -> &'static str { ⋮... │ fn compression_ratio(&self) -> f64 { ⋮... │ fn cache_key(&self) -> Option<&str> { ⋮... │ fn stats<'py>(&self, py: Python<'py>) -> Bound<'py, PyDict> { ⋮... │ fn stack_traces_seen(&self) -> usize { ⋮... │ fn stack_traces_kept(&self) -> usize { ⋮... │ fn warnings_dropped_by_dedupe(&self) -> usize { ⋮... │ fn ccr_emitted(&self) -> bool { ⋮... │ fn ccr_skip_reason(&self) -> Option<&str> { ⋮... │struct PyLogCompressor { ⋮... │ fn new(config: Option) -> Self { ⋮... │ fn compress(&self, py: Python<'>, content: &str, bias: f64) -> PyLogCompressionResult { ⋮... │fn detect_log_format(lines: Vec) -> &'static str { ⋮... │fn protect_tags( ⋮... │fn restore_tags(py: Python<'>, text: &str, blocks: Vec<(String, String)>) -> String { ⋮... │fn is_html_tag(name: &str) -> bool { ⋮... │fn known_html_tag_names() -> Vec<&'static str> { ⋮... │fn compress_openai_responses_live_zone( ⋮... │fn core(m: &Bound<', PyModule>) -> PyResult<()> { ⋮...
tmp/headroom/headroom/config.py: ⋮... │class HeadroomMode(str, Enum): ⋮... │class CacheAlignerConfig: ⋮... │class RelevanceScorerConfig: ⋮... │class AnchorConfig: ⋮... │class ReadLifecycleConfig: ⋮... │class CompressionProfile: ⋮... │class SmartCrusherConfig: ⋮... │class CacheOptimizerConfig: ⋮... │class CCRConfig: ⋮... │class PrefixFreezeConfig: ⋮... │class HeadroomConfig: ⋮... │class Block: ⋮... │class WasteSignals: ⋮... │class CachePrefixMetrics: ⋮... │class TransformResult: ⋮... │class TransformDiff: ⋮... │class DiffArtifact: ⋮... │class SimulationResult: ⋮... │class RequestMetrics: ⋮...
install.sh: ⋮... │check_python() { ⋮...