LeanCTX is the Context Gateway for AI Systems. Select task-relevant context, apply supported controls, connect local knowledge and inspect recorded evidence. Open-source Engine: CLI, MCP, hooks and supported proxy paths.
This report summarizes scanner evidence for yvgude/lean-ctx, a Rust project with 3,917 GitHub stars. SynthScan examined 1,226,748 lines of code across 3559 source files, recording 3209 pattern matches distributed across 21 syntactic categories. The legacy adjusted pattern signal is 3.7 (Low 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.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.
Can maintainers explain intent, assumptions, and trade-offs? 2555 finding(s).
Are imports declared and package/API names verified? 109 finding(s).
Are wrappers, guards, and repeated structures necessary? 1161 finding(s).
Which changes need focused human review? 3209 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 3209 distinct pattern matches across 21 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 | install.sh | 1 | #!/bin/sh | COMMENT |
| LOW | install.sh | 21 | # downloaded, has no entry for the archive, no sha256sum/shasum tool exists, or | COMMENT |
| LOW | PUBLISH_MANIFEST.toml | 1 | # Positive selection of the public Community tree (scripts/public-export.py). | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/types.rs | 1 | //! Wire types for the lean-ctx `/v1` contract. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/types.rs | 61 | /// Serialized tool arguments. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/types.rs | 101 | /// Page size requested. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/types.rs | 121 | /// Monotonic event id within the workspace/channel stream. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/ocla.rs | 21 | pub const MAX_OCLA_WIRE_BYTES: usize = 64 * 1024; | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/ocla.rs | 41 | /// Supported version. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/ocla.rs | 81 | #[derive(Clone, Copy, Debug, Eq, PartialEq, Serialize, Deserialize)] | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/client.rs | 321 | /// # Errors | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/error.rs | 1 | //! Error types for the lean-ctx client. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/lib.rs | 1 | //! # lean-ctx-client | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/lib.rs | 21 | //! // Call any tool over the boundary and read its text. | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/lib.rs | 41 | //! `GET /v1/events/lineage`, `GET /v1/metrics` | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/lib.rs | 61 | //! | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/conformance.rs | 1 | //! Shared SDK conformance kit (EPIC 12.5, industrialized in GL #395). | COMMENT |
| LOW | clients/rust/lean-ctx-client/src/tool_text.rs | 1 | //! Flatten an MCP tool result into plain text. | COMMENT |
| LOW | rust/Cargo.toml | 281 | # Upstream WebSocket client for the Codex ChatGPT remote-control passthrough | COMMENT |
| LOW | rust/proptest-regressions/core/science_props.txt | 1 | # Seeds for failure cases proptest has generated in the past. It is | COMMENT |
| LOW | rust/.config/nextest.toml | 1 | experimental = ["setup-scripts"] | COMMENT |
| LOW | rust/.config/nextest-tmpdir.sh | 1 | #!/usr/bin/env bash | COMMENT |
| LOW | rust/crates/lean-ctx-ocla/src/types.rs | 601 | /// [INTERNAL] Maximum number of samples before stopping. | COMMENT |
| LOW | rust/crates/lean-ctx-ocla/src/types.rs | 701 | /// [PII] Agent identifier. | COMMENT |
| LOW | rust/crates/lean-ctx-ocla/src/types.rs | 721 | pub struct DeliveryEntry { | COMMENT |
| LOW | rust/crates/lean-ctx-ocla/src/types.rs | 761 | /// [INTERNAL] Stub-delivery count. | COMMENT |
| LOW | rust/crates/lean-ctx-embed/tests/engine_read.rs | 1 | //! Acceptance tests for the embedding [`Engine`] — exercises the real tool | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/error.rs | 1 | //! The SDK's own error type. | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/error.rs | 21 | /// The engine could not be constructed (e.g. the project root does not | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/lib.rs | 1 | //! # lean-ctx-embed — in-process embedding façade (Track A) | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/lib.rs | 21 | //! assert!(again.saved_tokens >= first.saved_tokens); | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/read.rs | 1 | //! Read-mode selection — the SDK's stable mirror of the engine's `ctx_read` | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/compress.rs | 1 | //! Shell/tool output compression — the same pattern engine the proxy and | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/engine.rs | 1 | //! The embedding [`Engine`] — a safe, ergonomic handle over the lean-ctx | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/engine.rs | 21 | //! [`EngineBuilder::build`] is read-mostly and scoped: | COMMENT |
| LOW | rust/crates/lean-ctx-embed/src/engine.rs | 261 | COMMENT | |
| LOW | rust/crates/lean-ctx-protocol/tests/k2_review_schema.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/context_checkpoint.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | …t/crates/lean-ctx-protocol/src/engine_presented_use.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/context_lineage.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/knowledge_routing.rs | 1 | //! Frozen compatibility contracts for historical knowledge routing. | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/auto_routing.rs | 1 | //! Public `model=auto` wire contracts. | COMMENT |
| LOW | …rates/lean-ctx-protocol/src/context_policy_evidence.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | …rates/lean-ctx-protocol/src/context_policy_evidence.rs | 181 | pub observed_day: u64, | COMMENT |
| LOW | …rates/lean-ctx-protocol/src/context_policy_evidence.rs | 301 | COMMENT | |
| LOW | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 901 | pub delivered: u64, | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 961 | /// withheld and why, what reached which destination under which policy. | COMMENT |
| LOW | …-ctx-protocol/src/engine_context_materialization_v2.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | …st/crates/lean-ctx-protocol/src/org_policy_verifier.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | …es/lean-ctx-protocol/src/context_checkpoint_unicode.rs | 261 | /// Decisions taken, sorted by decision identity. | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/sealed.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/sealed.rs | 41 | /// key, HKDF-SHA256 (salt = ephemeral_pub || recipient_pub, info = | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/telemetry.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/policy.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/policy.rs | 21 | //! own key, and only this list binds them to the organization's signature. | COMMENT |
| LOW | …/crates/lean-ctx-protocol/src/hive/effective_policy.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| LOW | …/crates/lean-ctx-protocol/src/hive/effective_policy.rs | 21 | //! distributed and shown only. The ack's `unenforced` reports what is | COMMENT |
| LOW | …/crates/lean-ctx-protocol/src/hive/effective_policy.rs | 221 | #[serde(flatten)] | COMMENT |
| LOW | rust/crates/lean-ctx-protocol/src/hive/graph.rs | 1 | // SPDX-License-Identifier: Apache-2.0 | COMMENT |
| 1650 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | rust/crates/lean-ctx-protocol/tests/k2_review_schema.rs | 34 | // ── a minimal JSON-schema member walker ────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/tests/k2_review_schema.rs | 291 | // ── content shapes ─────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 149 | // ─── Classification ───────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 224 | // ─── Principal and destination ────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 256 | // ─── Reason codes, coverage, signals ──────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 314 | // ─── Decisions ────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 342 | // ─── Passport derivation ──────────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 430 | // ─── Receipt ──────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | …/crates/lean-ctx-protocol/src/context_gateway_tests.rs | 681 | // ─── Context quality section ──────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 38 | // ─── Classification ───────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 147 | // ─── Principal and destination ────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 279 | // ─── Reason codes and policy references ───────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 325 | // ─── Detector signals ─────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 492 | // ─── Decisions and transformations ────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 583 | // ─── Passport ─────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 732 | // ─── Context quality section ──────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/context_gateway.rs | 868 | // ─── Receipt ──────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/hive/metrics_v2.rs | 411 | // ── closed-pattern strings ─────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/hive/metrics_v2.rs | 713 | // ── closed enums ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/hive/metrics_v2.rs | 831 | // ── wire structs ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/crates/lean-ctx-protocol/src/hive/metrics_v2.rs | 1090 | // ── checks ─────────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | rust/tests/ticket_fixes_scenarios.rs | 737 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | rust/tests/ticket_fixes_scenarios.rs | 739 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | rust/tests/ticket_fixes_scenarios.rs | 748 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM⚡ | rust/tests/ticket_fixes_scenarios.rs | 750 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 17 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 21 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 129 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 131 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 150 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 154 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 222 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 225 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 247 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 251 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 319 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 323 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 389 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 394 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 462 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 466 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 497 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 502 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 538 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 542 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 565 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 567 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 584 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 588 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 643 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 645 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 685 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/ticket_fixes_scenarios.rs | 687 | // ────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/outcome_pricing_e2e.rs | 78 | // ── 1 + 2. Real compression → measured savings → signed hash chain ──────── | COMMENT |
| MEDIUM | rust/tests/outcome_pricing_e2e.rs | 107 | // ── 3. Signed batch + OFFLINE verification + tamper check ───────────────── | COMMENT |
| MEDIUM | rust/tests/outcome_pricing_e2e.rs | 132 | // ── 5. FOCUS FinOps export — savings as a Credit row ────────────────────── | COMMENT |
| MEDIUM | rust/tests/outcome_pricing_e2e.rs | 148 | // ── teardown ────────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | rust/tests/power_user_worksession.rs | 98 | // ── Phase 1: Setup & Orientation ─────────────────────────── | COMMENT |
| MEDIUM | rust/tests/power_user_worksession.rs | 157 | // ── Phase 2: Codebase Research (Read Modes) ──────────────── | COMMENT |
| MEDIUM | rust/tests/power_user_worksession.rs | 352 | // ── Phase 3: Code Search ─────────────────────────────────── | COMMENT |
| 437 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_license_policy.py | 20 | def test_cli_uses_the_canonical_classification_result(self): | CODE |
| LOW⚡ | tests/test_license_policy.py | 32 | def test_canonical_matrix_option_is_retained(self): | CODE |
| LOW⚡ | tests/test_license_policy.py | 36 | def test_external_matrix_cannot_replace_the_grant_authority(self): | CODE |
| LOW⚡ | tests/test_license_policy.py | 44 | def test_missing_repository_fails_without_traceback(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 60 | def test_valid_manifest_and_artifacts_verify(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 65 | def test_manifest_schema_validation_rejects_unknown_field(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 71 | def test_artifact_digest_mismatch_fails(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 77 | def test_payload_digest_mismatch_fails(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 85 | def test_outer_symlink_artifact_fails_closed(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 93 | def test_source_suffix_masquerade_requires_payload_digest(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 101 | def test_checksum_parser_handles_gnu_format_and_rejects_paths(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 111 | def test_sbom_parser_accepts_cyclonedx_and_rejects_empty_components(self): | CODE |
| LOW⚡ | tests/security/test_verify_release_integrity.py | 117 | def test_download_uses_http_and_fetches_checksum_listed_artifacts(self): | CODE |
| LOW | tests/security/test_verify_release_integrity.py | 137 | def test_download_replaces_symlink_without_writing_its_target(self): | CODE |
| LOW | …s/security/test_ci_protocol_surface_freeze_workflow.py | 10 | def test_gate_is_mandatory_in_delivery_security_job(self): | CODE |
| LOW | tests/security/test_private_paths.py | 28 | def test_current_repository_passes(self): | STRING |
| LOW | tests/security/test_private_paths.py | 31 | def test_a_tracked_denied_file_fails_even_if_it_predates_the_rule(self): | STRING |
| LOW⚡ | tests/security/test_private_paths.py | 42 | def test_an_internal_gitignore_entry_missing_from_the_deny_list_fails(self): | STRING |
| LOW⚡ | tests/security/test_private_paths.py | 52 | def test_other_sections_and_lookalike_paths_are_not_flagged(self): | STRING |
| LOW⚡ | tests/security/test_private_paths.py | 60 | def test_paid_detection_content_in_a_public_path_fails(self): | STRING |
| LOW⚡ | tests/security/test_open_core_boundary.py | 55 | def test_fixture_tree_passes_and_approved_local_import_is_not_private(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 60 | def test_missing_manifest_fails_closed(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 66 | def test_malformed_manifest_fails_closed(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 71 | def test_manifest_metadata_drift_fails_closed(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 77 | def test_manifest_rejects_invalid_module_digest(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 83 | def test_public_module_root_drift_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 89 | def test_root_reexport_drift_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 96 | def test_new_export_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 102 | def test_existing_public_wire_shape_drift_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 135 | def test_same_crate_root_symbol_import_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 142 | def test_same_crate_module_symbol_import_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 149 | def test_fully_qualified_root_symbol_reference_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 156 | def test_external_fully_qualified_root_symbol_reference_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 163 | def test_external_root_symbol_import_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 170 | def test_relevant_glob_imports_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 252 | def test_unicode_alias_consumer_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 262 | def test_alias_chain_consumer_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 272 | def test_parent_module_and_glob_consumers_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 295 | def test_rooted_alias_glob_consumer_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 304 | def test_unicode_intermediate_and_grouped_paths_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 314 | def test_combining_mark_alias_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 336 | def test_crate_alias_root_symbol_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 345 | def test_super_glob_bare_root_symbol_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 354 | def test_visible_super_glob_variants_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 402 | def test_unicode_xid_alias_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 412 | def test_grouped_raw_root_symbol_after_sibling_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 419 | def test_macro_surface_metavariable_is_resolved_at_its_invocation(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 427 | def test_uninvoked_and_unrelated_macros_are_not_consumers(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 467 | def test_extern_self_alias_in_protocol_crate_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 474 | def test_self_and_super_root_symbol_references_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 482 | def test_nested_surface_import_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 489 | def test_nested_grouped_and_spaced_surface_paths_are_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 497 | def test_raw_identifier_surface_reference_is_rejected(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 504 | def test_comments_and_literals_are_not_consumers(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 514 | def test_unrelated_surface_names_and_unused_crate_alias_are_not_consumers(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 529 | def test_identifier_suffixes_do_not_match_private_namespaces(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 539 | def test_private_and_protocol_prefixes_are_not_namespace_matches(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 549 | def test_combining_mark_suffixes_preserve_identifier_boundaries(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 701 | def test_source_entry_bound_fails_closed(self): | CODE |
| LOW⚡ | tests/security/test_open_core_boundary.py | 710 | def test_oversized_source_fails_closed(self): | CODE |
| 554 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | llms.txt | 22 | - [Where LeanCTX fits](https://github.com/yvgude/lean-ctx/blob/main/docs/where-leanctx-fits.md): RAG, vector stores, mod | CODE |
| MEDIUM | rust/src/core/jsonc.rs | 12 | /// "config is corrupt" and scaffold a fresh one over the user's file (#1586). | COMMENT |
| MEDIUM | rust/src/core/shell_allowlist/self_config.rs | 2 | //! Agent shells must not loosen lean-ctx's own guardrails. | COMMENT |
| MEDIUM | rust/src/core/input_filters/mod.rs | 5 | //! - [`pii`] — email, phone and payment cards (checksum guardrails against | COMMENT |
| MEDIUM | rust/src/core/input_filters/pii.rs | 1 | //! PII detection with checksum guardrails (GL #675). | COMMENT |
| MEDIUM | rust/src/core/extractive/tests.rs | 147 | /// `#[ignore]`d (needs the embedding model + is slow); reproduce with: | COMMENT |
| MEDIUM | rust/src/core/extractive/tests.rs | 152 | #[ignore = "benchmark; needs the embedding model; run with --ignored --nocapture"] | COMMENT |
| MEDIUM | rust/src/proxy/compress_tests.rs | 491 | /// shape, the CCR agentic loop silently stops firing — this test fails | COMMENT |
| MEDIUM | rust/src/proxy/compress.rs | 174 | /// remote gateway whose agentic loop scans for `hash=<24hex>` (#702). | COMMENT |
| MEDIUM | rust/src/proxy/compress_api.rs | 9 | //! guardrail resolves through `GET /v1/retrieve/{hash}` — the CCR agentic loop | COMMENT |
| MEDIUM | rust/src/proxy/compress_api.rs | 438 | /// guardrail's CCR agentic loop. | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 18 | //! The leading scaffold (`source`/`shopt`/`setopt`) and any `< /dev/null` are | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 41 | //! requires `eval` AND host scaffold markers (`setopt NO_EXTENDED_GLOB` / | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 130 | // Requires BOTH host scaffold markers AND trailing bare pwd. | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 131 | // A model-chosen `eval 'x' && pwd` without scaffold stays blocked. | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 490 | /// True when the command prefix (before any `eval`) contains agent-host scaffold | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 720 | /// `source <snapshot> … && shopt … &&` scaffold must be scanned past so the | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 721 | /// inner command is still found and the scaffold dropped. | COMMENT |
| MEDIUM | rust/src/shell/agent_wrapper.rs | 782 | /// SECURITY: `eval 'payload' && pwd` without host scaffold must NOT unwrap. | COMMENT |
| MEDIUM | rust/src/shell/exec/execution.rs | 357 | // #595: when the agent wraps its command in host scaffolding | COMMENT |
| MEDIUM | rust/src/cli/embeddings_cmd.rs | 42 | /// #1887: whether the selected embedding model is on disk, and where. | COMMENT |
| MEDIUM | rust/src/cli/dispatch/network/provider.rs | 112 | /// Writes the scaffold for `args` and returns its path. | COMMENT |
| MEDIUM | rust/src/cli/dispatch/network/provider.rs | 163 | /// `provider init <id>` — scaffold a config-provider TOML in the project-local | COMMENT |
| MEDIUM | rust/src/dashboard/routes/system.rs | 53 | // Protection area (GL #487): the OWASP agentic-risk alignment that | COMMENT |
| MEDIUM | rust/src/dashboard/routes/system.rs | 53 | // Protection area (GL #487): the OWASP agentic-risk alignment that | COMMENT |
| MEDIUM | rust/src/hooks/agents/opencode.rs | 7 | /// never replaced with a fresh lean-ctx-only scaffold. Starting from an empty | COMMENT |
| MEDIUM | rust/src/hooks/agents/opencode.rs | 168 | // is left alone, never overwritten with a fresh scaffold. | COMMENT |
| MEDIUM | rust/src/hooks/agents/opencode.rs | 799 | // rejection used to be read as "corrupt, scaffold a fresh one". | COMMENT |
| MEDIUM | cookbook/sdk/README.md | 57 | ## Historical conformance scaffolding | COMMENT |
| MEDIUM | docs/user-journeys.md | 28 | ### Act I — Govern & scale the context window | COMMENT |
| MEDIUM | docs/user-journeys.md | 133 | ## Journey 2 — "One `grep` blew up my context window" → Context Firewall | COMMENT |
| MEDIUM | docs/architecture/ADR-v4-via-resolution.md | 409 | ### VIA as a second orchestration or control plane | COMMENT |
| MEDIUM | docs/reference/10-customization-and-governance.md | 174 | lean-ctx filter init # scaffold a filter config | CODE |
| MEDIUM | docs/reference/05-advanced.md | 643 | lean-ctx plugin init # scaffold a new plugin | CODE |
| MEDIUM | integrations/hermes-lean-ctx/config.py | 21 | # Sensible default context window when the host has not called update_model(). | COMMENT |
| MEDIUM | integrations/hermes-lean-ctx/config.py | 75 | # Fraction of the context window at which compaction fires. | COMMENT |
| MEDIUM | .github/workflows/ci.yml | 30 | # CI must be hermetic: never let tests download the embedding model | COMMENT |
| MEDIUM | .github/workflows/ci.yml | 845 | # Raised 3000→3100 after wave of multi-agent merges pushed fixed cost to ~3008. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 58 | // Step 1: Consolidate | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 78 | // Step 2: Apply to session cache | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 90 | // Step 3: Verify cache contains provider data | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 100 | // Step 4: Cross-source hints for the referenced file | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 117 | // Step 5: Format hints (as ctx_read would append them) | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 267 | // Step 1: Provider query produces chunks and consolidates them | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 295 | // Step 2: Apply edges (these would be in the graph index) | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 300 | // Step 3: Simulate ctx_read — check cross-source hints for referenced files | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 331 | // Step 4: Verify format output matches what ctx_read appends | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 336 | // Step 5: Verify cache hit (session cache stores the provider results) | COMMENT |
| LOW | rust/src/core/context_compiler.rs | 315 | // Step 4: DEDUP — drop items whose CONTENT is >70% redundant with an | COMMENT |
| LOW | rust/src/core/context_compiler.rs | 349 | // Step 5: ORDER — Lost-in-the-Middle (LiTM) reorder. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 101 | // Step 3: Fidelity Check (structural only, no LLM) | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 162 | /// Step 1: Promote recent session decisions/findings into project knowledge. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 223 | /// Step 2: Remove edges whose endpoints no longer exist in the knowledge store. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 239 | /// Step 4: Connect related facts that share vocabulary but lack an explicit edge. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 279 | /// Step 5: Resolve contradictions — same category+key, different values. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 317 | /// Step 6: Strengthen edges between facts co-retrieved in the same session window. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 354 | /// Step 7: Decay confidence on stale facts, and decay edge counts for unseen edges. | COMMENT |
| LOW | rust/src/core/embeddings/mod.rs | 890 | /// NOTE: This function BLOCKS on first call while loading the ONNX model. | COMMENT |
| LOW | rust/src/core/hive/auth.rs | 52 | /// Step 1: ask Hive for a device code; `label` is the user's `--label`, if | COMMENT |
| LOW | rust/src/core/hive/auth.rs | 108 | /// Step 2: poll until the user approved (or the code expired), then verify | COMMENT |
| LOW | rust/src/cli/hive_connect_cmd.rs | 571 | /// Step 3: name the vault of the project at `root`. Never fails the | COMMENT |
| LOW | docs/guides/claude-code.md | 42 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/claude-code.md | 74 | ### Step 2: Agent Instructions (CLAUDE.md block + skill) | COMMENT |
| LOW | docs/guides/claude-code.md | 122 | ### Step 3: Shell Hook | COMMENT |
| LOW | docs/guides/claude-code.md | 149 | ### Step 4: SKILL.md (Optional) | COMMENT |
| LOW | docs/guides/windsurf.md | 49 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/windsurf.md | 65 | ### Step 2: Agent Rules | COMMENT |
| LOW | docs/guides/windsurf.md | 102 | ### Step 3: Shell Hook | COMMENT |
| LOW | docs/guides/cursor.md | 36 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/cursor.md | 54 | ### Step 2: Agent Rules (MDC Format) | COMMENT |
| LOW | docs/guides/cursor.md | 83 | ### Step 3: Shell Hook | COMMENT |
| LOW | docs/guides/cursor.md | 91 | ### Step 4: SKILL.md | COMMENT |
| LOW | docs/guides/codex-cli.md | 83 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/codex-cli.md | 97 | ### Step 2: Agent Rules | COMMENT |
| LOW | docs/guides/codex-cli.md | 135 | ### Step 3: Shell Hook | COMMENT |
| LOW⚡ | docs/guides/codex-cli.md | 323 | # Step 1: Analyze | COMMENT |
| LOW⚡ | docs/guides/codex-cli.md | 327 | # Step 2: Plan | COMMENT |
| LOW⚡ | docs/guides/codex-cli.md | 331 | # Step 3: Execute — Codex applies the rename with its own edit tools | COMMENT |
| LOW | docs/guides/aider.md | 129 | ### Step 1: Understand the Codebase | COMMENT |
| LOW⚡ | docs/guides/aider.md | 145 | ### Step 2: Analyze Impact | COMMENT |
| LOW⚡ | docs/guides/aider.md | 155 | ### Step 3: Add Files to Aider | COMMENT |
| LOW⚡ | docs/guides/aider.md | 163 | ### Step 4: Make Changes | COMMENT |
| LOW⚡ | docs/guides/aider.md | 167 | ### Step 5: Document | COMMENT |
| LOW | docs/guides/gemini-cli.md | 35 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/gemini-cli.md | 54 | ### Step 2: Rules (GEMINI.md) | COMMENT |
| LOW | docs/guides/gemini-cli.md | 90 | ### Step 3: Shell Hook | COMMENT |
| LOW | docs/guides/opencode.md | 35 | ### Step 1: MCP Server Registration | COMMENT |
| LOW | docs/guides/opencode.md | 62 | ### Step 2: Rules (AGENTS.md) | COMMENT |
| LOW | docs/guides/opencode.md | 103 | ### Step 3: Shell Hook | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | rust/tests/suite/security_hardening.rs | 5 | /// so that the security-invariant checks below stay robust to internal module | COMMENT |
| MEDIUM | rust/tests/suite/hn_hardening_scenarios.rs | 10 | /// so that the invariant checks below stay robust to internal module structure. | COMMENT |
| MEDIUM | rust/tests/suite/hn_hardening_scenarios.rs | 28 | /// brace) so structural assertions stay robust to where the guard lives and to | COMMENT |
| MEDIUM | rust/tests/suite/lock_contention_hardening.rs | 289 | // instead of a fixed sleep so the test stays robust on slow/loaded CI | COMMENT |
| MEDIUM | rust/tests/suite/setup_symlink_596.rs | 128 | // Fake `codex` binary so detection is robust regardless of host PATH. | COMMENT |
| MEDIUM | rust/src/tools/ctx_shell.rs | 532 | // Preserve #989's escape hatch for harness-provided scratch paths. | COMMENT |
| MEDIUM | rust/src/tools/ctx_callgraph.rs | 187 | // widely-called AND cognitively complex is the highest-leverage refactor. | COMMENT |
| MEDIUM | rust/src/core/path_resolve.rs | 349 | // it. Asserts only the Ok case (robust against parallel env mutation): with | COMMENT |
| MEDIUM | rust/src/core/handle.rs | 18 | //! robust than a brittle line-only reference. | COMMENT |
| MEDIUM | rust/src/core/tabular_crush.rs | 17 | //! The compact form is serialized with `serde_json` (robust quoting, escapes and | COMMENT |
| MEDIUM | rust/src/core/ort_execution_providers.rs | 98 | /// scale batch size: small mini-batches under-utilize a GPU and pay | COMMENT |
| MEDIUM | rust/src/core/pgvector_store.rs | 11 | //! one JSON object per line (`json_build_object(...)::text`), which is robust | COMMENT |
| MEDIUM | rust/src/core/tool_profiles.rs | 287 | /// formatting, and unrelated keys (robust against substring/comment matches). | COMMENT |
| MEDIUM | rust/src/core/graph_provider.rs | 472 | /// its current [`SymbolInfo`], robust to line drift. Resolution order: | COMMENT |
| MEDIUM | rust/src/core/graph_provider.rs | 483 | /// `@Lline` is never a hard requirement, so this is strictly more robust | COMMENT |
| MEDIUM | rust/src/core/graph_provider.rs | 1049 | // the current symbol at its real line (robust beyond line-only refs). | COMMENT |
| MEDIUM | rust/src/core/auto_mode_resolver.rs | 578 | // Structure-first cold-read floor (#361): on a phase-isolated harness a cold | COMMENT |
| MEDIUM | rust/src/core/editor_registry/paths.rs | 627 | // Env-robust: compares the two paths against each other, so it holds | COMMENT |
| MEDIUM | rust/src/core/code_health/annotate.rs | 43 | /// name (more robust than line numbers when attributes/decorators shift lines). | COMMENT |
| MEDIUM | rust/src/core/config/proxy_tests.rs | 385 | // assertion is robust without mutating process-global env vars. | COMMENT |
| MEDIUM | rust/src/core/config/render.rs | 188 | // through `toml::Value` (map equality is order-independent) so it is robust | COMMENT |
| MEDIUM | rust/src/server/call_tool/pipeline.rs | 1247 | // which break a JSON contract. This guard is the robust catch-all: | COMMENT |
| MEDIUM | rust/src/cli/shell_init.rs | 429 | # Answers on a pipe too: an agent harness captures stdout (#2092).\n\ | COMMENT |
| MEDIUM | rust/src/cli/shell_init.rs | 606 | # Called on purpose, so it answers on a pipe too: an agent harness captures | COMMENT |
| MEDIUM | rust/src/cli/shell_init.rs | 1116 | // #2092: stdout is a pipe here, as in every agent harness. | COMMENT |
| MEDIUM | cookbook/package-lock.json | 2923 | "resolved": "https://registry.npmjs.org/robust-predicates/-/robust-predicates-3.0.3.tgz", | CODE |
| MEDIUM | scripts/preflight.sh | 274 | # Both became modules of the merged harness (`tests/main.rs` → `suite/`) in | COMMENT |
| MEDIUM | .github/workflows/ci.yml | 644 | # a benchmark smoke that proves the harness runs offline (local fallback). | COMMENT |
| MEDIUM | skills/lean-ctx-review/scripts/scan_session.py | 127 | # a body full of scary words is not a signal; only the harness flag is | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/scripts/train_triage_model.py | 13 | CODE | |
| LOW | rust/scripts/train_triage_model.py | 14 | CODE | |
| LOW | rust/scripts/train_triage_model.py | 16 | CODE | |
| LOW | rust/scripts/train_triage_model.py | 24 | CODE | |
| LOW | rust/scripts/train_triage_model.py | 24 | CODE | |
| LOW | tests/test_ip_provenance_audit.py | 13 | CODE | |
| LOW | tests/governance/test_narrative_governance.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/config.py | 9 | CODE | |
| LOW | integrations/hermes-lean-ctx/transport.py | 8 | CODE | |
| LOW | integrations/hermes-lean-ctx/presets.py | 9 | CODE | |
| LOW | integrations/hermes-lean-ctx/tools.py | 7 | CODE | |
| LOW | integrations/hermes-lean-ctx/__init__.py | 16 | CODE | |
| LOW | integrations/hermes-lean-ctx/tokens.py | 8 | CODE | |
| LOW | integrations/hermes-lean-ctx/_hermes_compat.py | 18 | CODE | |
| LOW | integrations/hermes-lean-ctx/engine.py | 9 | CODE | |
| LOW | integrations/hermes-lean-ctx/schemas.py | 10 | CODE | |
| LOW | integrations/hermes-lean-ctx/compaction.py | 17 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_engine_abc.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_lifecycle.py | 8 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/conftest.py | 13 | CODE | |
| LOW | …egrations/hermes-lean-ctx/tests/test_engine_adapter.py | 11 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_compaction.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_benchmark.py | 9 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_live_daemon.py | 11 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_config.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_config.py | 5 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_registration.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_tools.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/_helpers.py | 3 | CODE | |
| LOW | integrations/hermes-lean-ctx/benchmarks/metrics.py | 11 | CODE | |
| LOW | integrations/hermes-lean-ctx/benchmarks/run.py | 12 | CODE | |
| LOW | integrations/hermes-lean-ctx/benchmarks/engines.py | 9 | CODE | |
| LOW | integrations/hermes-lean-ctx/benchmarks/corpus.py | 12 | CODE | |
| LOW | examples/sprint-poc/poc.py | 8 | CODE | |
| LOW | examples/sprint-poc/poc.py | 73 | CODE | |
| LOW | examples/sprint-poc/secret_guard.py | 3 | CODE | |
| LOW | examples/sprint-poc/agent.py | 7 | CODE | |
| LOW | examples/sprint-poc/quality.py | 7 | CODE | |
| LOW | scripts/release-prebuild.py | 23 | CODE | |
| LOW | scripts/pinned-evidence.py | 29 | CODE | |
| LOW | scripts/public-export.py | 20 | CODE | |
| LOW | scripts/generate-release-manifest.py | 5 | CODE | |
| LOW | scripts/check-addon-versions.py | 18 | CODE | |
| LOW | scripts/check-sdk-engine-coupling.py | 10 | CODE | |
| LOW | scripts/check-v3-fixture-migrations.py | 5 | CODE | |
| LOW | scripts/check-package-versions.py | 33 | CODE | |
| LOW | scripts/verify-engine-agent-tools.py | 14 | CODE | |
| LOW | scripts/publish-pins.py | 20 | CODE | |
| LOW | scripts/sync-capabilities.py | 34 | CODE | |
| LOW | scripts/export-offline-build.py | 26 | CODE | |
| LOW | scripts/export-secret-gate.py | 25 | CODE | |
| LOW | scripts/generate-third-party-notices.py | 10 | CODE | |
| LOW | scripts/check-narrative-governance.py | 4 | CODE | |
| LOW | scripts/check-sdk-surface.py | 10 | CODE | |
| LOW | scripts/check-capabilities.py | 15 | CODE | |
| LOW | scripts/verify-ocla-contract-suite.py | 4 | CODE | |
| LOW | scripts/check-receipt-authority.py | 5 | CODE | |
| LOW | scripts/source-export-manifest.py | 11 | CODE | |
| LOW | scripts/publish-gate.py | 25 | CODE | |
| LOW | scripts/license-policy-check.py | 5 | CODE | |
| 20 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/tests/e2e_test.py | 33 | CODE | |
| LOW | rust/tests/embedding_download_test.py | 119 | CODE | |
| LOW | rust/tests/embedding_download_test.py | 32 | CODE | |
| LOW | tests/release/test_generate_release_manifest.py | 40 | CODE | |
| LOW | tests/release/test_generate_release_manifest.py | 183 | CODE | |
| LOW | tests/governance/test_narrative_governance.py | 228 | CODE | |
| LOW | tests/delivery/test_windows_packages.py | 18 | CODE | |
| LOW | integrations/hermes-lean-ctx/tokens.py | 35 | CODE | |
| LOW | integrations/hermes-lean-ctx/compaction.py | 147 | CODE | |
| LOW | integrations/hermes-lean-ctx/compaction.py | 268 | CODE | |
| LOW | integrations/hermes-lean-ctx/tests/test_tools.py | 62 | CODE | |
| LOW | integrations/hermes-lean-ctx/benchmarks/engines.py | 50 | CODE | |
| LOW | scripts/release-prebuild.py | 426 | CODE | |
| LOW | scripts/pinned-evidence.py | 308 | CODE | |
| LOW | scripts/pinned-evidence.py | 372 | CODE | |
| LOW | scripts/public-export.py | 43 | CODE | |
| LOW | scripts/check-addon-versions.py | 109 | CODE | |
| LOW | scripts/release_inventory.py | 60 | CODE | |
| LOW | scripts/check-v3-fixture-migrations.py | 17 | CODE | |
| LOW | scripts/verify-team-context-v1.py | 71 | CODE | |
| LOW | scripts/verify-team-context-v1.py | 538 | CODE | |
| LOW | scripts/verify-team-context-v1.py | 1110 | CODE | |
| LOW | scripts/verify-team-context-v1.py | 1151 | CODE | |
| LOW | scripts/verify-team-context-v1.py | 1355 | CODE | |
| LOW | scripts/verify-release-integrity.py | 78 | CODE | |
| LOW | scripts/verify-release-integrity.py | 136 | CODE | |
| LOW | scripts/verify-team-seat-value-v1.py | 224 | CODE | |
| LOW | scripts/verify-team-seat-value-v1.py | 357 | CODE | |
| LOW | scripts/verify-team-seat-value-v1.py | 747 | CODE | |
| LOW | scripts/generate-third-party-notices.py | 242 | CODE | |
| LOW | scripts/generate-third-party-notices.py | 354 | CODE | |
| LOW | scripts/generate-third-party-notices.py | 375 | CODE | |
| LOW | scripts/check-narrative-governance.py | 388 | CODE | |
| LOW | scripts/check-narrative-governance.py | 437 | CODE | |
| LOW | scripts/check-narrative-governance.py | 468 | CODE | |
| LOW | scripts/check-narrative-governance.py | 570 | CODE | |
| LOW | scripts/check-narrative-governance.py | 669 | CODE | |
| LOW | scripts/check-narrative-governance.py | 418 | CODE | |
| LOW | scripts/history-policy-gate.py | 427 | CODE | |
| LOW | scripts/check-capabilities.py | 49 | CODE | |
| LOW | scripts/check-capabilities.py | 171 | CODE | |
| LOW | scripts/check-capabilities.py | 260 | CODE | |
| LOW | scripts/check-capabilities.py | 306 | CODE | |
| LOW | scripts/check-source-layout.py | 120 | CODE | |
| LOW | scripts/project-capabilities.py | 33 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 324 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 428 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 575 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 658 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 782 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 805 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 972 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 1070 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 1188 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 1321 | CODE | |
| LOW | scripts/check-open-core-boundary.py | 1410 | CODE | |
| LOW | scripts/check-local-free.py | 52 | CODE | |
| LOW | scripts/scan-release-artifacts.py | 189 | CODE | |
| LOW | scripts/check-publish-dependency-graph.py | 39 | CODE | |
| LOW | scripts/ip-provenance-audit.py | 192 | CODE | |
| 18 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 58 | // Step 1: Consolidate | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 78 | // Step 2: Apply to session cache | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 90 | // Step 3: Verify cache contains provider data | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 100 | // Step 4: Cross-source hints for the referenced file | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 117 | // Step 5: Format hints (as ctx_read would append them) | COMMENT |
| LOW | rust/tests/suite/cortex_wiring_integration.rs | 267 | // Step 1: Provider query produces chunks and consolidates them | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 295 | // Step 2: Apply edges (these would be in the graph index) | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 300 | // Step 3: Simulate ctx_read — check cross-source hints for referenced files | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 331 | // Step 4: Verify format output matches what ctx_read appends | COMMENT |
| LOW⚡ | rust/tests/suite/cortex_wiring_integration.rs | 336 | // Step 5: Verify cache hit (session cache stores the provider results) | COMMENT |
| LOW | rust/src/core/context_compiler.rs | 315 | // Step 4: DEDUP — drop items whose CONTENT is >70% redundant with an | COMMENT |
| LOW | rust/src/core/context_compiler.rs | 349 | // Step 5: ORDER — Lost-in-the-Middle (LiTM) reorder. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 101 | // Step 3: Fidelity Check (structural only, no LLM) | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 162 | /// Step 1: Promote recent session decisions/findings into project knowledge. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 223 | /// Step 2: Remove edges whose endpoints no longer exist in the knowledge store. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 239 | /// Step 4: Connect related facts that share vocabulary but lack an explicit edge. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 279 | /// Step 5: Resolve contradictions — same category+key, different values. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 317 | /// Step 6: Strengthen edges between facts co-retrieved in the same session window. | COMMENT |
| LOW | rust/src/core/cognition_loop.rs | 354 | /// Step 7: Decay confidence on stale facts, and decay edge counts for unseen edges. | COMMENT |
| LOW | rust/src/core/hive/auth.rs | 52 | /// Step 1: ask Hive for a device code; `label` is the user's `--label`, if | COMMENT |
| LOW | rust/src/core/hive/auth.rs | 108 | /// Step 2: poll until the user approved (or the code expired), then verify | COMMENT |
| LOW | rust/src/cli/hive_connect_cmd.rs | 571 | /// Step 3: name the vault of the project at `root`. Never fails the | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/tests/e2e_test.py | 114 | except Exception as e: | CODE |
| LOW | rust/tests/embedding_download_test.py | 105 | except Exception as e: | CODE |
| LOW | rust/tests/pre_release_check.sh | 71 | except Exception: | CODE |
| LOW | rust/scripts/train_triage_model.py | 210 | except Exception as e: | CODE |
| LOW | rust/scripts/train_triage_model.py | 343 | except Exception: | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 40 | except Exception as exc: # pragma: no cover - depends on install | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 56 | except Exception as exc: | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 81 | except Exception as exc: | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 103 | except Exception as exc: | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 117 | except Exception as exc: | CODE |
| LOW | integrations/hermes-lean-ctx/transport.py | 128 | except Exception as exc: | CODE |
| LOW | integrations/hermes-lean-ctx/__init__.py | 31 | except Exception: | CODE |
| MEDIUM | integrations/hermes-lean-ctx/__init__.py | 26 | def _resolve_hermes_home() -> str: | CODE |
| LOW | integrations/hermes-lean-ctx/tokens.py | 30 | except Exception: # pragma: no cover - depends on optional dep | CODE |
| LOW | integrations/hermes-lean-ctx/tokens.py | 65 | except Exception: # pragma: no cover - encoder edge cases | CODE |
| LOW | integrations/hermes-lean-ctx/engine.py | 17 | except Exception: # pragma: no cover - exercised outside Hermes | CODE |
| LOW | integrations/hermes-lean-ctx/engine.py | 72 | except Exception: # pragma: no cover - exotic host base | CODE |
| LOW | integrations/hermes-lean-ctx/engine.py | 146 | except Exception as exc: # never break the agent loop | CODE |
| LOW | integrations/hermes-lean-ctx/tests/conftest.py | 53 | except Exception: | CODE |
| MEDIUM | integrations/hermes-lean-ctx/tests/conftest.py | 48 | def _ensure_agent_context_engine() -> None: | CODE |
| LOW | integrations/hermes-lean-ctx/benchmarks/engines.py | 56 | except Exception as exc: # noqa: BLE001 - any import failure → skip | CODE |
| LOW | integrations/hermes-lean-ctx/benchmarks/engines.py | 68 | except Exception: # noqa: BLE001 - try the next constructor shape | CODE |
| LOW | examples/sprint-poc/poc.py | 110 | except Exception as exc: | CODE |
| LOW⚡ | examples/sprint-poc/poc.py | 278 | except Exception: | CODE |
| LOW | scripts/verify-team-seat-value-v1.py | 207 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 55 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 145 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 156 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 226 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 498 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 544 | except Exception as exc: | CODE |
| LOW | scripts/source-export-manifest.py | 620 | except Exception: | CODE |
| LOW | scripts/tests/check_compose_admission.py | 177 | except Exception as error: | CODE |
| LOW | scripts/tests/check_agent_tools_policy.py | 308 | except Exception as error: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | rust/scripts/train_triage_model.py | 143 | except (json.JSONDecodeError, ValueError): | CODE |
| HIGH | integrations/hermes-lean-ctx/tokens.py | 65 | except Exception: # pragma: no cover - encoder edge cases | CODE |
| HIGH | integrations/hermes-lean-ctx/engine.py | 72 | except Exception: # pragma: no cover - exotic host base | CODE |
| HIGH | integrations/hermes-lean-ctx/tests/conftest.py | 53 | except Exception: | CODE |
| HIGH | integrations/hermes-lean-ctx/tests/test_live_daemon.py | 51 | except json.JSONDecodeError: | CODE |
| HIGH | scripts/verify-engine-agent-tools.py | 119 | except OSError: | CODE |
| HIGH | scripts/generate-third-party-notices.py | 677 | except OSError: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …t/crates/lean-ctx-protocol/src/credential_redaction.rs | 91 | "placeholder", | CODE |
| LOW | rust/src/tools/ctx_transcript_compact.rs | 414 | "lorem ipsum dolor sit amet ".repeat(n) | CODE |
| LOW | rust/src/tools/ctx_transcript_compact.rs | 414 | "lorem ipsum dolor sit amet ".repeat(n) | CODE |
| LOW | rust/src/core/redaction.rs | 152 | "placeholder", | CODE |
| LOW | rust/src/core/graph_enricher.rs | 749 | assert_eq!(commits[0].author, "John Doe"); | CODE |
| LOW | rust/src/core/providers/jira.rs | 694 | crate::test_env::set_var("JIRA_EMAIL", "test@test.com"); | CODE |
| LOW | rust/src/core/agents/registry_tests.rs | 53 | .expect("placeholder"); | CODE |
| LOW | rust/src/core/bm25_index/chunking.rs | 771 | let prose = format!("{}\n", "lorem ipsum dolor sit amet ".repeat(60)).repeat(60); | CODE |
| LOW | rust/src/core/bm25_index/chunking.rs | 771 | let prose = format!("{}\n", "lorem ipsum dolor sit amet ".repeat(60)).repeat(60); | CODE |
| LOW | rust/src/proxy/compress_tests.rs | 539 | .map(|i| format!("Line {i:04}: lorem ipsum dolor sit amet consectetur")) | CODE |
| LOW | rust/src/proxy/compress_tests.rs | 539 | .map(|i| format!("Line {i:04}: lorem ipsum dolor sit amet consectetur")) | CODE |
| LOW | rust/src/proxy/compress_tests.rs | 554 | .map(|i| format!("Line {i:04}: lorem ipsum dolor sit amet consectetur")) | CODE |
| LOW | rust/src/proxy/compress_tests.rs | 554 | .map(|i| format!("Line {i:04}: lorem ipsum dolor sit amet consectetur")) | CODE |
| LOW | rust/src/proxy/cache_policy.rs | 217 | let big = "lorem ipsum dolor sit amet ".repeat(50); | CODE |
| LOW | rust/src/proxy/cache_policy.rs | 217 | let big = "lorem ipsum dolor sit amet ".repeat(50); | CODE |
| LOW | rust/src/proxy/anthropic_tests.rs | 1125 | let huge_tail = "lorem ipsum dolor sit amet consectetur ".repeat(4000); | CODE |
| LOW | rust/src/proxy/anthropic_tests.rs | 1125 | let huge_tail = "lorem ipsum dolor sit amet consectetur ".repeat(4000); | CODE |
| LOW | rust/src/proxy/anthropic_tests.rs | 1155 | let huge_tail = "lorem ipsum dolor sit amet consectetur ".repeat(4000); | CODE |
| LOW | rust/src/proxy/anthropic_tests.rs | 1155 | let huge_tail = "lorem ipsum dolor sit amet consectetur ".repeat(4000); | CODE |
| LOW | integrations/hermes-lean-ctx/tests/_helpers.py | 9 | return "lorem ipsum dolor sit amet " * n | CODE |
| LOW | integrations/hermes-lean-ctx/tests/_helpers.py | 9 | return "lorem ipsum dolor sit amet " * n | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | rust/src/core/engine_interface/source_execution.rs | 65 | plan.context_plan_id = Some(snapshot.plan.result.plan.context_plan_id.clone()); | CODE |
| CRITICAL | rust/src/core/hive/bus/handoff.rs | 193 | org_id: c.session.lease.lease.org_id.clone(), | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | rust/src/core/redaction.rs | 319 | /// authentication", "Bearer YOUR_TOKEN_HERE" must survive), but the identifier | COMMENT |
| HIGH | rust/src/core/security_corpus_tests.rs | 379 | wrap("<your-api-key>"), | CODE |
| HIGH | rust/src/core/security_corpus_tests.rs | 396 | wrap("curl -H 'Authorization-Hint: Bearer YOUR_TOKEN_HERE'"), | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/delivery/test_sdk_engine_coupling.py | 113 | "wrong fields": (PAIR.replace('"evidence": null', '"evidence": null, "note": 1'), | CODE |
| HIGH⚡ | scripts/tests/test_release_prebuild.py | 395 | self.assertIn("name: release-build-config-${{ matrix.artifact || matrix.target }}", self.WORKFLOW) | CODE |
| HIGH | scripts/tests/test_ip_provenance_audit.py | 398 | "Apache-2.0 && __import__('os')", | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | rust/src/tools/ctx_response.rs | 567 | assert!(is_filler_line("Let me know if you need more")); | CODE |
| MEDIUM | rust/src/proxy/response_shaper.rs | 300 | let input = "The fix is applied.\n\nLet me know if you need anything else!"; | CODE |
| MEDIUM | rust/src/proxy/response_shaper.rs | 328 | let input = "Great, I'll fix that for you.\n\nChanged line 42 from `x` to `y`.\n\nLet me know if you need anythi | CODE |
| MEDIUM | rust/src/proxy/response_shaper.rs | 349 | "content": "Great, I'll check that.\n\nThe answer is 42.\n\nLet me know if you need more help!" | CODE |
| MEDIUM | rust/src/proxy/shaping_hook.rs | 83 | "choices": [{"message": {"role": "assistant", "content": "Great, I'll do that.\n\nDone.\n\nLet me know if yo | CODE |
| MEDIUM | rust/src/proxy/shaping_hook.rs | 92 | "choices": [{"message": {"role": "assistant", "content": "Sure, let me check that.\n\nThe answer is 42.\n\nL | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | integrations/hermes-lean-ctx/transport.py | 16 | logger = logging.getLogger(__name__) | CODE |
| LOW | integrations/hermes-lean-ctx/__init__.py | 23 | logger = logging.getLogger(__name__) | CODE |
| LOW | integrations/hermes-lean-ctx/__init__.py | 74 | __all__ = ["register", "LeanCtxEngine", "__version__"] | CODE |
| LOW | integrations/hermes-lean-ctx/tokens.py | 13 | logger = logging.getLogger(__name__) | CODE |
| LOW | integrations/hermes-lean-ctx/_hermes_compat.py | 62 | def update_from_response(self, usage: Dict[str, Any]) -> None: | CODE |
| LOW | integrations/hermes-lean-ctx/engine.py | 27 | logger = logging.getLogger(__name__) | CODE |
| LOW | integrations/hermes-lean-ctx/engine.py | 93 | def update_from_response(self, usage: Dict[str, Any]) -> None: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | …ents/rust/lean-ctx-client/tests/dependency_boundary.rs | 33 | "# This file is automatically @generated by Cargo.\n\ | CODE |
| MEDIUM⚡ | rust/tests/suite/pattern_snapshots.rs | 664 | release # Create a release build\n\ | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | install.sh | 4 | # Usage: | COMMENT |
| LOW | scripts/preflight.sh | 25 | # Usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | integrations/hermes-lean-ctx/benchmarks/run.py | 68 | CODE | |
| LOW | scripts/tests/check_agent_tools_policy.py | 98 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | rust/src/core/code_health/cognitive.rs | 10 | //! ## Increment rules | COMMENT |