[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-qwen-codegraph-qa":3,"mdc--qjvovo-key":40,"related-repo-qwen-codegraph-qa":3689,"related-org-qwen-codegraph-qa":3811},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":12,"stars":29,"repoUrl":30,"updatedAt":31,"license":32,"forks":33,"topics":34,"repo":35,"sourceUrl":38,"mdContent":39},"codegraph-qa","analyze codebases using CodeScope","Use CodeScope to analyze any indexed codebase via its graph database (neug) and vector index (zvec). Supports Python, JavaScript\u002FTypeScript, C, and Java (including Hadoop-scale repositories). Covers call graphs, dependency analysis, dead code detection, hotspots, module coupling, architectural layering, commit history, change attribution, semantic code search, impact analysis, full architecture reports, and bug root cause analysis from GitHub issues. Use this skill whenever the user asks about code structure, code dependencies, who calls what, why something changed, finding similar functions, generating architecture reports, understanding module boundaries, analyzing GitHub issues\u002Fbugs, finding bug root causes, understanding why a project has many bugs, tracing bugs to code, indexing Java projects, or any question that benefits from a code knowledge graph — even if they don't mention \"CodeScope\" by name. If a `.codegraph` or similar index directory exists in the workspace, this skill applies.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},"qwen","Qwen","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Fqwen.png","QwenLM",[13,17,20,23,26],{"name":14,"slug":15,"type":16},"Java","java","tag",{"name":18,"slug":19,"type":16},"TypeScript","typescript",{"name":21,"slug":22,"type":16},"JavaScript","javascript",{"name":24,"slug":25,"type":16},"Python","python",{"name":27,"slug":28,"type":16},"Code Analysis","code-analysis",136,"https:\u002F\u002Fgithub.com\u002FQwenLM\u002Fqwen-code-examples","2026-07-16T06:01:30.356708",null,40,[],{"repoUrl":30,"stars":29,"forks":33,"topics":36,"description":37},[],"A collection of practical examples and best practices for Qwen Code","https:\u002F\u002Fgithub.com\u002FQwenLM\u002Fqwen-code-examples\u002Ftree\u002FHEAD\u002Fskills\u002Fcodegraph","---\nname: codegraph-qa\ndescription: Use CodeScope to analyze any indexed codebase via its graph database (neug) and vector index (zvec). Supports Python, JavaScript\u002FTypeScript, C, and Java (including Hadoop-scale repositories). Covers call graphs, dependency analysis, dead code detection, hotspots, module coupling, architectural layering, commit history, change attribution, semantic code search, impact analysis, full architecture reports, and bug root cause analysis from GitHub issues. Use this skill whenever the user asks about code structure, code dependencies, who calls what, why something changed, finding similar functions, generating architecture reports, understanding module boundaries, analyzing GitHub issues\u002Fbugs, finding bug root causes, understanding why a project has many bugs, tracing bugs to code, indexing Java projects, or any question that benefits from a code knowledge graph — even if they don't mention \"CodeScope\" by name. If a `.codegraph` or similar index directory exists in the workspace, this skill applies.\n---\n\n# CodeScope Q&A\n\nCodeScope indexes source code into a two-layer knowledge graph — **structure** (functions, calls, imports, classes, modules) and **evolution** (commits, file changes, function modifications) — plus **semantic embeddings** for every function. Supports **Python, JavaScript\u002FTypeScript, C, and Java** (including Hadoop-scale repositories with 8K+ files). This combination enables analyses that grep, LSP, or pure vector search cannot do alone. It can also **fetch GitHub issues and trace bugs to code** — mapping bug reports to root cause candidates using the graph + vector infrastructure.\n\n## When to Use This Skill\n\n- User asks about call chains, callers, callees, or dependencies\n- User wants to find dead code, hotspots, or architectural layers\n- User asks about code history, who changed what, or why something was modified\n- User wants to find semantically similar functions across a codebase\n- User wants a full architecture analysis or report\n- User asks about module coupling, circular dependencies, or bridge functions\n- User wants to index or analyze a Java project (Maven, Gradle, plain Java)\n- User wants to analyze GitHub issues or bug reports to find root causes\n- User asks \"why does this project have so many bugs\" or \"what code is most buggy\"\n- User wants to trace a bug report to the most relevant code locations\n- A `.codegraph` directory (or similar index) exists in the workspace\n\n## Getting Started\n\n### Installation\n\n```bash\npip install codegraph-ai\n```\n\n### Environment Variables (optional)\n\n```bash\n# Create Python virtural environment\npython -m venv .venv\n\nsource .venv\u002Fbin\u002Factivate\n\n# Point to a pre-built database (skip indexing)\nexport CODESCOPE_DB_DIR=\"\u002Fpath\u002Fto\u002F.linux_db\"\n\n# Offline mode for HuggingFace models\nexport HF_HUB_OFFLINE=\"1\"\n```\n\n### Check Index Status\n\n```bash\ncodegraph status --db $CODESCOPE_DB_DIR\n```\n\nIf no index exists, create one:\n\n```bash\ncodegraph init --repo . --lang auto --commits 500\n```\n\nSupported languages: `python`, `c`, `javascript`, `typescript`, `java`, or `auto` (auto-detects from file extensions).\n\nThe `--commits` flag ingests git history (for evolution queries). Without it, only structural analysis is available. Add `--backfill-limit 200` to also compute function-level `MODIFIES` edges (slower but enables `change_attribution` and `co_change`).\n\n## Two Interfaces: CLI vs Python\n\n**Use the CLI** for status and reports:\n\n```bash\ncodegraph status --db $CODESCOPE_DB_DIR\ncodegraph analyze --db $CODESCOPE_DB_DIR --output report.md\n```\n\n**Use the Python API** for queries and custom analyses:\n\n```python\nimport os\nos.environ['HF_HUB_OFFLINE'] = '1'  # required\n\nfrom codegraph.core import CodeScope\ncs = CodeScope(os.environ['CODESCOPE_DB_DIR'])\n\n# Cypher query\nrows = list(cs.conn.execute('''\n    MATCH (caller:Function)-[:CALLS]->(f:Function {name: \"free_irq\"})\n    RETURN caller.name, caller.file_path LIMIT 10\n'''))\nfor r in rows:\n    print(r)\n\ncs.close()  # always close when done\n```\n\nThe Python API is more powerful — it gives you raw Cypher access and lets you chain queries.\n\n## Core Python API\n\n### Raw Queries\n\nThese are the building blocks for any custom analysis:\n\n| Method | What it does |\n|--------|-------------|\n| `cs.conn.execute(cypher)` | Run any Cypher query against the graph — returns list of tuples |\n| `cs.vector_only_search(query, topk=10)` | Semantic search over all function embeddings — returns `[{id, score}]` |\n| `cs.summary()` | Print a human-readable overview of the indexed codebase |\n\n### Structural Analysis\n\n| Method | What it does |\n|--------|-------------|\n| `cs.impact(func_name, change_desc, max_hops=3)` | Find callers up to N hops, ranked by semantic relevance to the change |\n| `cs.hotspots(topk=10)` | Rank functions by structural risk (fan-in × fan-out) |\n| `cs.dead_code()` | Find functions with zero callers (excluding entry points) |\n| `cs.circular_deps()` | Detect circular import chains at file level |\n| `cs.module_coupling(topk=10)` | Find cross-module coupling pairs with call counts |\n| `cs.bridge_functions(topk=30)` | Find functions called from the most distinct modules |\n| `cs.layer_discovery(topk=30)` | Auto-discover infrastructure \u002F mid \u002F consumer layers |\n| `cs.stability_analysis(topk=50)` | Correlate fan-in with modification frequency |\n| `cs.class_hierarchy(class_name=None)` | Return inheritance tree for a class (or all classes) |\n\n### Semantic Search\n\n| Method | What it does |\n|--------|-------------|\n| `cs.similar(function, scope, topk=10)` | Find functions similar to a given function within a module scope |\n| `cs.cross_locate(query, topk=10)` | Find semantically related functions, then reveal call-chain connections |\n| `cs.semantic_cross_pollination(query, topk=15)` | Find similar functions across distant subsystems |\n\n### Evolution (requires `--commits` during init)\n\n| Method | What it does |\n|--------|-------------|\n| `cs.change_attribution(func_name, file_path=None, limit=20)` | Which commits modified a function? (requires backfill) |\n| `cs.co_change(func_name, file_path=None, min_commits=2, topk=10)` | Functions that are always modified together |\n| `cs.intent_search(query, topk=10)` | Find commits matching a natural-language intent |\n| `cs.commit_modularity(topk=20)` | Score commits by how many modules they touch |\n| `cs.hot_cold_map(topk=30)` | Module modification density |\n\n### Report Generation\n\n```python\nfrom codegraph.analyzer import generate_report\nreport = generate_report(cs)  # full architecture analysis as markdown\n```\n\nOr via CLI:\n\n```bash\ncodegraph analyze --output reports\u002Fanalysis.md\n```\n\nThe report covers: overview stats, subsystem distribution, top modules, architectural layers (with Mermaid diagrams), bridge functions, fan-in\u002Ffan-out hotspots, cross-module coupling, evolution hotspots, and dead code density.\n\n## Java Support\n\nCodeScope includes a full Java adapter that handles enterprise-scale repositories like Apache Hadoop (~8K files, ~97K functions indexed in ~3.5 minutes).\n\n### What Gets Indexed\n\n| Element | Graph Node\u002FEdge | Notes |\n|---------|----------------|-------|\n| Classes | `Class` node | Includes generics, annotations |\n| Interfaces | `Class` node | `extends` → `INHERITS` edge |\n| Enums | `Class` node | Enum methods extracted |\n| Methods | `Function` node | Full generic signatures, JavaDoc |\n| Constructors | `Function` node (name=`\u003Cinit>`) | Including `super()` calls |\n| Method calls | `CALLS` edge | Receiver context preserved (`obj.method()`) |\n| `new` expressions | `CALLS` edge to `ClassName.\u003Cinit>` | Constructor invocations |\n| Imports | `IMPORTS` edge (file→file) | Single, wildcard, static |\n| Inner classes | `Class` node (name=`Outer.Inner`) | Prefixed with outer class |\n| Inheritance | `INHERITS` edge | `extends` + `implements` |\n\n### Indexing a Java Project\n\n```bash\ncodegraph init --repo \u002Fpath\u002Fto\u002Fjava-project --lang java --commits 500\n```\n\nOr with auto-detection (auto-detects `.java` files):\n\n```bash\ncodegraph init --repo \u002Fpath\u002Fto\u002Fjava-project --lang auto\n```\n\n### Java-Specific Exclusions\n\nBy default, these directories are excluded when indexing Java projects: `target\u002F`, `build\u002F`, `.gradle\u002F`, `.idea\u002F`, `.settings\u002F`, `bin\u002F`, `out\u002F`, `test\u002F`, `tests\u002F`, `src\u002Ftest\u002F`.\n\n### Java Query Examples\n\n```python\n# Find all classes that extend a specific class\nlist(cs.conn.execute(\"\"\"\n    MATCH (c:Class)-[:INHERITS]->(p:Class {name: 'FileSystem'})\n    RETURN c.name, c.file_path\n\"\"\"))\n\n# Find all methods in a specific class\nlist(cs.conn.execute(\"\"\"\n    MATCH (c:Class {name: 'DefaultParser'})-[:HAS_METHOD]->(f:Function)\n    RETURN f.name, f.signature\n\"\"\"))\n\n# Find constructor call chains\nlist(cs.conn.execute(\"\"\"\n    MATCH (f:Function)-[:CALLS]->(init:Function {name: '\u003Cinit>'})\n    WHERE init.class_name = 'Configuration'\n    RETURN f.name, f.file_path LIMIT 10\n\"\"\"))\n```\n\n## Bug Root Cause Analysis\n\nCodeScope can fetch GitHub issues and map them to code using the graph + vector infrastructure. This is the core workflow for answering questions like \"why does this project have so many bugs?\" or \"where in the code does this bug come from?\"\n\n### Prerequisites\n\n- A code graph must already be indexed for the target repository\n- `gh` CLI must be installed and authenticated (`gh auth login`)\n\n### Bug Analysis API\n\n#### Single Issue Analysis\n\n```python\n# Analyze a specific GitHub issue against the indexed code graph\nresult = cs.analyze_issue(\"owner\", \"repo\", 1234, topk=10)\nprint(result.format_report())\n```\n\nThis:\n1. Fetches the issue from GitHub (or loads from cache)\n2. Parses file paths, function names, and stack traces from the issue body\n3. Matches extracted paths to File nodes in the graph\n4. Uses semantic search (`cross_locate`) to find related code\n5. Traces callers of mentioned functions via `impact()`\n6. Ranks and returns root cause candidates with explanation\n\n#### Batch Bug Analysis\n\n```python\n# Analyze top-k bug issues and get aggregated hotspot data\nresults = cs.analyze_top_bugs(\"owner\", \"repo\", k=10, label=\"bug\")\nfor r in results:\n    print(f\"#{r.issue.number}: {r.issue.title}\")\n    for c in r.candidates[:3]:\n        print(f\"  {c.function_name} ({c.file_path}) score={c.score:.2f}\")\n```\n\n#### CLI Commands\n\n```bash\n# Fetch and parse a single issue (no graph needed)\ncodegraph fetch-issue owner repo 1234\n\n# Fetch top-k bugs from a repo\ncodegraph fetch-bugs owner repo --top 10 --label bug\n\n# Analyze a single bug against the code graph\ncodegraph analyze-bug owner repo 1234 --db .codegraph --topk 10\n\n# Batch analyze top bugs\ncodegraph analyze-bugs owner repo --db .codegraph --top 10 --label bug\n```\n\n#### Lower-Level Components\n\nFor custom analysis pipelines, the components can be used individually:\n\n```python\nfrom codegraph.issue_fetcher import fetch_and_parse_issue\nfrom codegraph.bug_locator import (\n    resolve_paths_to_files,\n    find_semantic_matches,\n    trace_callers,\n    rank_root_causes,\n    analyze_bug,\n)\n\n# Fetch and parse (with caching)\nissue = fetch_and_parse_issue(\"owner\", \"repo\", 1234)\nprint(issue.extracted_paths)   # file paths found in body\nprint(issue.extracted_funcs)   # function names from stack traces\nprint(issue.linked_commits)    # merge commit SHAs from linked PRs\n\n# Match paths to graph nodes\npath_matches = resolve_paths_to_files(cs, issue.extracted_paths)\n\n# Semantic search using issue description\nsemantic_matches = find_semantic_matches(cs, f\"{issue.title}\\n{issue.body}\")\n\n# Trace callers of mentioned functions\ncaller_traces = trace_callers(cs, issue.extracted_funcs, max_hops=2)\n\n# Combine into ranked candidates\ncandidates = rank_root_causes(path_matches, semantic_matches, caller_traces, issue.extracted_funcs)\n```\n\n### Scoring System\n\nRoot cause candidates are scored by combining multiple signals:\n\n| Signal | Score | Description |\n|--------|-------|-------------|\n| Direct mention | +1.0 | Function name appears in issue body\u002Fstack trace |\n| File path match | +0.8 | Function is in a file mentioned in the issue |\n| Semantic match | +score | Raw cosine similarity (0.0-1.0) from `cross_locate` |\n| Caller relationship | +0.5\u002Fhops | Function calls a mentioned function (decays with distance) |\n\n### Issue Cache\n\nParsed issues are cached at `~\u002F.codegraph\u002Fissue_cache\u002F{owner}_{repo}_{number}.json`. Cache hits skip the GitHub API call entirely (sub-millisecond). To force a refresh, pass `use_cache=False` or use `--no-cache` on CLI.\n\n```python\nfrom codegraph.issue_cache import clear_cache\nclear_cache(owner=\"openclaw\", repo=\"openclaw\")  # clear specific repo\nclear_cache()  # clear all\n```\n\n### Stack Trace Parsing\n\nThe parser automatically extracts file paths and function names from stack traces in Python, C\u002FC++, JavaScript\u002FNode.js, Go, and Rust formats. It also extracts `func_name()` references in backticks and inline code.\n\n## How to Route Questions\n\nThe key decision is: **does the user want an exact structural answer, a fuzzy semantic one, or a bug-to-code mapping?**\n\n| User asks... | Best approach |\n|-------------|---------------|\n| \"Who calls `free_irq`?\" | Cypher: `MATCH (c:Function)-[:CALLS]->(f:Function {name: 'free_irq'}) RETURN c.name, c.file_path` |\n| \"Find functions related to memory allocation\" | `cs.vector_only_search(\"memory allocation\")` or `cs.cross_locate(\"memory allocation\")` |\n| \"What's the most complex function?\" | `cs.hotspots(topk=1)` |\n| \"Is there dead code in the networking stack?\" | `cs.dead_code()` then filter by file path |\n| \"How has `schedule()` changed recently?\" | `cs.change_attribution(\"schedule\", \"kernel\u002Fsched\u002Fcore.c\")` |\n| \"Which modules are tightly coupled?\" | `cs.module_coupling(topk=20)` |\n| \"Generate a full architecture report\" | `codegraph analyze` or `generate_report(cs)` |\n| \"What's the architectural role of `mm\u002F`?\" | `cs.layer_discovery()` then find `mm` entries |\n| \"Which functions act as API boundaries?\" | `cs.bridge_functions(topk=30)` |\n| \"Find commits about fixing race conditions\" | `cs.intent_search(\"fix race condition\")` |\n| \"What functions are always changed together with `kmalloc`?\" | `cs.co_change(\"kmalloc\")` |\n| \"Why does this project have so many bugs?\" | `cs.analyze_top_bugs(\"owner\", \"repo\", k=10)` then aggregate hotspots |\n| \"Analyze issue #1234 from GitHub\" | `cs.analyze_issue(\"owner\", \"repo\", 1234)` |\n| \"What code is related to this bug?\" | `cs.analyze_issue(...)` or manual `cross_locate(bug_description)` |\n| \"Find the root cause of the crash in issue #42\" | `cs.analyze_issue(\"owner\", \"repo\", 42)` |\n| \"Which modules have the most bugs?\" | `cs.analyze_top_bugs(...)` then aggregate by file\u002Fmodule |\n| \"Index this Java project\" | `codegraph init --repo . --lang java` |\n| \"What classes extend FileSystem in Hadoop?\" | Cypher: `MATCH (c:Class)-[:INHERITS]->(p:Class {name: 'FileSystem'}) RETURN c.name, c.file_path` |\n| \"Find all constructors called in this module\" | Cypher: `MATCH (f:Function)-[:CALLS]->(init:Function {name: '\u003Cinit>'}) WHERE f.file_path CONTAINS 'module' RETURN ...` |\n\nFor **novel investigations** not covered by pre-built methods, compose raw Cypher queries. See [patterns.md](.\u002Fpatterns.md) for templates. For bug analysis patterns, see [bug-analysis.md](.\u002Fbug-analysis.md).\n\n## Important Filters for Cypher\n\nWhen writing Cypher queries, these filters prevent misleading results:\n\n- **`f.is_historical = 0`** — exclude deleted\u002Frenamed functions that are still in the graph as historical records\n- **`f.is_external = 0`** (on File nodes) — exclude system headers\u002Flibrary files\n- **`c.version_tag = 'bf'`** — only backfilled commits have `MODIFIES` edges; non-backfilled commits only have `TOUCHES` (file-level) edges\n- **Always use `LIMIT`** — large codebases can return hundreds of thousands of rows\n\n## Checking Data Availability\n\nBefore running evolution queries, check what's available:\n\n```python\n# How many commits are indexed?\nlist(cs.conn.execute(\"MATCH (c:Commit) RETURN count(c)\"))\n\n# How many have MODIFIES edges (backfilled)?\nlist(cs.conn.execute(\"MATCH (c:Commit) WHERE c.version_tag = 'bf' RETURN count(c)\"))\n```\n\nIf no commits exist, evolution methods will return empty results — guide the user to run `codegraph ingest` first. If commits exist but aren't backfilled, `TOUCHES` (file-level) queries still work but `MODIFIES` (function-level) queries won't.\n\n## Troubleshooting\n\n| Error | Cause | Fix |\n|-------|-------|-----|\n| `Database locked` | Crashed process left neug lock | `rm \u003Cdb>\u002Fgraph.db\u002Fneugdb.lock` |\n| `Can't open lock file` | zvec LOCK file deleted | `touch \u003Cdb>\u002Fvectors\u002FLOCK` |\n| `Can't lock read-write collection` | Another process holds lock | Kill the other process |\n| `recovery idmap failed` | Stale WAL files | Remove empty `.log` files from `\u003Cdb>\u002Fvectors\u002Fidmap.0\u002F` |\n\nThe CLI auto-cleans lock issues on startup when possible.\n\n## References\n\n- **[schema.md](.\u002Fschema.md)** — Full graph schema: node types, edge types, properties, Cypher syntax notes\n- **[patterns.md](.\u002Fpatterns.md)** — Ready-to-use Cypher query templates and composition strategies\n- **[bug-analysis.md](.\u002Fbug-analysis.md)** — Bug analysis workflows: single issue, batch analysis, hotspot aggregation, custom pipelines\n",{"data":41,"body":42},{"name":4,"description":6},{"type":43,"children":44},"root",[45,54,96,103,172,178,185,219,225,390,396,426,431,481,527,572,578,588,645,655,785,790,796,802,807,892,898,1071,1077,1148,1161,1266,1272,1295,1300,1328,1333,1339,1344,1350,1672,1678,1722,1735,1770,1776,1852,1858,2006,2012,2017,2023,2049,2055,2062,2093,2098,2146,2152,2207,2213,2428,2434,2439,2657,2663,2668,2772,2778,2807,2838,2844,2857,2863,2873,3289,3317,3323,3328,3404,3410,3415,3461,3488,3494,3631,3636,3642,3683],{"type":46,"tag":47,"props":48,"children":50},"element","h1",{"id":49},"codescope-qa",[51],{"type":52,"value":53},"text","CodeScope Q&A",{"type":46,"tag":55,"props":56,"children":57},"p",{},[58,60,66,68,73,75,80,82,87,89,94],{"type":52,"value":59},"CodeScope indexes source code into a two-layer knowledge graph — ",{"type":46,"tag":61,"props":62,"children":63},"strong",{},[64],{"type":52,"value":65},"structure",{"type":52,"value":67}," (functions, calls, imports, classes, modules) and ",{"type":46,"tag":61,"props":69,"children":70},{},[71],{"type":52,"value":72},"evolution",{"type":52,"value":74}," (commits, file changes, function modifications) — plus ",{"type":46,"tag":61,"props":76,"children":77},{},[78],{"type":52,"value":79},"semantic embeddings",{"type":52,"value":81}," for every function. Supports ",{"type":46,"tag":61,"props":83,"children":84},{},[85],{"type":52,"value":86},"Python, JavaScript\u002FTypeScript, C, and Java",{"type":52,"value":88}," (including Hadoop-scale repositories with 8K+ files). This combination enables analyses that grep, LSP, or pure vector search cannot do alone. It can also ",{"type":46,"tag":61,"props":90,"children":91},{},[92],{"type":52,"value":93},"fetch GitHub issues and trace bugs to code",{"type":52,"value":95}," — mapping bug reports to root cause candidates using the graph + vector infrastructure.",{"type":46,"tag":97,"props":98,"children":100},"h2",{"id":99},"when-to-use-this-skill",[101],{"type":52,"value":102},"When to Use This Skill",{"type":46,"tag":104,"props":105,"children":106},"ul",{},[107,113,118,123,128,133,138,143,148,153,158],{"type":46,"tag":108,"props":109,"children":110},"li",{},[111],{"type":52,"value":112},"User asks about call chains, callers, callees, or dependencies",{"type":46,"tag":108,"props":114,"children":115},{},[116],{"type":52,"value":117},"User wants to find dead code, hotspots, or architectural layers",{"type":46,"tag":108,"props":119,"children":120},{},[121],{"type":52,"value":122},"User asks about code history, who changed what, or why something was modified",{"type":46,"tag":108,"props":124,"children":125},{},[126],{"type":52,"value":127},"User wants to find semantically similar functions across a codebase",{"type":46,"tag":108,"props":129,"children":130},{},[131],{"type":52,"value":132},"User wants a full architecture analysis or report",{"type":46,"tag":108,"props":134,"children":135},{},[136],{"type":52,"value":137},"User asks about module coupling, circular dependencies, or bridge functions",{"type":46,"tag":108,"props":139,"children":140},{},[141],{"type":52,"value":142},"User wants to index or analyze a Java project (Maven, Gradle, plain Java)",{"type":46,"tag":108,"props":144,"children":145},{},[146],{"type":52,"value":147},"User wants to analyze GitHub issues or bug reports to find root causes",{"type":46,"tag":108,"props":149,"children":150},{},[151],{"type":52,"value":152},"User asks \"why does this project have so many bugs\" or \"what code is most buggy\"",{"type":46,"tag":108,"props":154,"children":155},{},[156],{"type":52,"value":157},"User wants to trace a bug report to the most relevant code locations",{"type":46,"tag":108,"props":159,"children":160},{},[161,163,170],{"type":52,"value":162},"A ",{"type":46,"tag":164,"props":165,"children":167},"code",{"className":166},[],[168],{"type":52,"value":169},".codegraph",{"type":52,"value":171}," directory (or similar index) exists in the workspace",{"type":46,"tag":97,"props":173,"children":175},{"id":174},"getting-started",[176],{"type":52,"value":177},"Getting Started",{"type":46,"tag":179,"props":180,"children":182},"h3",{"id":181},"installation",[183],{"type":52,"value":184},"Installation",{"type":46,"tag":186,"props":187,"children":192},"pre",{"className":188,"code":189,"language":190,"meta":191,"style":191},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","pip install codegraph-ai\n","bash","",[193],{"type":46,"tag":164,"props":194,"children":195},{"__ignoreMap":191},[196],{"type":46,"tag":197,"props":198,"children":201},"span",{"class":199,"line":200},"line",1,[202,208,214],{"type":46,"tag":197,"props":203,"children":205},{"style":204},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[206],{"type":52,"value":207},"pip",{"type":46,"tag":197,"props":209,"children":211},{"style":210},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[212],{"type":52,"value":213}," install",{"type":46,"tag":197,"props":215,"children":216},{"style":210},[217],{"type":52,"value":218}," codegraph-ai\n",{"type":46,"tag":179,"props":220,"children":222},{"id":221},"environment-variables-optional",[223],{"type":52,"value":224},"Environment Variables (optional)",{"type":46,"tag":186,"props":226,"children":228},{"className":188,"code":227,"language":190,"meta":191,"style":191},"# Create Python virtural environment\npython -m venv .venv\n\nsource .venv\u002Fbin\u002Factivate\n\n# Point to a pre-built database (skip indexing)\nexport CODESCOPE_DB_DIR=\"\u002Fpath\u002Fto\u002F.linux_db\"\n\n# Offline mode for HuggingFace models\nexport HF_HUB_OFFLINE=\"1\"\n",[229],{"type":46,"tag":164,"props":230,"children":231},{"__ignoreMap":191},[232,241,264,274,289,297,306,343,351,360],{"type":46,"tag":197,"props":233,"children":234},{"class":199,"line":200},[235],{"type":46,"tag":197,"props":236,"children":238},{"style":237},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[239],{"type":52,"value":240},"# Create Python virtural environment\n",{"type":46,"tag":197,"props":242,"children":244},{"class":199,"line":243},2,[245,249,254,259],{"type":46,"tag":197,"props":246,"children":247},{"style":204},[248],{"type":52,"value":25},{"type":46,"tag":197,"props":250,"children":251},{"style":210},[252],{"type":52,"value":253}," -m",{"type":46,"tag":197,"props":255,"children":256},{"style":210},[257],{"type":52,"value":258}," venv",{"type":46,"tag":197,"props":260,"children":261},{"style":210},[262],{"type":52,"value":263}," .venv\n",{"type":46,"tag":197,"props":265,"children":267},{"class":199,"line":266},3,[268],{"type":46,"tag":197,"props":269,"children":271},{"emptyLinePlaceholder":270},true,[272],{"type":52,"value":273},"\n",{"type":46,"tag":197,"props":275,"children":277},{"class":199,"line":276},4,[278,284],{"type":46,"tag":197,"props":279,"children":281},{"style":280},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[282],{"type":52,"value":283},"source",{"type":46,"tag":197,"props":285,"children":286},{"style":210},[287],{"type":52,"value":288}," .venv\u002Fbin\u002Factivate\n",{"type":46,"tag":197,"props":290,"children":292},{"class":199,"line":291},5,[293],{"type":46,"tag":197,"props":294,"children":295},{"emptyLinePlaceholder":270},[296],{"type":52,"value":273},{"type":46,"tag":197,"props":298,"children":300},{"class":199,"line":299},6,[301],{"type":46,"tag":197,"props":302,"children":303},{"style":237},[304],{"type":52,"value":305},"# Point to a pre-built database (skip indexing)\n",{"type":46,"tag":197,"props":307,"children":309},{"class":199,"line":308},7,[310,316,322,328,333,338],{"type":46,"tag":197,"props":311,"children":313},{"style":312},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[314],{"type":52,"value":315},"export",{"type":46,"tag":197,"props":317,"children":319},{"style":318},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[320],{"type":52,"value":321}," CODESCOPE_DB_DIR",{"type":46,"tag":197,"props":323,"children":325},{"style":324},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[326],{"type":52,"value":327},"=",{"type":46,"tag":197,"props":329,"children":330},{"style":324},[331],{"type":52,"value":332},"\"",{"type":46,"tag":197,"props":334,"children":335},{"style":210},[336],{"type":52,"value":337},"\u002Fpath\u002Fto\u002F.linux_db",{"type":46,"tag":197,"props":339,"children":340},{"style":324},[341],{"type":52,"value":342},"\"\n",{"type":46,"tag":197,"props":344,"children":346},{"class":199,"line":345},8,[347],{"type":46,"tag":197,"props":348,"children":349},{"emptyLinePlaceholder":270},[350],{"type":52,"value":273},{"type":46,"tag":197,"props":352,"children":354},{"class":199,"line":353},9,[355],{"type":46,"tag":197,"props":356,"children":357},{"style":237},[358],{"type":52,"value":359},"# Offline mode for HuggingFace models\n",{"type":46,"tag":197,"props":361,"children":363},{"class":199,"line":362},10,[364,368,373,377,381,386],{"type":46,"tag":197,"props":365,"children":366},{"style":312},[367],{"type":52,"value":315},{"type":46,"tag":197,"props":369,"children":370},{"style":318},[371],{"type":52,"value":372}," HF_HUB_OFFLINE",{"type":46,"tag":197,"props":374,"children":375},{"style":324},[376],{"type":52,"value":327},{"type":46,"tag":197,"props":378,"children":379},{"style":324},[380],{"type":52,"value":332},{"type":46,"tag":197,"props":382,"children":383},{"style":210},[384],{"type":52,"value":385},"1",{"type":46,"tag":197,"props":387,"children":388},{"style":324},[389],{"type":52,"value":342},{"type":46,"tag":179,"props":391,"children":393},{"id":392},"check-index-status",[394],{"type":52,"value":395},"Check Index Status",{"type":46,"tag":186,"props":397,"children":399},{"className":188,"code":398,"language":190,"meta":191,"style":191},"codegraph status --db $CODESCOPE_DB_DIR\n",[400],{"type":46,"tag":164,"props":401,"children":402},{"__ignoreMap":191},[403],{"type":46,"tag":197,"props":404,"children":405},{"class":199,"line":200},[406,411,416,421],{"type":46,"tag":197,"props":407,"children":408},{"style":204},[409],{"type":52,"value":410},"codegraph",{"type":46,"tag":197,"props":412,"children":413},{"style":210},[414],{"type":52,"value":415}," status",{"type":46,"tag":197,"props":417,"children":418},{"style":210},[419],{"type":52,"value":420}," --db",{"type":46,"tag":197,"props":422,"children":423},{"style":318},[424],{"type":52,"value":425}," $CODESCOPE_DB_DIR\n",{"type":46,"tag":55,"props":427,"children":428},{},[429],{"type":52,"value":430},"If no index exists, create one:",{"type":46,"tag":186,"props":432,"children":434},{"className":188,"code":433,"language":190,"meta":191,"style":191},"codegraph init --repo . --lang auto --commits 500\n",[435],{"type":46,"tag":164,"props":436,"children":437},{"__ignoreMap":191},[438],{"type":46,"tag":197,"props":439,"children":440},{"class":199,"line":200},[441,445,450,455,460,465,470,475],{"type":46,"tag":197,"props":442,"children":443},{"style":204},[444],{"type":52,"value":410},{"type":46,"tag":197,"props":446,"children":447},{"style":210},[448],{"type":52,"value":449}," init",{"type":46,"tag":197,"props":451,"children":452},{"style":210},[453],{"type":52,"value":454}," --repo",{"type":46,"tag":197,"props":456,"children":457},{"style":210},[458],{"type":52,"value":459}," .",{"type":46,"tag":197,"props":461,"children":462},{"style":210},[463],{"type":52,"value":464}," --lang",{"type":46,"tag":197,"props":466,"children":467},{"style":210},[468],{"type":52,"value":469}," auto",{"type":46,"tag":197,"props":471,"children":472},{"style":210},[473],{"type":52,"value":474}," --commits",{"type":46,"tag":197,"props":476,"children":478},{"style":477},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[479],{"type":52,"value":480}," 500\n",{"type":46,"tag":55,"props":482,"children":483},{},[484,486,491,493,499,500,505,506,511,512,517,519,525],{"type":52,"value":485},"Supported languages: ",{"type":46,"tag":164,"props":487,"children":489},{"className":488},[],[490],{"type":52,"value":25},{"type":52,"value":492},", ",{"type":46,"tag":164,"props":494,"children":496},{"className":495},[],[497],{"type":52,"value":498},"c",{"type":52,"value":492},{"type":46,"tag":164,"props":501,"children":503},{"className":502},[],[504],{"type":52,"value":22},{"type":52,"value":492},{"type":46,"tag":164,"props":507,"children":509},{"className":508},[],[510],{"type":52,"value":19},{"type":52,"value":492},{"type":46,"tag":164,"props":513,"children":515},{"className":514},[],[516],{"type":52,"value":15},{"type":52,"value":518},", or ",{"type":46,"tag":164,"props":520,"children":522},{"className":521},[],[523],{"type":52,"value":524},"auto",{"type":52,"value":526}," (auto-detects from file extensions).",{"type":46,"tag":55,"props":528,"children":529},{},[530,532,538,540,546,548,554,556,562,564,570],{"type":52,"value":531},"The ",{"type":46,"tag":164,"props":533,"children":535},{"className":534},[],[536],{"type":52,"value":537},"--commits",{"type":52,"value":539}," flag ingests git history (for evolution queries). Without it, only structural analysis is available. Add ",{"type":46,"tag":164,"props":541,"children":543},{"className":542},[],[544],{"type":52,"value":545},"--backfill-limit 200",{"type":52,"value":547}," to also compute function-level ",{"type":46,"tag":164,"props":549,"children":551},{"className":550},[],[552],{"type":52,"value":553},"MODIFIES",{"type":52,"value":555}," edges (slower but enables ",{"type":46,"tag":164,"props":557,"children":559},{"className":558},[],[560],{"type":52,"value":561},"change_attribution",{"type":52,"value":563}," and ",{"type":46,"tag":164,"props":565,"children":567},{"className":566},[],[568],{"type":52,"value":569},"co_change",{"type":52,"value":571},").",{"type":46,"tag":97,"props":573,"children":575},{"id":574},"two-interfaces-cli-vs-python",[576],{"type":52,"value":577},"Two Interfaces: CLI vs Python",{"type":46,"tag":55,"props":579,"children":580},{},[581,586],{"type":46,"tag":61,"props":582,"children":583},{},[584],{"type":52,"value":585},"Use the CLI",{"type":52,"value":587}," for status and reports:",{"type":46,"tag":186,"props":589,"children":591},{"className":188,"code":590,"language":190,"meta":191,"style":191},"codegraph status --db $CODESCOPE_DB_DIR\ncodegraph analyze --db $CODESCOPE_DB_DIR --output report.md\n",[592],{"type":46,"tag":164,"props":593,"children":594},{"__ignoreMap":191},[595,614],{"type":46,"tag":197,"props":596,"children":597},{"class":199,"line":200},[598,602,606,610],{"type":46,"tag":197,"props":599,"children":600},{"style":204},[601],{"type":52,"value":410},{"type":46,"tag":197,"props":603,"children":604},{"style":210},[605],{"type":52,"value":415},{"type":46,"tag":197,"props":607,"children":608},{"style":210},[609],{"type":52,"value":420},{"type":46,"tag":197,"props":611,"children":612},{"style":318},[613],{"type":52,"value":425},{"type":46,"tag":197,"props":615,"children":616},{"class":199,"line":243},[617,621,626,630,635,640],{"type":46,"tag":197,"props":618,"children":619},{"style":204},[620],{"type":52,"value":410},{"type":46,"tag":197,"props":622,"children":623},{"style":210},[624],{"type":52,"value":625}," analyze",{"type":46,"tag":197,"props":627,"children":628},{"style":210},[629],{"type":52,"value":420},{"type":46,"tag":197,"props":631,"children":632},{"style":318},[633],{"type":52,"value":634}," $CODESCOPE_DB_DIR ",{"type":46,"tag":197,"props":636,"children":637},{"style":210},[638],{"type":52,"value":639},"--output",{"type":46,"tag":197,"props":641,"children":642},{"style":210},[643],{"type":52,"value":644}," report.md\n",{"type":46,"tag":55,"props":646,"children":647},{},[648,653],{"type":46,"tag":61,"props":649,"children":650},{},[651],{"type":52,"value":652},"Use the Python API",{"type":52,"value":654}," for queries and custom analyses:",{"type":46,"tag":186,"props":656,"children":659},{"className":657,"code":658,"language":25,"meta":191,"style":191},"language-python shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import os\nos.environ['HF_HUB_OFFLINE'] = '1'  # required\n\nfrom codegraph.core import CodeScope\ncs = CodeScope(os.environ['CODESCOPE_DB_DIR'])\n\n# Cypher query\nrows = list(cs.conn.execute('''\n    MATCH (caller:Function)-[:CALLS]->(f:Function {name: \"free_irq\"})\n    RETURN caller.name, caller.file_path LIMIT 10\n'''))\nfor r in rows:\n    print(r)\n\ncs.close()  # always close when done\n",[660],{"type":46,"tag":164,"props":661,"children":662},{"__ignoreMap":191},[663,671,679,686,694,702,709,717,725,733,741,750,759,768,776],{"type":46,"tag":197,"props":664,"children":665},{"class":199,"line":200},[666],{"type":46,"tag":197,"props":667,"children":668},{},[669],{"type":52,"value":670},"import os\n",{"type":46,"tag":197,"props":672,"children":673},{"class":199,"line":243},[674],{"type":46,"tag":197,"props":675,"children":676},{},[677],{"type":52,"value":678},"os.environ['HF_HUB_OFFLINE'] = '1'  # required\n",{"type":46,"tag":197,"props":680,"children":681},{"class":199,"line":266},[682],{"type":46,"tag":197,"props":683,"children":684},{"emptyLinePlaceholder":270},[685],{"type":52,"value":273},{"type":46,"tag":197,"props":687,"children":688},{"class":199,"line":276},[689],{"type":46,"tag":197,"props":690,"children":691},{},[692],{"type":52,"value":693},"from codegraph.core import CodeScope\n",{"type":46,"tag":197,"props":695,"children":696},{"class":199,"line":291},[697],{"type":46,"tag":197,"props":698,"children":699},{},[700],{"type":52,"value":701},"cs = CodeScope(os.environ['CODESCOPE_DB_DIR'])\n",{"type":46,"tag":197,"props":703,"children":704},{"class":199,"line":299},[705],{"type":46,"tag":197,"props":706,"children":707},{"emptyLinePlaceholder":270},[708],{"type":52,"value":273},{"type":46,"tag":197,"props":710,"children":711},{"class":199,"line":308},[712],{"type":46,"tag":197,"props":713,"children":714},{},[715],{"type":52,"value":716},"# Cypher query\n",{"type":46,"tag":197,"props":718,"children":719},{"class":199,"line":345},[720],{"type":46,"tag":197,"props":721,"children":722},{},[723],{"type":52,"value":724},"rows = list(cs.conn.execute('''\n",{"type":46,"tag":197,"props":726,"children":727},{"class":199,"line":353},[728],{"type":46,"tag":197,"props":729,"children":730},{},[731],{"type":52,"value":732},"    MATCH (caller:Function)-[:CALLS]->(f:Function {name: \"free_irq\"})\n",{"type":46,"tag":197,"props":734,"children":735},{"class":199,"line":362},[736],{"type":46,"tag":197,"props":737,"children":738},{},[739],{"type":52,"value":740},"    RETURN caller.name, caller.file_path LIMIT 10\n",{"type":46,"tag":197,"props":742,"children":744},{"class":199,"line":743},11,[745],{"type":46,"tag":197,"props":746,"children":747},{},[748],{"type":52,"value":749},"'''))\n",{"type":46,"tag":197,"props":751,"children":753},{"class":199,"line":752},12,[754],{"type":46,"tag":197,"props":755,"children":756},{},[757],{"type":52,"value":758},"for r in rows:\n",{"type":46,"tag":197,"props":760,"children":762},{"class":199,"line":761},13,[763],{"type":46,"tag":197,"props":764,"children":765},{},[766],{"type":52,"value":767},"    print(r)\n",{"type":46,"tag":197,"props":769,"children":771},{"class":199,"line":770},14,[772],{"type":46,"tag":197,"props":773,"children":774},{"emptyLinePlaceholder":270},[775],{"type":52,"value":273},{"type":46,"tag":197,"props":777,"children":779},{"class":199,"line":778},15,[780],{"type":46,"tag":197,"props":781,"children":782},{},[783],{"type":52,"value":784},"cs.close()  # always close when done\n",{"type":46,"tag":55,"props":786,"children":787},{},[788],{"type":52,"value":789},"The Python API is more powerful — it gives you raw Cypher access and lets you chain queries.",{"type":46,"tag":97,"props":791,"children":793},{"id":792},"core-python-api",[794],{"type":52,"value":795},"Core Python API",{"type":46,"tag":179,"props":797,"children":799},{"id":798},"raw-queries",[800],{"type":52,"value":801},"Raw Queries",{"type":46,"tag":55,"props":803,"children":804},{},[805],{"type":52,"value":806},"These are the building blocks for any custom analysis:",{"type":46,"tag":808,"props":809,"children":810},"table",{},[811,830],{"type":46,"tag":812,"props":813,"children":814},"thead",{},[815],{"type":46,"tag":816,"props":817,"children":818},"tr",{},[819,825],{"type":46,"tag":820,"props":821,"children":822},"th",{},[823],{"type":52,"value":824},"Method",{"type":46,"tag":820,"props":826,"children":827},{},[828],{"type":52,"value":829},"What it does",{"type":46,"tag":831,"props":832,"children":833},"tbody",{},[834,852,875],{"type":46,"tag":816,"props":835,"children":836},{},[837,847],{"type":46,"tag":838,"props":839,"children":840},"td",{},[841],{"type":46,"tag":164,"props":842,"children":844},{"className":843},[],[845],{"type":52,"value":846},"cs.conn.execute(cypher)",{"type":46,"tag":838,"props":848,"children":849},{},[850],{"type":52,"value":851},"Run any Cypher query against the graph — returns list of tuples",{"type":46,"tag":816,"props":853,"children":854},{},[855,864],{"type":46,"tag":838,"props":856,"children":857},{},[858],{"type":46,"tag":164,"props":859,"children":861},{"className":860},[],[862],{"type":52,"value":863},"cs.vector_only_search(query, topk=10)",{"type":46,"tag":838,"props":865,"children":866},{},[867,869],{"type":52,"value":868},"Semantic search over all function embeddings — returns ",{"type":46,"tag":164,"props":870,"children":872},{"className":871},[],[873],{"type":52,"value":874},"[{id, score}]",{"type":46,"tag":816,"props":876,"children":877},{},[878,887],{"type":46,"tag":838,"props":879,"children":880},{},[881],{"type":46,"tag":164,"props":882,"children":884},{"className":883},[],[885],{"type":52,"value":886},"cs.summary()",{"type":46,"tag":838,"props":888,"children":889},{},[890],{"type":52,"value":891},"Print a human-readable overview of the indexed codebase",{"type":46,"tag":179,"props":893,"children":895},{"id":894},"structural-analysis",[896],{"type":52,"value":897},"Structural Analysis",{"type":46,"tag":808,"props":899,"children":900},{},[901,915],{"type":46,"tag":812,"props":902,"children":903},{},[904],{"type":46,"tag":816,"props":905,"children":906},{},[907,911],{"type":46,"tag":820,"props":908,"children":909},{},[910],{"type":52,"value":824},{"type":46,"tag":820,"props":912,"children":913},{},[914],{"type":52,"value":829},{"type":46,"tag":831,"props":916,"children":917},{},[918,935,952,969,986,1003,1020,1037,1054],{"type":46,"tag":816,"props":919,"children":920},{},[921,930],{"type":46,"tag":838,"props":922,"children":923},{},[924],{"type":46,"tag":164,"props":925,"children":927},{"className":926},[],[928],{"type":52,"value":929},"cs.impact(func_name, change_desc, max_hops=3)",{"type":46,"tag":838,"props":931,"children":932},{},[933],{"type":52,"value":934},"Find callers up to N hops, ranked by semantic relevance to the change",{"type":46,"tag":816,"props":936,"children":937},{},[938,947],{"type":46,"tag":838,"props":939,"children":940},{},[941],{"type":46,"tag":164,"props":942,"children":944},{"className":943},[],[945],{"type":52,"value":946},"cs.hotspots(topk=10)",{"type":46,"tag":838,"props":948,"children":949},{},[950],{"type":52,"value":951},"Rank functions by structural risk (fan-in × fan-out)",{"type":46,"tag":816,"props":953,"children":954},{},[955,964],{"type":46,"tag":838,"props":956,"children":957},{},[958],{"type":46,"tag":164,"props":959,"children":961},{"className":960},[],[962],{"type":52,"value":963},"cs.dead_code()",{"type":46,"tag":838,"props":965,"children":966},{},[967],{"type":52,"value":968},"Find functions with zero callers (excluding entry points)",{"type":46,"tag":816,"props":970,"children":971},{},[972,981],{"type":46,"tag":838,"props":973,"children":974},{},[975],{"type":46,"tag":164,"props":976,"children":978},{"className":977},[],[979],{"type":52,"value":980},"cs.circular_deps()",{"type":46,"tag":838,"props":982,"children":983},{},[984],{"type":52,"value":985},"Detect circular import chains at file level",{"type":46,"tag":816,"props":987,"children":988},{},[989,998],{"type":46,"tag":838,"props":990,"children":991},{},[992],{"type":46,"tag":164,"props":993,"children":995},{"className":994},[],[996],{"type":52,"value":997},"cs.module_coupling(topk=10)",{"type":46,"tag":838,"props":999,"children":1000},{},[1001],{"type":52,"value":1002},"Find cross-module coupling pairs with call counts",{"type":46,"tag":816,"props":1004,"children":1005},{},[1006,1015],{"type":46,"tag":838,"props":1007,"children":1008},{},[1009],{"type":46,"tag":164,"props":1010,"children":1012},{"className":1011},[],[1013],{"type":52,"value":1014},"cs.bridge_functions(topk=30)",{"type":46,"tag":838,"props":1016,"children":1017},{},[1018],{"type":52,"value":1019},"Find functions called from the most distinct modules",{"type":46,"tag":816,"props":1021,"children":1022},{},[1023,1032],{"type":46,"tag":838,"props":1024,"children":1025},{},[1026],{"type":46,"tag":164,"props":1027,"children":1029},{"className":1028},[],[1030],{"type":52,"value":1031},"cs.layer_discovery(topk=30)",{"type":46,"tag":838,"props":1033,"children":1034},{},[1035],{"type":52,"value":1036},"Auto-discover infrastructure \u002F mid \u002F consumer layers",{"type":46,"tag":816,"props":1038,"children":1039},{},[1040,1049],{"type":46,"tag":838,"props":1041,"children":1042},{},[1043],{"type":46,"tag":164,"props":1044,"children":1046},{"className":1045},[],[1047],{"type":52,"value":1048},"cs.stability_analysis(topk=50)",{"type":46,"tag":838,"props":1050,"children":1051},{},[1052],{"type":52,"value":1053},"Correlate fan-in with modification frequency",{"type":46,"tag":816,"props":1055,"children":1056},{},[1057,1066],{"type":46,"tag":838,"props":1058,"children":1059},{},[1060],{"type":46,"tag":164,"props":1061,"children":1063},{"className":1062},[],[1064],{"type":52,"value":1065},"cs.class_hierarchy(class_name=None)",{"type":46,"tag":838,"props":1067,"children":1068},{},[1069],{"type":52,"value":1070},"Return inheritance tree for a class (or all classes)",{"type":46,"tag":179,"props":1072,"children":1074},{"id":1073},"semantic-search",[1075],{"type":52,"value":1076},"Semantic Search",{"type":46,"tag":808,"props":1078,"children":1079},{},[1080,1094],{"type":46,"tag":812,"props":1081,"children":1082},{},[1083],{"type":46,"tag":816,"props":1084,"children":1085},{},[1086,1090],{"type":46,"tag":820,"props":1087,"children":1088},{},[1089],{"type":52,"value":824},{"type":46,"tag":820,"props":1091,"children":1092},{},[1093],{"type":52,"value":829},{"type":46,"tag":831,"props":1095,"children":1096},{},[1097,1114,1131],{"type":46,"tag":816,"props":1098,"children":1099},{},[1100,1109],{"type":46,"tag":838,"props":1101,"children":1102},{},[1103],{"type":46,"tag":164,"props":1104,"children":1106},{"className":1105},[],[1107],{"type":52,"value":1108},"cs.similar(function, scope, topk=10)",{"type":46,"tag":838,"props":1110,"children":1111},{},[1112],{"type":52,"value":1113},"Find functions similar to a given function within a module scope",{"type":46,"tag":816,"props":1115,"children":1116},{},[1117,1126],{"type":46,"tag":838,"props":1118,"children":1119},{},[1120],{"type":46,"tag":164,"props":1121,"children":1123},{"className":1122},[],[1124],{"type":52,"value":1125},"cs.cross_locate(query, topk=10)",{"type":46,"tag":838,"props":1127,"children":1128},{},[1129],{"type":52,"value":1130},"Find semantically related functions, then reveal call-chain connections",{"type":46,"tag":816,"props":1132,"children":1133},{},[1134,1143],{"type":46,"tag":838,"props":1135,"children":1136},{},[1137],{"type":46,"tag":164,"props":1138,"children":1140},{"className":1139},[],[1141],{"type":52,"value":1142},"cs.semantic_cross_pollination(query, topk=15)",{"type":46,"tag":838,"props":1144,"children":1145},{},[1146],{"type":52,"value":1147},"Find similar functions across distant subsystems",{"type":46,"tag":179,"props":1149,"children":1151},{"id":1150},"evolution-requires-commits-during-init",[1152,1154,1159],{"type":52,"value":1153},"Evolution (requires ",{"type":46,"tag":164,"props":1155,"children":1157},{"className":1156},[],[1158],{"type":52,"value":537},{"type":52,"value":1160}," during init)",{"type":46,"tag":808,"props":1162,"children":1163},{},[1164,1178],{"type":46,"tag":812,"props":1165,"children":1166},{},[1167],{"type":46,"tag":816,"props":1168,"children":1169},{},[1170,1174],{"type":46,"tag":820,"props":1171,"children":1172},{},[1173],{"type":52,"value":824},{"type":46,"tag":820,"props":1175,"children":1176},{},[1177],{"type":52,"value":829},{"type":46,"tag":831,"props":1179,"children":1180},{},[1181,1198,1215,1232,1249],{"type":46,"tag":816,"props":1182,"children":1183},{},[1184,1193],{"type":46,"tag":838,"props":1185,"children":1186},{},[1187],{"type":46,"tag":164,"props":1188,"children":1190},{"className":1189},[],[1191],{"type":52,"value":1192},"cs.change_attribution(func_name, file_path=None, limit=20)",{"type":46,"tag":838,"props":1194,"children":1195},{},[1196],{"type":52,"value":1197},"Which commits modified a function? (requires backfill)",{"type":46,"tag":816,"props":1199,"children":1200},{},[1201,1210],{"type":46,"tag":838,"props":1202,"children":1203},{},[1204],{"type":46,"tag":164,"props":1205,"children":1207},{"className":1206},[],[1208],{"type":52,"value":1209},"cs.co_change(func_name, file_path=None, min_commits=2, topk=10)",{"type":46,"tag":838,"props":1211,"children":1212},{},[1213],{"type":52,"value":1214},"Functions that are always modified together",{"type":46,"tag":816,"props":1216,"children":1217},{},[1218,1227],{"type":46,"tag":838,"props":1219,"children":1220},{},[1221],{"type":46,"tag":164,"props":1222,"children":1224},{"className":1223},[],[1225],{"type":52,"value":1226},"cs.intent_search(query, topk=10)",{"type":46,"tag":838,"props":1228,"children":1229},{},[1230],{"type":52,"value":1231},"Find commits matching a natural-language intent",{"type":46,"tag":816,"props":1233,"children":1234},{},[1235,1244],{"type":46,"tag":838,"props":1236,"children":1237},{},[1238],{"type":46,"tag":164,"props":1239,"children":1241},{"className":1240},[],[1242],{"type":52,"value":1243},"cs.commit_modularity(topk=20)",{"type":46,"tag":838,"props":1245,"children":1246},{},[1247],{"type":52,"value":1248},"Score commits by how many modules they touch",{"type":46,"tag":816,"props":1250,"children":1251},{},[1252,1261],{"type":46,"tag":838,"props":1253,"children":1254},{},[1255],{"type":46,"tag":164,"props":1256,"children":1258},{"className":1257},[],[1259],{"type":52,"value":1260},"cs.hot_cold_map(topk=30)",{"type":46,"tag":838,"props":1262,"children":1263},{},[1264],{"type":52,"value":1265},"Module modification density",{"type":46,"tag":179,"props":1267,"children":1269},{"id":1268},"report-generation",[1270],{"type":52,"value":1271},"Report Generation",{"type":46,"tag":186,"props":1273,"children":1275},{"className":657,"code":1274,"language":25,"meta":191,"style":191},"from codegraph.analyzer import generate_report\nreport = generate_report(cs)  # full architecture analysis as markdown\n",[1276],{"type":46,"tag":164,"props":1277,"children":1278},{"__ignoreMap":191},[1279,1287],{"type":46,"tag":197,"props":1280,"children":1281},{"class":199,"line":200},[1282],{"type":46,"tag":197,"props":1283,"children":1284},{},[1285],{"type":52,"value":1286},"from codegraph.analyzer import generate_report\n",{"type":46,"tag":197,"props":1288,"children":1289},{"class":199,"line":243},[1290],{"type":46,"tag":197,"props":1291,"children":1292},{},[1293],{"type":52,"value":1294},"report = generate_report(cs)  # full architecture analysis as markdown\n",{"type":46,"tag":55,"props":1296,"children":1297},{},[1298],{"type":52,"value":1299},"Or via CLI:",{"type":46,"tag":186,"props":1301,"children":1303},{"className":188,"code":1302,"language":190,"meta":191,"style":191},"codegraph analyze --output reports\u002Fanalysis.md\n",[1304],{"type":46,"tag":164,"props":1305,"children":1306},{"__ignoreMap":191},[1307],{"type":46,"tag":197,"props":1308,"children":1309},{"class":199,"line":200},[1310,1314,1318,1323],{"type":46,"tag":197,"props":1311,"children":1312},{"style":204},[1313],{"type":52,"value":410},{"type":46,"tag":197,"props":1315,"children":1316},{"style":210},[1317],{"type":52,"value":625},{"type":46,"tag":197,"props":1319,"children":1320},{"style":210},[1321],{"type":52,"value":1322}," --output",{"type":46,"tag":197,"props":1324,"children":1325},{"style":210},[1326],{"type":52,"value":1327}," reports\u002Fanalysis.md\n",{"type":46,"tag":55,"props":1329,"children":1330},{},[1331],{"type":52,"value":1332},"The report covers: overview stats, subsystem distribution, top modules, architectural layers (with Mermaid diagrams), bridge functions, fan-in\u002Ffan-out hotspots, cross-module coupling, evolution hotspots, and dead code density.",{"type":46,"tag":97,"props":1334,"children":1336},{"id":1335},"java-support",[1337],{"type":52,"value":1338},"Java Support",{"type":46,"tag":55,"props":1340,"children":1341},{},[1342],{"type":52,"value":1343},"CodeScope includes a full Java adapter that handles enterprise-scale repositories like Apache Hadoop (~8K files, ~97K functions indexed in ~3.5 minutes).",{"type":46,"tag":179,"props":1345,"children":1347},{"id":1346},"what-gets-indexed",[1348],{"type":52,"value":1349},"What Gets Indexed",{"type":46,"tag":808,"props":1351,"children":1352},{},[1353,1374],{"type":46,"tag":812,"props":1354,"children":1355},{},[1356],{"type":46,"tag":816,"props":1357,"children":1358},{},[1359,1364,1369],{"type":46,"tag":820,"props":1360,"children":1361},{},[1362],{"type":52,"value":1363},"Element",{"type":46,"tag":820,"props":1365,"children":1366},{},[1367],{"type":52,"value":1368},"Graph Node\u002FEdge",{"type":46,"tag":820,"props":1370,"children":1371},{},[1372],{"type":52,"value":1373},"Notes",{"type":46,"tag":831,"props":1375,"children":1376},{},[1377,1401,1437,1459,1482,1521,1551,1586,1610,1639],{"type":46,"tag":816,"props":1378,"children":1379},{},[1380,1385,1396],{"type":46,"tag":838,"props":1381,"children":1382},{},[1383],{"type":52,"value":1384},"Classes",{"type":46,"tag":838,"props":1386,"children":1387},{},[1388,1394],{"type":46,"tag":164,"props":1389,"children":1391},{"className":1390},[],[1392],{"type":52,"value":1393},"Class",{"type":52,"value":1395}," node",{"type":46,"tag":838,"props":1397,"children":1398},{},[1399],{"type":52,"value":1400},"Includes generics, annotations",{"type":46,"tag":816,"props":1402,"children":1403},{},[1404,1409,1418],{"type":46,"tag":838,"props":1405,"children":1406},{},[1407],{"type":52,"value":1408},"Interfaces",{"type":46,"tag":838,"props":1410,"children":1411},{},[1412,1417],{"type":46,"tag":164,"props":1413,"children":1415},{"className":1414},[],[1416],{"type":52,"value":1393},{"type":52,"value":1395},{"type":46,"tag":838,"props":1419,"children":1420},{},[1421,1427,1429,1435],{"type":46,"tag":164,"props":1422,"children":1424},{"className":1423},[],[1425],{"type":52,"value":1426},"extends",{"type":52,"value":1428}," → ",{"type":46,"tag":164,"props":1430,"children":1432},{"className":1431},[],[1433],{"type":52,"value":1434},"INHERITS",{"type":52,"value":1436}," edge",{"type":46,"tag":816,"props":1438,"children":1439},{},[1440,1445,1454],{"type":46,"tag":838,"props":1441,"children":1442},{},[1443],{"type":52,"value":1444},"Enums",{"type":46,"tag":838,"props":1446,"children":1447},{},[1448,1453],{"type":46,"tag":164,"props":1449,"children":1451},{"className":1450},[],[1452],{"type":52,"value":1393},{"type":52,"value":1395},{"type":46,"tag":838,"props":1455,"children":1456},{},[1457],{"type":52,"value":1458},"Enum methods extracted",{"type":46,"tag":816,"props":1460,"children":1461},{},[1462,1467,1477],{"type":46,"tag":838,"props":1463,"children":1464},{},[1465],{"type":52,"value":1466},"Methods",{"type":46,"tag":838,"props":1468,"children":1469},{},[1470,1476],{"type":46,"tag":164,"props":1471,"children":1473},{"className":1472},[],[1474],{"type":52,"value":1475},"Function",{"type":52,"value":1395},{"type":46,"tag":838,"props":1478,"children":1479},{},[1480],{"type":52,"value":1481},"Full generic signatures, JavaDoc",{"type":46,"tag":816,"props":1483,"children":1484},{},[1485,1490,1508],{"type":46,"tag":838,"props":1486,"children":1487},{},[1488],{"type":52,"value":1489},"Constructors",{"type":46,"tag":838,"props":1491,"children":1492},{},[1493,1498,1500,1506],{"type":46,"tag":164,"props":1494,"children":1496},{"className":1495},[],[1497],{"type":52,"value":1475},{"type":52,"value":1499}," node (name=",{"type":46,"tag":164,"props":1501,"children":1503},{"className":1502},[],[1504],{"type":52,"value":1505},"\u003Cinit>",{"type":52,"value":1507},")",{"type":46,"tag":838,"props":1509,"children":1510},{},[1511,1513,1519],{"type":52,"value":1512},"Including ",{"type":46,"tag":164,"props":1514,"children":1516},{"className":1515},[],[1517],{"type":52,"value":1518},"super()",{"type":52,"value":1520}," calls",{"type":46,"tag":816,"props":1522,"children":1523},{},[1524,1529,1539],{"type":46,"tag":838,"props":1525,"children":1526},{},[1527],{"type":52,"value":1528},"Method calls",{"type":46,"tag":838,"props":1530,"children":1531},{},[1532,1538],{"type":46,"tag":164,"props":1533,"children":1535},{"className":1534},[],[1536],{"type":52,"value":1537},"CALLS",{"type":52,"value":1436},{"type":46,"tag":838,"props":1540,"children":1541},{},[1542,1544,1550],{"type":52,"value":1543},"Receiver context preserved (",{"type":46,"tag":164,"props":1545,"children":1547},{"className":1546},[],[1548],{"type":52,"value":1549},"obj.method()",{"type":52,"value":1507},{"type":46,"tag":816,"props":1552,"children":1553},{},[1554,1565,1581],{"type":46,"tag":838,"props":1555,"children":1556},{},[1557,1563],{"type":46,"tag":164,"props":1558,"children":1560},{"className":1559},[],[1561],{"type":52,"value":1562},"new",{"type":52,"value":1564}," expressions",{"type":46,"tag":838,"props":1566,"children":1567},{},[1568,1573,1575],{"type":46,"tag":164,"props":1569,"children":1571},{"className":1570},[],[1572],{"type":52,"value":1537},{"type":52,"value":1574}," edge to ",{"type":46,"tag":164,"props":1576,"children":1578},{"className":1577},[],[1579],{"type":52,"value":1580},"ClassName.\u003Cinit>",{"type":46,"tag":838,"props":1582,"children":1583},{},[1584],{"type":52,"value":1585},"Constructor invocations",{"type":46,"tag":816,"props":1587,"children":1588},{},[1589,1594,1605],{"type":46,"tag":838,"props":1590,"children":1591},{},[1592],{"type":52,"value":1593},"Imports",{"type":46,"tag":838,"props":1595,"children":1596},{},[1597,1603],{"type":46,"tag":164,"props":1598,"children":1600},{"className":1599},[],[1601],{"type":52,"value":1602},"IMPORTS",{"type":52,"value":1604}," edge (file→file)",{"type":46,"tag":838,"props":1606,"children":1607},{},[1608],{"type":52,"value":1609},"Single, wildcard, static",{"type":46,"tag":816,"props":1611,"children":1612},{},[1613,1618,1634],{"type":46,"tag":838,"props":1614,"children":1615},{},[1616],{"type":52,"value":1617},"Inner classes",{"type":46,"tag":838,"props":1619,"children":1620},{},[1621,1626,1627,1633],{"type":46,"tag":164,"props":1622,"children":1624},{"className":1623},[],[1625],{"type":52,"value":1393},{"type":52,"value":1499},{"type":46,"tag":164,"props":1628,"children":1630},{"className":1629},[],[1631],{"type":52,"value":1632},"Outer.Inner",{"type":52,"value":1507},{"type":46,"tag":838,"props":1635,"children":1636},{},[1637],{"type":52,"value":1638},"Prefixed with outer class",{"type":46,"tag":816,"props":1640,"children":1641},{},[1642,1647,1656],{"type":46,"tag":838,"props":1643,"children":1644},{},[1645],{"type":52,"value":1646},"Inheritance",{"type":46,"tag":838,"props":1648,"children":1649},{},[1650,1655],{"type":46,"tag":164,"props":1651,"children":1653},{"className":1652},[],[1654],{"type":52,"value":1434},{"type":52,"value":1436},{"type":46,"tag":838,"props":1657,"children":1658},{},[1659,1664,1666],{"type":46,"tag":164,"props":1660,"children":1662},{"className":1661},[],[1663],{"type":52,"value":1426},{"type":52,"value":1665}," + ",{"type":46,"tag":164,"props":1667,"children":1669},{"className":1668},[],[1670],{"type":52,"value":1671},"implements",{"type":46,"tag":179,"props":1673,"children":1675},{"id":1674},"indexing-a-java-project",[1676],{"type":52,"value":1677},"Indexing a Java Project",{"type":46,"tag":186,"props":1679,"children":1681},{"className":188,"code":1680,"language":190,"meta":191,"style":191},"codegraph init --repo \u002Fpath\u002Fto\u002Fjava-project --lang java --commits 500\n",[1682],{"type":46,"tag":164,"props":1683,"children":1684},{"__ignoreMap":191},[1685],{"type":46,"tag":197,"props":1686,"children":1687},{"class":199,"line":200},[1688,1692,1696,1700,1705,1709,1714,1718],{"type":46,"tag":197,"props":1689,"children":1690},{"style":204},[1691],{"type":52,"value":410},{"type":46,"tag":197,"props":1693,"children":1694},{"style":210},[1695],{"type":52,"value":449},{"type":46,"tag":197,"props":1697,"children":1698},{"style":210},[1699],{"type":52,"value":454},{"type":46,"tag":197,"props":1701,"children":1702},{"style":210},[1703],{"type":52,"value":1704}," \u002Fpath\u002Fto\u002Fjava-project",{"type":46,"tag":197,"props":1706,"children":1707},{"style":210},[1708],{"type":52,"value":464},{"type":46,"tag":197,"props":1710,"children":1711},{"style":210},[1712],{"type":52,"value":1713}," java",{"type":46,"tag":197,"props":1715,"children":1716},{"style":210},[1717],{"type":52,"value":474},{"type":46,"tag":197,"props":1719,"children":1720},{"style":477},[1721],{"type":52,"value":480},{"type":46,"tag":55,"props":1723,"children":1724},{},[1725,1727,1733],{"type":52,"value":1726},"Or with auto-detection (auto-detects ",{"type":46,"tag":164,"props":1728,"children":1730},{"className":1729},[],[1731],{"type":52,"value":1732},".java",{"type":52,"value":1734}," files):",{"type":46,"tag":186,"props":1736,"children":1738},{"className":188,"code":1737,"language":190,"meta":191,"style":191},"codegraph init --repo \u002Fpath\u002Fto\u002Fjava-project --lang auto\n",[1739],{"type":46,"tag":164,"props":1740,"children":1741},{"__ignoreMap":191},[1742],{"type":46,"tag":197,"props":1743,"children":1744},{"class":199,"line":200},[1745,1749,1753,1757,1761,1765],{"type":46,"tag":197,"props":1746,"children":1747},{"style":204},[1748],{"type":52,"value":410},{"type":46,"tag":197,"props":1750,"children":1751},{"style":210},[1752],{"type":52,"value":449},{"type":46,"tag":197,"props":1754,"children":1755},{"style":210},[1756],{"type":52,"value":454},{"type":46,"tag":197,"props":1758,"children":1759},{"style":210},[1760],{"type":52,"value":1704},{"type":46,"tag":197,"props":1762,"children":1763},{"style":210},[1764],{"type":52,"value":464},{"type":46,"tag":197,"props":1766,"children":1767},{"style":210},[1768],{"type":52,"value":1769}," auto\n",{"type":46,"tag":179,"props":1771,"children":1773},{"id":1772},"java-specific-exclusions",[1774],{"type":52,"value":1775},"Java-Specific Exclusions",{"type":46,"tag":55,"props":1777,"children":1778},{},[1779,1781,1787,1788,1794,1795,1801,1802,1808,1809,1815,1816,1822,1823,1829,1830,1836,1837,1843,1844,1850],{"type":52,"value":1780},"By default, these directories are excluded when indexing Java projects: ",{"type":46,"tag":164,"props":1782,"children":1784},{"className":1783},[],[1785],{"type":52,"value":1786},"target\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1789,"children":1791},{"className":1790},[],[1792],{"type":52,"value":1793},"build\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1796,"children":1798},{"className":1797},[],[1799],{"type":52,"value":1800},".gradle\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1803,"children":1805},{"className":1804},[],[1806],{"type":52,"value":1807},".idea\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1810,"children":1812},{"className":1811},[],[1813],{"type":52,"value":1814},".settings\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1817,"children":1819},{"className":1818},[],[1820],{"type":52,"value":1821},"bin\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1824,"children":1826},{"className":1825},[],[1827],{"type":52,"value":1828},"out\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1831,"children":1833},{"className":1832},[],[1834],{"type":52,"value":1835},"test\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1838,"children":1840},{"className":1839},[],[1841],{"type":52,"value":1842},"tests\u002F",{"type":52,"value":492},{"type":46,"tag":164,"props":1845,"children":1847},{"className":1846},[],[1848],{"type":52,"value":1849},"src\u002Ftest\u002F",{"type":52,"value":1851},".",{"type":46,"tag":179,"props":1853,"children":1855},{"id":1854},"java-query-examples",[1856],{"type":52,"value":1857},"Java Query Examples",{"type":46,"tag":186,"props":1859,"children":1861},{"className":657,"code":1860,"language":25,"meta":191,"style":191},"# Find all classes that extend a specific class\nlist(cs.conn.execute(\"\"\"\n    MATCH (c:Class)-[:INHERITS]->(p:Class {name: 'FileSystem'})\n    RETURN c.name, c.file_path\n\"\"\"))\n\n# Find all methods in a specific class\nlist(cs.conn.execute(\"\"\"\n    MATCH (c:Class {name: 'DefaultParser'})-[:HAS_METHOD]->(f:Function)\n    RETURN f.name, f.signature\n\"\"\"))\n\n# Find constructor call chains\nlist(cs.conn.execute(\"\"\"\n    MATCH (f:Function)-[:CALLS]->(init:Function {name: '\u003Cinit>'})\n    WHERE init.class_name = 'Configuration'\n    RETURN f.name, f.file_path LIMIT 10\n\"\"\"))\n",[1862],{"type":46,"tag":164,"props":1863,"children":1864},{"__ignoreMap":191},[1865,1873,1881,1889,1897,1905,1912,1920,1927,1935,1943,1950,1957,1965,1972,1980,1989,1998],{"type":46,"tag":197,"props":1866,"children":1867},{"class":199,"line":200},[1868],{"type":46,"tag":197,"props":1869,"children":1870},{},[1871],{"type":52,"value":1872},"# Find all classes that extend a specific class\n",{"type":46,"tag":197,"props":1874,"children":1875},{"class":199,"line":243},[1876],{"type":46,"tag":197,"props":1877,"children":1878},{},[1879],{"type":52,"value":1880},"list(cs.conn.execute(\"\"\"\n",{"type":46,"tag":197,"props":1882,"children":1883},{"class":199,"line":266},[1884],{"type":46,"tag":197,"props":1885,"children":1886},{},[1887],{"type":52,"value":1888},"    MATCH (c:Class)-[:INHERITS]->(p:Class {name: 'FileSystem'})\n",{"type":46,"tag":197,"props":1890,"children":1891},{"class":199,"line":276},[1892],{"type":46,"tag":197,"props":1893,"children":1894},{},[1895],{"type":52,"value":1896},"    RETURN c.name, c.file_path\n",{"type":46,"tag":197,"props":1898,"children":1899},{"class":199,"line":291},[1900],{"type":46,"tag":197,"props":1901,"children":1902},{},[1903],{"type":52,"value":1904},"\"\"\"))\n",{"type":46,"tag":197,"props":1906,"children":1907},{"class":199,"line":299},[1908],{"type":46,"tag":197,"props":1909,"children":1910},{"emptyLinePlaceholder":270},[1911],{"type":52,"value":273},{"type":46,"tag":197,"props":1913,"children":1914},{"class":199,"line":308},[1915],{"type":46,"tag":197,"props":1916,"children":1917},{},[1918],{"type":52,"value":1919},"# Find all methods in a specific class\n",{"type":46,"tag":197,"props":1921,"children":1922},{"class":199,"line":345},[1923],{"type":46,"tag":197,"props":1924,"children":1925},{},[1926],{"type":52,"value":1880},{"type":46,"tag":197,"props":1928,"children":1929},{"class":199,"line":353},[1930],{"type":46,"tag":197,"props":1931,"children":1932},{},[1933],{"type":52,"value":1934},"    MATCH (c:Class {name: 'DefaultParser'})-[:HAS_METHOD]->(f:Function)\n",{"type":46,"tag":197,"props":1936,"children":1937},{"class":199,"line":362},[1938],{"type":46,"tag":197,"props":1939,"children":1940},{},[1941],{"type":52,"value":1942},"    RETURN f.name, f.signature\n",{"type":46,"tag":197,"props":1944,"children":1945},{"class":199,"line":743},[1946],{"type":46,"tag":197,"props":1947,"children":1948},{},[1949],{"type":52,"value":1904},{"type":46,"tag":197,"props":1951,"children":1952},{"class":199,"line":752},[1953],{"type":46,"tag":197,"props":1954,"children":1955},{"emptyLinePlaceholder":270},[1956],{"type":52,"value":273},{"type":46,"tag":197,"props":1958,"children":1959},{"class":199,"line":761},[1960],{"type":46,"tag":197,"props":1961,"children":1962},{},[1963],{"type":52,"value":1964},"# Find constructor call chains\n",{"type":46,"tag":197,"props":1966,"children":1967},{"class":199,"line":770},[1968],{"type":46,"tag":197,"props":1969,"children":1970},{},[1971],{"type":52,"value":1880},{"type":46,"tag":197,"props":1973,"children":1974},{"class":199,"line":778},[1975],{"type":46,"tag":197,"props":1976,"children":1977},{},[1978],{"type":52,"value":1979},"    MATCH (f:Function)-[:CALLS]->(init:Function {name: '\u003Cinit>'})\n",{"type":46,"tag":197,"props":1981,"children":1983},{"class":199,"line":1982},16,[1984],{"type":46,"tag":197,"props":1985,"children":1986},{},[1987],{"type":52,"value":1988},"    WHERE init.class_name = 'Configuration'\n",{"type":46,"tag":197,"props":1990,"children":1992},{"class":199,"line":1991},17,[1993],{"type":46,"tag":197,"props":1994,"children":1995},{},[1996],{"type":52,"value":1997},"    RETURN f.name, f.file_path LIMIT 10\n",{"type":46,"tag":197,"props":1999,"children":2001},{"class":199,"line":2000},18,[2002],{"type":46,"tag":197,"props":2003,"children":2004},{},[2005],{"type":52,"value":1904},{"type":46,"tag":97,"props":2007,"children":2009},{"id":2008},"bug-root-cause-analysis",[2010],{"type":52,"value":2011},"Bug Root Cause Analysis",{"type":46,"tag":55,"props":2013,"children":2014},{},[2015],{"type":52,"value":2016},"CodeScope can fetch GitHub issues and map them to code using the graph + vector infrastructure. This is the core workflow for answering questions like \"why does this project have so many bugs?\" or \"where in the code does this bug come from?\"",{"type":46,"tag":179,"props":2018,"children":2020},{"id":2019},"prerequisites",[2021],{"type":52,"value":2022},"Prerequisites",{"type":46,"tag":104,"props":2024,"children":2025},{},[2026,2031],{"type":46,"tag":108,"props":2027,"children":2028},{},[2029],{"type":52,"value":2030},"A code graph must already be indexed for the target repository",{"type":46,"tag":108,"props":2032,"children":2033},{},[2034,2040,2042,2048],{"type":46,"tag":164,"props":2035,"children":2037},{"className":2036},[],[2038],{"type":52,"value":2039},"gh",{"type":52,"value":2041}," CLI must be installed and authenticated (",{"type":46,"tag":164,"props":2043,"children":2045},{"className":2044},[],[2046],{"type":52,"value":2047},"gh auth login",{"type":52,"value":1507},{"type":46,"tag":179,"props":2050,"children":2052},{"id":2051},"bug-analysis-api",[2053],{"type":52,"value":2054},"Bug Analysis API",{"type":46,"tag":2056,"props":2057,"children":2059},"h4",{"id":2058},"single-issue-analysis",[2060],{"type":52,"value":2061},"Single Issue Analysis",{"type":46,"tag":186,"props":2063,"children":2065},{"className":657,"code":2064,"language":25,"meta":191,"style":191},"# Analyze a specific GitHub issue against the indexed code graph\nresult = cs.analyze_issue(\"owner\", \"repo\", 1234, topk=10)\nprint(result.format_report())\n",[2066],{"type":46,"tag":164,"props":2067,"children":2068},{"__ignoreMap":191},[2069,2077,2085],{"type":46,"tag":197,"props":2070,"children":2071},{"class":199,"line":200},[2072],{"type":46,"tag":197,"props":2073,"children":2074},{},[2075],{"type":52,"value":2076},"# Analyze a specific GitHub issue against the indexed code graph\n",{"type":46,"tag":197,"props":2078,"children":2079},{"class":199,"line":243},[2080],{"type":46,"tag":197,"props":2081,"children":2082},{},[2083],{"type":52,"value":2084},"result = cs.analyze_issue(\"owner\", \"repo\", 1234, topk=10)\n",{"type":46,"tag":197,"props":2086,"children":2087},{"class":199,"line":266},[2088],{"type":46,"tag":197,"props":2089,"children":2090},{},[2091],{"type":52,"value":2092},"print(result.format_report())\n",{"type":46,"tag":55,"props":2094,"children":2095},{},[2096],{"type":52,"value":2097},"This:",{"type":46,"tag":2099,"props":2100,"children":2101},"ol",{},[2102,2107,2112,2117,2130,2141],{"type":46,"tag":108,"props":2103,"children":2104},{},[2105],{"type":52,"value":2106},"Fetches the issue from GitHub (or loads from cache)",{"type":46,"tag":108,"props":2108,"children":2109},{},[2110],{"type":52,"value":2111},"Parses file paths, function names, and stack traces from the issue body",{"type":46,"tag":108,"props":2113,"children":2114},{},[2115],{"type":52,"value":2116},"Matches extracted paths to File nodes in the graph",{"type":46,"tag":108,"props":2118,"children":2119},{},[2120,2122,2128],{"type":52,"value":2121},"Uses semantic search (",{"type":46,"tag":164,"props":2123,"children":2125},{"className":2124},[],[2126],{"type":52,"value":2127},"cross_locate",{"type":52,"value":2129},") to find related code",{"type":46,"tag":108,"props":2131,"children":2132},{},[2133,2135],{"type":52,"value":2134},"Traces callers of mentioned functions via ",{"type":46,"tag":164,"props":2136,"children":2138},{"className":2137},[],[2139],{"type":52,"value":2140},"impact()",{"type":46,"tag":108,"props":2142,"children":2143},{},[2144],{"type":52,"value":2145},"Ranks and returns root cause candidates with explanation",{"type":46,"tag":2056,"props":2147,"children":2149},{"id":2148},"batch-bug-analysis",[2150],{"type":52,"value":2151},"Batch Bug Analysis",{"type":46,"tag":186,"props":2153,"children":2155},{"className":657,"code":2154,"language":25,"meta":191,"style":191},"# Analyze top-k bug issues and get aggregated hotspot data\nresults = cs.analyze_top_bugs(\"owner\", \"repo\", k=10, label=\"bug\")\nfor r in results:\n    print(f\"#{r.issue.number}: {r.issue.title}\")\n    for c in r.candidates[:3]:\n        print(f\"  {c.function_name} ({c.file_path}) score={c.score:.2f}\")\n",[2156],{"type":46,"tag":164,"props":2157,"children":2158},{"__ignoreMap":191},[2159,2167,2175,2183,2191,2199],{"type":46,"tag":197,"props":2160,"children":2161},{"class":199,"line":200},[2162],{"type":46,"tag":197,"props":2163,"children":2164},{},[2165],{"type":52,"value":2166},"# Analyze top-k bug issues and get aggregated hotspot data\n",{"type":46,"tag":197,"props":2168,"children":2169},{"class":199,"line":243},[2170],{"type":46,"tag":197,"props":2171,"children":2172},{},[2173],{"type":52,"value":2174},"results = cs.analyze_top_bugs(\"owner\", \"repo\", k=10, label=\"bug\")\n",{"type":46,"tag":197,"props":2176,"children":2177},{"class":199,"line":266},[2178],{"type":46,"tag":197,"props":2179,"children":2180},{},[2181],{"type":52,"value":2182},"for r in results:\n",{"type":46,"tag":197,"props":2184,"children":2185},{"class":199,"line":276},[2186],{"type":46,"tag":197,"props":2187,"children":2188},{},[2189],{"type":52,"value":2190},"    print(f\"#{r.issue.number}: {r.issue.title}\")\n",{"type":46,"tag":197,"props":2192,"children":2193},{"class":199,"line":291},[2194],{"type":46,"tag":197,"props":2195,"children":2196},{},[2197],{"type":52,"value":2198},"    for c in r.candidates[:3]:\n",{"type":46,"tag":197,"props":2200,"children":2201},{"class":199,"line":299},[2202],{"type":46,"tag":197,"props":2203,"children":2204},{},[2205],{"type":52,"value":2206},"        print(f\"  {c.function_name} ({c.file_path}) score={c.score:.2f}\")\n",{"type":46,"tag":2056,"props":2208,"children":2210},{"id":2209},"cli-commands",[2211],{"type":52,"value":2212},"CLI Commands",{"type":46,"tag":186,"props":2214,"children":2216},{"className":188,"code":2215,"language":190,"meta":191,"style":191},"# Fetch and parse a single issue (no graph needed)\ncodegraph fetch-issue owner repo 1234\n\n# Fetch top-k bugs from a repo\ncodegraph fetch-bugs owner repo --top 10 --label bug\n\n# Analyze a single bug against the code graph\ncodegraph analyze-bug owner repo 1234 --db .codegraph --topk 10\n\n# Batch analyze top bugs\ncodegraph analyze-bugs owner repo --db .codegraph --top 10 --label bug\n",[2217],{"type":46,"tag":164,"props":2218,"children":2219},{"__ignoreMap":191},[2220,2228,2255,2262,2270,2310,2317,2325,2369,2376,2384],{"type":46,"tag":197,"props":2221,"children":2222},{"class":199,"line":200},[2223],{"type":46,"tag":197,"props":2224,"children":2225},{"style":237},[2226],{"type":52,"value":2227},"# Fetch and parse a single issue (no graph needed)\n",{"type":46,"tag":197,"props":2229,"children":2230},{"class":199,"line":243},[2231,2235,2240,2245,2250],{"type":46,"tag":197,"props":2232,"children":2233},{"style":204},[2234],{"type":52,"value":410},{"type":46,"tag":197,"props":2236,"children":2237},{"style":210},[2238],{"type":52,"value":2239}," fetch-issue",{"type":46,"tag":197,"props":2241,"children":2242},{"style":210},[2243],{"type":52,"value":2244}," owner",{"type":46,"tag":197,"props":2246,"children":2247},{"style":210},[2248],{"type":52,"value":2249}," repo",{"type":46,"tag":197,"props":2251,"children":2252},{"style":477},[2253],{"type":52,"value":2254}," 1234\n",{"type":46,"tag":197,"props":2256,"children":2257},{"class":199,"line":266},[2258],{"type":46,"tag":197,"props":2259,"children":2260},{"emptyLinePlaceholder":270},[2261],{"type":52,"value":273},{"type":46,"tag":197,"props":2263,"children":2264},{"class":199,"line":276},[2265],{"type":46,"tag":197,"props":2266,"children":2267},{"style":237},[2268],{"type":52,"value":2269},"# Fetch top-k bugs from a repo\n",{"type":46,"tag":197,"props":2271,"children":2272},{"class":199,"line":291},[2273,2277,2282,2286,2290,2295,2300,2305],{"type":46,"tag":197,"props":2274,"children":2275},{"style":204},[2276],{"type":52,"value":410},{"type":46,"tag":197,"props":2278,"children":2279},{"style":210},[2280],{"type":52,"value":2281}," fetch-bugs",{"type":46,"tag":197,"props":2283,"children":2284},{"style":210},[2285],{"type":52,"value":2244},{"type":46,"tag":197,"props":2287,"children":2288},{"style":210},[2289],{"type":52,"value":2249},{"type":46,"tag":197,"props":2291,"children":2292},{"style":210},[2293],{"type":52,"value":2294}," --top",{"type":46,"tag":197,"props":2296,"children":2297},{"style":477},[2298],{"type":52,"value":2299}," 10",{"type":46,"tag":197,"props":2301,"children":2302},{"style":210},[2303],{"type":52,"value":2304}," --label",{"type":46,"tag":197,"props":2306,"children":2307},{"style":210},[2308],{"type":52,"value":2309}," bug\n",{"type":46,"tag":197,"props":2311,"children":2312},{"class":199,"line":299},[2313],{"type":46,"tag":197,"props":2314,"children":2315},{"emptyLinePlaceholder":270},[2316],{"type":52,"value":273},{"type":46,"tag":197,"props":2318,"children":2319},{"class":199,"line":308},[2320],{"type":46,"tag":197,"props":2321,"children":2322},{"style":237},[2323],{"type":52,"value":2324},"# Analyze a single bug against the code graph\n",{"type":46,"tag":197,"props":2326,"children":2327},{"class":199,"line":345},[2328,2332,2337,2341,2345,2350,2354,2359,2364],{"type":46,"tag":197,"props":2329,"children":2330},{"style":204},[2331],{"type":52,"value":410},{"type":46,"tag":197,"props":2333,"children":2334},{"style":210},[2335],{"type":52,"value":2336}," analyze-bug",{"type":46,"tag":197,"props":2338,"children":2339},{"style":210},[2340],{"type":52,"value":2244},{"type":46,"tag":197,"props":2342,"children":2343},{"style":210},[2344],{"type":52,"value":2249},{"type":46,"tag":197,"props":2346,"children":2347},{"style":477},[2348],{"type":52,"value":2349}," 1234",{"type":46,"tag":197,"props":2351,"children":2352},{"style":210},[2353],{"type":52,"value":420},{"type":46,"tag":197,"props":2355,"children":2356},{"style":210},[2357],{"type":52,"value":2358}," .codegraph",{"type":46,"tag":197,"props":2360,"children":2361},{"style":210},[2362],{"type":52,"value":2363}," --topk",{"type":46,"tag":197,"props":2365,"children":2366},{"style":477},[2367],{"type":52,"value":2368}," 10\n",{"type":46,"tag":197,"props":2370,"children":2371},{"class":199,"line":353},[2372],{"type":46,"tag":197,"props":2373,"children":2374},{"emptyLinePlaceholder":270},[2375],{"type":52,"value":273},{"type":46,"tag":197,"props":2377,"children":2378},{"class":199,"line":362},[2379],{"type":46,"tag":197,"props":2380,"children":2381},{"style":237},[2382],{"type":52,"value":2383},"# Batch analyze top bugs\n",{"type":46,"tag":197,"props":2385,"children":2386},{"class":199,"line":743},[2387,2391,2396,2400,2404,2408,2412,2416,2420,2424],{"type":46,"tag":197,"props":2388,"children":2389},{"style":204},[2390],{"type":52,"value":410},{"type":46,"tag":197,"props":2392,"children":2393},{"style":210},[2394],{"type":52,"value":2395}," analyze-bugs",{"type":46,"tag":197,"props":2397,"children":2398},{"style":210},[2399],{"type":52,"value":2244},{"type":46,"tag":197,"props":2401,"children":2402},{"style":210},[2403],{"type":52,"value":2249},{"type":46,"tag":197,"props":2405,"children":2406},{"style":210},[2407],{"type":52,"value":420},{"type":46,"tag":197,"props":2409,"children":2410},{"style":210},[2411],{"type":52,"value":2358},{"type":46,"tag":197,"props":2413,"children":2414},{"style":210},[2415],{"type":52,"value":2294},{"type":46,"tag":197,"props":2417,"children":2418},{"style":477},[2419],{"type":52,"value":2299},{"type":46,"tag":197,"props":2421,"children":2422},{"style":210},[2423],{"type":52,"value":2304},{"type":46,"tag":197,"props":2425,"children":2426},{"style":210},[2427],{"type":52,"value":2309},{"type":46,"tag":2056,"props":2429,"children":2431},{"id":2430},"lower-level-components",[2432],{"type":52,"value":2433},"Lower-Level Components",{"type":46,"tag":55,"props":2435,"children":2436},{},[2437],{"type":52,"value":2438},"For custom analysis pipelines, the components can be used individually:",{"type":46,"tag":186,"props":2440,"children":2442},{"className":657,"code":2441,"language":25,"meta":191,"style":191},"from codegraph.issue_fetcher import fetch_and_parse_issue\nfrom codegraph.bug_locator import (\n    resolve_paths_to_files,\n    find_semantic_matches,\n    trace_callers,\n    rank_root_causes,\n    analyze_bug,\n)\n\n# Fetch and parse (with caching)\nissue = fetch_and_parse_issue(\"owner\", \"repo\", 1234)\nprint(issue.extracted_paths)   # file paths found in body\nprint(issue.extracted_funcs)   # function names from stack traces\nprint(issue.linked_commits)    # merge commit SHAs from linked PRs\n\n# Match paths to graph nodes\npath_matches = resolve_paths_to_files(cs, issue.extracted_paths)\n\n# Semantic search using issue description\nsemantic_matches = find_semantic_matches(cs, f\"{issue.title}\\n{issue.body}\")\n\n# Trace callers of mentioned functions\ncaller_traces = trace_callers(cs, issue.extracted_funcs, max_hops=2)\n\n# Combine into ranked candidates\ncandidates = rank_root_causes(path_matches, semantic_matches, caller_traces, issue.extracted_funcs)\n",[2443],{"type":46,"tag":164,"props":2444,"children":2445},{"__ignoreMap":191},[2446,2454,2462,2470,2478,2486,2494,2502,2510,2517,2525,2533,2541,2549,2557,2564,2572,2580,2587,2596,2605,2613,2622,2631,2639,2648],{"type":46,"tag":197,"props":2447,"children":2448},{"class":199,"line":200},[2449],{"type":46,"tag":197,"props":2450,"children":2451},{},[2452],{"type":52,"value":2453},"from codegraph.issue_fetcher import fetch_and_parse_issue\n",{"type":46,"tag":197,"props":2455,"children":2456},{"class":199,"line":243},[2457],{"type":46,"tag":197,"props":2458,"children":2459},{},[2460],{"type":52,"value":2461},"from codegraph.bug_locator import (\n",{"type":46,"tag":197,"props":2463,"children":2464},{"class":199,"line":266},[2465],{"type":46,"tag":197,"props":2466,"children":2467},{},[2468],{"type":52,"value":2469},"    resolve_paths_to_files,\n",{"type":46,"tag":197,"props":2471,"children":2472},{"class":199,"line":276},[2473],{"type":46,"tag":197,"props":2474,"children":2475},{},[2476],{"type":52,"value":2477},"    find_semantic_matches,\n",{"type":46,"tag":197,"props":2479,"children":2480},{"class":199,"line":291},[2481],{"type":46,"tag":197,"props":2482,"children":2483},{},[2484],{"type":52,"value":2485},"    trace_callers,\n",{"type":46,"tag":197,"props":2487,"children":2488},{"class":199,"line":299},[2489],{"type":46,"tag":197,"props":2490,"children":2491},{},[2492],{"type":52,"value":2493},"    rank_root_causes,\n",{"type":46,"tag":197,"props":2495,"children":2496},{"class":199,"line":308},[2497],{"type":46,"tag":197,"props":2498,"children":2499},{},[2500],{"type":52,"value":2501},"    analyze_bug,\n",{"type":46,"tag":197,"props":2503,"children":2504},{"class":199,"line":345},[2505],{"type":46,"tag":197,"props":2506,"children":2507},{},[2508],{"type":52,"value":2509},")\n",{"type":46,"tag":197,"props":2511,"children":2512},{"class":199,"line":353},[2513],{"type":46,"tag":197,"props":2514,"children":2515},{"emptyLinePlaceholder":270},[2516],{"type":52,"value":273},{"type":46,"tag":197,"props":2518,"children":2519},{"class":199,"line":362},[2520],{"type":46,"tag":197,"props":2521,"children":2522},{},[2523],{"type":52,"value":2524},"# Fetch and parse (with caching)\n",{"type":46,"tag":197,"props":2526,"children":2527},{"class":199,"line":743},[2528],{"type":46,"tag":197,"props":2529,"children":2530},{},[2531],{"type":52,"value":2532},"issue = fetch_and_parse_issue(\"owner\", \"repo\", 1234)\n",{"type":46,"tag":197,"props":2534,"children":2535},{"class":199,"line":752},[2536],{"type":46,"tag":197,"props":2537,"children":2538},{},[2539],{"type":52,"value":2540},"print(issue.extracted_paths)   # file paths found in body\n",{"type":46,"tag":197,"props":2542,"children":2543},{"class":199,"line":761},[2544],{"type":46,"tag":197,"props":2545,"children":2546},{},[2547],{"type":52,"value":2548},"print(issue.extracted_funcs)   # function names from stack traces\n",{"type":46,"tag":197,"props":2550,"children":2551},{"class":199,"line":770},[2552],{"type":46,"tag":197,"props":2553,"children":2554},{},[2555],{"type":52,"value":2556},"print(issue.linked_commits)    # merge commit SHAs from linked PRs\n",{"type":46,"tag":197,"props":2558,"children":2559},{"class":199,"line":778},[2560],{"type":46,"tag":197,"props":2561,"children":2562},{"emptyLinePlaceholder":270},[2563],{"type":52,"value":273},{"type":46,"tag":197,"props":2565,"children":2566},{"class":199,"line":1982},[2567],{"type":46,"tag":197,"props":2568,"children":2569},{},[2570],{"type":52,"value":2571},"# Match paths to graph nodes\n",{"type":46,"tag":197,"props":2573,"children":2574},{"class":199,"line":1991},[2575],{"type":46,"tag":197,"props":2576,"children":2577},{},[2578],{"type":52,"value":2579},"path_matches = resolve_paths_to_files(cs, issue.extracted_paths)\n",{"type":46,"tag":197,"props":2581,"children":2582},{"class":199,"line":2000},[2583],{"type":46,"tag":197,"props":2584,"children":2585},{"emptyLinePlaceholder":270},[2586],{"type":52,"value":273},{"type":46,"tag":197,"props":2588,"children":2590},{"class":199,"line":2589},19,[2591],{"type":46,"tag":197,"props":2592,"children":2593},{},[2594],{"type":52,"value":2595},"# Semantic search using issue description\n",{"type":46,"tag":197,"props":2597,"children":2599},{"class":199,"line":2598},20,[2600],{"type":46,"tag":197,"props":2601,"children":2602},{},[2603],{"type":52,"value":2604},"semantic_matches = find_semantic_matches(cs, f\"{issue.title}\\n{issue.body}\")\n",{"type":46,"tag":197,"props":2606,"children":2608},{"class":199,"line":2607},21,[2609],{"type":46,"tag":197,"props":2610,"children":2611},{"emptyLinePlaceholder":270},[2612],{"type":52,"value":273},{"type":46,"tag":197,"props":2614,"children":2616},{"class":199,"line":2615},22,[2617],{"type":46,"tag":197,"props":2618,"children":2619},{},[2620],{"type":52,"value":2621},"# Trace callers of mentioned functions\n",{"type":46,"tag":197,"props":2623,"children":2625},{"class":199,"line":2624},23,[2626],{"type":46,"tag":197,"props":2627,"children":2628},{},[2629],{"type":52,"value":2630},"caller_traces = trace_callers(cs, issue.extracted_funcs, max_hops=2)\n",{"type":46,"tag":197,"props":2632,"children":2634},{"class":199,"line":2633},24,[2635],{"type":46,"tag":197,"props":2636,"children":2637},{"emptyLinePlaceholder":270},[2638],{"type":52,"value":273},{"type":46,"tag":197,"props":2640,"children":2642},{"class":199,"line":2641},25,[2643],{"type":46,"tag":197,"props":2644,"children":2645},{},[2646],{"type":52,"value":2647},"# Combine into ranked candidates\n",{"type":46,"tag":197,"props":2649,"children":2651},{"class":199,"line":2650},26,[2652],{"type":46,"tag":197,"props":2653,"children":2654},{},[2655],{"type":52,"value":2656},"candidates = rank_root_causes(path_matches, semantic_matches, caller_traces, issue.extracted_funcs)\n",{"type":46,"tag":179,"props":2658,"children":2660},{"id":2659},"scoring-system",[2661],{"type":52,"value":2662},"Scoring System",{"type":46,"tag":55,"props":2664,"children":2665},{},[2666],{"type":52,"value":2667},"Root cause candidates are scored by combining multiple signals:",{"type":46,"tag":808,"props":2669,"children":2670},{},[2671,2692],{"type":46,"tag":812,"props":2672,"children":2673},{},[2674],{"type":46,"tag":816,"props":2675,"children":2676},{},[2677,2682,2687],{"type":46,"tag":820,"props":2678,"children":2679},{},[2680],{"type":52,"value":2681},"Signal",{"type":46,"tag":820,"props":2683,"children":2684},{},[2685],{"type":52,"value":2686},"Score",{"type":46,"tag":820,"props":2688,"children":2689},{},[2690],{"type":52,"value":2691},"Description",{"type":46,"tag":831,"props":2693,"children":2694},{},[2695,2713,2731,2754],{"type":46,"tag":816,"props":2696,"children":2697},{},[2698,2703,2708],{"type":46,"tag":838,"props":2699,"children":2700},{},[2701],{"type":52,"value":2702},"Direct mention",{"type":46,"tag":838,"props":2704,"children":2705},{},[2706],{"type":52,"value":2707},"+1.0",{"type":46,"tag":838,"props":2709,"children":2710},{},[2711],{"type":52,"value":2712},"Function name appears in issue body\u002Fstack trace",{"type":46,"tag":816,"props":2714,"children":2715},{},[2716,2721,2726],{"type":46,"tag":838,"props":2717,"children":2718},{},[2719],{"type":52,"value":2720},"File path match",{"type":46,"tag":838,"props":2722,"children":2723},{},[2724],{"type":52,"value":2725},"+0.8",{"type":46,"tag":838,"props":2727,"children":2728},{},[2729],{"type":52,"value":2730},"Function is in a file mentioned in the issue",{"type":46,"tag":816,"props":2732,"children":2733},{},[2734,2739,2744],{"type":46,"tag":838,"props":2735,"children":2736},{},[2737],{"type":52,"value":2738},"Semantic match",{"type":46,"tag":838,"props":2740,"children":2741},{},[2742],{"type":52,"value":2743},"+score",{"type":46,"tag":838,"props":2745,"children":2746},{},[2747,2749],{"type":52,"value":2748},"Raw cosine similarity (0.0-1.0) from ",{"type":46,"tag":164,"props":2750,"children":2752},{"className":2751},[],[2753],{"type":52,"value":2127},{"type":46,"tag":816,"props":2755,"children":2756},{},[2757,2762,2767],{"type":46,"tag":838,"props":2758,"children":2759},{},[2760],{"type":52,"value":2761},"Caller relationship",{"type":46,"tag":838,"props":2763,"children":2764},{},[2765],{"type":52,"value":2766},"+0.5\u002Fhops",{"type":46,"tag":838,"props":2768,"children":2769},{},[2770],{"type":52,"value":2771},"Function calls a mentioned function (decays with distance)",{"type":46,"tag":179,"props":2773,"children":2775},{"id":2774},"issue-cache",[2776],{"type":52,"value":2777},"Issue Cache",{"type":46,"tag":55,"props":2779,"children":2780},{},[2781,2783,2789,2791,2797,2799,2805],{"type":52,"value":2782},"Parsed issues are cached at ",{"type":46,"tag":164,"props":2784,"children":2786},{"className":2785},[],[2787],{"type":52,"value":2788},"~\u002F.codegraph\u002Fissue_cache\u002F{owner}_{repo}_{number}.json",{"type":52,"value":2790},". Cache hits skip the GitHub API call entirely (sub-millisecond). To force a refresh, pass ",{"type":46,"tag":164,"props":2792,"children":2794},{"className":2793},[],[2795],{"type":52,"value":2796},"use_cache=False",{"type":52,"value":2798}," or use ",{"type":46,"tag":164,"props":2800,"children":2802},{"className":2801},[],[2803],{"type":52,"value":2804},"--no-cache",{"type":52,"value":2806}," on CLI.",{"type":46,"tag":186,"props":2808,"children":2810},{"className":657,"code":2809,"language":25,"meta":191,"style":191},"from codegraph.issue_cache import clear_cache\nclear_cache(owner=\"openclaw\", repo=\"openclaw\")  # clear specific repo\nclear_cache()  # clear all\n",[2811],{"type":46,"tag":164,"props":2812,"children":2813},{"__ignoreMap":191},[2814,2822,2830],{"type":46,"tag":197,"props":2815,"children":2816},{"class":199,"line":200},[2817],{"type":46,"tag":197,"props":2818,"children":2819},{},[2820],{"type":52,"value":2821},"from codegraph.issue_cache import clear_cache\n",{"type":46,"tag":197,"props":2823,"children":2824},{"class":199,"line":243},[2825],{"type":46,"tag":197,"props":2826,"children":2827},{},[2828],{"type":52,"value":2829},"clear_cache(owner=\"openclaw\", repo=\"openclaw\")  # clear specific repo\n",{"type":46,"tag":197,"props":2831,"children":2832},{"class":199,"line":266},[2833],{"type":46,"tag":197,"props":2834,"children":2835},{},[2836],{"type":52,"value":2837},"clear_cache()  # clear all\n",{"type":46,"tag":179,"props":2839,"children":2841},{"id":2840},"stack-trace-parsing",[2842],{"type":52,"value":2843},"Stack Trace Parsing",{"type":46,"tag":55,"props":2845,"children":2846},{},[2847,2849,2855],{"type":52,"value":2848},"The parser automatically extracts file paths and function names from stack traces in Python, C\u002FC++, JavaScript\u002FNode.js, Go, and Rust formats. It also extracts ",{"type":46,"tag":164,"props":2850,"children":2852},{"className":2851},[],[2853],{"type":52,"value":2854},"func_name()",{"type":52,"value":2856}," references in backticks and inline code.",{"type":46,"tag":97,"props":2858,"children":2860},{"id":2859},"how-to-route-questions",[2861],{"type":52,"value":2862},"How to Route Questions",{"type":46,"tag":55,"props":2864,"children":2865},{},[2866,2868],{"type":52,"value":2867},"The key decision is: ",{"type":46,"tag":61,"props":2869,"children":2870},{},[2871],{"type":52,"value":2872},"does the user want an exact structural answer, a fuzzy semantic one, or a bug-to-code mapping?",{"type":46,"tag":808,"props":2874,"children":2875},{},[2876,2892],{"type":46,"tag":812,"props":2877,"children":2878},{},[2879],{"type":46,"tag":816,"props":2880,"children":2881},{},[2882,2887],{"type":46,"tag":820,"props":2883,"children":2884},{},[2885],{"type":52,"value":2886},"User asks...",{"type":46,"tag":820,"props":2888,"children":2889},{},[2890],{"type":52,"value":2891},"Best approach",{"type":46,"tag":831,"props":2893,"children":2894},{},[2895,2922,2947,2964,2982,3007,3024,3048,3082,3098,3115,3139,3158,3175,3200,3217,3236,3253,3271],{"type":46,"tag":816,"props":2896,"children":2897},{},[2898,2911],{"type":46,"tag":838,"props":2899,"children":2900},{},[2901,2903,2909],{"type":52,"value":2902},"\"Who calls ",{"type":46,"tag":164,"props":2904,"children":2906},{"className":2905},[],[2907],{"type":52,"value":2908},"free_irq",{"type":52,"value":2910},"?\"",{"type":46,"tag":838,"props":2912,"children":2913},{},[2914,2916],{"type":52,"value":2915},"Cypher: ",{"type":46,"tag":164,"props":2917,"children":2919},{"className":2918},[],[2920],{"type":52,"value":2921},"MATCH (c:Function)-[:CALLS]->(f:Function {name: 'free_irq'}) RETURN c.name, c.file_path",{"type":46,"tag":816,"props":2923,"children":2924},{},[2925,2930],{"type":46,"tag":838,"props":2926,"children":2927},{},[2928],{"type":52,"value":2929},"\"Find functions related to memory allocation\"",{"type":46,"tag":838,"props":2931,"children":2932},{},[2933,2939,2941],{"type":46,"tag":164,"props":2934,"children":2936},{"className":2935},[],[2937],{"type":52,"value":2938},"cs.vector_only_search(\"memory allocation\")",{"type":52,"value":2940}," or ",{"type":46,"tag":164,"props":2942,"children":2944},{"className":2943},[],[2945],{"type":52,"value":2946},"cs.cross_locate(\"memory allocation\")",{"type":46,"tag":816,"props":2948,"children":2949},{},[2950,2955],{"type":46,"tag":838,"props":2951,"children":2952},{},[2953],{"type":52,"value":2954},"\"What's the most complex function?\"",{"type":46,"tag":838,"props":2956,"children":2957},{},[2958],{"type":46,"tag":164,"props":2959,"children":2961},{"className":2960},[],[2962],{"type":52,"value":2963},"cs.hotspots(topk=1)",{"type":46,"tag":816,"props":2965,"children":2966},{},[2967,2972],{"type":46,"tag":838,"props":2968,"children":2969},{},[2970],{"type":52,"value":2971},"\"Is there dead code in the networking stack?\"",{"type":46,"tag":838,"props":2973,"children":2974},{},[2975,2980],{"type":46,"tag":164,"props":2976,"children":2978},{"className":2977},[],[2979],{"type":52,"value":963},{"type":52,"value":2981}," then filter by file path",{"type":46,"tag":816,"props":2983,"children":2984},{},[2985,2998],{"type":46,"tag":838,"props":2986,"children":2987},{},[2988,2990,2996],{"type":52,"value":2989},"\"How has ",{"type":46,"tag":164,"props":2991,"children":2993},{"className":2992},[],[2994],{"type":52,"value":2995},"schedule()",{"type":52,"value":2997}," changed recently?\"",{"type":46,"tag":838,"props":2999,"children":3000},{},[3001],{"type":46,"tag":164,"props":3002,"children":3004},{"className":3003},[],[3005],{"type":52,"value":3006},"cs.change_attribution(\"schedule\", \"kernel\u002Fsched\u002Fcore.c\")",{"type":46,"tag":816,"props":3008,"children":3009},{},[3010,3015],{"type":46,"tag":838,"props":3011,"children":3012},{},[3013],{"type":52,"value":3014},"\"Which modules are tightly coupled?\"",{"type":46,"tag":838,"props":3016,"children":3017},{},[3018],{"type":46,"tag":164,"props":3019,"children":3021},{"className":3020},[],[3022],{"type":52,"value":3023},"cs.module_coupling(topk=20)",{"type":46,"tag":816,"props":3025,"children":3026},{},[3027,3032],{"type":46,"tag":838,"props":3028,"children":3029},{},[3030],{"type":52,"value":3031},"\"Generate a full architecture report\"",{"type":46,"tag":838,"props":3033,"children":3034},{},[3035,3041,3042],{"type":46,"tag":164,"props":3036,"children":3038},{"className":3037},[],[3039],{"type":52,"value":3040},"codegraph analyze",{"type":52,"value":2940},{"type":46,"tag":164,"props":3043,"children":3045},{"className":3044},[],[3046],{"type":52,"value":3047},"generate_report(cs)",{"type":46,"tag":816,"props":3049,"children":3050},{},[3051,3063],{"type":46,"tag":838,"props":3052,"children":3053},{},[3054,3056,3062],{"type":52,"value":3055},"\"What's the architectural role of ",{"type":46,"tag":164,"props":3057,"children":3059},{"className":3058},[],[3060],{"type":52,"value":3061},"mm\u002F",{"type":52,"value":2910},{"type":46,"tag":838,"props":3064,"children":3065},{},[3066,3072,3074,3080],{"type":46,"tag":164,"props":3067,"children":3069},{"className":3068},[],[3070],{"type":52,"value":3071},"cs.layer_discovery()",{"type":52,"value":3073}," then find ",{"type":46,"tag":164,"props":3075,"children":3077},{"className":3076},[],[3078],{"type":52,"value":3079},"mm",{"type":52,"value":3081}," entries",{"type":46,"tag":816,"props":3083,"children":3084},{},[3085,3090],{"type":46,"tag":838,"props":3086,"children":3087},{},[3088],{"type":52,"value":3089},"\"Which functions act as API boundaries?\"",{"type":46,"tag":838,"props":3091,"children":3092},{},[3093],{"type":46,"tag":164,"props":3094,"children":3096},{"className":3095},[],[3097],{"type":52,"value":1014},{"type":46,"tag":816,"props":3099,"children":3100},{},[3101,3106],{"type":46,"tag":838,"props":3102,"children":3103},{},[3104],{"type":52,"value":3105},"\"Find commits about fixing race conditions\"",{"type":46,"tag":838,"props":3107,"children":3108},{},[3109],{"type":46,"tag":164,"props":3110,"children":3112},{"className":3111},[],[3113],{"type":52,"value":3114},"cs.intent_search(\"fix race condition\")",{"type":46,"tag":816,"props":3116,"children":3117},{},[3118,3130],{"type":46,"tag":838,"props":3119,"children":3120},{},[3121,3123,3129],{"type":52,"value":3122},"\"What functions are always changed together with ",{"type":46,"tag":164,"props":3124,"children":3126},{"className":3125},[],[3127],{"type":52,"value":3128},"kmalloc",{"type":52,"value":2910},{"type":46,"tag":838,"props":3131,"children":3132},{},[3133],{"type":46,"tag":164,"props":3134,"children":3136},{"className":3135},[],[3137],{"type":52,"value":3138},"cs.co_change(\"kmalloc\")",{"type":46,"tag":816,"props":3140,"children":3141},{},[3142,3147],{"type":46,"tag":838,"props":3143,"children":3144},{},[3145],{"type":52,"value":3146},"\"Why does this project have so many bugs?\"",{"type":46,"tag":838,"props":3148,"children":3149},{},[3150,3156],{"type":46,"tag":164,"props":3151,"children":3153},{"className":3152},[],[3154],{"type":52,"value":3155},"cs.analyze_top_bugs(\"owner\", \"repo\", k=10)",{"type":52,"value":3157}," then aggregate hotspots",{"type":46,"tag":816,"props":3159,"children":3160},{},[3161,3166],{"type":46,"tag":838,"props":3162,"children":3163},{},[3164],{"type":52,"value":3165},"\"Analyze issue #1234 from GitHub\"",{"type":46,"tag":838,"props":3167,"children":3168},{},[3169],{"type":46,"tag":164,"props":3170,"children":3172},{"className":3171},[],[3173],{"type":52,"value":3174},"cs.analyze_issue(\"owner\", \"repo\", 1234)",{"type":46,"tag":816,"props":3176,"children":3177},{},[3178,3183],{"type":46,"tag":838,"props":3179,"children":3180},{},[3181],{"type":52,"value":3182},"\"What code is related to this bug?\"",{"type":46,"tag":838,"props":3184,"children":3185},{},[3186,3192,3194],{"type":46,"tag":164,"props":3187,"children":3189},{"className":3188},[],[3190],{"type":52,"value":3191},"cs.analyze_issue(...)",{"type":52,"value":3193}," or manual ",{"type":46,"tag":164,"props":3195,"children":3197},{"className":3196},[],[3198],{"type":52,"value":3199},"cross_locate(bug_description)",{"type":46,"tag":816,"props":3201,"children":3202},{},[3203,3208],{"type":46,"tag":838,"props":3204,"children":3205},{},[3206],{"type":52,"value":3207},"\"Find the root cause of the crash in issue #42\"",{"type":46,"tag":838,"props":3209,"children":3210},{},[3211],{"type":46,"tag":164,"props":3212,"children":3214},{"className":3213},[],[3215],{"type":52,"value":3216},"cs.analyze_issue(\"owner\", \"repo\", 42)",{"type":46,"tag":816,"props":3218,"children":3219},{},[3220,3225],{"type":46,"tag":838,"props":3221,"children":3222},{},[3223],{"type":52,"value":3224},"\"Which modules have the most bugs?\"",{"type":46,"tag":838,"props":3226,"children":3227},{},[3228,3234],{"type":46,"tag":164,"props":3229,"children":3231},{"className":3230},[],[3232],{"type":52,"value":3233},"cs.analyze_top_bugs(...)",{"type":52,"value":3235}," then aggregate by file\u002Fmodule",{"type":46,"tag":816,"props":3237,"children":3238},{},[3239,3244],{"type":46,"tag":838,"props":3240,"children":3241},{},[3242],{"type":52,"value":3243},"\"Index this Java project\"",{"type":46,"tag":838,"props":3245,"children":3246},{},[3247],{"type":46,"tag":164,"props":3248,"children":3250},{"className":3249},[],[3251],{"type":52,"value":3252},"codegraph init --repo . --lang java",{"type":46,"tag":816,"props":3254,"children":3255},{},[3256,3261],{"type":46,"tag":838,"props":3257,"children":3258},{},[3259],{"type":52,"value":3260},"\"What classes extend FileSystem in Hadoop?\"",{"type":46,"tag":838,"props":3262,"children":3263},{},[3264,3265],{"type":52,"value":2915},{"type":46,"tag":164,"props":3266,"children":3268},{"className":3267},[],[3269],{"type":52,"value":3270},"MATCH (c:Class)-[:INHERITS]->(p:Class {name: 'FileSystem'}) RETURN c.name, c.file_path",{"type":46,"tag":816,"props":3272,"children":3273},{},[3274,3279],{"type":46,"tag":838,"props":3275,"children":3276},{},[3277],{"type":52,"value":3278},"\"Find all constructors called in this module\"",{"type":46,"tag":838,"props":3280,"children":3281},{},[3282,3283],{"type":52,"value":2915},{"type":46,"tag":164,"props":3284,"children":3286},{"className":3285},[],[3287],{"type":52,"value":3288},"MATCH (f:Function)-[:CALLS]->(init:Function {name: '\u003Cinit>'}) WHERE f.file_path CONTAINS 'module' RETURN ...",{"type":46,"tag":55,"props":3290,"children":3291},{},[3292,3294,3299,3301,3308,3310,3316],{"type":52,"value":3293},"For ",{"type":46,"tag":61,"props":3295,"children":3296},{},[3297],{"type":52,"value":3298},"novel investigations",{"type":52,"value":3300}," not covered by pre-built methods, compose raw Cypher queries. See ",{"type":46,"tag":3302,"props":3303,"children":3305},"a",{"href":3304},".\u002Fpatterns.md",[3306],{"type":52,"value":3307},"patterns.md",{"type":52,"value":3309}," for templates. For bug analysis patterns, see ",{"type":46,"tag":3302,"props":3311,"children":3313},{"href":3312},".\u002Fbug-analysis.md",[3314],{"type":52,"value":3315},"bug-analysis.md",{"type":52,"value":1851},{"type":46,"tag":97,"props":3318,"children":3320},{"id":3319},"important-filters-for-cypher",[3321],{"type":52,"value":3322},"Important Filters for Cypher",{"type":46,"tag":55,"props":3324,"children":3325},{},[3326],{"type":52,"value":3327},"When writing Cypher queries, these filters prevent misleading results:",{"type":46,"tag":104,"props":3329,"children":3330},{},[3331,3345,3359,3388],{"type":46,"tag":108,"props":3332,"children":3333},{},[3334,3343],{"type":46,"tag":61,"props":3335,"children":3336},{},[3337],{"type":46,"tag":164,"props":3338,"children":3340},{"className":3339},[],[3341],{"type":52,"value":3342},"f.is_historical = 0",{"type":52,"value":3344}," — exclude deleted\u002Frenamed functions that are still in the graph as historical records",{"type":46,"tag":108,"props":3346,"children":3347},{},[3348,3357],{"type":46,"tag":61,"props":3349,"children":3350},{},[3351],{"type":46,"tag":164,"props":3352,"children":3354},{"className":3353},[],[3355],{"type":52,"value":3356},"f.is_external = 0",{"type":52,"value":3358}," (on File nodes) — exclude system headers\u002Flibrary files",{"type":46,"tag":108,"props":3360,"children":3361},{},[3362,3371,3373,3378,3380,3386],{"type":46,"tag":61,"props":3363,"children":3364},{},[3365],{"type":46,"tag":164,"props":3366,"children":3368},{"className":3367},[],[3369],{"type":52,"value":3370},"c.version_tag = 'bf'",{"type":52,"value":3372}," — only backfilled commits have ",{"type":46,"tag":164,"props":3374,"children":3376},{"className":3375},[],[3377],{"type":52,"value":553},{"type":52,"value":3379}," edges; non-backfilled commits only have ",{"type":46,"tag":164,"props":3381,"children":3383},{"className":3382},[],[3384],{"type":52,"value":3385},"TOUCHES",{"type":52,"value":3387}," (file-level) edges",{"type":46,"tag":108,"props":3389,"children":3390},{},[3391,3402],{"type":46,"tag":61,"props":3392,"children":3393},{},[3394,3396],{"type":52,"value":3395},"Always use ",{"type":46,"tag":164,"props":3397,"children":3399},{"className":3398},[],[3400],{"type":52,"value":3401},"LIMIT",{"type":52,"value":3403}," — large codebases can return hundreds of thousands of rows",{"type":46,"tag":97,"props":3405,"children":3407},{"id":3406},"checking-data-availability",[3408],{"type":52,"value":3409},"Checking Data Availability",{"type":46,"tag":55,"props":3411,"children":3412},{},[3413],{"type":52,"value":3414},"Before running evolution queries, check what's available:",{"type":46,"tag":186,"props":3416,"children":3418},{"className":657,"code":3417,"language":25,"meta":191,"style":191},"# How many commits are indexed?\nlist(cs.conn.execute(\"MATCH (c:Commit) RETURN count(c)\"))\n\n# How many have MODIFIES edges (backfilled)?\nlist(cs.conn.execute(\"MATCH (c:Commit) WHERE c.version_tag = 'bf' RETURN count(c)\"))\n",[3419],{"type":46,"tag":164,"props":3420,"children":3421},{"__ignoreMap":191},[3422,3430,3438,3445,3453],{"type":46,"tag":197,"props":3423,"children":3424},{"class":199,"line":200},[3425],{"type":46,"tag":197,"props":3426,"children":3427},{},[3428],{"type":52,"value":3429},"# How many commits are indexed?\n",{"type":46,"tag":197,"props":3431,"children":3432},{"class":199,"line":243},[3433],{"type":46,"tag":197,"props":3434,"children":3435},{},[3436],{"type":52,"value":3437},"list(cs.conn.execute(\"MATCH (c:Commit) RETURN count(c)\"))\n",{"type":46,"tag":197,"props":3439,"children":3440},{"class":199,"line":266},[3441],{"type":46,"tag":197,"props":3442,"children":3443},{"emptyLinePlaceholder":270},[3444],{"type":52,"value":273},{"type":46,"tag":197,"props":3446,"children":3447},{"class":199,"line":276},[3448],{"type":46,"tag":197,"props":3449,"children":3450},{},[3451],{"type":52,"value":3452},"# How many have MODIFIES edges (backfilled)?\n",{"type":46,"tag":197,"props":3454,"children":3455},{"class":199,"line":291},[3456],{"type":46,"tag":197,"props":3457,"children":3458},{},[3459],{"type":52,"value":3460},"list(cs.conn.execute(\"MATCH (c:Commit) WHERE c.version_tag = 'bf' RETURN count(c)\"))\n",{"type":46,"tag":55,"props":3462,"children":3463},{},[3464,3466,3472,3474,3479,3481,3486],{"type":52,"value":3465},"If no commits exist, evolution methods will return empty results — guide the user to run ",{"type":46,"tag":164,"props":3467,"children":3469},{"className":3468},[],[3470],{"type":52,"value":3471},"codegraph ingest",{"type":52,"value":3473}," first. If commits exist but aren't backfilled, ",{"type":46,"tag":164,"props":3475,"children":3477},{"className":3476},[],[3478],{"type":52,"value":3385},{"type":52,"value":3480}," (file-level) queries still work but ",{"type":46,"tag":164,"props":3482,"children":3484},{"className":3483},[],[3485],{"type":52,"value":553},{"type":52,"value":3487}," (function-level) queries won't.",{"type":46,"tag":97,"props":3489,"children":3491},{"id":3490},"troubleshooting",[3492],{"type":52,"value":3493},"Troubleshooting",{"type":46,"tag":808,"props":3495,"children":3496},{},[3497,3518],{"type":46,"tag":812,"props":3498,"children":3499},{},[3500],{"type":46,"tag":816,"props":3501,"children":3502},{},[3503,3508,3513],{"type":46,"tag":820,"props":3504,"children":3505},{},[3506],{"type":52,"value":3507},"Error",{"type":46,"tag":820,"props":3509,"children":3510},{},[3511],{"type":52,"value":3512},"Cause",{"type":46,"tag":820,"props":3514,"children":3515},{},[3516],{"type":52,"value":3517},"Fix",{"type":46,"tag":831,"props":3519,"children":3520},{},[3521,3547,3573,3595],{"type":46,"tag":816,"props":3522,"children":3523},{},[3524,3533,3538],{"type":46,"tag":838,"props":3525,"children":3526},{},[3527],{"type":46,"tag":164,"props":3528,"children":3530},{"className":3529},[],[3531],{"type":52,"value":3532},"Database locked",{"type":46,"tag":838,"props":3534,"children":3535},{},[3536],{"type":52,"value":3537},"Crashed process left neug lock",{"type":46,"tag":838,"props":3539,"children":3540},{},[3541],{"type":46,"tag":164,"props":3542,"children":3544},{"className":3543},[],[3545],{"type":52,"value":3546},"rm \u003Cdb>\u002Fgraph.db\u002Fneugdb.lock",{"type":46,"tag":816,"props":3548,"children":3549},{},[3550,3559,3564],{"type":46,"tag":838,"props":3551,"children":3552},{},[3553],{"type":46,"tag":164,"props":3554,"children":3556},{"className":3555},[],[3557],{"type":52,"value":3558},"Can't open lock file",{"type":46,"tag":838,"props":3560,"children":3561},{},[3562],{"type":52,"value":3563},"zvec LOCK file deleted",{"type":46,"tag":838,"props":3565,"children":3566},{},[3567],{"type":46,"tag":164,"props":3568,"children":3570},{"className":3569},[],[3571],{"type":52,"value":3572},"touch \u003Cdb>\u002Fvectors\u002FLOCK",{"type":46,"tag":816,"props":3574,"children":3575},{},[3576,3585,3590],{"type":46,"tag":838,"props":3577,"children":3578},{},[3579],{"type":46,"tag":164,"props":3580,"children":3582},{"className":3581},[],[3583],{"type":52,"value":3584},"Can't lock read-write collection",{"type":46,"tag":838,"props":3586,"children":3587},{},[3588],{"type":52,"value":3589},"Another process holds lock",{"type":46,"tag":838,"props":3591,"children":3592},{},[3593],{"type":52,"value":3594},"Kill the other process",{"type":46,"tag":816,"props":3596,"children":3597},{},[3598,3607,3612],{"type":46,"tag":838,"props":3599,"children":3600},{},[3601],{"type":46,"tag":164,"props":3602,"children":3604},{"className":3603},[],[3605],{"type":52,"value":3606},"recovery idmap failed",{"type":46,"tag":838,"props":3608,"children":3609},{},[3610],{"type":52,"value":3611},"Stale WAL files",{"type":46,"tag":838,"props":3613,"children":3614},{},[3615,3617,3623,3625],{"type":52,"value":3616},"Remove empty ",{"type":46,"tag":164,"props":3618,"children":3620},{"className":3619},[],[3621],{"type":52,"value":3622},".log",{"type":52,"value":3624}," files from ",{"type":46,"tag":164,"props":3626,"children":3628},{"className":3627},[],[3629],{"type":52,"value":3630},"\u003Cdb>\u002Fvectors\u002Fidmap.0\u002F",{"type":46,"tag":55,"props":3632,"children":3633},{},[3634],{"type":52,"value":3635},"The CLI auto-cleans lock issues on startup when possible.",{"type":46,"tag":97,"props":3637,"children":3639},{"id":3638},"references",[3640],{"type":52,"value":3641},"References",{"type":46,"tag":104,"props":3643,"children":3644},{},[3645,3659,3671],{"type":46,"tag":108,"props":3646,"children":3647},{},[3648,3657],{"type":46,"tag":61,"props":3649,"children":3650},{},[3651],{"type":46,"tag":3302,"props":3652,"children":3654},{"href":3653},".\u002Fschema.md",[3655],{"type":52,"value":3656},"schema.md",{"type":52,"value":3658}," — Full graph schema: node types, edge types, properties, Cypher syntax notes",{"type":46,"tag":108,"props":3660,"children":3661},{},[3662,3669],{"type":46,"tag":61,"props":3663,"children":3664},{},[3665],{"type":46,"tag":3302,"props":3666,"children":3667},{"href":3304},[3668],{"type":52,"value":3307},{"type":52,"value":3670}," — Ready-to-use Cypher query templates and composition strategies",{"type":46,"tag":108,"props":3672,"children":3673},{},[3674,3681],{"type":46,"tag":61,"props":3675,"children":3676},{},[3677],{"type":46,"tag":3302,"props":3678,"children":3679},{"href":3312},[3680],{"type":52,"value":3315},{"type":52,"value":3682}," — Bug analysis workflows: single issue, batch analysis, hotspot aggregation, custom pipelines",{"type":46,"tag":3684,"props":3685,"children":3686},"style",{},[3687],{"type":52,"value":3688},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"items":3690,"total":362},[3691,3713,3732,3740,3752,3765,3796],{"slug":3692,"name":3692,"fn":3693,"description":3694,"org":3695,"tags":3696,"stars":29,"repoUrl":30,"updatedAt":3712},"auto-pr","automate pull request submission and review","Automated PR submission assistant, including code review, documentation generation, and PR creation",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3697,3700,3703,3706,3709],{"name":3698,"slug":3699,"type":16},"Automation","automation",{"name":3701,"slug":3702,"type":16},"Code Review","code-review",{"name":3704,"slug":3705,"type":16},"Documentation","documentation",{"name":3707,"slug":3708,"type":16},"GitHub","github",{"name":3710,"slug":3711,"type":16},"Pull Requests","pull-requests","2026-07-16T06:00:01.890524",{"slug":3714,"name":3714,"fn":3715,"description":3716,"org":3717,"tags":3718,"stars":29,"repoUrl":30,"updatedAt":3731},"browser-use","automate web browser interactions","Control browser pages using the Playwright MCP server. Use when the user asks to open, inspect, navigate, click, type, test, or automate websites, localhost web apps, browser tabs, forms, and web UI.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3719,3722,3725,3728],{"name":3720,"slug":3721,"type":16},"Browser Automation","browser-automation",{"name":3723,"slug":3724,"type":16},"MCP","mcp",{"name":3726,"slug":3727,"type":16},"Playwright","playwright",{"name":3729,"slug":3730,"type":16},"Testing","testing","2026-07-16T06:00:52.14183",{"slug":4,"name":4,"fn":5,"description":6,"org":3733,"tags":3734,"stars":29,"repoUrl":30,"updatedAt":31},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3735,3736,3737,3738,3739],{"name":27,"slug":28,"type":16},{"name":14,"slug":15,"type":16},{"name":21,"slug":22,"type":16},{"name":24,"slug":25,"type":16},{"name":18,"slug":19,"type":16},{"slug":3741,"name":3741,"fn":3742,"description":3743,"org":3744,"tags":3745,"stars":29,"repoUrl":30,"updatedAt":3751},"computer-use","control local desktop applications","Control the local desktop using the `computer` MCP tool from computer-use-mcp. Use when the user asks to operate local Mac\u002FWindows apps, inspect the screen, click UI, type text, press shortcuts, scroll, drag, or interact with native GUI software.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3746,3747,3750],{"name":3698,"slug":3699,"type":16},{"name":3748,"slug":3749,"type":16},"Desktop","desktop",{"name":3723,"slug":3724,"type":16},"2026-07-16T05:59:22.346785",{"slug":3753,"name":3753,"fn":3754,"description":3755,"org":3756,"tags":3757,"stars":29,"repoUrl":30,"updatedAt":3764},"computer-use-hybrid","control desktop apps with hybrid context","Control native macOS, Windows, and Linux desktop apps through the `open-computer-use` MCP server. Use when the user asks to operate local apps with accessibility-tree context plus screenshots, inspect the screen, click UI, type text, press shortcuts, scroll, drag, or interact with OS-level GUI software.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3758,3761,3762,3763],{"name":3759,"slug":3760,"type":16},"Accessibility","accessibility",{"name":3698,"slug":3699,"type":16},{"name":3748,"slug":3749,"type":16},{"name":3723,"slug":3724,"type":16},"2026-07-16T06:00:52.479995",{"slug":3766,"name":3766,"fn":3767,"description":3768,"org":3769,"tags":3770,"stars":29,"repoUrl":30,"updatedAt":3795},"dashboard-builder","build full-stack dashboard applications","Build full-stack dashboard applications using React\u002FNext.js + shadcn\u002Fui + Tailwind CSS + Recharts + Express with customizable data sources. Use when creating data visualization dashboards, business intelligence interfaces, monitoring systems, KPI displays, analytics platforms, or any project requiring data visualization with modern UI components and dynamic effects.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3771,3774,3777,3780,3783,3786,3789,3792],{"name":3772,"slug":3773,"type":16},"Dashboards","dashboards",{"name":3775,"slug":3776,"type":16},"Data Visualization","data-visualization",{"name":3778,"slug":3779,"type":16},"Express","express",{"name":3781,"slug":3782,"type":16},"Frontend","frontend",{"name":3784,"slug":3785,"type":16},"Next.js","next-js",{"name":3787,"slug":3788,"type":16},"React","react",{"name":3790,"slug":3791,"type":16},"shadcn\u002Fui","shadcn-ui",{"name":3793,"slug":3794,"type":16},"Tailwind CSS","tailwind-css","2026-07-16T06:01:27.983011",{"slug":3797,"name":3797,"fn":3798,"description":3799,"org":3800,"tags":3801,"stars":29,"repoUrl":30,"updatedAt":3810},"image-generation","generate images from text descriptions","Image generation skill based on Alibaba Cloud DashScope, supporting the creation of high-quality hand-drawn or standard images from user descriptions.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3802,3805,3808],{"name":3803,"slug":3804,"type":16},"Creative","creative",{"name":3806,"slug":3807,"type":16},"Generative Art","generative-art",{"name":3809,"slug":3797,"type":16},"Image Generation","2026-07-16T06:01:27.641573",{"items":3812,"total":2607},[3813,3826,3837,3849,3863,3877,3893,3907,3918,3930,3942,3957],{"slug":3814,"name":3814,"fn":3815,"description":3816,"org":3817,"tags":3818,"stars":3823,"repoUrl":3824,"updatedAt":3825},"batch","execute parallel batch operations on files","Execute batch operations on multiple files in parallel. Automatically discovers files, splits into chunks, and processes with parallel worker agents. Use `\u002Fbatch` followed by operation and file pattern.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3819,3820],{"name":3698,"slug":3699,"type":16},{"name":3821,"slug":3822,"type":16},"Concurrency","concurrency",26008,"https:\u002F\u002Fgithub.com\u002FQwenLM\u002Fqwen-code","2026-07-20T05:58:45.650067",{"slug":3827,"name":3827,"fn":3828,"description":3829,"org":3830,"tags":3831,"stars":3823,"repoUrl":3824,"updatedAt":3836},"cua-driver-rs","drive native GUI applications via MCP","Drive a native GUI app (macOS, Windows, Linux) via the cua-driver CLI (default) or MCP server — snapshot its accessibility tree, click\u002Ftype\u002Fscroll by element_index or pixel coords, verify via re-snapshot, all without bringing the target to the foreground. Use when the user asks you to operate, drive, automate, or perform a GUI task in a real application on the host.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3832,3833,3834,3835],{"name":3759,"slug":3760,"type":16},{"name":3720,"slug":3721,"type":16},{"name":3748,"slug":3749,"type":16},{"name":3723,"slug":3724,"type":16},"2026-07-16T05:59:28.687299",{"slug":3838,"name":3838,"fn":3839,"description":3840,"org":3841,"tags":3842,"stars":3823,"repoUrl":3824,"updatedAt":3848},"dataviz","design and validate data visualizations","Design guidance for charts, graphs, dashboards, maps, and data visualizations, including a local palette validator.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3843,3846,3847],{"name":3844,"slug":3845,"type":16},"Charts","charts",{"name":3772,"slug":3773,"type":16},{"name":3775,"slug":3776,"type":16},"2026-07-16T05:59:28.31755",{"slug":3850,"name":3850,"fn":3851,"description":3852,"org":3853,"tags":3854,"stars":3823,"repoUrl":3824,"updatedAt":3862},"extension-creator","create Qwen Code extensions","Create, scaffold, customize, validate, and locally test Qwen Code extensions. Use when the user wants a new Qwen Code extension, needs help choosing an extension template, wants to add QWEN.md context, commands, skills, agents, MCP servers, settings, hooks, channels, or LSP servers, or asks how to link and test an extension locally. Invoke with `\u002Fextension-creator` followed by an extension path and optional template name.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3855,3858,3859],{"name":3856,"slug":3857,"type":16},"Coding","coding",{"name":3704,"slug":3705,"type":16},{"name":3860,"slug":3861,"type":16},"Plugin Development","plugin-development","2026-07-16T05:59:24.818967",{"slug":3864,"name":3864,"fn":3865,"description":3866,"org":3867,"tags":3868,"stars":3823,"repoUrl":3824,"updatedAt":3876},"loop","run scheduled or self-paced prompt loops","Create a loop that runs a prompt now and follows up either on a fixed schedule or through self-paced wakeups. Usage - \u002Floop check the build, \u002Floop 5m check the build, \u002Floop check the PR every 30m. \u002Floop list to show jobs, \u002Floop clear to cancel all.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3869,3870,3873],{"name":3698,"slug":3699,"type":16},{"name":3871,"slug":3872,"type":16},"Productivity","productivity",{"name":3874,"slug":3875,"type":16},"Scheduling","scheduling","2026-07-16T05:59:25.50027",{"slug":3878,"name":3878,"fn":3879,"description":3880,"org":3881,"tags":3882,"stars":3823,"repoUrl":3824,"updatedAt":3892},"new-app","build new applications from scratch","Workflow for creating new applications from scratch. Covers requirements gathering, tech stack selection, scaffolding, implementation, and delivery of a functional prototype.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3883,3886,3889],{"name":3884,"slug":3885,"type":16},"Engineering","engineering",{"name":3887,"slug":3888,"type":16},"Prototyping","prototyping",{"name":3890,"slug":3891,"type":16},"Web Development","web-development","2026-07-16T05:59:25.157573",{"slug":3894,"name":3894,"fn":3895,"description":3896,"org":3897,"tags":3898,"stars":3823,"repoUrl":3824,"updatedAt":3906},"qc-helper","provide Qwen Code usage and configuration support","Answer any question about Qwen Code usage, features, configuration, and troubleshooting by referencing the official user documentation. Also helps users view or modify their settings.json. Invoke with `\u002Fqc-helper` followed by a question, e.g. `\u002Fqc-helper how do I configure MCP servers?` or `\u002Fqc-helper change approval mode to yolo`.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3899,3902,3903],{"name":3900,"slug":3901,"type":16},"Configuration","configuration",{"name":3704,"slug":3705,"type":16},{"name":3904,"slug":3905,"type":16},"Reference","reference","2026-07-16T05:59:29.118413",{"slug":3908,"name":3908,"fn":3909,"description":3910,"org":3911,"tags":3912,"stars":3823,"repoUrl":3824,"updatedAt":3917},"review","review code for quality and security","Review changed code for correctness, security, code quality, and performance. Use when the user asks to review code changes, a PR, or specific files. Invoke with `\u002Freview`, `\u002Freview \u003Cpr-number>`, `\u002Freview \u003Cfile-path>`, or `\u002Freview \u003Cpr-number> --comment` to post inline comments on the PR. Add `--effort low|medium|high` to trade depth for speed (defaults to high for PRs, medium for local changes).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3913,3914],{"name":3701,"slug":3702,"type":16},{"name":3915,"slug":3916,"type":16},"Security","security","2026-07-30T05:30:17.682893",{"slug":3919,"name":3919,"fn":3920,"description":3921,"org":3922,"tags":3923,"stars":3823,"repoUrl":3824,"updatedAt":3929},"simplify","clean up and simplify code changes","Review recent code changes for reuse, code quality, and efficiency, then directly apply straightforward cleanup improvements. Use when the user wants a post-implementation cleanup pass, pre-PR polish, or asks to simplify\u002Frefine recent changes. Invoke with `\u002Fsimplify` or `\u002Fsimplify \u003Cfocus>`.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3924,3925,3926],{"name":27,"slug":28,"type":16},{"name":3884,"slug":3885,"type":16},{"name":3927,"slug":3928,"type":16},"Performance","performance","2026-07-20T05:58:46.653811",{"slug":3931,"name":3931,"fn":3932,"description":3933,"org":3934,"tags":3935,"stars":3823,"repoUrl":3824,"updatedAt":3941},"stuck","diagnose and debug stuck Qwen Code sessions","Diagnose frozen, stuck, or slow Qwen Code sessions on this machine. Scans for problematic processes, high CPU\u002Fmemory usage, hung subprocesses, and debug logs. Use \u002Fstuck or \u002Fstuck \u003CPID> to focus on a specific process.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3936,3939,3940],{"name":3937,"slug":3938,"type":16},"Debugging","debugging",{"name":3884,"slug":3885,"type":16},{"name":3927,"slug":3928,"type":16},"2026-07-16T05:59:25.838629",{"slug":3943,"name":3943,"fn":3944,"description":3945,"org":3946,"tags":3947,"stars":3954,"repoUrl":3955,"updatedAt":3956},"open-computer-use","configure Open Computer Use MCP server","Platform-neutral guidance for using Open Computer Use, the open-source Computer Use MCP server and CLI for macOS, Linux, and Windows. Use when an agent needs to install, verify, troubleshoot, configure, or operate Open Computer Use through its native CLI, stdio MCP server, or direct Computer Use tool calls.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3948,3949,3952,3953],{"name":3698,"slug":3699,"type":16},{"name":3950,"slug":3951,"type":16},"CLI","cli",{"name":3748,"slug":3749,"type":16},{"name":3723,"slug":3724,"type":16},176,"https:\u002F\u002Fgithub.com\u002FQwenLM\u002Fopen-computer-use","2026-07-16T05:59:22.010839",{"slug":3692,"name":3692,"fn":3693,"description":3694,"org":3958,"tags":3959,"stars":29,"repoUrl":30,"updatedAt":3712},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3960,3961,3962,3963,3964],{"name":3698,"slug":3699,"type":16},{"name":3701,"slug":3702,"type":16},{"name":3704,"slug":3705,"type":16},{"name":3707,"slug":3708,"type":16},{"name":3710,"slug":3711,"type":16}]