Repository Analysis

chaosblade-io/chaosblade

An easy to use and powerful chaos engineering experiment toolkit.(阿里巴巴开源的一款简单易用、功能强大的混沌实验注入工具)

45.9 Strong AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of chaosblade-io/chaosblade, a Python project with 6,401 GitHub stars. SynthScan v2.0 examined 192,653 lines of code across 727 source files, recording 5983 pattern matches distributed across 20 syntactic categories. The overall adjusted score of 45.9 places this repository in the Strong AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

45.9
Adjusted Score
45.9
Raw Score
100%
Time Factor
2026-07-10
Last Push
6.4K
Stars
Python
Language
192.7K
Lines of Code
727
Files
6.0K
Pattern Hits
2026-07-14
Scan Date
0.02
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 0HIGH 11MEDIUM 1174LOW 4798

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 5983 distinct pattern matches across 20 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. 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 diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Decorative Section Separators1140 hits · 4027 pts
SeverityFileLineSnippetContext
MEDIUMblade-ai/tui/src/cli.tsx85 // ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/cli.tsx90 // ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/cli.tsx270 // ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/cli.tsx277 // ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/utils/overflowProbe.ts658 // ──────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/store.tsx113// ── Provider + context plumbing ──────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/store.tsx145// ── Public hooks ─────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/commands.ts326// ── built-in commands ────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/commands.ts534// ── Locator command helpers ──────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/commands.ts2238// ── /tasks filter helpers ────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/commands.ts2323// ── /review · /experiments · /recover · /skills formatters ──────────COMMENT
MEDIUMblade-ai/tui/src/state/commands.ts2702// ── helpers ──────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts18// ── Step model ─────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts51// ── Per-step value storage ─────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts83// ── Validation state ───────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts97// ── Top-level wizard state ─────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts146// ── Actions ────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts166// ── Reducer ────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/state/wizard.ts331// ── Helpers (UI side) ──────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/SlashMenu.tsx121// ── Root mode ────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/SlashMenu.tsx216// ── Sub mode ─────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx286 // ── Esc / Ctrl+C cascade ────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx306 // ── slash menu navigation ───────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx432 // ── command history ─────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx449 // ── inline cursor movement ──────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx471 // ── submit ──────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/InputPrompt.tsx488 // ── editing at cursor ───────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/boot/BootRunner.tsx153 // -- Effect 1: spawning → health → needs-setup check ───────────────COMMENT
MEDIUMblade-ai/tui/src/components/boot/BootRunner.tsx240 // -- Effect 2: sessioning → createSession + welcome card ──────────COMMENT
MEDIUMblade-ai/tui/src/components/boot/BootRunner.tsx343 // ── Render ────────────────────────────────────────────────────────COMMENT
MEDIUM…e-ai/tui/src/components/boot/PendingTasksCard.test.tsx81 // ────────────────────────────────────────────────────────────────COMMENT
MEDIUM…e-ai/tui/src/components/boot/PendingTasksCard.test.tsx90 // ────────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/boot/BootOrchestrator.tsx54 // ── Phase 1: preflight ─────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/boot/BootOrchestrator.tsx111 // ── Phase 2: pending tasks ─────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx49// ── Layout constants (mirror ConfirmMessage v3) ──────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx55// ── Shared widgets (private to wizard) ────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx245// ── Radio row (matches Select.tsx ``[A] label`` chip style) ───────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx277// ── Text input row ────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx321// ── Step renderers ────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx605// ── Step metadata (chip glyph + chip label + title) ──────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx624// ── Main component ────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx724 // ── Async commit handlers ───────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx800 // ── Keyboard handler ────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx967 // ── Render ───────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/wizard/WizardCard.tsx1045// ── Helpers ───────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/shared/Select.tsx124 // ──────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/shared/Select.tsx126 // ──────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/shared/Select.tsx181 // ──────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/components/shared/Select.tsx183 // ──────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tui/src/api/wizard.ts239 // ── internals ─────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py10# ── Reset global singletons ──────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py40# ── Settings ──────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py54# ── Temporary skills directory ────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py126# ── Mock run_command ──────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py194# ── AgentState sample ────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py256# ── Temporary memory directory ────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py276# ── Mock LLM ──────────────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py287# ── Mock SkillRegistry ────────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/conftest.py300# ── Mock config file path ────────────────────────────────────────────────COMMENT
MEDIUMblade-ai/tests/test_errors.py128# ---------------------------------------------------------------------------COMMENT
1080 more matches not shown…
Hyper-Verbose Identifiers3134 hits · 3082 pts
SeverityFileLineSnippetContext
LOWblade-ai/tui/src/utils/synchronizedOutput.ts43export function terminalSupportsSynchronizedOutput(CODE
LOWblade-ai/tui/src/utils/synchronizedOutput.ts87export function installSynchronizedOutput(CODE
LOWblade-ai/tui/src/utils/markdownSplit.ts71function findEnclosingCodeBlockStart(content: string, index: number): number {CODE
LOWblade-ai/tui/src/utils/terminalRedrawOptimizer.ts62export function optimizeMultilineEraseLines(output: string): string {CODE
LOWblade-ai/tui/src/utils/terminalRedrawOptimizer.ts99export function installTerminalRedrawOptimizer(CODE
LOWblade-ai/tui/src/state/commands.ts359function makePermissionModeHandler(CODE
LOWblade-ai/tui/src/state/chromeMeasureRef.ts152export function subscribeChromeMeasureRef(cb: () => void): () => void {CODE
LOWblade-ai/tests/test_errors.py76 def test_is_transient_returns_true(self):CODE
LOWblade-ai/tests/test_errors.py80 def test_is_transient_returns_false_for_permanent(self):CODE
LOWblade-ai/tests/test_errors.py84 def test_is_transient_returns_false_for_plain_exception(self):CODE
LOWblade-ai/tests/test_errors.py111 def test_context_overflow_is_recoverable(self):CODE
LOWblade-ai/tests/test_errors.py116 def test_is_recoverable_returns_true(self):CODE
LOWblade-ai/tests/test_errors.py120 def test_is_recoverable_returns_false_for_transient(self):CODE
LOWblade-ai/tests/test_errors.py124 def test_is_recoverable_returns_false_for_plain_exception(self):CODE
LOWblade-ai/tests/test_errors.py142 def test_finds_last_ai_message(self):CODE
LOWblade-ai/tests/test_errors.py151 def test_empty_messages_returns_fallback(self):CODE
LOWblade-ai/tests/test_errors.py154 def test_skips_tool_only_ai_messages(self):CODE
LOWblade-ai/tests/test_errors.py195 def test_unknown_flag_triggers_replan(self):CODE
LOWblade-ai/tests/test_errors.py199 def test_unknown_flag_case_insensitive(self):CODE
LOWblade-ai/tests/test_errors.py203 def test_unsupported_flag_triggers_replan(self):CODE
LOWblade-ai/tests/test_errors.py207 def test_resource_not_found_triggers_replan(self):CODE
LOWblade-ai/tests/test_errors.py210 def test_permission_denied_no_replan(self):CODE
LOWblade-ai/tests/test_errors.py218 def test_unknown_flag_dominates_when_combined_with_timeout(self):CODE
LOWblade-ai/tests/test_errors.py37 def test_default_severity_is_permanent(self):CODE
LOWblade-ai/tests/test_errors.py169 def test_reasoning_content_fallback(self):CODE
LOWblade-ai/tests/test_errors.py181 def test_prefers_content_over_reasoning(self):CODE
LOWblade-ai/tests/test_errors_classify.py25 def test_empty_returns_unknown(self):CODE
LOWblade-ai/tests/test_errors_classify.py31 def test_none_returns_unknown(self):CODE
LOWblade-ai/tests/test_errors_classify.py37 def test_bad_file_descriptor_is_transient(self):CODE
LOWblade-ai/tests/test_errors_classify.py48 def test_timeout_is_transient(self):CODE
LOWblade-ai/tests/test_errors_classify.py53 def test_connection_refused_is_transient(self):CODE
LOWblade-ai/tests/test_errors_classify.py58 def test_dns_lookup_is_transient(self):CODE
LOWblade-ai/tests/test_errors_classify.py63 def test_diskpressure_is_persistent(self):CODE
LOWblade-ai/tests/test_errors_classify.py69 def test_evicted_is_persistent(self):CODE
LOWblade-ai/tests/test_errors_classify.py76 def test_permission_denied_is_auth(self):CODE
LOWblade-ai/tests/test_errors_classify.py87 def test_resource_not_found_is_target_gone(self):CODE
LOWblade-ai/tests/test_errors_classify.py97 def test_unknown_flag_is_interface_mismatch(self):CODE
LOWblade-ai/tests/test_errors_classify.py114 def test_completely_novel_error_falls_to_unknown(self):CODE
LOWblade-ai/tests/test_errors_classify.py119 def test_priority_auth_beats_other_overlaps(self):CODE
LOWblade-ai/tests/test_errors_classify.py135 def test_target_gone_returns_true(self):CODE
LOWblade-ai/tests/test_errors_classify.py139 def test_user_config_returns_true(self):CODE
LOWblade-ai/tests/test_errors_classify.py147 def test_transient_returns_false(self):CODE
LOWblade-ai/tests/test_errors_classify.py153 def test_unknown_returns_false(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py11 def test_disabled_passes_through(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py19 def test_disabled_flush_empty(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py23 def test_disabled_structural_passes_through(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py34 def test_single_token_buffered(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py39 def test_buffered_tokens_flushed_on_structural(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py49 def test_thinking_buffered_separately(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py71 def test_chars_threshold_triggers_flush(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py81 def test_chars_threshold_includes_thinking(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py92 def test_deadline_flush_on_next_feed(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py106 def test_deadline_not_exceeded_keeps_buffering(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py119 def test_task_id_preserved_on_flush(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py126 def test_task_id_updated_from_latest_event(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py137 def test_flush_with_nothing_buffered(self):CODE
LOWblade-ai/tests/test_server/test_sse_batcher.py141 def test_only_structural_events(self):CODE
LOWblade-ai/tests/test_server/test_agent_runtime.py36async def test_short_circuits_when_no_llm_bound_key_changed(fake_app):CODE
LOWblade-ai/tests/test_server/test_agent_runtime.py51async def test_short_circuits_on_empty_iterable(fake_app):CODE
LOWblade-ai/tests/test_server/test_agent_runtime.py62async def test_rebuilds_and_swaps_state_on_llm_bound_change(fake_app):CODE
3074 more matches not shown…
Excessive Try-Catch Wrapping454 hits · 452 pts
SeverityFileLineSnippetContext
LOWblade-ai/tests/test_memory/test_hook.py322 except Exception:CODE
LOWblade-ai/tests/test_memory/test_hook.py368 except Exception:CODE
LOW…e-ai/tests/test_observability/test_metrics_endpoint.py88 except Exception:CODE
LOWblade-ai/scripts/uninstall.sh229except Exception:CODE
LOWblade-ai/scripts/install.sh176except Exception:CODE
LOWblade-ai/src/chaos_agent/chaosblade_installer.py175 except Exception:CODE
LOWblade-ai/src/chaos_agent/chaosblade_installer.py183 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/chaosblade_installer.py222 except Exception:CODE
LOWblade-ai/src/chaos_agent/preflight.py285 except Exception:CODE
LOWblade-ai/src/chaos_agent/preflight.py302 except Exception:CODE
LOWblade-ai/src/chaos_agent/preflight.py349 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py375 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py465 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py535 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py609 except Exception as e: # pragma: no cover — helper catches its ownCODE
LOWblade-ai/src/chaos_agent/preflight.py743 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py898 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py973 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py1100 except Exception:CODE
LOWblade-ai/src/chaos_agent/preflight.py1122 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/preflight.py1168 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/shell.py69 except Exception:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py137 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py187 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py269 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py314 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py352 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/blade.py397 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/retry.py94 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/knowledge_reader.py234 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/web_search.py70 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/tools/kubectl.py271 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/compactor.py665 except Exception as e:STRING
LOWblade-ai/src/chaos_agent/memory/hook.py187 except Exception as e: # extractor must never raise, but guard anywayCODE
LOWblade-ai/src/chaos_agent/memory/hook.py201 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/hook.py374 except Exception:CODE
LOWblade-ai/src/chaos_agent/memory/hook.py584 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/hook.py666 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/hook.py679 except Exception:CODE
LOWblade-ai/src/chaos_agent/memory/hook.py741 except Exception:CODE
MEDIUMblade-ai/src/chaos_agent/memory/tokens.py353def _hf_enabled() -> bool:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py249 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py273 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py389 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py234 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py348 except Exception:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py357 except Exception:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py406 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py428 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/tui_session_store.py392 except Exception:CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py408 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py544 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/config/wizard_validators.py262 except Exception as e:CODE
LOWblade-ai/src/chaos_agent/config/wizard_validators.py304 except Exception:CODE
LOWblade-ai/src/chaos_agent/config/wizard_validators.py390 except Exception:CODE
LOWblade-ai/src/chaos_agent/config/wizard_validators.py400 except Exception:CODE
LOWblade-ai/src/chaos_agent/tui/console.py79 except Exception:CODE
LOWblade-ai/src/chaos_agent/tui/console.py85 except Exception:CODE
MEDIUMblade-ai/src/chaos_agent/tui/console.py76def bell(self) -> None:CODE
MEDIUMblade-ai/src/chaos_agent/tui/console.py82def clear(self) -> None:CODE
394 more matches not shown…
Unused Imports486 hits · 396 pts
SeverityFileLineSnippetContext
LOWblade-ai/tests/test_errors_classify.py7CODE
LOWblade-ai/tests/test_errors_classify.py9CODE
LOWblade-ai/tests/_helpers.py8CODE
LOWblade-ai/tests/test_server/test_agent_runtime.py12CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py19CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py45CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py46CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py47CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py48CODE
LOW…ade-ai/tests/test_server/routes/test_phase3a_routes.py67CODE
LOWblade-ai/tests/test_server/routes/test_wizard.py15CODE
LOWblade-ai/tests/test_server/routes/test_wizard.py18CODE
LOWblade-ai/tests/test_server/routes/test_wizard.py19CODE
LOWblade-ai/tests/test_server/routes/test_wizard.py20CODE
LOWblade-ai/tests/test_server/routes/test_wizard.py36CODE
LOW…tests/test_server/routes/test_turn_double_interrupt.py26CODE
LOWblade-ai/tests/test_tools/test_fault_type.py3CODE
LOWblade-ai/tests/test_tools/test_guard_parser.py3CODE
LOWblade-ai/tests/test_tools/test_guard_parser.py5CODE
LOWblade-ai/tests/test_utils/test_coerce.py3CODE
LOWblade-ai/tests/test_utils/test_coerce.py5CODE
LOWblade-ai/tests/test_utils/test_file_watcher.py12CODE
LOWblade-ai/tests/test_utils/test_file_watcher.py16CODE
LOWblade-ai/tests/test_utils/test_file_watcher.py20CODE
LOWblade-ai/tests/test_utils/test_fault_context.py13CODE
LOWblade-ai/tests/test_utils/test_blade_uid.py15CODE
LOWblade-ai/tests/test_utils/test_inject_context.py10CODE
LOWblade-ai/tests/integration/test_fault_spec_e2e.py19CODE
LOWblade-ai/tests/integration/test_postmortem_e2e.py17CODE
LOWblade-ai/tests/integration/test_postmortem_e2e.py629CODE
LOWblade-ai/tests/test_tui/test_prompt_keymap.py19CODE
LOWblade-ai/tests/test_tui/test_prompt_keymap.py21CODE
LOWblade-ai/tests/test_tui/test_tool_panel.py23CODE
LOWblade-ai/tests/test_tui/test_experiment_card.py20CODE
LOWblade-ai/tests/test_tui/test_replay.py23CODE
LOWblade-ai/tests/test_tui/test_onboarding_wizard.py9CODE
LOWblade-ai/tests/test_tui/conftest.py29CODE
LOWblade-ai/tests/test_tui/test_jit_hints.py20CODE
LOWblade-ai/tests/test_tui/test_markdown_domain.py16CODE
LOWblade-ai/tests/test_tui/test_app_injection_count.py12CODE
LOWblade-ai/tests/test_tui/test_phase_timeline.py15CODE
LOWblade-ai/tests/test_tui/test_phase_timeline.py21CODE
LOWblade-ai/tests/test_tui/test_inflight.py20CODE
LOWblade-ai/tests/test_tui/test_cost_latency.py19CODE
LOWblade-ai/tests/test_tui/test_preflight.py3CODE
LOWblade-ai/tests/test_tui/test_locators.py21CODE
LOWblade-ai/tests/test_tui/test_state.py3CODE
LOWblade-ai/tests/test_tui/test_intent_confirm_risk.py21CODE
LOWblade-ai/tests/test_tui/test_live_coordinator.py29CODE
LOWblade-ai/tests/test_tui/test_intent.py3CODE
LOWblade-ai/tests/test_tui/test_recording.py24CODE
LOWblade-ai/tests/test_tui/test_theme_a11y.py22CODE
LOWblade-ai/tests/test_tui/test_baseline_compare.py25CODE
LOWblade-ai/tests/test_tui/test_commands_mode.py10CODE
LOWblade-ai/tests/test_tui/test_renderer_snapshots.py21CODE
LOWblade-ai/tests/test_tui/test_result_timeline.py20CODE
LOWblade-ai/tests/test_tui/test_result_timeline.py24CODE
LOWblade-ai/tests/test_tui/test_layout_cjk.py14CODE
LOWblade-ai/tests/test_agent/test_fault_spec.py15CODE
LOWblade-ai/tests/test_agent/test_metric_extractor.py8CODE
426 more matches not shown…
Over-Commented Block257 hits · 232 pts
SeverityFileLineSnippetContext
LOW.yamllint.yml1# Copyright 2025 The ChaosBlade AuthorsCOMMENT
LOWnsexec.c21#include <sched.h>COMMENT
LOW.golangci.yml1# Copyright 2025 The ChaosBlade AuthorsCOMMENT
LOWlicenserc.toml1# Copyright 2025 The ChaosBlade AuthorsCOMMENT
LOWlicenserc.toml41# 1. `includes` does not support `!`COMMENT
LOWlicenserc.toml61# There are also preset attributes that can be used in the header template (no need to surround them with `props[]`).:COMMENT
LOWhack/init.sh1#!/usr/bin/env bashCOMMENT
LOWhack/verify-gofmt.sh1#!/usr/bin/env bashCOMMENT
LOWhack/update-gofmt.sh1#!/usr/bin/env bashCOMMENT
LOWhack/update-imports.sh1#!/usr/bin/env bashCOMMENT
LOWhack/verify-imports.sh1#!/usr/bin/env bashCOMMENT
LOWblade-ai/pyproject.toml61[tool.hatch.build.targets.wheel]COMMENT
LOWblade-ai/pyproject.toml81# only fires on wheel builds) — main.py's _resolve_ts_bundle walks theCOMMENT
LOWblade-ai/tui/vitest.config.ts21 // Tests that render Ink components are .tsx (JSX); everythingCOMMENT
LOWblade-ai/tui/src/cli.tsx81 // ``blade-ai config-wizard`` CLI command — see ``utils/configGate.ts``.COMMENT
LOWblade-ai/tui/src/cli.tsx101 const capturedAt = new Date().toISOString();COMMENT
LOWblade-ai/tui/src/cli.tsx121 // 1. Terminal redraw optimizer: folds Ink's per-lineCOMMENT
LOWblade-ai/tui/src/utils/printGoodbye.tsx41COMMENT
LOWblade-ai/tui/src/utils/overflowProbe.ts181// Module-scope refs. Hack but intentional: lets MainContent andCOMMENT
LOWblade-ai/tui/src/utils/overflowProbe.ts661 // Why this is the killer probe for the "blank gap" mystery: theCOMMENT
LOWblade-ai/tui/src/utils/overflowProbe.ts881COMMENT
LOWblade-ai/tui/src/state/commands.ts841 // boot screen runs (LLM key valid / kubeconfig parses /COMMENT
LOWblade-ai/tui/src/state/commands.ts1081 await runSessionInfoHandler(ctx);COMMENT
LOWblade-ai/tui/src/state/commands.ts1101 dispatchesOwnTurn: true,COMMENT
LOWblade-ai/tui/src/state/commands.ts1281 pushLog(ctx, formatReviewCard(taskId, data), "info");COMMENT
LOWblade-ai/tui/src/state/commands.ts1321 //COMMENT
LOWblade-ai/tui/src/state/commands.ts1441 }COMMENT
LOWblade-ai/tui/src/state/commands.ts1621 },COMMENT
LOWblade-ai/tui/src/state/commands.ts1941 async handler(ctx) {COMMENT
LOWblade-ai/tui/src/state/commands.ts2041 }COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1121 // pending — so that when the FIRST token finally arrives,COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1301 // ✓" strip even though execute / verify never ran. UsersCOMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1521 // The next 3 tests lock in the CONFIRM_RECEIVED force-flush contract:COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1981 // tail and the end-of-turn TurnUsageItem both go silent for theCOMMENT
LOWblade-ai/tui/src/state/reducer.test.ts2121 // c1 still running; agent emits inter-tool commentary token.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts2281COMMENT
LOWblade-ai/tui/src/state/reducer.ts741 // Reset the per-turn rejection flag so a follow-up turnCOMMENT
LOWblade-ai/tui/src/state/reducer.ts761 dur: performance.now() - __perfStart,COMMENT
LOWblade-ai/tui/src/state/reducer.ts781COMMENT
LOWblade-ai/tui/src/state/reducer.ts801 // this, the dynamic frame would have to re-paint the entireCOMMENT
LOWblade-ai/tui/src/state/reducer.ts821 // tailItem]`` which is BACKWARDS from the chronologicalCOMMENT
LOWblade-ai/tui/src/state/reducer.ts921 pendingLen: next.length,COMMENT
LOWblade-ai/tui/src/state/reducer.ts941 // pending from before (a resolved confirm card, a stale agentCOMMENT
LOWblade-ai/tui/src/state/reducer.ts981 // 1. Field missing from frame entirely — older servers, orCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1001 ...state,COMMENT
LOWblade-ai/tui/src/state/reducer.ts1061COMMENT
LOWblade-ai/tui/src/state/reducer.ts1161 // carries a name, match the FIRST running tool with thatCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1261 // leading group, the group is now stable and can be flushedCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1281 const nextIsInjection =COMMENT
LOWblade-ai/tui/src/state/reducer.ts1301 // stepper at pending[0] (its old home) every thinking /COMMENT
LOWblade-ai/tui/src/state/reducer.ts1361 // agent as "might still receive tokens", but the serverCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1381 // frame doesn't grow with confirm content.COMMENT
LOWblade-ai/tui/src/state/reducer.ts1401 let s = sanitized === state.pending ? state : { ...state, pending: sanitized };COMMENT
LOWblade-ai/tui/src/state/reducer.ts1481 // Mark the matching ConfirmItem resolved and flip the streamCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1521 // sees as a flicker burst right before the cursor returns toCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1541 // so ``/show E1`` / ``/copy E1`` / ``/rerun E1`` can resolveCOMMENT
LOWblade-ai/tui/src/state/reducer.ts1581 // ---------------------------------------------------------------COMMENT
LOWblade-ai/tui/src/state/reducer.ts1601 ...state,COMMENT
LOWblade-ai/tui/src/state/reducer.ts1741 return { ...state, session: action.session };COMMENT
LOWblade-ai/tui/src/state/reducer.ts1841 // Commit the replayed pending items to history and resetCOMMENT
197 more matches not shown…
Modern Structural Boilerplate182 hits · 200 pts
SeverityFileLineSnippetContext
LOWblade-ai/src/chaos_agent/chaosblade_installer.py36logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/chaosblade_installer.py104def _set_executable(path: Path) -> None:CODE
LOWblade-ai/src/chaos_agent/preflight.py41logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/file_reader.py11logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/shell.py20logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/wait.py13logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/__init__.py11__all__ = [CODE
LOWblade-ai/src/chaos_agent/tools/blade.py17logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/file_writer.py14logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/file_search.py13logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/retry.py15logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/guard.py37logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/web_search.py15logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tools/kubectl.py26logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/compactor.py28logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/context_manager.py35logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/context_manager.py41__all__ = [CODE
LOWblade-ai/src/chaos_agent/memory/operational_memory.py10logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/hook.py25logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/__init__.py17__all__ = [CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py59logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py519__all__ = [CODE
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py23logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/tui_session_store.py38logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/tui_session_store.py43def set_global_tui_session_store(store: "TuiSessionStore") -> None:CODE
LOWblade-ai/src/chaos_agent/memory/tui_session_store.py201 def update_stats(self, tui_session_id: str, stats: dict) -> None:CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py23logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py31def set_global_session_store(store: "SessionStore") -> None:CODE
LOWblade-ai/src/chaos_agent/config/settings.py17logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/locators.py92 def update_payload(self, locator: str, **fields) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/recording.py39logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/interrupt.py15logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/interrupt.py40 def set_console(self, console) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/interrupt.py44 def set_renderer(self, renderer) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/interrupt.py48 def set_state(self, state) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/bridge.py24logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/__init__.py5__all__ = ["run_tui"]CODE
LOWblade-ai/src/chaos_agent/tui/config_store.py19logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/config_store.py180 def set_many(self, updates: dict[str, Any]) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/replay.py47logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/app.py36logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/live_coordinator.py96logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/commands.py19logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/state.py136 def set_permission_mode(self, mode: PermissionMode) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py140 def set_namespace(self, ns: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py144 def set_cluster_name(self, name: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py148 def set_active_task(self, task_id: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py152 def set_current_phase(self, phase: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py156 def set_streaming(self, streaming: bool) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py160 def set_dry_run(self, value: bool) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py166 def set_connection_status(self, status: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py170 def set_config_complete(self, complete: bool) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py174 def set_active_task_count(self, count: int) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py186 def set_display_mode(self, mode: DisplayMode) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py209 def set_model_name(self, name: str) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/state.py213 def set_context_limit(self, limit: int) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/renderers/__init__.py32logger = logging.getLogger(__name__)CODE
LOWblade-ai/src/chaos_agent/tui/renderers/__init__.py80 def set_interrupt_handler(self, cb: InterruptCallback) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/renderers/__init__.py83 def set_task_done_handler(self, cb: Callable[[str], None]) -> None:CODE
LOWblade-ai/src/chaos_agent/tui/renderers/tool_panel.py39logger = logging.getLogger(__name__)CODE
122 more matches not shown…
Deep Nesting174 hits · 142 pts
SeverityFileLineSnippetContext
LOWblade-ai/tests/test_agent/nodes/test_verifier.py2461CODE
LOWblade-ai/src/chaos_agent/preflight.py771CODE
LOWblade-ai/src/chaos_agent/tools/guard_parser.py204CODE
LOWblade-ai/src/chaos_agent/tools/file_search.py19CODE
LOWblade-ai/src/chaos_agent/tools/knowledge_reader.py132CODE
LOWblade-ai/src/chaos_agent/tools/kubectl.py183CODE
LOWblade-ai/src/chaos_agent/memory/compactor.py316CODE
LOWblade-ai/src/chaos_agent/memory/operational_memory.py195CODE
LOWblade-ai/src/chaos_agent/memory/hook.py633CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py361CODE
LOWblade-ai/src/chaos_agent/memory/tokens.py437CODE
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py213CODE
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py421CODE
LOWblade-ai/src/chaos_agent/memory/tui_session_store.py268CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py508CODE
LOWblade-ai/src/chaos_agent/memory/session_store.py650CODE
LOWblade-ai/src/chaos_agent/config/settings.py435CODE
LOWblade-ai/src/chaos_agent/tui/inflight.py53CODE
LOWblade-ai/src/chaos_agent/tui/bridge.py42CODE
LOWblade-ai/src/chaos_agent/tui/replay.py132CODE
LOWblade-ai/src/chaos_agent/tui/replay.py175CODE
LOWblade-ai/src/chaos_agent/tui/replay.py304CODE
LOWblade-ai/src/chaos_agent/tui/app.py142CODE
LOWblade-ai/src/chaos_agent/tui/streaming.py63CODE
LOWblade-ai/src/chaos_agent/tui/streaming.py519CODE
LOWblade-ai/src/chaos_agent/tui/renderers/onboarding.py595CODE
LOWblade-ai/src/chaos_agent/tui/renderers/onboarding.py664CODE
LOWblade-ai/src/chaos_agent/tui/renderers/onboarding.py939CODE
LOWblade-ai/src/chaos_agent/tui/renderers/__init__.py87CODE
LOWblade-ai/src/chaos_agent/tui/renderers/result.py302CODE
LOWblade-ai/src/chaos_agent/tui/renderers/review_panel.py122CODE
LOWblade-ai/src/chaos_agent/tui/renderers/tool_panel.py230CODE
LOWblade-ai/src/chaos_agent/tui/renderers/tool_panel.py385CODE
LOW…ade-ai/src/chaos_agent/tui/renderers/phase_timeline.py191CODE
LOWblade-ai/src/chaos_agent/tui/renderers/confirm.py26CODE
LOWblade-ai/src/chaos_agent/tui/controllers/commands.py1051CODE
LOWblade-ai/src/chaos_agent/tui/controllers/commands.py1211CODE
LOWblade-ai/src/chaos_agent/tui/controllers/commands.py1101CODE
LOWblade-ai/src/chaos_agent/l4/agent.py272CODE
LOWblade-ai/src/chaos_agent/l4/agent.py631CODE
LOWblade-ai/src/chaos_agent/l4/agent.py290CODE
LOWblade-ai/src/chaos_agent/server/app.py90CODE
LOWblade-ai/src/chaos_agent/server/routes/turn.py246CODE
LOWblade-ai/src/chaos_agent/server/routes/turn.py501CODE
LOWblade-ai/src/chaos_agent/server/routes/turn.py615CODE
LOWblade-ai/src/chaos_agent/server/routes/status_stream.py22CODE
LOWblade-ai/src/chaos_agent/server/routes/status_stream.py32CODE
LOWblade-ai/src/chaos_agent/server/routes/recordings.py61CODE
LOWblade-ai/src/chaos_agent/server/routes/sessions.py256CODE
LOWblade-ai/src/chaos_agent/server/routes/sessions.py424CODE
LOWblade-ai/src/chaos_agent/server/routes/inject.py19CODE
LOWblade-ai/src/chaos_agent/server/routes/inject.py69CODE
LOWblade-ai/src/chaos_agent/server/routes/inject_stream.py25CODE
LOWblade-ai/src/chaos_agent/server/routes/inject_stream.py89CODE
LOWblade-ai/src/chaos_agent/server/routes/recover.py17CODE
LOWblade-ai/src/chaos_agent/utils/blade_uid.py79CODE
LOWblade-ai/src/chaos_agent/utils/coerce.py42CODE
LOWblade-ai/src/chaos_agent/utils/coerce.py111CODE
LOWblade-ai/src/chaos_agent/agent/safety_score.py123CODE
LOWblade-ai/src/chaos_agent/agent/factory.py155CODE
114 more matches not shown…
Verbosity Indicators47 hits · 80 pts
SeverityFileLineSnippetContext
LOWblade-ai/tui/src/state/reducer.test.ts1133 // Step 1: agent_loop — stepper materialises in slot.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1144 // Step 2: safety_check — strip advances to ``safety``.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1155 // Step 3: execute_loop — strip advances to ``execute``.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1166 // Step 4: verifier_loop — strip advances to ``verify``.COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py43 # Step 1: load_memoryCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py49 # Step 2: agent_loop (simulates LLM planning)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py58 # Step 3: Route after agent_loop → extract_planning_metadataCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py62 # Step 4: safety_checkCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py68 # Step 5: Route after safety → confirmation_gate (warning needs confirmation)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py72 # Step 6: baseline_capture (shared across all modes)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py78 # Step 7: execute_loop (simulates LLM executing blade commands)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py86 # Step 8: Route after execute_loop → verifierCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py90 # Step 9: verifier (with mocked blade_status returning Running)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py107 # Step 10: save_memoryCOMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py522 # Step 1: initial inject → DB stores task_state="injecting"COMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py529 # Step 2: verification arrives → should transition to "injected"COMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py544 # Step 1: start recoveryCOMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py550 # Step 2: recovery verification arrivesCOMMENT
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py439 # Step 1: Time-based micro-compact (clear stale tool results)COMMENT
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py444 # Step 2: Size-based two-stage truncationCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py764 # Step 1: atomic rename. Skip if .jsonl doesn't exist (compactCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py773 # Step 2: write snapshot atomically. If this fails the orphanCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py789 # Step 3: delete the orphan. If this fails leave it — the nextCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py697 # Step 1: kubectl debug node/{node} -n {namespace} --image=busybox -- sleep 3600COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py732 # Step 2: kubectl exec {debug_pod} -n {namespace} -c debugger -- {cmd}COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py798 # Step 3: cleanup debug podCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py349 # Step 1: Discover running tool podsCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py548 # Step 2: blade_query_k8s — per-resource check (supplementary)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py255 # Step 0: Try the original injection pod first (if known)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py365 # Step 2: Try blade query k8s (primary) then blade status (fallback)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py511 # Step 1: blade_status — experiment-level checkCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py369 # Step 1: Discover a running otel-c-tool pod via direct run_commandCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py511 # Step 1: Discover tool pod on target nodeCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py538 # Step 2: Check for fill file in the tool pod's overlay filesystemCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py556 # Step 3: Check overlay df for usage increaseCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py788 # Step 3: Parse diskstats and compute write throughput per partitionCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py410 # Step 2: Build blade command (without --kubeconfig)COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py422 # Step 3: Execute via kubectl exec (direct run_command for tracker visibility)COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py452 # Step 4: Extract blade_uid from kubectl exec output.COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py759 # Step 2: Sample /proc/diskstats twice with 5-second intervalCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_conflict_check.py198 # Step 1: Discover running tool podsCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_conflict_check.py214 # Step 2: Run blade status --type create in the first available pod.COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_recover_layer1.py334 # Step 1: Execute blade_destroyCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_recover_layer1.py348 # Step 2: Verify via blade_status that experiment is DestroyedCOMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py329 # Step 1: Match scope to directory prefixCOMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py343 # Step 2: Narrow by target keywords.COMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py399 # Step 3: Collect ALL matching .md files (not just the first)COMMENT
Structural Annotation Overuse47 hits · 79 pts
SeverityFileLineSnippetContext
LOWblade-ai/tui/src/state/reducer.test.ts1133 // Step 1: agent_loop — stepper materialises in slot.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1144 // Step 2: safety_check — strip advances to ``safety``.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1155 // Step 3: execute_loop — strip advances to ``execute``.COMMENT
LOWblade-ai/tui/src/state/reducer.test.ts1166 // Step 4: verifier_loop — strip advances to ``verify``.COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py43 # Step 1: load_memoryCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py49 # Step 2: agent_loop (simulates LLM planning)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py58 # Step 3: Route after agent_loop → extract_planning_metadataCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py62 # Step 4: safety_checkCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py68 # Step 5: Route after safety → confirmation_gate (warning needs confirmation)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py72 # Step 6: baseline_capture (shared across all modes)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py78 # Step 7: execute_loop (simulates LLM executing blade commands)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py86 # Step 8: Route after execute_loop → verifierCOMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py90 # Step 9: verifier (with mocked blade_status returning Running)COMMENT
LOWblade-ai/tests/integration/test_inject_graph_flow.py107 # Step 10: save_memoryCOMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py522 # Step 1: initial inject → DB stores task_state="injecting"COMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py529 # Step 2: verification arrives → should transition to "injected"COMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py544 # Step 1: start recoveryCOMMENT
LOWblade-ai/tests/test_persistence/test_task_store.py550 # Step 2: recovery verification arrivesCOMMENT
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py439 # Step 1: Time-based micro-compact (clear stale tool results)COMMENT
LOWblade-ai/src/chaos_agent/memory/tool_compactor.py444 # Step 2: Size-based two-stage truncationCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py764 # Step 1: atomic rename. Skip if .jsonl doesn't exist (compactCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py773 # Step 2: write snapshot atomically. If this fails the orphanCOMMENT
LOWblade-ai/src/chaos_agent/memory/session_store.py789 # Step 3: delete the orphan. If this fails leave it — the nextCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py697 # Step 1: kubectl debug node/{node} -n {namespace} --image=busybox -- sleep 3600COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py732 # Step 2: kubectl exec {debug_pod} -n {namespace} -c debugger -- {cmd}COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py798 # Step 3: cleanup debug podCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py349 # Step 1: Discover running tool podsCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py548 # Step 2: blade_query_k8s — per-resource check (supplementary)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py255 # Step 0: Try the original injection pod first (if known)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py365 # Step 2: Try blade query k8s (primary) then blade status (fallback)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py511 # Step 1: blade_status — experiment-level checkCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py369 # Step 1: Discover a running otel-c-tool pod via direct run_commandCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py511 # Step 1: Discover tool pod on target nodeCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py538 # Step 2: Check for fill file in the tool pod's overlay filesystemCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py556 # Step 3: Check overlay df for usage increaseCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py788 # Step 3: Parse diskstats and compute write throughput per partitionCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py410 # Step 2: Build blade command (without --kubeconfig)COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py422 # Step 3: Execute via kubectl exec (direct run_command for tracker visibility)COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py452 # Step 4: Extract blade_uid from kubectl exec output.COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/direct_execute.py759 # Step 2: Sample /proc/diskstats twice with 5-second intervalCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_conflict_check.py198 # Step 1: Discover running tool podsCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_conflict_check.py214 # Step 2: Run blade status --type create in the first available pod.COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_recover_layer1.py334 # Step 1: Execute blade_destroyCOMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_recover_layer1.py348 # Step 2: Verify via blade_status that experiment is DestroyedCOMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py329 # Step 1: Match scope to directory prefixCOMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py343 # Step 2: Narrow by target keywords.COMMENT
LOWblade-ai/src/chaos_agent/skills/registry.py399 # Step 3: Collect ALL matching .md files (not just the first)COMMENT
Self-Referential Comments12 hits · 40 pts
SeverityFileLineSnippetContext
MEDIUMblade-ai/tests/test_server/test_app.py52 # Create a task that never completesCOMMENT
MEDIUMblade-ai/tests/integration/test_skill_loading_flow.py79 # Create a mixed directory with valid and invalid skillsCOMMENT
MEDIUMblade-ai/tests/test_memory/test_compactor.py413 # Create a very long skill content message that matches extraction heuristicsCOMMENT
MEDIUMblade-ai/tests/test_cli/test_runner.py53 # Create a mock registryCOMMENT
MEDIUMblade-ai/tests/test_cli/test_config_manager.py104 # Create a legacy mode.jsonCOMMENT
MEDIUMblade-ai/tests/test_skills/test_registry.py52 # Create a second skill dir with the same name "test-skill"COMMENT
MEDIUMblade-ai/tests/test_skills/test_catalog_generator.py249 # Create a skill directory with a fileCOMMENT
MEDIUMblade-ai/src/chaos_agent/memory/context_manager.py510 # Create a copy with truncated contentCOMMENT
MEDIUMblade-ai/src/chaos_agent/agent/factory.py746 # Create a shared tracing callback that routes to the correct TaskTraceCOMMENT
MEDIUMblade-ai/src/chaos_agent/cli/runner.py1744 # Create a separate session file for the recover record. InjectCOMMENT
MEDIUMblade-ai/src/chaos_agent/cli/runner.py1901 # Create a lightweight LLM instance for catalog generationCOMMENT
MEDIUM…ade-ai/src/chaos_agent/observability/status_tracker.py243 # Create a tracer span for this node executionCOMMENT
Docstring Block Structure8 hits · 40 pts
SeverityFileLineSnippetContext
HIGHblade-ai/src/chaos_agent/tools/file_reader.py46Read a file safely, with deny-list filtering and directory listing support. If *file_path* points to a directory, rSTRING
HIGHblade-ai/src/chaos_agent/tools/shell.py82Execute a command safely via async subprocess. Args: cmd: Command and arguments as a list. Never uses shellSTRING
HIGHblade-ai/src/chaos_agent/tools/file_writer.py82Write content to a file safely. Creates parent directories if they don't exist. Fails if the path is in a denieSTRING
HIGHblade-ai/src/chaos_agent/tools/file_search.py24Search for files matching a glob pattern under a directory. Recursively searches for files whose names match the giSTRING
HIGHblade-ai/src/chaos_agent/tools/retry.py36Execute an async function with exponential backoff retry. Args: func: The awaitable to execute. conSTRING
HIGHblade-ai/src/chaos_agent/agent/attempt_tracker.py88Record the start of a new pipeline attempt. Returns a delta dict the caller MERGES into state — does not mutateSTRING
HIGHblade-ai/src/chaos_agent/agent/attempt_tracker.py144Mark the current (last) attempt as ended. Called from the graph's terminal node (save_memory) or from the rejecSTRING
HIGHblade-ai/src/chaos_agent/agent/prompts/builders.py383Unified prompt builder entry point — routes by PromptMode. This is the P1 integration: all nodes should call this fSTRING
Redundant / Tautological Comments16 hits · 23 pts
SeverityFileLineSnippetContext
LOWblade-ai/tests/test_server/test_agent_runtime.py109 # Set state to a spec'd object so getattr returns the defaultCOMMENT
LOWblade-ai/scripts/install.sh462# Check if ~/.local/bin is already in PATHCOMMENT
LOWblade-ai/src/chaos_agent/memory/context_manager.py228 # Check if the last message in to_compact is a tool_call (AI message with tool_calls)COMMENT
LOWblade-ai/src/chaos_agent/server/routes/status_stream.py42 # Check if client disconnectedCOMMENT
LOWblade-ai/src/chaos_agent/server/routes/inject.py25 # Check if server is shutting downCOMMENT
LOWblade-ai/src/chaos_agent/server/routes/inject_stream.py39 # Check if server is shutting downCOMMENT
LOWblade-ai/src/chaos_agent/server/routes/inject_stream.py119 # Check if paused at confirmation_gateCOMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py267 # Check if blade query k8s is available (not in older ChaosBlade versions)COMMENT
LOW…ade-ai/src/chaos_agent/agent/nodes/_verifier_layer1.py311 # Check if the original pod is unavailableCOMMENT
LOW…i/src/chaos_agent/agent/nodes/_recover_layer2_parse.py399 # Check if any fault-specific evidence keyword appears in L2 detailsCOMMENT
LOW…i/src/chaos_agent/agent/nodes/_recover_layer2_parse.py406 # Check if generic health indicators appear (confirming the evidence is generic)COMMENT
LOWblade-ai/src/chaos_agent/agent/nodes/_conflict_check.py105 # Check if action matches current request (e.g. both are pod-disk-burn)COMMENT
LOW…ai/src/chaos_agent/agent/nodes/_injection_detection.py156 # Check if the kubectl call succeeded (no error in content)COMMENT
LOWblade-ai/src/chaos_agent/cli/runner.py537 # Check if graph paused at an interrupt point (confirmation_gate, ask_human, etc.)COMMENT
LOWscripts/sync_go_mod.sh66 # Check if Makefile existsCOMMENT
LOWscripts/sync_go_mod.sh118 # Check if go.mod existsCOMMENT
Modern AI Meta-Vocabulary6 hits · 17 pts
SeverityFileLineSnippetContext
MEDIUMblade-ai/tests/test_agent/test_verifier_cross_check.py174 # This is the core E2 win: detect baseline→post hallucination.COMMENT
MEDIUMblade-ai/src/chaos_agent/preflight.py1082# ── Command orchestration ──────────────────────────────────────────COMMENT
MEDIUMblade-ai/src/chaos_agent/config/settings.py32# context window size + the compact_ratio that's appropriate forCOMMENT
MEDIUMblade-ai/src/chaos_agent/tui/strings.py93# tokens. We do NOT show the raw chain-of-thought; only one of theseCOMMENT
MEDIUMblade-ai/src/chaos_agent/tui/state.py90 self.context_limit: int = 128000 # Default context window sizeCODE
MEDIUM…de-ai/src/chaos_agent/agent/nodes/_metric_extractor.py285# "no errors observed" hallucination — if extractor saw 12 OOMKilledCOMMENT
AI Slop Vocabulary5 hits · 13 pts
SeverityFileLineSnippetContext
MEDIUMblade-ai/tests/test_memory/test_context_manager.py332 """Test group_messages_by_round() robust API round grouping."""STRING
MEDIUMblade-ai/src/chaos_agent/memory/context_manager.py444 # Use group_messages_by_round for robust grouping: if the firstCOMMENT
MEDIUMblade-ai/src/chaos_agent/server/routes/recordings.py49 # is robust to symlinks resolving outside the dir).COMMENT
MEDIUMblade-ai/src/chaos_agent/agent/state.py580 # verifier verdict parsing robust to compression.COMMENT
MEDIUM…ade-ai/src/chaos_agent/agent/nodes/baseline_capture.py1748 # with it. ``isinstance`` keeps the runner robustCOMMENT
Cross-Language Confusion3 hits · 12 pts
SeverityFileLineSnippetContext
HIGHblade-ai/tests/test_agent/test_streaming.py361 the 0, the TS reducer's ``Math.max(0, undefined)`` returnedSTRING
HIGHblade-ai/src/chaos_agent/agent/streaming.py134 ``Math.max(0, undefined)`` returns ``NaN``, and the per-turnSTRING
HIGHblade-ai/src/chaos_agent/persistence/task_store.py512 await backend.close() # type: ignore[possibly-undefined]CODE
AI Structural Patterns6 hits · 6 pts
SeverityFileLineSnippetContext
LOWblade-ai/src/chaos_agent/tools/blade.py70CODE
LOWblade-ai/src/chaos_agent/server/routes/interrupt.py53CODE
LOWblade-ai/src/chaos_agent/server/routes/interrupt.py63CODE
LOW…ai/src/chaos_agent/agent/nodes/intent_clarification.py599CODE
LOWblade-ai/src/chaos_agent/cli/config_manager.py128CODE
LOWblade-ai/src/chaos_agent/cli/commands/inject.py14CODE
Slop Phrases1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMlicenserc.toml55# For a defined key-value pair, you can use {{props["key"]}} in the header template, which will beCOMMENT
Example Usage Blocks2 hits · 2 pts
SeverityFileLineSnippetContext
LOWblade-ai/scripts/uninstall.sh15# Usage:COMMENT
LOWblade-ai/scripts/install.sh6# Usage:COMMENT
Fake / Example Data2 hits · 2 pts
SeverityFileLineSnippetContext
LOW…tests/test_server/routes/test_turn_double_interrupt.py55 return SimpleNamespace(tasks=tasks, next=("placeholder",), values={})CODE
LOWblade-ai/src/chaos_agent/tui/prompt.py48 "placeholder": "#888888",CODE
Dead Code1 hit · 2 pts
SeverityFileLineSnippetContext
MEDIUMblade-ai/tests/test_tui/test_app_injection_count.py132CODE