Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.
This report summarizes scanner evidence for headroomlabs-ai/headroom, a Python project with 74,963 GitHub stars. SynthScan examined 804,060 lines of code across 2249 source files, recording 22724 pattern matches distributed across 26 syntactic categories. The legacy adjusted pattern signal is 39.0 (High pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 15785 finding(s).
Are imports declared and package/API names verified? 2485 finding(s).
Are wrappers, guards, and repeated structures necessary? 18107 finding(s).
Which changes need focused human review? 22724 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 22724 distinct pattern matches across 26 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …ates/headroom-core/src/transforms/search_compressor.rs | 13 | //! src/models.py:15:class DataProcessor: | COMMENT |
| LOW | …ns/headroom-oauth2/tests/test_scope_and_proxy_token.py | 115 | def test_local_routes_are_passed_through_without_minting(path): | CODE |
| LOW | …ns/headroom-oauth2/tests/test_scope_and_proxy_token.py | 135 | def test_upstream_routes_are_injected(path): | CODE |
| LOW | …ns/headroom-oauth2/tests/test_scope_and_proxy_token.py | 142 | def test_install_log_line_does_not_carry_the_token_url_query(monkeypatch, caplog): | CODE |
| LOW | …ns/headroom-oauth2/tests/test_scope_and_proxy_token.py | 204 | def test_bearer_proxy_token_survives_replacement_when_gate_runs_inside(monkeypatch): | CODE |
| LOW⚡ | plugins/headroom-oauth2/tests/test_oauth2.py | 310 | def test_install_noop_when_unset(monkeypatch): | CODE |
| LOW⚡ | plugins/headroom-oauth2/tests/test_oauth2.py | 320 | def test_install_fail_closed_on_bad_config(monkeypatch): | CODE |
| LOW⚡ | plugins/headroom-oauth2/tests/test_oauth2.py | 327 | def test_install_warns_for_envauth_backend(monkeypatch, caplog): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 144 | def test_concurrent_single_flight(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 158 | def test_error_on_bad_status_hides_body(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 166 | def test_error_body_drain_failure_is_sanitized(monkeypatch, caplog): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 193 | def test_unreachable_token_url(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 241 | def test_parse_headers_rejects_control_chars(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 247 | def test_provider_from_env_wires_knobs(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 264 | def test_provider_from_env_none_when_unset(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 269 | def test_middleware_injects_bearer(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 280 | def test_middleware_non_http_passthrough(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 344 | def test_install_fail_closed_on_bad_timeout(monkeypatch): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 353 | def test_parse_headers_rejects_bad_keys(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 365 | def test_middleware_handles_missing_headers_key(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 406 | def test_allow_insecure_env_permits_nonloopback_http(): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 419 | def test_extra_params_cannot_override_canonical(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 435 | def test_auth_style_basic_via_env(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 449 | def test_scopes_comma_separated_via_env(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 462 | def test_expires_in_missing_falls_back(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 469 | def test_expires_in_non_numeric_falls_back(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 485 | def test_single_flight_on_refresh(idp): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 499 | def test_install_sets_static_headers(monkeypatch): | CODE |
| LOW | plugins/headroom-oauth2/tests/test_oauth2.py | 519 | def test_install_handles_invalid_litellm_headers(monkeypatch, caplog): | CODE |
| LOW | plugins/openclaw/src/proxy-manager.ts | 413 | export function normalizeAndValidateProxyUrl(proxyUrl: string): string { | CODE |
| LOW | plugins/openclaw/src/gateway-config.ts | 18 | export function resolveGatewayProviderIds(config: Record<string, unknown> | undefined): string[] { | CODE |
| LOW | plugins/openclaw/src/gateway-config.ts | 31 | function normalizeGatewayProviderIds(value: unknown): string[] { | CODE |
| LOW | plugins/openclaw/src/gateway-config.ts | 67 | export function applyGatewayProviderBaseUrlsInPlace( | CODE |
| LOW | plugins/openclaw/src/convert.ts | 430 | function normalizeAssistantMessage(message: Record<string, any>): Record<string, any> { | CODE |
| LOW | plugins/openclaw/src/convert.ts | 454 | function normalizeToolResultMessage(message: Record<string, any>): Record<string, any> { | CODE |
| LOW | plugins/openclaw/src/convert.ts | 478 | function normalizeAssistantContent(content: unknown): any[] { | CODE |
| LOW | plugins/openclaw/src/convert.ts | 521 | function normalizeToolResultContent(content: unknown): any[] { | CODE |
| LOW | plugins/openclaw/src/openclaw-compaction.ts | 36 | export async function delegateCompactionToRuntime( | CODE |
| LOW | plugins/openclaw/src/tools/headroom-retrieve.ts | 15 | export function createHeadroomRetrieveTool(config: RetrieveToolConfig) { | CODE |
| LOW | plugins/hermes/headroom_retrieve/__init__.py | 47 | def _handle_headroom_retrieve(args: dict, **kw) -> str: | CODE |
| LOW | plugins/opencode/src/retrieve.ts | 28 | export function createHeadroomRetrieveTool(config: RetrieveToolConfig) { | CODE |
| LOW | plugins/opencode/src/transport.ts | 274 | export function modelBaseRoutesThroughProxy( | CODE |
| LOW | plugins/opencode/src/transport.ts | 290 | function normalizedOpenAiProxyPath(pathname: string): string | undefined { | CODE |
| LOW | plugins/opencode/src/transport.ts | 593 | export function uninstallHeadroomTransport(): void { | CODE |
| LOW | plugins/opencode/src/provider.ts | 75 | export function buildOpencodeConfigContent( | CODE |
| LOW | plugins/opencode/src/provider.ts | 87 | export function buildOpencodeConfigContentJson( | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 90 | def test_token_is_minted_under_the_clients_integration_id(monkeypatch) -> None: | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 101 | def test_forwarded_header_matches_the_minted_token(monkeypatch) -> None: | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 112 | def test_no_duplicate_integration_id_header_is_emitted(monkeypatch) -> None: | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 127 | def test_a_forwardable_client_token_keeps_the_clients_id(monkeypatch) -> None: | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 143 | def test_a_client_that_states_its_identity_beats_the_configured_default( | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 160 | def test_the_configured_default_applies_when_the_client_sends_none( | CODE |
| LOW⚡ | tests/test_copilot_integration_id_hmac.py | 172 | def test_client_value_wins_over_the_default(monkeypatch) -> None: | CODE |
| LOW⚡ | tests/test_copilot_integration_id_hmac.py | 176 | def test_default_when_the_client_sends_none(monkeypatch) -> None: | CODE |
| LOW⚡ | tests/test_copilot_integration_id_hmac.py | 186 | def test_blank_client_values_fall_back(blank) -> None: | CODE |
| LOW⚡ | tests/test_copilot_integration_id_hmac.py | 190 | def test_non_copilot_upstream_is_untouched(monkeypatch) -> None: | CODE |
| LOW | tests/test_copilot_integration_id_hmac.py | 203 | def test_tokens_are_cached_per_integration_id(monkeypatch) -> None: | CODE |
| LOW⚡ | tests/test_quota_registry.py | 88 | def test_register_single_tracker(): | CODE |
| LOW⚡ | tests/test_quota_registry.py | 95 | def test_register_multiple_trackers(): | CODE |
| LOW⚡ | tests/test_quota_registry.py | 104 | def test_duplicate_key_raises(): | CODE |
| 13554 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | run-all-plugins.sh | 2 | # ───────────────────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 13 | # ───────────────────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 24 | # ── 1. venv ────────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 31 | # ── 2. install (guarded) ────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 63 | # ── 3. secrets from ~/env.txt ───────────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 71 | # ── 4. plugin license (Ed25519, offline, wildcard) ──────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 83 | # ── 5. Kompress ML offload → Modal ──────────────────────────────────────────── | COMMENT |
| MEDIUM | run-all-plugins.sh | 90 | # ── 6. observability sink → Langfuse + spend attribution ────────────────────── | COMMENT |
| MEDIUM⚡ | run-all-plugins.sh | 102 | # ── 7. tier_router ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | run-all-plugins.sh | 108 | # ── 8. plugin tuning (defaults shown; override as needed) ───────────────────── | COMMENT |
| MEDIUM⚡ | run-all-plugins.sh | 115 | # ── 9. coding profile + mode ─────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | run-all-plugins.sh | 120 | # ── 10. run + confirm ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | Cargo.toml | 89 | # ── Release profile — wheel size optimization ─────────────────────── | COMMENT |
| MEDIUM | docker-compose.yml | 1 | # ============================================================================= | COMMENT |
| MEDIUM | docker-compose.yml | 3 | # ============================================================================= | COMMENT |
| MEDIUM | docker-compose.yml | 35 | # ============================================================================= | COMMENT |
| MEDIUM | crates/headroom-core/config/pipeline.toml | 35 | # ─── Per-domain bloat estimator config ────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/config/pipeline.toml | 79 | # ─── Reformat configs ─────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/config/pipeline.toml | 106 | # ─── JSON-array offload config (SmartCrusher wrapper) ───────────── | COMMENT |
| MEDIUM | crates/headroom-core/config/pipeline.toml | 122 | # ─── Diff-noise offload config ───────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/config/pipeline.toml | 153 | # ─── Structured prose-field offload config ───────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/ccr_backends.rs | 155 | // ─── Sliding (idle-window) TTL semantics — #2604 ─────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/ccr_backends.rs | 155 | // ─── Sliding (idle-window) TTL semantics — #2604 ─────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/ccr_backends.rs | 324 | // ─── Redis-feature-gated tests ───────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_arm_properties.rs | 40 | // ─── Part 0: kill-switch alias round trip (bug class extinction) ────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_arm_properties.rs | 82 | // ─── Part 1: pathological-text generators (properties 1 & 2) ────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_arm_properties.rs | 583 | // ─── Part 1, property 3: byte fidelity around the SourceCode arm ────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_arm_properties.rs | 721 | // ─── Part 1, instrumentation: measured dispatch-reach fractions ─────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/auth_mode.rs | 27 | // ── Required matrix ────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/auth_mode.rs | 96 | // ── Bonus matrix ────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/auth_mode.rs | 152 | // ── Performance ────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_dispatch.rs | 21 | // ─── Routing tests ───────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/live_zone_dispatch.rs | 430 | // ─── Cache-safety invariant ──────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/ccr_roundtrip.rs | 226 | // ─── PR8 additions: marker injection + walker unification ────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/ccr_roundtrip.rs | 404 | // ─── helpers ────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/tests/cache_control.rs | 199 | // ─── Property tests ─────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/benches/ccr_store.rs | 28 | // ─── Baseline: the old single-Mutex<HashMap> design ──────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/auth_mode.rs | 122 | // ── User-Agent ─────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/auth_mode.rs | 147 | // ── Authorization header ───────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/auth_mode.rs | 193 | // ── Vendor-specific API-key headers ────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/auth_mode.rs | 204 | // ── Default ────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/unidiff_detector.rs | 152 | // ─── Tests ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 47 | // ─── Score-weight constants ──────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 74 | // ─── Public API ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 530 | // ─── Internal types ──────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 580 | // ─── Parser ──────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 826 | // ─── Scoring ─────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 917 | // ─── Hunk selection (max_hunks_per_file cap) ─────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1000 | // ─── Context trimming ────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1083 | // ─── Output formatter ────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1153 | // ─── Helpers ─────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1217 | // ─── Tests ───────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1315 | // ─── Lossy-path tests ─────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/diff_compressor.rs | 1515 | // ─── Bug-fix tests (rename/combined-diff/no-newline/pre-diff) ────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/kompress.rs | 71 | // ─── Tunable defaults (parity-pinned to kompress-v2-base) ─────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/kompress.rs | 108 | // ─── Types ────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/kompress.rs | 191 | // ─── Compressor ───────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | crates/headroom-core/src/transforms/kompress.rs | 581 | // ─── Loading helpers ──────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | crates/headroom-core/src/transforms/magika_detector.rs | 451 | // ── JSON ─────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | crates/headroom-core/src/transforms/magika_detector.rs | 458 | // ── Diffs ────────────────────────────────────────────────── | COMMENT |
| 2781 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | docker/differential-network-capture/mitm_capture.py | 3 | CODE | |
| LOW | …ns/headroom-oauth2/tests/test_scope_and_proxy_token.py | 10 | CODE | |
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/provider.py | 8 | CODE | |
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/__init__.py | 7 | CODE | |
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/__init__.py | 15 | CODE | |
| LOW | …gins/headroom-oauth2/src/headroom_oauth2/middleware.py | 18 | CODE | |
| LOW | plugins/hermes/headroom_retrieve/__init__.py | 13 | CODE | |
| LOW | tests/test_copilot_integration_id_hmac.py | 32 | CODE | |
| LOW | tests/test_quota_registry.py | 3 | CODE | |
| LOW | tests/test_sse_thinking_blocks.py | 21 | CODE | |
| LOW | tests/test_paths_backward_compat.py | 16 | CODE | |
| LOW | tests/test_usage_reporter_snapshot.py | 6 | CODE | |
| LOW | tests/test_provider_codex_install.py | 1 | CODE | |
| LOW | tests/test_token_count_cache.py | 8 | CODE | |
| LOW | tests/test_memory_decision.py | 27 | CODE | |
| LOW | tests/test_hook_protect_messages.py | 10 | CODE | |
| LOW | tests/test_extension_attribution.py | 10 | CODE | |
| LOW | tests/test_dataset_recall_runner.py | 9 | CODE | |
| LOW | tests/e2e_cortex_savings.py | 30 | CODE | |
| LOW | tests/e2e_cortex_savings.py | 45 | CODE | |
| LOW | tests/test_openai_responses_t3_replay_regression.py | 1 | CODE | |
| LOW | tests/test_provider_antigravity.py | 1 | CODE | |
| LOW | tests/test_h2_stream_reset_retry.py | 11 | CODE | |
| LOW | tests/test_memory_wrapper.py | 1 | CODE | |
| LOW | tests/test_system_compaction_handler.py | 5 | CODE | |
| LOW | tests/test_codex_responses_passthrough_bytes.py | 11 | CODE | |
| LOW | tests/test_tool_name_policy.py | 1 | CODE | |
| LOW | tests/test_error_detection.py | 3 | CODE | |
| LOW | tests/test_proxy_pipeline_lifecycle.py | 1 | CODE | |
| LOW | tests/test_tool_injection_config.py | 1 | CODE | |
| LOW | tests/test_kompress_line_integrity.py | 5 | CODE | |
| LOW | tests/_gemini_live.py | 3 | CODE | |
| LOW | tests/test_wrap_concurrent_settings.py | 16 | CODE | |
| LOW | tests/test_codex_ws_per_frame_memory.py | 1 | CODE | |
| LOW | tests/test_anthropic_auto_mode_passthrough.py | 1 | CODE | |
| LOW | tests/test_memory_rank_policy.py | 3 | CODE | |
| LOW | tests/test_hermes_passthrough_compression.py | 15 | CODE | |
| LOW | tests/test_openai_responses_buffered_sse.py | 5 | CODE | |
| LOW | tests/test_openai_responses_context_compaction.py | 1 | CODE | |
| LOW | tests/test_codex_ws_savings_deferral.py | 11 | CODE | |
| LOW | tests/test_websearch_tool_result_protection.py | 3 | CODE | |
| LOW | tests/test_image_compression_offload.py | 9 | CODE | |
| LOW | tests/test_turn_hooks.py | 10 | CODE | |
| LOW | tests/test_memory_tool_stream.py | 9 | CODE | |
| LOW | tests/test_system_compaction.py | 10 | CODE | |
| LOW | tests/test_provider_copilot_vscode_config.py | 1 | CODE | |
| LOW | tests/test_cost_budget_performance.py | 3 | CODE | |
| LOW | tests/test_proxy_loop_exception_health.py | 3 | CODE | |
| LOW | tests/test_provider_registry_extended.py | 1 | CODE | |
| LOW | tests/test_stats_new_input_savings_rate.py | 10 | CODE | |
| LOW | tests/test_code_compressor_syntax_breaker.py | 11 | CODE | |
| LOW | tests/test_content_router_recovery_tool_exclusion.py | 13 | CODE | |
| LOW | tests/test_outcome_token_scale.py | 19 | CODE | |
| LOW | tests/test_utils.py | 1 | CODE | |
| LOW | tests/test_proxy_cache_ttl_metrics.py | 3 | CODE | |
| LOW | tests/test_prometheus_obs_counters.py | 17 | CODE | |
| LOW | tests/test_storage_backends.py | 1 | CODE | |
| LOW | tests/test_provider_route_specs.py | 1 | CODE | |
| LOW | tests/test_codex_rate_limits.py | 3 | CODE | |
| LOW | tests/test_stateless_writers.py | 8 | CODE | |
| 2202 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_memory_decision.py | 52 | except FrozenInstanceError: | CODE |
| HIGH | tests/test_codex_ws_per_frame_memory.py | 352 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_codex_ws_per_frame_memory.py | 382 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_codex_ws_per_frame_memory.py | 416 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_codex_ws_per_frame_memory.py | 454 | except asyncio.CancelledError: | CODE |
| HIGH | tests/conftest.py | 562 | except Exception: # pragma: no cover - a closed/rotated file is fine | CODE |
| HIGH | tests/test_stateless_writers.py | 32 | except Exception: | CODE |
| HIGH | tests/test_proxy_savings_history.py | 360 | except OSError: | CODE |
| HIGH | tests/test_image_compression.py | 29 | except ImportError: | CODE |
| HIGH | tests/test_wrap_code_memory.py | 173 | except click.ClickException: | CODE |
| HIGH | tests/test_memory_injection_budget.py | 26 | except FrozenInstanceError: | CODE |
| HIGH | tests/test_startup_log_noise.py | 40 | except Exception: | CODE |
| HIGH | tests/test_startup_log_noise.py | 60 | except Exception: | CODE |
| HIGH | tests/test_compression_decision.py | 64 | except FrozenInstanceError: | CODE |
| HIGH | tests/test_memory_integration.py | 44 | except OSError: | CODE |
| HIGH | tests/test_openai_codex_ws_lifecycle.py | 704 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_openai_codex_ws_lifecycle.py | 767 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_openai_codex_ws_lifecycle.py | 826 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_openai_codex_ws_lifecycle.py | 1208 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_openai_codex_ws_lifecycle.py | 1330 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_providers_opencode_config.py | 489 | except click_mod.ClickException: | CODE |
| HIGH | tests/test_providers_opencode_config.py | 491 | except OSError: | CODE |
| HIGH | tests/test_memory_query.py | 37 | except FrozenInstanceError: | CODE |
| HIGH | tests/_mcp_stub.py | 90 | except AttributeError: | CODE |
| HIGH | tests/test_kompress_request_nonblocking.py | 195 | except ValueError: | CODE |
| HIGH | tests/test_image_compression_decision.py | 49 | except FrozenInstanceError: | CODE |
| HIGH | tests/test_provider_codex_runtime.py | 207 | except Exception: # pragma: no cover - best effort poll | CODE |
| HIGH | tests/e2e_ws_responses_compression.py | 131 | except websockets.exceptions.ConnectionClosed: | CODE |
| HIGH | tests/test_stateless_no_disk.py | 56 | except Exception: | CODE |
| HIGH | tests/test_ws_session_registry.py | 114 | except asyncio.CancelledError: | CODE |
| HIGH | tests/test_proxy_debug_endpoints.py | 333 | except (asyncio.CancelledError, BaseException): | CODE |
| HIGH | tests/test_proxy_debug_endpoints.py | 366 | except (asyncio.CancelledError, BaseException): | CODE |
| HIGH | tests/test_offline_egress_chokepoint.py | 273 | except OfflineEgressBlocked: | CODE |
| HIGH | tests/test_direct_chat_ccr_resolution.py | 138 | except Exception: # pragma: no cover - a test handler must not raise | CODE |
| HIGH | tests/test_upstream_guard.py | 219 | except Exception: # noqa: BLE001 - route errors are not the subject | CODE |
| HIGH | tests/e2e_ws_codex_usage_headers.py | 100 | except websockets.exceptions.ConnectionClosed: | CODE |
| HIGH | tests/test_proxy_hardening.py | 390 | except Exception: # noqa: BLE001 - the refusal shape is asserted above | CODE |
| HIGH | tests/test_proxy_hardening.py | 404 | except Exception: # noqa: BLE001 - route may fail with no upstream | CODE |
| HIGH | tests/test_proxy_hardening.py | 720 | except Exception: # noqa: BLE001 - spy closes the socket immediately | CODE |
| HIGH | …roxy/test_anthropic_no_optimize_history_passthrough.py | 240 | except ImportError: | CODE |
| HIGH | tests/test_install/test_native_installers.py | 257 | except OSError: | CODE |
| HIGH | tests/test_install/test_native_installers.py | 745 | except FileNotFoundError: | CODE |
| HIGH | …sts/test_integrations/langchain/test_langchain_live.py | 26 | except ImportError: | CODE |
| HIGH | tests/test_cli/test_wrap_sighup_proxy_leak.py | 243 | except (ProcessLookupError, PermissionError): | CODE |
| HIGH | tests/test_scripts/test_repro_codex_replay_smoke.py | 100 | except asyncio.TimeoutError: | CODE |
| HIGH | examples/vertex_gemini_benchmark/benchmark.py | 353 | except Exception: | CODE |
| HIGH | examples/vertex_gemini_benchmark/benchmark.py | 635 | except Exception: | CODE |
| HIGH | benchmarks/agent_cost_benchmark.py | 237 | except (json.JSONDecodeError, TypeError): | CODE |
| HIGH | benchmarks/agent_cost_benchmark.py | 429 | except Exception: | CODE |
| HIGH | benchmarks/agent_cost_benchmark.py | 509 | except (json.JSONDecodeError, TypeError): | CODE |
| HIGH | benchmarks/codemode_ab.py | 169 | except Exception: | CODE |
| HIGH | headroom/onnx_runtime.py | 281 | except Exception: | CODE |
| HIGH | headroom/proxy_client_liveness.py | 35 | except Exception: | CODE |
| HIGH | headroom/_subprocess.py | 30 | except Exception: | CODE |
| HIGH | headroom/_subprocess.py | 61 | except Exception: | CODE |
| HIGH | headroom/binaries.py | 155 | except (FileNotFoundError, subprocess.TimeoutExpired, OSError): | CODE |
| HIGH | headroom/binaries.py | 360 | except ImportError: | CODE |
| HIGH | headroom/settings_store.py | 1039 | except (ValueError, TypeError): | CODE |
| HIGH | headroom/context_tool_cleanup.py | 355 | except ValueError: | CODE |
| HIGH | headroom/context_tool_cleanup.py | 230 | except OSError: | CODE |
| 178 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | run-all-plugins.sh | 1 | #!/usr/bin/env bash | COMMENT |
| LOW | run-all-plugins.sh | 81 | fi | COMMENT |
| LOW | run-all-plugins.sh | 101 | COMMENT | |
| LOW | Cargo.toml | 41 | # I1 (byte-faithful passthrough on unmutated bytes; see REALIGNMENT/02- | COMMENT |
| LOW | Cargo.toml | 61 | axum = "0.8" | COMMENT |
| LOW | Cargo.toml | 81 | # (ADC) → bearer token for the `Authorization: Bearer <token>` header. | COMMENT |
| LOW | Cargo.toml | 101 | # * Single codegen unit (better inlining + dead-code elim, at the | COMMENT |
| LOW | pyproject.toml | 121 | ] | COMMENT |
| LOW | pyproject.toml | 161 | "torch>=2.12.1; sys_platform == 'darwin'", | COMMENT |
| LOW | pyproject.toml | 181 | # existing v1 tuple-shaped API call. | COMMENT |
| LOW | pyproject.toml | 321 | # test_upstream_guard builds a self-signed cert to prove the pinned connection | COMMENT |
| LOW | pyproject.toml | 341 | # a locked-down/low-resource sandbox and offloading heavy ML elsewhere. | COMMENT |
| LOW | pyproject.toml | 381 | # without a wheel and the rust toolchain isn't available to compile it. | COMMENT |
| LOW | pyproject.toml | 421 | COMMENT | |
| LOW | docker-compose.yml | 1 | # ============================================================================= | COMMENT |
| LOW | docker-compose.yml | 21 | # 7474 Neo4j Browser 7687 Neo4j Bolt | COMMENT |
| LOW | .gitguardian.yaml | 1 | # GitGuardian configuration — secret-detection allowlist | COMMENT |
| LOW | rust-toolchain.toml | 1 | [toolchain] | COMMENT |
| LOW | claude_analysis_ttl.py | 181 | f" Median post-idle write (5-60min gap) : {med_5_60:>10,} tokens " | COMMENT |
| LOW | crates/headroom-parity/src/lib.rs | 181 | stub_comparator!(CacheAlignerComparator, "cache_aligner"); | COMMENT |
| LOW | crates/headroom-parity/src/lib.rs | 241 | COMMENT | |
| LOW | crates/headroom-parity/src/lib.rs | 621 | /// | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 21 | # `hf-hub` is the HuggingFace Hub client. We use the blocking `ureq` transport | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 41 | # ASCII terminators, so the default ASCII splitter/tokenizer collapses a whole | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 61 | # >15% ratio divergence so small per-byte differences don't change the | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 81 | # Stage-3d ContentRouter detection arch). Bundled standard-model is | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 101 | aho-corasick = "1" | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 121 | blake3 = "1" | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 161 | # on Windows it emits DirectML link libs (`DXCORE`, `DXGI`, `D3D12`, | COMMENT |
| LOW | crates/headroom-core/Cargo.toml | 181 | # the ONNX-backed transforms (fastembed embeddings, magika detection, the | COMMENT |
| LOW | …core/proptest-regressions/transforms/tag_protector.txt | 1 | # Seeds for failure cases proptest has generated in the past. It is | COMMENT |
| LOW | crates/headroom-core/config/pipeline.toml | 1 | # Compression pipeline default configuration. | COMMENT |
| LOW | crates/headroom-core/config/pipeline.toml | 21 | COMMENT | |
| LOW | crates/headroom-core/config/pipeline.toml | 41 | COMMENT | |
| LOW | crates/headroom-core/config/pipeline.toml | 81 | # Reformats pack input denser without losing information. Configs here | COMMENT |
| LOW | crates/headroom-core/config/pipeline.toml | 101 | # Floor on the number of constant tokens a template must have. A | COMMENT |
| LOW | crates/headroom-core/config/pipeline.toml | 121 | COMMENT | |
| LOW | crates/headroom-core/tests/live_zone_kompress_absent.rs | 1 | //! Model-absent NoOp — dedicated integration test file. | COMMENT |
| LOW | crates/headroom-core/tests/recommendations_loader.rs | 1 | //! Integration tests for `transforms::recommendations` (PR-B5). | COMMENT |
| LOW | crates/headroom-core/tests/ccr_backends.rs | 241 | COMMENT | |
| LOW | …s/headroom-core/tests/live_zone_kompress_async_init.rs | 1 | //! Non-blocking Kompress initialization — dedicated integration test file. | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 1 | //! Property coverage for the PR-B4 dispatch arms (`SourceCode` → | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 41 | COMMENT | |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 161 | /// drawn from `CODE_IDENTIFIERS`. Added after a review measured that | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 181 | /// | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 381 | "public", | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 441 | /// byte a shell or log scraper can hand a tool_result without ever | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 481 | ] | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 501 | // ranges back down to threshold-capped sizes (that would silently | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 721 | // ─── Part 1, instrumentation: measured dispatch-reach fractions ─────── | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_arm_properties.rs | 741 | /// invoked from `live_zone.rs` right before `compress_one_block`'s | COMMENT |
| LOW | crates/headroom-core/tests/kompress_parity.rs | 1 | //! Byte-parity integration test for the Kompress Rust port. | COMMENT |
| LOW | crates/headroom-core/tests/auth_mode.rs | 1 | //! Integration tests for `headroom_core::auth_mode::classify`. | COMMENT |
| LOW | …/headroom-core/tests/live_zone_disable_arms_parsing.rs | 1 | //! Parsing contract of the `HEADROOM_LIVE_ZONE_DISABLE_ARMS` kill | COMMENT |
| LOW | …ates/headroom-core/tests/live_zone_token_validation.rs | 61 | let s = std::str::from_utf8(bytes).expect("body is UTF-8 JSON"); | COMMENT |
| LOW | …ates/headroom-core/tests/live_zone_token_validation.rs | 81 | // tokenize into many short BPE pieces post-rewrite. | COMMENT |
| LOW | …ates/headroom-core/tests/live_zone_token_validation.rs | 201 | proptest! { | COMMENT |
| LOW | crates/headroom-core/tests/tokenizer_proptest.rs | 41 | let est = EstimatingCounter::default(); | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_dispatch.rs | 1 | //! Integration tests for the PR-B3 live-zone dispatcher. | COMMENT |
| LOW | crates/headroom-core/tests/live_zone_disable_arms.rs | 1 | //! Env-var kill-switch for the live-zone dispatch arms — dedicated | COMMENT |
| 1052 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH⚡ | tests/test_ccr_tool_injection.py | 354 | """A tool call with an explicit {"function": null} / {"functionCall": null} | STRING |
| HIGH | tests/test_proxy_savings_history.py | 1620 | assert "if (this.historySelectedSeriesKey === 'history') return null;" in html | CODE |
| HIGH | tests/test_ccr_tool_calls.py | 63 | # A partial/streamed OpenAI tool call with an explicit {"function": null} | COMMENT |
| HIGH | tests/test_output_steering.py | 39 | # A malformed client block ({"type": "text", "text": null}) must not crash | COMMENT |
| HIGH⚡ | tests/test_copilot_vscode_completions_routing.py | 205 | ``token?.endpoints.proxy || DEFAULT_PROXY_BASE_URL`` where | STRING |
| HIGH⚡ | tests/test_beacon_gzip.py | 192 | 0x1f && bytes[1] === 0x8b` check stops matching and every upload 400s.""" | STRING |
| HIGH⚡ | tests/test_stream_output_tokens.py | 105 | 'data: {"choices": [null]}\n\n', | CODE |
| HIGH⚡ | tests/test_stream_output_tokens.py | 106 | 'data: {"choices": [{"delta": null}]}\n\n', | CODE |
| HIGH⚡ | tests/test_cortex_code_compression.py | 13 | cd headroom && uv run python tests/test_cortex_code_compression.py | STRING |
| HIGH⚡ | tests/test_cortex_code_compression.py | 16 | cd headroom && uv run --with pytest pytest tests/test_cortex_code_compression.py -v -s | STRING |
| HIGH⚡ | tests/test_ccr_response_handler.py | 1022 | `choices: []` or `[null]` on content-filtered / usage-only responses).""" | STRING |
| HIGH | tests/test_dashboard_poll_guard_playwright.py | 36 | window.__urls.push(String(url)); | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 305 | "cd /x && cat a.py", | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 306 | "cd /x && cat -A a.py | head -60", | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 358 | "cd /tmp/core && rg -l safe_math --type py", | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 359 | "cd /tmp/core && grep -rn foo suma/", | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 361 | "cd /a && cd b && rg pat", # chained cds | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 367 | for cmd in ["cd /x && cat a.py", "cd /x && python -c 'x'", "cd /x && ls -la"]: | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 372 | assert _stripcd("cd /tmp/core && rg x") == "rg x" | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 374 | assert _stripcd("cd a && cd b && grep x") == "grep x" | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 480 | anthropic_input = {"command": "cd /tmp/core && cat suma/x.py"} # Anthropic: dict | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 481 | openai_args = json.dumps({"command": "cd /tmp/core && cat suma/x.py"}) # OpenAI: JSON string | CODE |
| HIGH⚡ | tests/test_observed_wire_shapes.py | 486 | assert not _isread2(_cmdtext({"command": "cd /x && rg pat"})) | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 51 | "input": {"command": 'cd /tmp/core && rg -l "safe_math" --type py | head'}, | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 394 | "content": "THOUGHT: look\n```bash\ncd /r && cat x.py\n```", | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 423 | _fenced_shell_command("T\n```mswea_bash_command\ncd /r && cat x.py\n```") | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 424 | == "cd /r && cat x.py" | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 435 | "content": "T\n```mswea_bash_command\ncd /r && cat a.py\n```", | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 444 | "content": "T\n```mswea_bash_command\ncd /r && grep -rn foo .\n```", | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 557 | {"role": "assistant", "content": "", "tool_calls": [tc("c_read", "cd /r && cat a.py")]}, | CODE |
| HIGH | tests/test_observed_wire_shapes.py | 562 | "tool_calls": [tc("c_grep", "cd /r && grep -rn foo .")], | CODE |
| HIGH | tests/test_memory_handler_null_function.py | 5 | ``{"function": null}`` (the default only applies to a missing key). Both | STRING |
| HIGH | tests/test_proxy_handlers_batch.py | 689 | # null), or a request whose `body` isn't a dict, must pass through instead | COMMENT |
| HIGH | tests/test_toin_feedback.py | 324 | 'data: {"type":"message_start","message":{"id":"msg_01","model":"claude-3-5-sonnet-20241022","role":"assista | CODE |
| HIGH | tests/test_backend_nonstreaming_cache_metrics.py | 494 | value null) rather than omitting them — the direct-Anthropic path already | STRING |
| HIGH | tests/test_openai_codex_ws_timings.py | 293 | with ``upstream_first_event`` absent (null).""" | STRING |
| HIGH | tests/test_anthropic_buffered_sse.py | 43 | '"stop_reason":null,"stop_sequence":null,"usage":{"input_tokens":10,' | CODE |
| HIGH | tests/test_anthropic_buffered_sse.py | 56 | '"stop_sequence":null},"usage":{"output_tokens":5}}\n\n' | CODE |
| HIGH⚡ | tests/test_tool_call_arguments_not_a_string.py | 75 | """``{"function": null}`` / ``{"id": null}`` reach the same encode path.""" | STRING |
| HIGH⚡ | tests/test_code_compressor_bash.py | 21 | if [[ "$( git config --global alias.pushall 2>/dev/null )" != '!git remote | xargs -L1 git push --all' ]] | CODE |
| HIGH | tests/test_prefix_tracker_client_rewrote_reply.py | 39 | "input": {"command": "cd /work && git ls-files"}, | CODE |
| HIGH | tests/test_dashboard_token_savings.py | 36 | assert 'x-show="(stats.tokens?.new_input_tokens || 0) > 0"' in html | CODE |
| HIGH | tests/test_code_aware_brace_comment_regressions.py | 61 | this.users.push(user); | CODE |
| HIGH | tests/test_proxy_streaming_request_logger.py | 285 | b'"content":[],"stop_reason":null,"usage":{' | CODE |
| HIGH⚡ | tests/test_cache_prefix_overlay.py | 296 | _openai_asst("cd /tmp/core && rg -n foo ."), | CODE |
| HIGH⚡ | tests/test_cache_prefix_overlay.py | 298 | _openai_asst("cd /tmp/core && cat foo.py"), # NEW delta (assistant) | CODE |
| HIGH | tests/test_cache_prefix_overlay.py | 270 | cmd = "cd /tmp/core && cat suma/apps/underwriting/followup/service.py" | CODE |
| HIGH⚡ | tests/test_proxy_dashboard_stats_cache.py | 209 | assert "formatNumber(stats.tokens?.saved || 0) + ' tokens total'" not in html | CODE |
| HIGH | tests/test_release_workflows.py | 214 | "${{ steps.bake.outcome == 'success' && steps.bake.outputs.metadata || steps.bake-fallback.outputs.metadata }}" | CODE |
| HIGH | tests/test_release_workflows.py | 243 | "steps.bake.outcome == 'success' && steps.bake.outputs.metadata || steps.bake-fallback.outputs.metadata" | CODE |
| HIGH⚡ | tests/test_content_router_compact_json.py | 81 | '{"id":79,"epic_id":9,"title":"test","description":null,' | CODE |
| HIGH⚡ | tests/test_content_router_compact_json.py | 83 | '"assigned_to":null,"estimated_hours":null,"actual_hours":null,' | CODE |
| HIGH⚡ | tests/test_content_router_compact_json.py | 84 | '"due_date":null,"source_ref":null,"metadata":"{}",' | CODE |
| HIGH⚡ | tests/test_content_router_compact_json.py | 86 | '"description_locked":0,"is_deleted":0,"deleted_at":null,' | CODE |
| HIGH⚡ | tests/test_content_router_compact_json.py | 87 | '"deleted_by":null,"delete_reason":null,"epic_name":"latency-routing",' | CODE |
| HIGH⚡ | tests/test_proxy/test_context_guard.py | 144 | # Upstreams and gateways put null, objects and lists in the message | COMMENT |
| HIGH | tests/test_proxy/test_gemini_savings_profile.py | 116 | b'"usageMetadata":{"promptTokenCount":20,"candidatesTokenCount":null}}' | CODE |
| HIGH | tests/test_proxy/test_transformations_feed.py | 76 | three body fields are absent (not null) and every other field is the same | STRING |
| HIGH | tests/test_install/test_native_installers.py | 871 | $InstallScript, [ref]$null, [ref]$null) | STRING |
| HIGH | tests/test_install/test_native_installers.py | 945 | $InstallScript, [ref]$null, [ref]$null) | STRING |
| 97 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | claude_analysis_ttl.py | 55 | except Exception: | CODE |
| LOW | claude_analysis_ttl.py | 65 | except Exception: | CODE |
| LOW | claude_analysis_ttl.py | 108 | except Exception: | CODE |
| LOW | docker/differential-network-capture/mitm_capture.py | 58 | except Exception: | CODE |
| LOW | tests/e2e_cortex_savings.py | 382 | except Exception as e: | CODE |
| LOW | tests/test_prometheus_obs_counters.py | 170 | except Exception as exc: # pragma: no cover - failure path | CODE |
| MEDIUM | tests/conftest.py | 166 | def _reset_litellm_model_resolution_cache(): | CODE |
| LOW | tests/conftest.py | 34 | except Exception: | CODE |
| LOW | tests/conftest.py | 222 | except Exception: | CODE |
| LOW | tests/conftest.py | 562 | except Exception: # pragma: no cover - a closed/rotated file is fine | CODE |
| LOW | tests/test_stateless_writers.py | 32 | except Exception: | CODE |
| LOW | tests/e2e_real_compression.py | 86 | except Exception: | CODE |
| LOW | tests/e2e_real_compression.py | 124 | except Exception: | CODE |
| LOW | tests/test_tokenizer.py | 54 | except Exception: # vocab unavailable → estimator fallback; monotonicity above still holds | CODE |
| MEDIUM | tests/test_compression_cache.py | 587 | def reader() -> None: | CODE |
| MEDIUM | tests/test_compression_cache.py | 594 | def writer() -> None: | CODE |
| LOW | tests/test_compression_cache.py | 116 | except Exception as exc: # pragma: no cover | CODE |
| LOW | tests/test_compression_cache.py | 591 | except Exception as e: # pragma: no cover | CODE |
| LOW | tests/test_compression_cache.py | 599 | except Exception as e: # pragma: no cover | CODE |
| LOW | tests/test_compression_cache.py | 700 | except Exception as e: # pragma: no cover | CODE |
| LOW | tests/test_compression_cache.py | 740 | except Exception as e: # pragma: no cover | CODE |
| LOW | tests/test_startup_log_noise.py | 40 | except Exception: | CODE |
| LOW | tests/test_startup_log_noise.py | 60 | except Exception: | CODE |
| MEDIUM | tests/test_compression_store.py | 1341 | def retrieve_item() -> None: | CODE |
| LOW | tests/test_compression_store.py | 1321 | except Exception as e: | CODE |
| LOW | tests/test_compression_store.py | 1346 | except Exception as e: | CODE |
| LOW | tests/test_compression_store.py | 1381 | except Exception as e: | CODE |
| LOW | tests/e2e_cortex_mcp.py | 336 | except Exception as e: | CODE |
| LOW | tests/e2e_cortex_quality.py | 371 | except Exception as exc: | CODE |
| MEDIUM | tests/test_memory_bridge.py | 73 | def wrapper(*args, **kwargs): | CODE |
| LOW⚡ | tests/test_memory_bridge.py | 76 | except Exception as exc: | CODE |
| LOW | tests/test_critical_gaps.py | 364 | except Exception as e: | CODE |
| LOW | tests/test_critical_gaps.py | 476 | except Exception as e: | CODE |
| LOW | tests/test_critical_gaps.py | 490 | except Exception as e: | CODE |
| LOW | tests/test_critical_gaps.py | 501 | except Exception as e: | CODE |
| MEDIUM | tests/test_memory_handler_concurrent_init.py | 34 | def wrapper(*args, **kwargs): | CODE |
| LOW⚡ | tests/test_memory_handler_concurrent_init.py | 37 | except Exception as exc: | CODE |
| LOW⚡ | tests/test_memory_handler_concurrent_init.py | 303 | except Exception: | CODE |
| LOW⚡ | tests/test_memory_handler_concurrent_init.py | 306 | except Exception: # pragma: no cover - env-dependent | CODE |
| LOW | tests/e2e_cortex_latency.py | 434 | except Exception as exc: | CODE |
| LOW | tests/e2e_cortex_proxy_mcp.py | 107 | except Exception: | CODE |
| LOW | tests/e2e_cortex_proxy_mcp.py | 360 | except Exception as e: | CODE |
| LOW⚡ | tests/e2e_cortex_proxy.py | 116 | except Exception: | CODE |
| LOW | tests/e2e_cortex_proxy.py | 217 | except Exception as e: | CODE |
| LOW⚡ | tests/e2e_cortex_proxy.py | 274 | except Exception as e: | CODE |
| LOW⚡ | tests/e2e_cortex_proxy.py | 288 | except Exception as e: | CODE |
| LOW | tests/test_provider_codex_runtime.py | 207 | except Exception: # pragma: no cover - best effort poll | CODE |
| LOW | tests/e2e_ws_responses_compression.py | 55 | except Exception: | CODE |
| LOW | tests/test_stateless_no_disk.py | 56 | except Exception: | CODE |
| LOW | tests/test_ccr.py | 351 | except Exception as e: | CODE |
| MEDIUM | tests/test_ccr.py | 336 | def store_and_retrieve(i): | CODE |
| LOW⚡ | tests/test_offline_egress_chokepoint.py | 271 | except Exception: # noqa: BLE001 — the whole point of the test | CODE |
| LOW | tests/test_offline_egress_chokepoint.py | 2169 | except Exception: # pragma: no cover - defensive | CODE |
| LOW | tests/test_offline_egress_chokepoint.py | 2219 | except Exception: # pragma: no cover - defensive | CODE |
| LOW | tests/test_direct_chat_ccr_resolution.py | 138 | except Exception: # pragma: no cover - a test handler must not raise | CODE |
| LOW | tests/test_upstream_guard.py | 219 | except Exception: # noqa: BLE001 - route errors are not the subject | CODE |
| LOW | tests/test_upstream_guard.py | 387 | except Exception as exc: # noqa: BLE001 - an upstream failure is a pass here | CODE |
| LOW | tests/test_upstream_guard.py | 526 | except Exception as exc: # noqa: BLE001 | CODE |
| LOW | tests/test_upstream_guard.py | 560 | except Exception: # noqa: BLE001 - a refused handshake is the pass | CODE |
| LOW | tests/test_upstream_guard.py | 716 | except Exception as exc: # noqa: BLE001 - the refusal is the subject | CODE |
| 946 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | claude_analysis_ttl.py | 45 | CODE | |
| LOW | claude_analysis_ttl.py | 98 | CODE | |
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/__init__.py | 114 | CODE | |
| LOW | tests/test_output_only_request_blocks.py | 45 | CODE | |
| LOW | tests/test_output_only_request_blocks.py | 120 | CODE | |
| LOW | tests/test_output_only_request_blocks.py | 185 | CODE | |
| LOW | tests/test_backend_anyllm.py | 530 | CODE | |
| LOW | tests/test_dashboard_cache_net_playwright.py | 358 | CODE | |
| LOW | tests/test_proxy_openai_cache_stability.py | 1183 | CODE | |
| LOW | tests/e2e_real_compression.py | 79 | CODE | |
| LOW | tests/e2e_real_compression.py | 252 | CODE | |
| LOW | tests/test_read_maturation_handler_nobust.py | 164 | CODE | |
| LOW | tests/test_read_maturation_handler_nobust.py | 285 | CODE | |
| LOW | tests/test_handler_outcome_tag_invariant.py | 38 | CODE | |
| LOW | tests/test_mixed_content_scan_cache.py | 23 | CODE | |
| LOW | tests/test_proxy_system_prompt_immutable.py | 371 | CODE | |
| LOW | tests/test_cache_control_ttl_order.py | 46 | CODE | |
| LOW | tests/test_dashboard_accessibility.py | 113 | CODE | |
| LOW | tests/test_dashboard_accessibility.py | 117 | CODE | |
| LOW | tests/test_memory_integration.py | 280 | CODE | |
| LOW | tests/test_openai_codex_ws_lifecycle.py | 1402 | CODE | |
| LOW | tests/test_critical_gaps.py | 163 | CODE | |
| LOW | tests/test_critical_gaps.py | 340 | CODE | |
| LOW | tests/test_critical_gaps.py | 355 | CODE | |
| LOW | tests/test_binaries.py | 540 | CODE | |
| LOW | tests/test_realignment_live_multi_turn.py | 559 | CODE | |
| LOW | tests/test_realignment_live_multi_turn.py | 864 | CODE | |
| LOW | tests/test_tag_protector_invariant.py | 121 | CODE | |
| LOW | tests/test_cross_turn_dedup.py | 141 | CODE | |
| LOW | tests/_mcp_stub.py | 58 | CODE | |
| LOW | tests/e2e_cortex_proxy_mcp.py | 148 | CODE | |
| LOW | tests/test_proxy_anthropic_cache_stability.py | 1688 | CODE | |
| LOW | tests/test_anthropic_pre_upstream_backpressure.py | 1022 | CODE | |
| LOW | tests/test_anthropic_pre_upstream_backpressure.py | 1027 | CODE | |
| LOW | tests/test_keep_last_turns.py | 483 | CODE | |
| LOW | tests/test_keep_last_turns.py | 557 | CODE | |
| LOW | tests/test_tool_result_interceptors.py | 38 | CODE | |
| LOW | tests/e2e_ws_responses_compression.py | 48 | CODE | |
| LOW | tests/test_claude_session_mode_benchmark.py | 442 | CODE | |
| LOW | tests/test_claude_session_mode_benchmark.py | 450 | CODE | |
| LOW | tests/test_offline_egress_chokepoint.py | 2053 | CODE | |
| LOW | tests/test_offline_egress_chokepoint.py | 2127 | CODE | |
| LOW | tests/test_offline_egress_chokepoint.py | 1331 | CODE | |
| LOW | tests/test_upstream_guard.py | 191 | CODE | |
| LOW | tests/test_upstream_guard.py | 912 | CODE | |
| LOW | tests/test_release_workflows.py | 719 | CODE | |
| LOW | tests/e2e_ws_codex_usage_headers.py | 65 | CODE | |
| LOW | tests/test_sse_safeguards_passthrough.py | 20 | CODE | |
| LOW | tests/test_plugin_hook_launcher.py | 34 | CODE | |
| LOW | tests/test_no_trust_remote_code.py | 51 | CODE | |
| LOW | tests/test_cache/test_prefix_tracker.py | 896 | CODE | |
| LOW | tests/test_cache/test_client_integration.py | 38 | CODE | |
| LOW | tests/test_integrations/langchain/test_chat_model.py | 1087 | CODE | |
| LOW | tests/test_integrations/agno/test_model.py | 1048 | CODE | |
| LOW | tests/test_cli/test_wrap_copilot.py | 56 | CODE | |
| LOW | tests/test_cli/test_wrap_copilot.py | 245 | CODE | |
| LOW | tests/test_cli/test_wrap_codex.py | 1914 | CODE | |
| LOW | tests/test_cli/test_wrap_codex.py | 2066 | CODE | |
| LOW | tests/test_cli/test_wrap_codex.py | 2122 | CODE | |
| LOW | tests/test_cli/test_wrap_grok.py | 25 | CODE | |
| 482 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/__init__.py | 17 | __all__ = ["OAuth2ClientCredentials", "OAuth2Error", "OAuth2Middleware", "install", "parse_headers"] | CODE |
| LOW⚡ | tests/test_providers_opencode_config.py | 21 | def _set_test_home(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None: | CODE |
| LOW | tests/test_cli_learn.py | 545 | def set_context_target(self, target: str | None) -> None: | CODE |
| LOW⚡ | tests/test_ssl_context.py | 96 | def set_alpn_protocols(self, protocols: list[str]) -> None: | CODE |
| LOW | …ts/test_proxy/test_anthropic_ccr_deferred_injection.py | 107 | def update_from_result(self, originals, compressed) -> None: # noqa: ARG002 | CODE |
| LOW | tests/test_learn/test_opencode_scanner.py | 99 | def _set_mtime(path: Path, *, seconds: int) -> None: | CODE |
| LOW | tests/parity/recorder.py | 1388 | __all__ = [ | CODE |
| LOW | tests/test_cli/test_wrap_codex.py | 31 | def _set_test_home(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None: | CODE |
| LOW⚡ | tests/test_cli/test_wrap_opencode.py | 45 | def _set_test_home(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None: | CODE |
| LOW⚡ | tests/test_cli/test_wrap_bridge.py | 25 | def _set_test_home(monkeypatch, tmp_path: Path) -> None: | CODE |
| LOW | tests/test_mcp_registry/test_claude_registrar.py | 872 | def _set_enabled(settings: Path, enabled: bool, *, plugin_id: str = _PLUGIN_ID) -> None: | CODE |
| LOW | tests/test_compression/test_evals.py | 132 | logger = logging.getLogger(__name__) | STRING |
| LOW | benchmarks/__init__.py | 36 | __all__ = [ | CODE |
| LOW | benchmarks/scenarios/__init__.py | 22 | __all__ = [ | CODE |
| LOW⚡ | scripts/version-sync.py | 40 | def update_package_json(file_path: Path, version: str) -> None: | CODE |
| LOW⚡ | scripts/version-sync.py | 50 | def update_plugin_manifest(file_path: Path, version: str) -> None: | CODE |
| LOW⚡ | scripts/version-sync.py | 60 | def update_marketplace_manifest(file_path: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 77 | def update_server_json(file_path: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 99 | def update_plugin_versions(root: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 115 | def update_openclaw_package_json(file_path: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 130 | def update_opencode_package_json(file_path: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 145 | def update_pyproject_version(root: Path, version: str) -> None: | CODE |
| LOW | scripts/version-sync.py | 176 | def update_uv_lock_version(root: Path, version: str) -> None: | CODE |
| LOW | e2e/_lib/harness.py | 327 | __all__ = [ | CODE |
| LOW | e2e/_lib/__init__.py | 23 | __all__ = [ | CODE |
| LOW | headroom/onnx_runtime.py | 13 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/proxy_client_liveness.py | 17 | __all__ = ["identity_mismatch", "marker_pid_reused", "pid_alive", "proc_identity"] | CODE |
| LOW⚡ | headroom/paths.py | 109 | def set_process_stateless(value: bool) -> None: | CODE |
| LOW | headroom/paths.py | 474 | __all__ = [ | CODE |
| LOW | headroom/binaries.py | 59 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/binaries.py | 61 | __all__ = [ | CODE |
| LOW | headroom/update_check.py | 34 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/update_check.py | 327 | __all__ = [ | CODE |
| LOW | headroom/savings_ledger.py | 765 | __all__ = [ | CODE |
| LOW | headroom/settings_store.py | 30 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/client.py | 38 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/managed_block.py | 44 | __all__ = ["block_pattern", "sanitize_block_text"] | CODE |
| LOW | headroom/__init__.py | 97 | __all__ = [ | CODE |
| LOW | headroom/copilot_linux_secret.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/rollout.py | 19 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/shared_context.py | 33 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/compress.py | 73 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/_ort.py | 46 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/copilot_auth.py | 32 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/copilot_auth.py | 1041 | def _set_header_default(headers: dict[str, str], name: str, value: str) -> None: | CODE |
| LOW | headroom/agent_savings.py | 11 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/copilot_macos_keychain.py | 14 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/mcp_registry/codex.py | 28 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/mcp_registry/claude.py | 42 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/mcp_registry/grok.py | 28 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/mcp_registry/__init__.py | 33 | __all__ = [ | CODE |
| LOW | headroom/mcp_registry/opencode.py | 22 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/mcp_registry/antigravity.py | 41 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/relevance/embedding.py | 60 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/relevance/__init__.py | 57 | __all__ = [ | CODE |
| LOW | headroom/tokenizers/mistral.py | 17 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/tokenizers/registry.py | 20 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/tokenizers/__init__.py | 58 | __all__ = [ | CODE |
| LOW | headroom/tokenizers/huggingface.py | 17 | logger = logging.getLogger(__name__) | CODE |
| LOW | headroom/tokenizers/tiktoken_counter.py | 21 | logger = logging.getLogger(__name__) | CODE |
| 255 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM⚡ | run-all-plugins.sh | 128 | # wait for readiness (no foreground sleep on this harness) | COMMENT |
| MEDIUM | codecov.yml | 6 | # Gate on the comprehensive unit suite (`python` flag from ci.yml's 4 test | COMMENT |
| MEDIUM | pyproject.toml | 330 | # The EleutherAI lm-evaluation-harness is intentionally not exposed as a | COMMENT |
| MEDIUM | pyproject.toml | 332 | # (`python -m lm_eval`), and the harness currently pulls sqlitedict | COMMENT |
| MEDIUM | pyproject.toml | 350 | # ML weight a sandbox avoids; evals is a dev/test harness, not a | COMMENT |
| MEDIUM | pyproject.toml | 528 | # test-teardown thread; this is a test-harness artifact, not a production issue | COMMENT |
| MEDIUM | crates/headroom-parity/src/lib.rs | 56 | /// differing by 1 ULP). To make comparisons robust we round-trip the | COMMENT |
| MEDIUM | crates/headroom-py/Cargo.toml | 23 | # Disable the default test harness — Rust `cargo test` can't run a cdylib that | COMMENT |
| MEDIUM | tests/test_openai_responses_t3_replay_regression.py | 173 | # Simulate a harness that changed/trimmed the ancient envelope. | COMMENT |
| MEDIUM⚡ | tests/test_request_outcome.py | 149 | # ── classify_client — the harness ID source ───────────────────────── | COMMENT |
| MEDIUM⚡ | tests/test_request_outcome.py | 172 | # X-Client wins even when UA matches a different harness | COMMENT |
| MEDIUM⚡ | tests/test_request_outcome.py | 110 | assert o.client is None # unidentified harness | CODE |
| MEDIUM | tests/test_request_outcome.py | 217 | # Bind the real method to this harness. | COMMENT |
| MEDIUM⚡ | tests/test_google_multimodal.py | 557 | # Parametrized tests for comprehensive coverage | COMMENT |
| MEDIUM | tests/test_dashboard_cache_net_playwright.py | 154 | # escapes the harness to the real network. | COMMENT |
| LOW | tests/test_image_compressor.py | 613 | # URL images should just pass through since we can't extract data | COMMENT |
| MEDIUM | tests/test_proxy_handler_helpers.py | 297 | # Issue #765: compression relocated the harness system block into | COMMENT |
| MEDIUM | tests/test_ccr_feedback.py | 327 | """get_stats returns comprehensive overview.""" | STRING |
| MEDIUM⚡ | tests/test_tool_search_client_deferral.py | 151 | # prefix test miss a shipped harness. | COMMENT |
| MEDIUM⚡ | tests/test_observed_wire_shapes.py | 289 | # HEADROOM_LOG_MESSAGES trace of the `inspect` non-litellm harness); | COMMENT |
| MEDIUM⚡ | tests/test_observed_wire_shapes.py | 332 | # Section 5 — command classification is harness-agnostic (Bug A + Bug B) | COMMENT |
| MEDIUM⚡ | tests/test_observed_wire_shapes.py | 474 | # The SAME read action, as each provider/harness serializes its tool call. | COMMENT |
| MEDIUM⚡ | tests/test_observed_wire_shapes.py | 511 | # object — raw and harness-wrapped — is RELEASED (not protected) for compression | COMMENT |
| MEDIUM⚡ | tests/test_observed_wire_shapes.py | 534 | # whatever role the harness stamps on it. | COMMENT |
| MEDIUM | tests/test_observed_wire_shapes.py | 411 | # command* so cat/sed code reads are passed verbatim on ANY model/harness. | COMMENT |
| MEDIUM⚡ | tests/test_cross_turn_dedup.py | 347 | # — role:tool, role:function, or a text-harness role:user string — keyed off the | COMMENT |
| MEDIUM | tests/test_cross_turn_dedup.py | 364 | # Text-harness shape: the read output arrives as a role:user STRING after an | COMMENT |
| MEDIUM | tests/test_openai_tool_search_deferral.py | 206 | # --- client-harness exclusion (GH #2660) ------------------------------------- | COMMENT |
| MEDIUM | tests/test_transforms_content_router.py | 2494 | # A text harness returns its tool output as a role:user string after the | COMMENT |
| MEDIUM⚡ | tests/test_densify_agent_mode.py | 125 | # Generic harness: OpenAI chat format (role='tool', string content) — not | COMMENT |
| LOW | tests/test_bedrock_region.py | 162 | # We need to actually test the function, so let's just use the | COMMENT |
| MEDIUM | tests/test_proxy_hooks_regression.py | 46 | # from that same tokenizer so the test stays robust to any future | COMMENT |
| MEDIUM | tests/test_offline_egress_chokepoint.py | 2033 | | (?:datasets\.)?load_dataset # HF datasets (eval harness) | CODE |
| MEDIUM⚡ | tests/test_counterfactual_pricing.py | 184 | # ── Provider agnosticism: every harness, every backend ──────────────────── | COMMENT |
| MEDIUM | tests/test_savings_ledger.py | 329 | # identified harness -> recorded as that client | COMMENT |
| MEDIUM | tests/test_savings_ledger.py | 341 | # unidentified harness -> falls back to "proxy" | COMMENT |
| MEDIUM | tests/test_dashboard_cache_ttl_playwright.py | 187 | # escapes the harness to the real network. | COMMENT |
| LOW | tests/test_evals/test_html_extraction_eval.py | 308 | # These should not fail (just create the evaluator) | COMMENT |
| MEDIUM | tests/test_evals/test_html_oss_benchmarks.py | 279 | # Print comprehensive results | COMMENT |
| MEDIUM⚡ | tests/test_transforms/test_compaction_codec.py | 142 | # A harness that round-trips the block through a Windows text-mode file (or | COMMENT |
| MEDIUM | tests/gateway/test_kong_integration.py | 52 | try: # owned by the harness; may land after this file | CODE |
| MEDIUM | tests/gateway/test_kong_integration.py | 54 | except ImportError: # pragma: no cover - harness not present yet | CODE |
| MEDIUM | tests/gateway/test_kong_integration.py | 101 | # This harness deliberately binds 0.0.0.0 with no inbound token so the | COMMENT |
| MEDIUM | examples/strands_via_proxy_demo.py | 9 | Fix #4 Strands harness label in CLIENT_UA_MAP | STRING |
| MEDIUM | benchmarks/i18n_compression_eval.py | 48 | # CJK has no spaces; drop all whitespace so substring match is robust. | COMMENT |
| MEDIUM | benchmarks/conftest.py | 241 | "\n\n## Guidelines\n1. Always explain your reasoning\n2. Provide code examples when helpful\n3. Consider edge ca | CODE |
| MEDIUM⚡ | benchmarks/real_world_agent_benchmark.py | 52 | #: changing it changes every number this harness reports. | COMMENT |
| MEDIUM | benchmarks/comprehensive_eval.py | 710 | """Run comprehensive evaluation.""" | STRING |
| MEDIUM | .github/workflows/rust.yml | 217 | # harness fails only on a Diff — `parity-run` sets `any_diffs` inside the | COMMENT |
| MEDIUM | e2e/init/run.py | 33 | # Add repo root to sys.path so the harness import works whether the file is | COMMENT |
| MEDIUM | e2e/init/run.py | 56 | # The harness restores PATH before assertions, but `headroom init` ran with a | COMMENT |
| MEDIUM | e2e/wrap/run.py | 498 | # Container defaults now bind to all interfaces; this isolated harness | COMMENT |
| MEDIUM | e2e/wrap/run.py | 1008 | # This harness owns a foreground gateway under an isolated HOME. | COMMENT |
| LOW | headroom/config.py | 318 | # Why NOT just add these to DEFAULT_VERBATIM_EXCLUDE_TOOLS, which would have been | COMMENT |
| MEDIUM⚡ | headroom/evals/suite_runner.py | 60 | # Standard benchmarks via lm-eval harness (through Headroom proxy) | COMMENT |
| MEDIUM | headroom/evals/comprehensive_benchmark.py | 449 | """Run comprehensive benchmark suite. | STRING |
| MEDIUM | headroom/learn/verbosity.py | 273 | # Backfill has_tools (a session-level property of the harness). | COMMENT |
| MEDIUM | headroom/proxy/memory_query_policy.py | 67 | # Code's <system-reminder> harness blocks: they are appended to | COMMENT |
| MEDIUM | headroom/proxy/server.py | 5408 | """Get comprehensive proxy statistics. | STRING |
| MEDIUM | headroom/proxy/prometheus_metrics.py | 586 | # that names the harness when an agent is pointed at a persistent proxy | COMMENT |
| 37 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_integrations/langchain/test_streaming.py | 0 | tests for behavior when langchain is not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_memory.py | 0 | tests for behavior when langchain is not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_retriever.py | 0 | tests for behavior when langchain is not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_agents.py | 0 | tests for behavior when langchain is not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_streaming.py | 0 | _check_langchain_available raises importerror when not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_memory.py | 0 | _check_langchain_available raises importerror when not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_retriever.py | 0 | _check_langchain_available raises importerror when not available. | STRING |
| HIGH | tests/test_integrations/langchain/test_agents.py | 0 | _check_langchain_available raises importerror when not available. | STRING |
| HIGH | headroom/memory/system.py | 0 | retrieve a specific memory by id. args: memory_id: the memory identifier. returns: memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/backends/mem0_system_adapter.py | 0 | retrieve a specific memory by id. args: memory_id: the memory identifier. returns: memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/backends/direct_mem0.py | 0 | retrieve a specific memory by id. args: memory_id: the memory identifier. returns: memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/ports.py | 0 | get a memory by id. args: memory_id: the unique identifier of the memory. returns: the memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/adapters/sqlite.py | 0 | get a memory by id. args: memory_id: the unique identifier of the memory. returns: the memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/backends/local.py | 0 | get a memory by id. args: memory_id: the unique identifier of the memory. returns: the memory if found, none otherwise. | STRING |
| HIGH | headroom/memory/ports.py | 0 | get the full history chain for a memory. follows supersession links to return all versions of a memory. args: memory_id: | STRING |
| HIGH | headroom/memory/adapters/sqlite.py | 0 | get the full history chain for a memory. follows supersession links to return all versions of a memory. args: memory_id: | STRING |
| HIGH | headroom/memory/core.py | 0 | get the full history chain for a memory. follows supersession links to return all versions of a memory. args: memory_id: | STRING |
| HIGH | headroom/memory/ports.py | 0 | clear all memories at or below a scope level. args: user_id: required user scope. session_id: if provided, clear session | STRING |
| HIGH | headroom/memory/core.py | 0 | clear all memories at or below a scope level. args: user_id: required user scope. session_id: if provided, clear session | STRING |
| HIGH | headroom/memory/adapters/sqlite.py | 0 | clear all memories at or below a scope level. args: user_id: required user scope. session_id: if provided, clear session | STRING |
| HIGH | headroom/memory/ports.py | 0 | remove multiple memories from the text index (protocol-compliant). args: memory_ids: list of memory ids to remove. retur | STRING |
| HIGH | headroom/memory/adapters/hnsw.py | 0 | remove multiple memories from the text index (protocol-compliant). args: memory_ids: list of memory ids to remove. retur | STRING |
| HIGH | headroom/memory/adapters/fts5.py | 0 | remove multiple memories from the text index (protocol-compliant). args: memory_ids: list of memory ids to remove. retur | STRING |
| HIGH | headroom/memory/adapters/sqlite_vector.py | 0 | remove multiple memories from the text index (protocol-compliant). args: memory_ids: list of memory ids to remove. retur | STRING |
| HIGH | headroom/memory/ports.py | 0 | retrieve an entity by id. args: entity_id: the unique identifier of the entity. returns: the entity if found, none other | STRING |
| HIGH | headroom/memory/adapters/sqlite_graph.py | 0 | retrieve an entity by id. args: entity_id: the unique identifier of the entity. returns: the entity if found, none other | STRING |
| HIGH | headroom/memory/adapters/graph.py | 0 | retrieve an entity by id. args: entity_id: the unique identifier of the entity. returns: the entity if found, none other | STRING |
| HIGH | headroom/memory/ports.py | 0 | delete a single relationship. args: relationship_id: the unique identifier of the relationship. returns: true if the rel | STRING |
| HIGH | headroom/memory/adapters/sqlite_graph.py | 0 | delete a single relationship. args: relationship_id: the unique identifier of the relationship. returns: true if the rel | STRING |
| HIGH | headroom/memory/adapters/graph.py | 0 | delete a single relationship. args: relationship_id: the unique identifier of the relationship. returns: true if the rel | STRING |
| HIGH | headroom/memory/adapters/graph.py | 0 | get memory statistics for the memorytracker. returns: componentstats with current memory usage. | STRING |
| HIGH | headroom/memory/adapters/hnsw.py | 0 | get memory statistics for the memorytracker. returns: componentstats with current memory usage. | STRING |
| HIGH | headroom/proxy/request_logger.py | 0 | get memory statistics for the memorytracker. returns: componentstats with current memory usage. | STRING |
| HIGH | headroom/proxy/semantic_cache.py | 0 | get memory statistics for the memorytracker. returns: componentstats with current memory usage. | STRING |
| HIGH | headroom/cache/compression_store.py | 0 | get memory statistics for the memorytracker. returns: componentstats with current memory usage. | STRING |
| HIGH | headroom/cache/compression_feedback.py | 0 | fraction of retrievals that were full (not search). | STRING |
| HIGH | headroom/telemetry/toin.py | 0 | fraction of retrievals that were full (not search). | STRING |
| HIGH | headroom/telemetry/models.py | 0 | fraction of retrievals that were full (not search). | STRING |
| HIGH | headroom/providers/cursor/runtime.py | 0 | build the local proxy urls shown to antigravity users. ``project`` (the wrap launch directory) is encoded as a ``/p/<nam | STRING |
| HIGH | headroom/providers/grok_build/runtime.py | 0 | build the local proxy urls shown to antigravity users. ``project`` (the wrap launch directory) is encoded as a ``/p/<nam | STRING |
| HIGH | headroom/providers/antigravity/runtime.py | 0 | build the local proxy urls shown to antigravity users. ``project`` (the wrap launch directory) is encoded as a ``/p/<nam | STRING |
| HIGH | headroom/integrations/crewai/agents.py | 0 | initialize headroomtoolwrapper. args: tool: the autogen functiontool to wrap. min_chars_to_compress: minimum character c | STRING |
| HIGH | headroom/integrations/langchain/agents.py | 0 | initialize headroomtoolwrapper. args: tool: the autogen functiontool to wrap. min_chars_to_compress: minimum character c | STRING |
| HIGH | headroom/integrations/autogen/agents.py | 0 | initialize headroomtoolwrapper. args: tool: the autogen functiontool to wrap. min_chars_to_compress: minimum character c | STRING |
| HIGH | headroom/integrations/strands/hooks.py | 0 | reset all tracked metrics (thread-safe). clears the metrics history and resets the total tokens saved counter. useful fo | STRING |
| HIGH | headroom/integrations/strands/model.py | 0 | reset all tracked metrics (thread-safe). clears the metrics history and resets the total tokens saved counter. useful fo | STRING |
| HIGH | headroom/integrations/agno/model.py | 0 | reset all tracked metrics (thread-safe). clears the metrics history and resets the total tokens saved counter. useful fo | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_compression/test_evals.py | 116 | """Authentication middleware for FastAPI applications. This module provides JWT-based authentication with role-based ac | STRING |
| HIGH | headroom/onnx_runtime.py | 104 | Download a file from HuggingFace Hub, preferring the local cache. Tries ``local_files_only=True`` first to avoid a | STRING |
| HIGH | headroom/compress.py | 222 | Compress messages using Headroom's full compression pipeline. This is the simplest way to use Headroom. No proxy, n | STRING |
| HIGH | headroom/relevance/__init__.py | 76 | Factory function to create a relevance scorer. Args: tier: Scorer tier to create: - "hybrid": H | STRING |
| HIGH | headroom/tokenizers/registry.py | 174 | Get tokenizer for a model. Args: model: Model name (e.g., 'gpt-4o', 'claude-3-sonnet'). | STRING |
| HIGH | headroom/tokenizers/huggingface.py | 469 | Encode text to token IDs. Args: text: Text to encode. Returns: List of token I | STRING |
| HIGH | headroom/tokenizers/huggingface.py | 488 | Decode token IDs to text. Args: tokens: List of token IDs. Returns: Decoded te | STRING |
| HIGH | headroom/tokenizers/base.py | 459 | Encode text to token IDs. Optional method - not all backends support encoding. Default implementation r | STRING |
| HIGH | headroom/tokenizers/base.py | 476 | Decode token IDs to text. Optional method - not all backends support decoding. Default implementation r | STRING |
| HIGH | headroom/learn/analyzer.py | 594 | Strip optional markdown fences and parse JSON. Handles raw JSON and fenced code blocks (e.g. ```json ... ```), in | STRING |
| HIGH | headroom/learn/analyzer.py | 729 | Call a locally installed CLI tool as the LLM backend. Enables keyless usage for subscription-based CLI tools that h | STRING |
| HIGH | headroom/memory/system.py | 99 | Update an existing memory with new content. Creates a new version while preserving history (supersession). | STRING |
| HIGH | headroom/memory/core.py | 536 | Supersede an existing memory with a new version. Creates a temporal chain where the old memory's validity ends | STRING |
| HIGH | headroom/memory/factory.py | 69 | Create a complete memory system from configuration. This factory function creates and initializes all memory system | STRING |
| HIGH | headroom/memory/factory.py | 117 | Create a memory store backend. Args: config: Memory system configuration. Returns: A MemorySto | STRING |
| HIGH | headroom/memory/factory.py | 145 | Create or return a cached embedder backend. The embedder is shared across every ``LocalBackend`` instance that | STRING |
| HIGH | headroom/memory/factory.py | 231 | Create a vector index backend. Args: config: Memory system configuration. Returns: A VectorInd | STRING |
| HIGH | headroom/memory/factory.py | 324 | Create a text index backend. Args: config: Memory system configuration. Returns: A TextIndex i | STRING |
| HIGH | headroom/memory/backends/local.py | 557 | Update a memory with new content (creates versioned history). Uses HierarchicalMemory.supersede() to create a n | STRING |
| HIGH | headroom/memory/backends/mem0_system_adapter.py | 255 | Update an existing memory with new content. Creates a new version while preserving history (supersession). | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 677 | Call OpenAI API with retry logic for transient failures. Args: texts: List of texts to embed. | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 721 | Generate an embedding for a single text. Args: text: The text to embed. Returns: | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 740 | Generate embeddings for multiple texts. Automatically handles batching for large inputs. Args: | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 899 | Call Ollama API with retry logic for a single text. Args: text: Text to embed. Returns: | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 954 | Generate an embedding for a single text. Args: text: The text to embed. Returns: | STRING |
| HIGH | headroom/memory/adapters/embedders.py | 973 | Generate embeddings for multiple texts. Ollama API doesn't support batch embedding natively, so we make | STRING |
| HIGH | headroom/memory/adapters/sqlite.py | 661 | Supersede an existing memory with a new version. This creates a temporal chain: the old memory's valid_until is | STRING |
| HIGH | headroom/memory/adapters/hnsw.py | 583 | Search for similar memories using vector similarity. Args: filter: Vector search filter with query | STRING |
| HIGH | headroom/proxy/server.py | 1575 | Run a synchronous compression callable on the bounded executor with cancel-aware metrics. Replaces ``as | STRING |
| HIGH | headroom/cache/registry.py | 83 | Get a cache optimizer for a provider. Args: provider: Provider name (e.g., "anthropic", "o | STRING |
| HIGH | headroom/providers/base.py | 54 | Get a token counter for a specific model. Args: model: The model name. Returns: | STRING |
| HIGH | headroom/providers/base.py | 70 | Get the context window limit for a model. Args: model: The model name. Returns: | STRING |
| HIGH | headroom/backends/base.py | 125 | Send an OpenAI-format message request. Unlike send_message(), this takes OpenAI-format input and returns | STRING |
| HIGH | headroom/backends/base.py | 148 | Stream an OpenAI-format chat completion. Yields SSE-formatted strings: 'data: {...}\\n\\n' for each chunk, | STRING |
| HIGH | headroom/cli/_utils/parsers.py | 10 | Parse a duration string into a timedelta. Supported formats: - "7d" - 7 days - "2w" - 2 weeks | STRING |
| HIGH | headroom/storage/sqlite.py | 145 | Query metrics with filters. Matches are ordered by timestamp descending, then request_id descending (th | STRING |
| HIGH | headroom/storage/jsonl.py | 105 | Query metrics with filters. Matches are ordered by timestamp descending, then request_id descending (th | STRING |
| HIGH | headroom/transforms/spreadsheet_ingest.py | 139 | Load a spreadsheet file into ``{sheet_name: csv_text}``. Args: path: Path to a ``.xlsx`` or ``.xls`` file. | STRING |
| HIGH | headroom/transforms/code_compressor.py | 217 | Get a tree-sitter parser for the given language. Returns a **thread-local** ``tree_sitter.Parser`` instance. t | STRING |
| HIGH | headroom/transforms/compressor_registry.py | 168 | Register ``compressor`` under its ``descriptor.name``. Args: compressor: The compressor to register | STRING |
| HIGH | headroom/transforms/kompress_compressor.py | 2111 | Compress multiple texts. Uses batched inference on GPU, sequential on CPU. On GPU (PyTorch + CUDA / MPS), runs | STRING |
| HIGH | headroom/compression/masks.py | 88 | Combine masks - preserve if EITHER mask says preserve. Useful when combining multiple structure detection strat | STRING |
| HIGH | headroom/compression/masks.py | 111 | Combine masks - preserve only if BOTH masks say preserve. Useful for being more aggressive with compression. | STRING |
| HIGH | headroom/pricing/registry.py | 106 | Estimate the cost for a given token usage. Args: model: The model name/identifier. inpu | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | CHANGELOG.md | 19 | - **cache/prefix-freeze:** resolve `PrefixCacheTracker`s per conversation lineage within a session id, so concurrent con | CODE |
| MEDIUM | CHANGELOG.md | 19 | - **cache/prefix-freeze:** resolve `PrefixCacheTracker`s per conversation lineage within a session id, so concurrent con | CODE |
| MEDIUM | CHANGELOG.md | 152 | * **wrap/doctor:** make the Claude Remote Control gate warning accurate and stop it firing for users who never had the f | COMMENT |
| MEDIUM | crates/headroom-core/src/ccr/mod.rs | 63 | /// (`CCRConfig.store_ttl_seconds`). Session-scale: agentic sessions | COMMENT |
| MEDIUM | …adroom-proxy/src/cache_stabilization/drift_detector.rs | 67 | //! under a millisecond on a typical agentic request; the detector | COMMENT |
| MEDIUM | …adroom-proxy/src/cache_stabilization/drift_detector.rs | 559 | /// *measured* axes, and agentic clients legitimately mutate them | COMMENT |
| MEDIUM | …/headroom-proxy/src/cache_stabilization/beta_sticky.rs | 63 | //! the `(model, system)` bucket conflating parallel agentic | COMMENT |
| MEDIUM | REALIGNMENT/04-phase-B-live-zone.md | 88 | - **MessageScorer Rust port retirement:** PR #338 and #343 (April 2026) ported MessageScorer to Rust. That work becomes | CODE |
| MEDIUM | REALIGNMENT/12-decisions-needed.md | 35 | The PR #338 / #343 port (April 2026) was investment in the wrong abstraction (per Agent G's audit: scoring's only consum | CODE |
| MEDIUM⚡ | tests/test_proxy_warmup.py | 102 | # Startup orchestration tests — use HeadroomProxy + stubbed transforms | COMMENT |
| MEDIUM | tests/test_anthropic_compaction_transforms.py | 55 | # Two blocks, mirroring how agentic clients actually shape the system array: | COMMENT |
| MEDIUM | tests/test_openai_codex_ws_lifecycle.py | 1177 | # out is a cancel from the handler's orchestration. | COMMENT |
| MEDIUM | tests/test_memory_handler_native_ops.py | 714 | # handles its own context window. See ``MemoryQuery``. | COMMENT |
| MEDIUM⚡ | tests/test_relevance_split.py | 259 | # the embedding model on the request thread (the swap happens later, in the | COMMENT |
| MEDIUM⚡ | tests/test_proxy/test_model_router.py | 41 | # Inverse of require_no_tools: route agentic (tool-using) turns to a | COMMENT |
| MEDIUM⚡ | tests/test_proxy/test_context_guard.py | 154 | # not a context window must not clamp the budget for the process. | COMMENT |
| MEDIUM⚡ | tests/test_memory/test_traffic_learner.py | 2580 | # Malformed input — we'd rather drop than persist scaffolding. | COMMENT |
| MEDIUM⚡ | tests/test_cli/test_wrap_helpers.py | 978 | # _resolve_1m_model — 1M context window suffix logic (#1158). | COMMENT |
| MEDIUM | wiki/langchain.md | 412 | ### Example 2: RAG Pipeline with Document Filtering | COMMENT |
| MEDIUM⚡ | examples/vertex_gemini_benchmark/scenarios.py | 335 | # 4. Multi-Turn RAG & System Architecture Synthesis | COMMENT |
| MEDIUM⚡ | benchmarks/agent_cost_benchmark.py | 390 | # SCENARIO 3: RAG Context Scaling | COMMENT |
| MEDIUM | benchmarks/agent_cost_benchmark.py | 404 | # Generate RAG conversation with ~50K tokens of context | COMMENT |
| MEDIUM⚡ | benchmarks/bench_latency.py | 114 | content_type: str # json, code, text, logs, agentic, rag | CODE |
| MEDIUM | benchmarks/bench_latency.py | 589 | # Set a model_limit large enough to exercise compression on big agentic contexts | COMMENT |
| MEDIUM | benchmarks/bench_latency.py | 601 | # --- RAG conversations --- | COMMENT |
| MEDIUM | benchmarks/bench_latency.py | 864 | # --- Per-Transform Breakdown (for agentic/rag scenarios) --- | COMMENT |
| MEDIUM | .github/workflows/ci.yml | 7 | # prefetch-model — download the embedding model ONCE (authenticated), warm shared cache | COMMENT |
| MEDIUM | headroom/config.py | 877 | # Session-scale TTL. The original 5-minute default predates agentic | COMMENT |
| MEDIUM | headroom/__init__.py | 200 | # Shared context for multi-agent workflows | COMMENT |
| MEDIUM | headroom/parser.py | 40 | # Patterns for RAG detection (best effort) | COMMENT |
| MEDIUM | headroom/parser.py | 265 | # Check if this looks like RAG content | COMMENT |
| MEDIUM⚡ | headroom/evals/datasets.py | 83 | # RAG / RETRIEVAL DATASETS | COMMENT |
| MEDIUM⚡ | headroom/evals/datasets.py | 1186 | # RAG/Retrieval | COMMENT |
| MEDIUM | headroom/evals/README.md | 176 | ### RAG / Retrieval | COMMENT |
| MEDIUM | headroom/evals/__main__.py | 389 | python -m headroom.evals benchmark --dataset rag # Run all RAG datasets | CODE |
| MEDIUM | headroom/learn/models.py | 166 | # guards against a detected repeated pattern. Loop guardrails are ranked | COMMENT |
| MEDIUM | headroom/learn/analyzer.py | 271 | # Weight loop guardrails above one-off rules using MEASURED waste. | COMMENT |
| MEDIUM⚡ | headroom/memory/traffic_learner.py | 1047 | # implementation matched scaffolding ("don't mention this | COMMENT |
| MEDIUM | headroom/memory/traffic_learner.py | 71 | # Agent harnesses can encode orchestration metadata as user-role messages. | COMMENT |
| MEDIUM | headroom/proxy/server.py | 1102 | # code/RAG context — see issue #454). | COMMENT |
| MEDIUM | headroom/proxy/server.py | 4192 | # remain the unauthenticated probes for orchestration health. | COMMENT |
| MEDIUM | headroom/proxy/request_logger.py | 105 | # a long agentic session grew one proxy to 100 GB RSS. Light fields stay | COMMENT |
| MEDIUM | headroom/proxy/models.py | 287 | # of input lives in user messages (pasted code/text, RAG context) and the | COMMENT |
| MEDIUM | headroom/proxy/context_guard.py | 71 | # not a context window: gateways return the same "prompt is too long: N > M" | COMMENT |
| MEDIUM | headroom/proxy/context_guard.py | 214 | # Not a context window. Learning it would clamp the budget on a number | COMMENT |
| MEDIUM⚡ | headroom/proxy/helpers.py | 3494 | # local context window — tens of K tokens. That decision is made client-side | COMMENT |
| MEDIUM⚡ | headroom/proxy/helpers.py | 3644 | # Anthropic then excludes deferred tools from the context window (they stop | COMMENT |
| MEDIUM | headroom/proxy/handlers/anthropic.py | 3221 | # them from the context window — they stop counting as input tokens until | COMMENT |
| MEDIUM | headroom/proxy/handlers/streaming.py | 970 | # where the agentic traffic is, so without this the split — and the one | COMMENT |
| MEDIUM | headroom/providers/openai.py | 79 | # OpenAI context window limits | COMMENT |
| MEDIUM | headroom/providers/anthropic.py | 129 | # Claude Sonnet 4.6 - 1M context window | COMMENT |
| MEDIUM | headroom/providers/claude/runtime.py | 13 | # every one into its context window) when ANTHROPIC_BASE_URL is a custom host | COMMENT |
| MEDIUM | headroom/providers/claude/runtime.py | 54 | # family as #746 (on-demand tool loading) and #1158 (1M context window), both of | COMMENT |
| MEDIUM | headroom/providers/claude/install.py | 20 | # its context window (GH #746) — breaking sub-agents and forcing compaction. | COMMENT |
| MEDIUM | headroom/cli/init.py | 213 | # all into its context window — overflowing it (breaks sub-agent spawns, | COMMENT |
| MEDIUM | headroom/cli/wrap.py | 337 | # inflates the local context window by tens of K tokens. Setting the env var | COMMENT |
| MEDIUM | headroom/cli/wrap.py | 356 | # 1M context window for `wrap claude` (#1158). Claude Code only sends the | COMMENT |
| MEDIUM | headroom/cli/wrap.py | 6308 | # Issue #1158: opt-in 1M context window. Claude Code only sends the | COMMENT |
| MEDIUM | headroom/cli/wrap.py | 5983 | headroom wrap claude --1m # Preserve the 1M context window | STRING |
| MEDIUM | headroom/transforms/content_router.py | 2039 | # embedding model is pre-warmed in the background (BM25 scores until it's | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_memory_system.py | 26 | # Check if hnswlib is available for LocalBackend tests | COMMENT |
| LOW | tests/test_proxy_memory_integration.py | 221 | # Check if response indicates tool was used | COMMENT |
| LOW | tests/test_proxy_memory_integration.py | 281 | # Check if response mentions the saved info | COMMENT |
| LOW⚡ | tests/test_memory_integration.py | 264 | # Check if memory tool was called | COMMENT |
| LOW⚡ | tests/test_memory_integration.py | 271 | # Check if auto-handled | COMMENT |
| LOW | tests/test_memory_integration.py | 310 | # Check if memory tool was called with pre-extraction | COMMENT |
| LOW | tests/test_memory_integration.py | 558 | # Check if search was invoked | COMMENT |
| LOW | tests/test_critical_gaps.py | 830 | # Set _last_save_time to past so elapsed > interval | COMMENT |
| LOW | tests/test_proxy_ccr.py | 445 | # Check if compression was actually performed (not skipped) | COMMENT |
| LOW | tests/test_hnsw_only.py | 16 | # Check if hnswlib is available (use lazy check to avoid SIGILL on incompatible CPUs) | COMMENT |
| LOW | tests/test_sqlite_vector_index.py | 22 | # Check if sqlite-vec is available | COMMENT |
| LOW | tests/test_google_multimodal_e2e.py | 145 | # Check if model made a function call | COMMENT |
| LOW | tests/test_cache/test_anthropic.py | 70 | # Check if cache_control was inserted | COMMENT |
| LOW | tests/test_evals/test_html_oss_benchmarks.py | 70 | # Print results | COMMENT |
| LOW⚡ | tests/test_integrations/langchain/test_chat_model.py | 1067 | # Check if Ollama server is running on default port | COMMENT |
| LOW | tests/test_integrations/langchain/test_chat_model.py | 18 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_extended.py | 15 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_streaming.py | 16 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_langgraph.py | 15 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_memory.py | 15 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_retriever.py | 15 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/langchain/test_agents.py | 16 | # Check if LangChain is available | COMMENT |
| LOW | tests/test_integrations/agno/test_model.py | 15 | # Check if Agno is available | COMMENT |
| LOW | tests/test_integrations/agno/test_model.py | 1038 | # Check if Ollama server is running on default port | COMMENT |
| LOW | tests/test_integrations/agno/test_hooks.py | 14 | # Check if Agno is available | COMMENT |
| LOW⚡ | tests/test_memory/test_factory.py | 29 | # Check if hnswlib is available (most factory tests require it) | COMMENT |
| LOW⚡ | tests/test_memory/test_hierarchical.py | 659 | # Check if hnswlib is available (use lazy check to avoid SIGILL on incompatible CPUs) | COMMENT |
| LOW | tests/test_memory/test_easy.py | 29 | # Check if hnswlib is available (local backend requires it) | COMMENT |
| LOW | tests/test_memory/test_core_operations.py | 36 | # Check if hnswlib is available (HierarchicalMemory requires it) | COMMENT |
| LOW | tests/test_cli/test_mcp.py | 18 | # Check if MCP SDK is available | COMMENT |
| LOW | tests/integrations/test_strands/test_model.py | 23 | # Check if strands-agents is installed | COMMENT |
| LOW | tests/integrations/test_strands/test_model_unit.py | 16 | # Check if strands-agents is installed for proper skip handling | COMMENT |
| LOW | tests/integrations/test_strands/test_hooks.py | 23 | # Check if strands-agents is installed | COMMENT |
| LOW | tests/integrations/test_strands/test_hooks_unit.py | 18 | # Check if strands-agents is installed for proper skip handling | COMMENT |
| LOW | examples/strands_bedrock_demo.py | 646 | # Display results | COMMENT |
| LOW | examples/strands_bedrock_demo.py | 816 | # Display results | COMMENT |
| LOW | examples/langchain_demo/run_comparison.py | 195 | # Check if done | COMMENT |
| LOW | examples/langchain_demo/run_comparison.py | 296 | # Check if done | COMMENT |
| LOW⚡ | examples/deployment/macos-launchagent/uninstall.sh | 67 | # Check if we're on macOS | COMMENT |
| LOW⚡ | examples/deployment/macos-launchagent/uninstall.sh | 74 | # Check if LaunchAgent is installed | COMMENT |
| LOW⚡ | examples/deployment/macos-launchagent/uninstall.sh | 81 | # Check if service is running and stop it | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 75 | # Check if we're on macOS | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 81 | # Check if headroom is installed | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 96 | # Check if service is already installed | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 100 | # Check if service is running | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 130 | # Check if port is in use | COMMENT |
| LOW | examples/deployment/macos-launchagent/install.sh | 189 | # Check if port is listening | COMMENT |
| LOW | …ples/deployment/macos-launchagent/shell-integration.sh | 32 | # Check if proxy is running (fast path using lsof) | COMMENT |
| LOW | …ples/deployment/macos-launchagent/shell-integration.sh | 41 | # Check if LaunchAgent is installed | COMMENT |
| LOW⚡ | benchmarks/adversarial_ccr_tests.py | 658 | # Check if error items with unicode were preserved | COMMENT |
| LOW⚡ | benchmarks/adversarial_ccr_tests.py | 1505 | # Check if we kept the TARGET item | COMMENT |
| LOW⚡ | benchmarks/adversarial_ccr_tests.py | 1614 | # Check if null-byte items were preserved (they have status=error) | COMMENT |
| LOW | benchmarks/adversarial_ccr_tests.py | 332 | # Check if anomaly was preserved | COMMENT |
| LOW | benchmarks/adversarial_ccr_tests.py | 618 | # Check if our compression worked despite fake markers | COMMENT |
| LOW | benchmarks/adversarial_ccr_tests.py | 1001 | # Check if the nested error was preserved | COMMENT |
| LOW | benchmarks/adversarial_ccr_tests.py | 1121 | # Check if future timestamp was preserved | COMMENT |
| LOW | benchmarks/compression_benchmark.py | 537 | # Check if most key terms appear in answer | COMMENT |
| LOW | benchmarks/run_benchmarks.py | 260 | # Write file | COMMENT |
| LOW | benchmarks/ccr_regression_benchmark.py | 150 | # Check if ALL errors were retained | COMMENT |
| LOW | benchmarks/ccr_regression_benchmark.py | 225 | # Check if target UUID was found | COMMENT |
| 53 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | crates/headroom-core/config/pipeline.toml | 3 | # This file is embedded into the headroom-core binary via `include_str!` | COMMENT |
| MEDIUM | tests/test_security_validations.py | 109 | # Create a memory with safe metadata | COMMENT |
| MEDIUM⚡ | tests/test_memory_system.py | 642 | # Create a simple graph: e1 -> e2 -> e3 | COMMENT |
| MEDIUM⚡ | tests/test_memory_system.py | 802 | # Create a chain longer than max_depth | COMMENT |
| MEDIUM | tests/test_memory_system.py | 665 | # Create a chain: e1 -> e2 -> e3 -> e4 | COMMENT |
| MEDIUM | tests/test_memory_system.py | 1688 | # Create a graph structure | COMMENT |
| MEDIUM⚡ | tests/test_cli_memory_index_sync.py | 347 | # Create a non-empty vector DB file so the code doesn't short-circuit. | COMMENT |
| MEDIUM⚡ | tests/test_image_compression.py | 256 | # Create a simple test image | COMMENT |
| MEDIUM⚡ | tests/test_image_compressor.py | 61 | # Create a simple 100x100 red image | COMMENT |
| MEDIUM | tests/test_image_compressor.py | 74 | # Create a 1024x1024 image with some pattern | COMMENT |
| MEDIUM | tests/test_critical_fixes.py | 110 | # Create a signature using the correct factory method | COMMENT |
| MEDIUM | tests/test_critical_gaps.py | 69 | # Create a pattern | COMMENT |
| MEDIUM | tests/test_toin_feedback.py | 249 | # Create a minimal proxy to test the method | COMMENT |
| MEDIUM | tests/test_proxy_batch_integration.py | 77 | # Create a list of items that will be compressible | COMMENT |
| MEDIUM⚡ | tests/test_backend_bugs.py | 715 | # Create an async iterator for the mock streaming response | COMMENT |
| MEDIUM | tests/test_acceptance.py | 16 | # Create a shared provider for tests | COMMENT |
| MEDIUM | tests/repro_unsendable_panic.py | 41 | # Create the parser on the main thread | COMMENT |
| MEDIUM | tests/test_memory_tracker_integration.py | 414 | # Create a component that reports large size | COMMENT |
| MEDIUM | tests/test_memory_sync.py | 233 | # Create an existing MEMORY.md | COMMENT |
| MEDIUM | tests/test_ccr_sqlite_backend.py | 110 | # Create the target with a deliberately wider mode via umask (not an | COMMENT |
| MEDIUM⚡ | tests/test_adapter_hooks.py | 213 | # Create a new TOIN instance with same backend — should load patterns | COMMENT |
| MEDIUM | tests/test_cli_update.py | 332 | # Create a fake .pyd file | COMMENT |
| MEDIUM | tests/test_proxy_streaming_resilience.py | 247 | # Create a realistic HTTP 429 error | COMMENT |
| MEDIUM | tests/test_proxy_compress_endpoint.py | 216 | # Create a large repetitive tool output that should be compressible | COMMENT |
| MEDIUM | tests/test_cache/test_client_integration.py | 294 | # Create a spy optimizer to track calls | COMMENT |
| MEDIUM | tests/test_cache/test_client_integration.py | 618 | # Create a conversation that will trigger some optimization | COMMENT |
| MEDIUM | tests/test_integrations/langchain/test_chat_model.py | 1259 | # Create a conversation with repetitive content that should be compressed | COMMENT |
| MEDIUM⚡ | tests/test_integrations/agno/test_model.py | 883 | # Create a real OpenAIChat model (doesn't need API key for instantiation) | COMMENT |
| MEDIUM | tests/test_integrations/agno/test_model.py | 71 | # Create a proper ModelResponse that Agno's response() can process | COMMENT |
| MEDIUM | tests/test_memory/test_hierarchical.py | 344 | # Create a chain: v1 -> v2 -> v3 | COMMENT |
| MEDIUM | tests/test_memory/test_hierarchical.py | 594 | # Create a supersession chain | COMMENT |
| MEDIUM | tests/test_transforms/test_diff_compressor.py | 124 | # Create a diff with many hunks | COMMENT |
| MEDIUM | e2e/_lib/make_shim.sh | 2 | # Create a noop executable shim at $2/$1 suitable for use in PATH during | COMMENT |
| MEDIUM | headroom/evals/batch_compression_eval.py | 738 | # Create a long document | COMMENT |
| MEDIUM | headroom/evals/runners/compression_only.py | 382 | # Create a document with specific facts embedded | COMMENT |
| MEDIUM | headroom/memory/backends/direct_mem0.py | 600 | # Create the background task | STRING |
| MEDIUM | headroom/memory/adapters/fts5.py | 419 | # Create a minimal Memory object from FTS data | COMMENT |
| MEDIUM | headroom/proxy/memory_handler.py | 244 | # Create the directory owner-only (and narrow it if an earlier run left | COMMENT |
| MEDIUM | headroom/cache/compression_store.py | 925 | # Create a synthetic "success" event that we'll process later | COMMENT |
| MEDIUM | headroom/backends/anyllm.py | 53 | # Create the AnyLLM instance once and reuse. api_key/api_base are only | COMMENT |
| MEDIUM | headroom/integrations/asgi.py | 166 | # Create a new receive that returns the (possibly modified) body | COMMENT |
| MEDIUM | headroom/integrations/strands/hooks.py | 10 | # Create the hook provider | STRING |
| MEDIUM | headroom/transforms/content_router.py | 1434 | # Create a deterministic structure hash based on content type | COMMENT |
| MEDIUM | headroom/transforms/content_router.py | 2801 | # Create a content-type signature | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | tests/test_proxy_savings_history.py | 1432 | client.app.state.proxy.metrics.savings_tracker.flush() | CODE |
| CRITICAL | tests/test_openai_chat_turn_hooks.py | 207 | logs = client.app.state.proxy.logger.get_recent(10) | CODE |
| CRITICAL | tests/test_openai_chat_turn_hooks.py | 307 | logs = client.app.state.proxy.logger.get_recent(5) | CODE |
| CRITICAL | tests/test_compression/test_evals.py | 357 | at com.example.app.client.InventoryClient.updateStock(InventoryClient.java:87) | STRING |
| CRITICAL | tests/test_compression/test_evals.py | 358 | at com.example.app.service.InventoryService.decrementStock(InventoryService.java:156) | STRING |
| CRITICAL | tests/gateway/test_contract_response_half.py | 307 | tracker = headroom_client.app.state.proxy.session_tracker_store.peek( | CODE |
| CRITICAL | benchmarks/headroom_worst_case_benchmark.py | 290 | at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:897) | CODE |
| CRITICAL⚡ | benchmarks/comprehensive_eval.py | 141 | at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:82) | CODE |
| CRITICAL⚡ | benchmarks/comprehensive_eval.py | 142 | at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:376) | CODE |
| CRITICAL⚡ | benchmarks/comprehensive_eval.py | 145 | at org.apache.commons.dbcp2.BasicDataSource.getConnection(BasicDataSource.java:1421) | CODE |
| CRITICAL | headroom/memory/wrapper.py | 243 | response = self._wrapper._client.chat.completions.create(**kwargs) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | crates/headroom-core/tests/ccr_backends.rs | 136 | // Step 1: same payload yields byte-equal keys. | COMMENT |
| LOW⚡ | crates/headroom-core/tests/ccr_backends.rs | 139 | // Step 2: store in sqlite, mirror to in-memory under the same | COMMENT |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 464 | # Step 1: Count tokens with large content | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 470 | # Step 2: Make countTokens request | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 479 | # Step 3: Verify stats updated | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 483 | # Step 4: Verify tokens saved is tracked (may be negative for small overhead) | STRING |
| LOW⚡ | tests/test_proxy_batch_integration.py | 151 | # Step 1: Create JSONL content with compressible messages | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 170 | # Step 2: Upload the JSONL file directly to OpenAI | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 184 | # Step 3: Create batch through proxy with compression | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 222 | # Step 4: Cancel the batch to avoid costs | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 600 | # Step 2: Retrieve through proxy endpoint (by hash → full content) | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 610 | # Step 3: Verify TOIN learned | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 622 | # Step 4: Verify field semantics were learned | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 629 | # Step 5: PR-B5 retired the request-time recommendation API in favor of | COMMENT |
| LOW | wiki/ARCHITECTURE.md | 312 | ### Step 1: You call the API | COMMENT |
| LOW | wiki/ARCHITECTURE.md | 327 | ### Step 2: HeadroomClient intercepts | COMMENT |
| LOW | wiki/ARCHITECTURE.md | 339 | ### Step 3: Transform Pipeline runs | COMMENT |
| LOW | wiki/ARCHITECTURE.md | 370 | ### Step 4: Call real API | COMMENT |
| LOW | wiki/ARCHITECTURE.md | 379 | ### Step 5: Log metrics and return | COMMENT |
| LOW⚡ | wiki/quickstart.md | 60 | ### Step 1: Start the Proxy | COMMENT |
| LOW⚡ | wiki/quickstart.md | 66 | ### Step 2: Verify It's Running | COMMENT |
| LOW⚡ | wiki/quickstart.md | 73 | ### Step 3: Point Your Client | COMMENT |
| LOW | wiki/quickstart.md | 90 | ### Step 4: Check Savings | COMMENT |
| LOW | wiki/macos-deployment.md | 117 | ### Step 1: Create Log Directory | COMMENT |
| LOW | wiki/macos-deployment.md | 123 | ### Step 2: Generate LaunchAgent Plist | COMMENT |
| LOW | wiki/macos-deployment.md | 150 | ### Step 3: Load the LaunchAgent | COMMENT |
| LOW | wiki/macos-deployment.md | 156 | ### Step 4: Verify Service | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 642 | # Step 1: Compress | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 647 | # Step 2: Cache | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 656 | # Step 3: Record compression in feedback | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 659 | # Step 4: Retrieve and search | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 663 | # Step 5: Process feedback | COMMENT |
| LOW⚡ | benchmarks/scenarios/conversations.py | 502 | ### Step 1: Setup | COMMENT |
| LOW⚡ | benchmarks/scenarios/conversations.py | 508 | ### Step 2: Implementation | COMMENT |
| LOW | benchmarks/scenarios/conversations.py | 523 | ### Step 3: Testing | COMMENT |
| LOW⚡ | headroom/proxy/handlers/batch.py | 957 | # Step 3: Create compressed JSONL content | COMMENT |
| LOW⚡ | headroom/proxy/handlers/batch.py | 960 | # Step 4: Upload compressed file to OpenAI | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 923 | # Step 1: Download the input file from OpenAI | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 939 | # Step 2: Parse and compress each line | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 978 | # Step 5: Create batch with compressed file | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 135 | # Step 1: Analyze content sections | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 138 | # Step 2: Stabilize prefix | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 144 | # Step 3: Plan breakpoint placement | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 148 | # Step 4: Insert cache_control blocks | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 153 | # Step 5: Compute metrics | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 318 | # Step 1: Classify query with trained model | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 321 | # Step 2: Analyze image with SigLIP (if enabled) | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 327 | # Step 3: Combine signals for final decision | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 60 | # Step 1: scale so max dimension ≤ 2048 | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 67 | # Step 2: scale so shortest side ≤ 768 | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 74 | # Step 3: count 512×512 tiles | COMMENT |
| LOW⚡ | headroom/image/compressor.py | 723 | # Step 2: ML-based technique routing | COMMENT |
| LOW⚡ | headroom/image/compressor.py | 771 | # Step 3: Apply compression technique | COMMENT |
| LOW | headroom/image/compressor.py | 708 | # Step 1: Tile-boundary optimization (always safe, pure math) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1626 | # Step 1: Serialize under lock (fast in-memory operation) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1630 | # Step 2: Write outside lock (slow I/O operation) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1634 | # Step 3: Update state under lock (fast) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | crates/headroom-core/tests/ccr_backends.rs | 136 | // Step 1: same payload yields byte-equal keys. | COMMENT |
| LOW⚡ | crates/headroom-core/tests/ccr_backends.rs | 139 | // Step 2: store in sqlite, mirror to in-memory under the same | COMMENT |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 464 | # Step 1: Count tokens with large content | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 470 | # Step 2: Make countTokens request | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 479 | # Step 3: Verify stats updated | STRING |
| LOW⚡ | tests/test_proxy_count_tokens_integration.py | 483 | # Step 4: Verify tokens saved is tracked (may be negative for small overhead) | STRING |
| LOW⚡ | tests/test_proxy_batch_integration.py | 151 | # Step 1: Create JSONL content with compressible messages | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 170 | # Step 2: Upload the JSONL file directly to OpenAI | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 184 | # Step 3: Create batch through proxy with compression | COMMENT |
| LOW | tests/test_proxy_batch_integration.py | 222 | # Step 4: Cancel the batch to avoid costs | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 600 | # Step 2: Retrieve through proxy endpoint (by hash → full content) | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 610 | # Step 3: Verify TOIN learned | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 622 | # Step 4: Verify field semantics were learned | COMMENT |
| LOW⚡ | tests/test_proxy_ccr.py | 629 | # Step 5: PR-B5 retired the request-time recommendation API in favor of | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 642 | # Step 1: Compress | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 647 | # Step 2: Cache | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 656 | # Step 3: Record compression in feedback | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 659 | # Step 4: Retrieve and search | COMMENT |
| LOW⚡ | benchmarks/ccr_regression_benchmark.py | 663 | # Step 5: Process feedback | COMMENT |
| LOW⚡ | benchmarks/scenarios/conversations.py | 502 | ### Step 1: Setup | COMMENT |
| LOW⚡ | benchmarks/scenarios/conversations.py | 508 | ### Step 2: Implementation | COMMENT |
| LOW | benchmarks/scenarios/conversations.py | 523 | ### Step 3: Testing | COMMENT |
| LOW⚡ | headroom/proxy/handlers/batch.py | 957 | # Step 3: Create compressed JSONL content | COMMENT |
| LOW⚡ | headroom/proxy/handlers/batch.py | 960 | # Step 4: Upload compressed file to OpenAI | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 923 | # Step 1: Download the input file from OpenAI | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 939 | # Step 2: Parse and compress each line | COMMENT |
| LOW | headroom/proxy/handlers/batch.py | 978 | # Step 5: Create batch with compressed file | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 135 | # Step 1: Analyze content sections | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 138 | # Step 2: Stabilize prefix | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 144 | # Step 3: Plan breakpoint placement | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 148 | # Step 4: Insert cache_control blocks | COMMENT |
| LOW⚡ | headroom/cache/anthropic.py | 153 | # Step 5: Compute metrics | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 318 | # Step 1: Classify query with trained model | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 321 | # Step 2: Analyze image with SigLIP (if enabled) | COMMENT |
| LOW⚡ | headroom/image/trained_router.py | 327 | # Step 3: Combine signals for final decision | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 60 | # Step 1: scale so max dimension ≤ 2048 | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 67 | # Step 2: scale so shortest side ≤ 768 | COMMENT |
| LOW⚡ | headroom/image/tile_optimizer.py | 74 | # Step 3: count 512×512 tiles | COMMENT |
| LOW⚡ | headroom/image/compressor.py | 723 | # Step 2: ML-based technique routing | COMMENT |
| LOW⚡ | headroom/image/compressor.py | 771 | # Step 3: Apply compression technique | COMMENT |
| LOW | headroom/image/compressor.py | 708 | # Step 1: Tile-boundary optimization (always safe, pure math) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1626 | # Step 1: Serialize under lock (fast in-memory operation) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1630 | # Step 2: Write outside lock (slow I/O operation) | COMMENT |
| LOW⚡ | headroom/telemetry/toin.py | 1634 | # Step 3: Update state under lock (fast) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_transforms/test_html_extractor.py | 466 | <pre><code>Authorization: Bearer YOUR_API_KEY</code></pre> | CODE |
| HIGH | wiki/typescript-sdk.md | 61 | apiKey: 'your-api-key', // optional, for authenticated endpoints | CODE |
| HIGH | wiki/typescript-sdk.md | 94 | apiKey: 'your-api-key', | CODE |
| HIGH | wiki/configuration.md | 503 | export HEADROOM_API_KEY=your-api-key | CODE |
| HIGH | wiki/configuration.md | 515 | apiKey: 'your-api-key', | CODE |
| HIGH | wiki/proxy.md | 377 | api_key="your-api-key", # Still needed for upstream | CODE |
| HIGH | sdk/typescript/README.md | 371 | apiKey: 'your-api-key', // optional, for authenticated endpoints | CODE |
| HIGH | benchmarks/scenarios/conversations.py | 542 | Authorization: Bearer <your-api-key> | CODE |
| HIGH | headroom/evals/html_extraction.py | 561 | <pre><code>Authorization: Bearer YOUR_API_KEY</code></pre> | CODE |
| HIGH | headroom/providers/google.py | 14 | genai.configure(api_key="your-api-key") | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | crates/headroom-core/tests/live_zone_ccr.rs | 27 | "notes": "lorem ipsum dolor sit amet, consectetur adipiscing elit", | CODE |
| LOW | crates/headroom-core/tests/live_zone_ccr.rs | 27 | "notes": "lorem ipsum dolor sit amet, consectetur adipiscing elit", | CODE |
| LOW | …/headroom-core/src/transforms/smart_crusher/anchors.rs | 295 | assert!(anchors.contains("user@example.com")); | CODE |
| LOW | …-proxy/tests/integration_e3_anthropic_cache_control.rs | 84 | .header("x-api-key", "sk-ant-api01-fake-key") | CODE |
| LOW | …-proxy/tests/integration_e3_anthropic_cache_control.rs | 174 | .header("x-api-key", "sk-ant-api01-fake-key") | CODE |
| LOW | …-proxy/tests/integration_e3_anthropic_cache_control.rs | 278 | .header("x-api-key", "sk-ant-api01-fake-key") | CODE |
| LOW | …-proxy/tests/integration_e3_anthropic_cache_control.rs | 374 | .header("x-api-key", "sk-ant-api01-fake-key") | CODE |
| LOW⚡ | tests/test_memory_system.py | 1424 | entities=["Alice", "Acme Corp"], | CODE |
| LOW⚡ | tests/test_memory_system.py | 1428 | assert "Acme Corp" in memory.entity_refs | CODE |
| LOW⚡ | tests/test_memory_system.py | 1433 | acme_entity = await graph.get_entity_by_name("alice", "Acme Corp") | CODE |
| LOW⚡ | tests/test_memory_system.py | 1445 | entities=["Alice", "Acme Corp"], | CODE |
| LOW⚡ | tests/test_memory_system.py | 1446 | relationships=[{"source": "Alice", "target": "Acme Corp", "type": "works_at"}], | CODE |
| LOW⚡ | tests/test_cli_memory_index_sync.py | 349 | vector_db.write_bytes(b"placeholder") | CODE |
| LOW⚡ | tests/test_cli_memory_index_sync.py | 383 | vector_db.write_bytes(b"placeholder") | CODE |
| LOW⚡ | tests/test_memory_integration.py | 412 | entities=["Alice", "Acme Corp"], | CODE |
| LOW⚡ | tests/test_memory_integration.py | 415 | {"entity": "Acme Corp", "entity_type": "organization"}, | CODE |
| LOW⚡ | tests/test_memory_integration.py | 421 | "destination": "Acme Corp", | CODE |
| LOW⚡ | tests/test_memory_integration.py | 430 | entities=["Acme Corp", "San Francisco"], | CODE |
| LOW⚡ | tests/test_memory_integration.py | 432 | {"entity": "Acme Corp", "entity_type": "organization"}, | CODE |
| LOW | tests/test_gemini_prefix_freeze.py | 59 | return f"{tag} " + "lorem ipsum dolor sit amet " * 40 | CODE |
| LOW | tests/test_gemini_prefix_freeze.py | 59 | return f"{tag} " + "lorem ipsum dolor sit amet " * 40 | CODE |
| LOW | tests/test_quality_retention.py | 325 | "snippet": "Lorem ipsum " * 20, | CODE |
| LOW⚡ | tests/test_backend_bugs.py | 876 | "x-api-key": "sk-ant-dummy-key", | CODE |
| LOW⚡ | tests/test_backend_bugs.py | 877 | "authorization": "Bearer sk-ant-dummy-key", | CODE |
| LOW | tests/parity/recorder.py | 599 | "Lorem ipsum dolor sit amet, consectetur adipiscing elit.", | STRING |
| LOW | tests/parity/recorder.py | 599 | "Lorem ipsum dolor sit amet, consectetur adipiscing elit.", | STRING |
| LOW | tests/test_cli/test_mcp_reconcile.py | 23 | "oauthAccount": {"email": "user@example.com"}, | CODE |
| LOW | tests/test_cli/test_mcp_reconcile.py | 79 | assert data["oauthAccount"] == {"email": "user@example.com"} | CODE |
| LOW | tests/test_transforms/test_html_extractor.py | 218 | <meta name="author" content="John Doe"> | CODE |
| LOW⚡ | tests/test_providers/test_openai.py | 44 | large = "lorem ipsum dolor sit amet consectetur adipiscing elit " * 8 # > 256 chars | CODE |
| LOW⚡ | tests/test_providers/test_openai.py | 44 | large = "lorem ipsum dolor sit amet consectetur adipiscing elit " * 8 # > 256 chars | CODE |
| LOW | tests/test_compression/test_llm_eval.py | 201 | email="admin@example.com", | CODE |
| LOW | wiki/langchain.md | 555 | ("placeholder", "{agent_scratchpad}"), | CODE |
| LOW | examples/mcp_demo/run_agent_eval.py | 180 | "email": "test@test.com", | CODE |
| LOW | examples/mcp_demo/mock_mcp_servers.py | 179 | "body": "Lorem ipsum dolor sit amet..." if random.random() > 0.5 else "", | CODE |
| LOW | examples/mcp_demo/mock_mcp_servers.py | 179 | "body": "Lorem ipsum dolor sit amet..." if random.random() > 0.5 else "", | CODE |
| LOW⚡ | scripts/replay_codex_ws_load.py | 126 | "Lorem ipsum dolor sit amet, consectetur adipiscing elit. " | CODE |
| LOW⚡ | scripts/replay_codex_ws_load.py | 126 | "Lorem ipsum dolor sit amet, consectetur adipiscing elit. " | CODE |
| LOW | scripts/replay_codex_ws_load.py | 154 | # plain_text_like / unknown / jsonl_like → lorem ipsum is fine as a | COMMENT |
| LOW | headroom/evals/datasets.py | 1119 | "name": "Acme Corp", | CODE |
| LOW | headroom/memory/tools.py | 326 | Example: [{"source": "user", "relationship": "works_at", "destination": "Acme Corp"}] | CODE |
| LOW | headroom/memory/backends/local.py | 98 | entities=["Alice", "Acme Corp"], | STRING |
| LOW | headroom/memory/backends/local.py | 99 | relationships=[{"source": "Alice", "target": "Acme Corp", "type": "works_at"}], | STRING |
| LOW | headroom/dashboard/static/tailwind.min.js | 27 | `),v=y.length-1,v>0?(k=a+v,S=w-y[v].length):(k=a,S=s),T=D.comment,a=k,p=k,d=w-S):c===D.slash?(w=o,T=c,p=a,d=o-s,l=w+1):( | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | plugins/headroom-oauth2/src/headroom_oauth2/provider.py | 42 | CODE | |
| LOW | tests/test_memory_system.py | 898 | CODE | |
| LOW | tests/test_proxy_compression_executor.py | 135 | CODE | |
| LOW | tests/test_router_external_dispatch.py | 110 | CODE | |
| LOW | tests/gateway/fake_gateway.py | 178 | CODE | |
| LOW | headroom/savings_ledger.py | 257 | CODE | |
| LOW | headroom/pipeline.py | 241 | CODE | |
| LOW | headroom/memory/core.py | 131 | CODE | |
| LOW | headroom/memory/easy.py | 109 | CODE | |
| LOW | headroom/memory/backends/direct_mem0.py | 544 | CODE | |
| LOW | headroom/memory/backends/local.py | 231 | CODE | |
| LOW | headroom/memory/adapters/embedders.py | 156 | CODE | |
| LOW | headroom/memory/adapters/hnsw.py | 227 | CODE | |
| LOW | headroom/proxy/savings_tracker.py | 488 | CODE | |
| LOW | headroom/proxy/savings_tracker.py | 1059 | CODE | |
| LOW | headroom/proxy/server.py | 2516 | CODE | |
| LOW | headroom/proxy/prometheus_metrics.py | 837 | CODE | |
| LOW | headroom/proxy/outcome.py | 306 | CODE | |
| LOW | headroom/proxy/persistent_metrics.py | 389 | CODE | |
| LOW | headroom/proxy/cost.py | 1021 | CODE | |
| LOW | headroom/proxy/helpers.py | 164 | CODE | |
| LOW | headroom/proxy/handlers/streaming.py | 760 | CODE | |
| LOW | headroom/proxy/handlers/streaming.py | 1018 | CODE | |
| LOW | headroom/cache/semantic.py | 426 | CODE | |
| LOW | headroom/cache/compression_store.py | 287 | CODE | |
| LOW | headroom/cli/install.py | 567 | CODE | |
| LOW | headroom/cli/wrap.py | 698 | CODE | |
| LOW | headroom/cli/wrap.py | 4720 | CODE | |
| LOW | headroom/cli/wrap.py | 5438 | CODE | |
| LOW | headroom/observability/metrics.py | 445 | CODE | |
| LOW | headroom/testing/harness.py | 744 | CODE | |
| LOW | headroom/testing/harness.py | 880 | CODE | |
| LOW | headroom/testing/harness.py | 1020 | CODE | |
| LOW | headroom/testing/harness.py | 1216 | CODE | |
| LOW | headroom/transforms/smart_crusher.py | 280 | CODE | |
| LOW | headroom/transforms/kompress_compressor.py | 1754 | CODE | |
| LOW | headroom/transforms/kompress_compressor.py | 2098 | CODE | |
| LOW | headroom/transforms/content_router.py | 7178 | CODE | |
| LOW | headroom/telemetry/collector.py | 101 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | tests/test_search_compressor.py | 64 | src/main.py:42:def process_data(items): | CODE |
| LOW⚡ | tests/test_search_compressor.py | 289 | content = """src/main.py:10:def process_data(): | CODE |
| LOW | tests/test_search_compressor.py | 50 | content = """src/main.py:42:def process_data(items): | CODE |
| LOW | tests/test_search_compressor.py | 89 | C:\\Users\\dev\\src\\utils.py:20:def helper(): | CODE |
| LOW⚡ | tests/test_ccr_rust_marker_hash_bridge.py | 65 | original = "src/app.py:12: def handle_request(payload):\n" * 40 | CODE |
| LOW⚡ | tests/test_transforms_content_detection.py | 279 | "src/main.py:42:def process_data(items):", | CODE |
| LOW | tests/test_mixed_content_sections.py | 64 | "src/main.py:42:def process_data(items):", | CODE |
| LOW | tests/test_mixed_content_sections.py | 84 | assert "src/main.py:42:def process_data(items):" in sections[1].content | CODE |
| LOW | tests/test_compression_summary.py | 23 | ("function handleRequest(req, res) {", " res.send('ok');", 5), | CODE |
| LOW⚡ | tests/test_text_compressors.py | 36 | content = """src/main.py:42:def process_data(items): | CODE |
| LOW | tests/test_text_compressors.py | 90 | def process_data(items: list[dict]) -> dict[str, Any]: | CODE |
| LOW | tests/parity/recorder.py | 1052 | "export function processData(items) {\n" | CODE |
| LOW | tests/test_transforms/test_content_router.py | 97 | lines.append(f"src/module{i}.py:42: def process_data(input: str) -> str:") | CODE |
| LOW | headroom/evals/batch_compression_eval.py | 717 | function processData(items) { | CODE |
| LOW | headroom/transforms/code_compressor.py | 1013 | ... def process_data(items: List[str]) -> List[str]: | STRING |
| LOW | headroom/transforms/code_compressor.py | 1029 | def process_data(items: List[str]) -> List[str]: | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_request_body_decompression_limits.py | 111 | CODE | |
| MEDIUM | tests/test_route_advice.py | 189 | CODE | |
| MEDIUM | tests/test_route_advice.py | 194 | CODE | |
| MEDIUM | tests/test_litellm_transport_errors.py | 159 | CODE | |
| MEDIUM | tests/test_bedrock_region.py | 612 | CODE | |
| MEDIUM | tests/test_integrations/langchain/test_streaming.py | 618 | CODE | |
| MEDIUM | headroom/backends/base.py | 165 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | sdk/typescript/test/parity.test.ts | 73 | print(json.dumps({ | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | .serena/project.yml | 30 | # Same syntax as gitignore, so you can use * and **. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_proxy_count_tokens_integration.py | 300 | # Example usage | COMMENT |
| LOW | …ples/deployment/macos-launchagent/shell-integration.sh | 8 | # Usage: | COMMENT |