codegraphcontext 0.5.1__tar.gz → 0.5.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {codegraphcontext-0.5.1/src/codegraphcontext.egg-info → codegraphcontext-0.5.2}/PKG-INFO +190 -18
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/README.md +176 -11
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/pyproject.toml +22 -7
- codegraphcontext-0.5.2/src/codegraphcontext/api/mcp_sse.py +105 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/cli_helpers.py +57 -5
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/config_manager.py +103 -8
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/main.py +80 -11
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/setup_wizard.py +61 -56
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/cgcignore.py +4 -1
- codegraphcontext-0.5.1/src/codegraphcontext/core/database_kuzu.py → codegraphcontext-0.5.2/src/codegraphcontext/core/database_embedded_kuzu.py +119 -61
- codegraphcontext-0.5.2/src/codegraphcontext/core/database_kuzu.py +41 -0
- codegraphcontext-0.5.2/src/codegraphcontext/core/database_ladybug.py +41 -0
- codegraphcontext-0.5.2/src/codegraphcontext/core/graph_query.py +45 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/watcher.py +100 -31
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/server.py +57 -14
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/code_finder.py +16 -19
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/graph_builder.py +6 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/embeddings.py +63 -49
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/persistence/writer.py +116 -58
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/pipeline.py +44 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/resolution/calls.py +54 -29
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/resolution/inheritance.py +9 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/scip_pipeline.py +25 -10
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/vector_resolver.py +72 -57
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/python.py +2 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/c_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/csharp_toolkit.py +2 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/dart_toolkit.py +2 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/go_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/haskell_toolkit.py +3 -3
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/javascript_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/perl_toolkit.py +2 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/python_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/ruby_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/rust_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/scala_toolkit.py +2 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/swift_toolkit.py +2 -2
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/typescript_toolkit.py +1 -1
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/scip_indexer.py +45 -3
- codegraphcontext-0.5.2/src/codegraphcontext/tools/tree_sitter_parser.py +66 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/debug_log.py +5 -0
- codegraphcontext-0.5.2/src/codegraphcontext/utils/gcf_encoder.py +58 -0
- codegraphcontext-0.5.2/src/codegraphcontext/utils/visualize_graph.py +462 -0
- codegraphcontext-0.5.2/src/codegraphcontext/viz/server.py +658 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2/src/codegraphcontext.egg-info}/PKG-INFO +190 -18
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext.egg-info/SOURCES.txt +5 -39
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext.egg-info/requires.txt +8 -9
- codegraphcontext-0.5.2/tests/test_mcp_sse.py +56 -0
- codegraphcontext-0.5.1/src/codegraphcontext/api/mcp_sse.py +0 -69
- codegraphcontext-0.5.1/src/codegraphcontext/core/database_ladybug.py +0 -1181
- codegraphcontext-0.5.1/src/codegraphcontext/tools/tree_sitter_parser.py +0 -121
- codegraphcontext-0.5.1/src/codegraphcontext/utils/visualize_graph.py +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/__vite-browser-external-9wXp6ZBx.js +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/function-calls-BtRHrqa2.png +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/graph-total-D1fBAugo.png +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/hero-graph-2voMJp2a.jpg +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/hierarchy-DGADo0YT.png +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/index-C-187lf0.js +0 -5587
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/index-fNAa6jgv.css +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/parser-pyodide.worker-BgsDfaad.js +0 -370
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/parser.worker-_nvrecvj.js +0 -233
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/assets/tree-sitter-qKYAACSa.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/cgcIcon.png +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/favicon.ico +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/index.html +0 -32
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/logo-icon.svg +0 -85
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/logo.svg +0 -100
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/placeholder.svg +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/preview-image.png +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/robots.txt +0 -14
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-c.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-c_sharp.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-core.js +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-cpp.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-dart.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-go.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-java.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-javascript.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-kotlin.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-perl.wasm +0 -1
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-php.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-python.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-ruby.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-rust.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-swift.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-tsx.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter-typescript.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/tree-sitter.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/web-tree-sitter.js +0 -4007
- codegraphcontext-0.5.1/src/codegraphcontext/viz/dist/wasm/web-tree-sitter.wasm +0 -0
- codegraphcontext-0.5.1/src/codegraphcontext/viz/server.py +0 -342
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/LICENSE +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/MANIFEST.in +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/setup.cfg +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/__main__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/api/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/api/app.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/api/router.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/api/schemas.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/hook_manager.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/registry_commands.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/setup_macos.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/cli/visualizer.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/bundle_registry.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/cgc_bundle.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/database.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/database_falkordb.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/database_falkordb_remote.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/database_nornic.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/falkor_worker.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/core/jobs.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/prompts.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/stdlibs.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tool_definitions.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/advanced_language_query_tool.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/datasources/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/datasources/cassandra_ingester.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/datasources/mysql_ingester.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/datasources/redis_ingester.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/handlers/analysis_handlers.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/handlers/indexing_handlers.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/handlers/management_handlers.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/handlers/query_handlers.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/handlers/watcher_handlers.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/constants.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/discovery.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/persistence/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/persistence/utils.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/pre_scan.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/resolution/__init__.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/resolution/post_resolution.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/sanitize.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/schema.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/indexing/schema_contract.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/c.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/cpp.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/csharp.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/css.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/dart.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/elisp.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/elixir.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/go.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/gradle.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/haskell.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/html.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/java.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/javascript.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/kotlin.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/lua.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/maven.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/mybatis.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/perl.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/php.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/ruby.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/rust.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/scala.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/swift.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/typescript.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/languages/typescriptjsx.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/package_resolver.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/cpp_toolkit.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/elisp_toolkit.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/query_tool_languages/java_toolkit.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/report_generator.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/scip_pb2.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/system.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/tools/type_utils.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/cypher_readonly.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/git_utils.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/path_ignore.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/path_sandbox.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/repo_path.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/tool_limits.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext/utils/tree_sitter_manager.py +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext.egg-info/dependency_links.txt +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext.egg-info/entry_points.txt +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/src/codegraphcontext.egg-info/top_level.txt +0 -0
- {codegraphcontext-0.5.1 → codegraphcontext-0.5.2}/tests/test_issue_806_fix.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: codegraphcontext
|
|
3
|
-
Version: 0.5.
|
|
3
|
+
Version: 0.5.2
|
|
4
4
|
Summary: An MCP server that indexes local code into a graph database to provide context to AI assistants.
|
|
5
5
|
Author-email: Shashank Shekhar Singh <shashankshekharsingh1205@gmail.com>
|
|
6
6
|
License: MIT License
|
|
@@ -28,6 +28,11 @@ License: MIT License
|
|
|
28
28
|
Project-URL: Homepage, https://github.com/Shashankss1205/CodeGraphContext
|
|
29
29
|
Project-URL: Bug Tracker, https://github.com/Shashankss1205/CodeGraphContext/issues
|
|
30
30
|
Classifier: Programming Language :: Python :: 3
|
|
31
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
32
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
33
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
34
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
35
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
31
36
|
Classifier: License :: OSI Approved :: MIT License
|
|
32
37
|
Classifier: Operating System :: OS Independent
|
|
33
38
|
Classifier: Development Status :: 3 - Alpha
|
|
@@ -43,9 +48,9 @@ Requires-Dist: typer>=0.9.0
|
|
|
43
48
|
Requires-Dist: rich>=13.7.0
|
|
44
49
|
Requires-Dist: inquirerpy>=0.3.4
|
|
45
50
|
Requires-Dist: python-dotenv>=1.0.0
|
|
46
|
-
Requires-Dist: tree-sitter<0.26.0,>=0.
|
|
47
|
-
Requires-Dist: tree-sitter-language-pack<
|
|
48
|
-
Requires-Dist: tree-sitter-c-sharp>=0.21.0
|
|
51
|
+
Requires-Dist: tree-sitter<0.26.0,>=0.24.0
|
|
52
|
+
Requires-Dist: tree-sitter-language-pack<2.0,>=1.6
|
|
53
|
+
Requires-Dist: tree-sitter-c-sharp>=0.21.0
|
|
49
54
|
Requires-Dist: pyyaml
|
|
50
55
|
Requires-Dist: nbformat
|
|
51
56
|
Requires-Dist: nbconvert>=7.16.6
|
|
@@ -61,9 +66,9 @@ Requires-Dist: mcp>=1.0.0
|
|
|
61
66
|
Requires-Dist: fastapi>=0.100.0
|
|
62
67
|
Requires-Dist: uvicorn>=0.22.0
|
|
63
68
|
Provides-Extra: parsing
|
|
64
|
-
Requires-Dist: tree-sitter<0.26.0,>=0.
|
|
65
|
-
Requires-Dist: tree-sitter-language-pack<
|
|
66
|
-
Requires-Dist: tree-sitter-c-sharp>=0.21.0;
|
|
69
|
+
Requires-Dist: tree-sitter<0.26.0,>=0.24.0; extra == "parsing"
|
|
70
|
+
Requires-Dist: tree-sitter-language-pack<2.0,>=1.6; extra == "parsing"
|
|
71
|
+
Requires-Dist: tree-sitter-c-sharp>=0.21.0; extra == "parsing"
|
|
67
72
|
Provides-Extra: falkordb-embedded
|
|
68
73
|
Requires-Dist: falkordblite<0.10,>=0.7; (sys_platform != "win32" and python_version >= "3.12") and extra == "falkordb-embedded"
|
|
69
74
|
Requires-Dist: falkordb<1.6,>=1.0; extra == "falkordb-embedded"
|
|
@@ -77,6 +82,8 @@ Provides-Extra: ladybug
|
|
|
77
82
|
Requires-Dist: ladybug; (sys_platform == "win32" or (sys_platform != "win32" and python_version >= "3.10")) and extra == "ladybug"
|
|
78
83
|
Provides-Extra: neo4j
|
|
79
84
|
Requires-Dist: neo4j>=5.15.0; extra == "neo4j"
|
|
85
|
+
Provides-Extra: gcf
|
|
86
|
+
Requires-Dist: gcf-python>=1.0.0; extra == "gcf"
|
|
80
87
|
Provides-Extra: dev
|
|
81
88
|
Requires-Dist: pytest>=7.4.0; extra == "dev"
|
|
82
89
|
Requires-Dist: black>=23.11.0; extra == "dev"
|
|
@@ -102,7 +109,7 @@ Dynamic: license-file
|
|
|
102
109
|
- 🇯🇵 [日本語](docs/translations/README.ja.md)
|
|
103
110
|
- 🇪🇸 Español (Soon)
|
|
104
111
|
|
|
105
|
-
🌍 **Help translate CodeGraphContext to your language by raising an issue & PR on [GitHub Issues](https://github.com/
|
|
112
|
+
🌍 **Help translate CodeGraphContext to your language by raising an issue & PR on [GitHub Issues](https://github.com/CodeGraphContext/CodeGraphContext/issues)!**
|
|
106
113
|
|
|
107
114
|
<p align="center">
|
|
108
115
|
<br>
|
|
@@ -190,6 +197,43 @@ A powerful **MCP server** and **CLI toolkit** that indexes local code into a gra
|
|
|
190
197
|
|
|
191
198
|
---
|
|
192
199
|
|
|
200
|
+
## Why CodeGraphContext?
|
|
201
|
+
|
|
202
|
+
CodeGraphContext is built for the moment when plain text search stops being enough. It turns a repository into a graph of files, symbols, calls, inheritance, imports, and relationships so you can move from "where is this defined?" to "how does this actually connect?" without jumping between tools.
|
|
203
|
+
|
|
204
|
+
```mermaid
|
|
205
|
+
flowchart LR
|
|
206
|
+
A[Source code] --> B[Tree-sitter and SCIP indexers]
|
|
207
|
+
B --> C[Graph database]
|
|
208
|
+
C --> D[CLI queries]
|
|
209
|
+
C --> E[MCP server]
|
|
210
|
+
D --> F[Direct analysis]
|
|
211
|
+
E --> G[AI assistants with repo context]
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
### Comparison at a glance
|
|
215
|
+
|
|
216
|
+
| Approach | Best for | Tradeoff |
|
|
217
|
+
| --- | --- | --- |
|
|
218
|
+
| `grep` / file search | Exact string lookup | Misses relationships and code structure |
|
|
219
|
+
| RAG over code chunks | Natural-language retrieval | Can lose symbol-level precision |
|
|
220
|
+
| CodeGraphContext | Repository-wide reasoning | Requires an indexing step |
|
|
221
|
+
|
|
222
|
+
### Common use cases
|
|
223
|
+
|
|
224
|
+
- Trace call chains across files and packages.
|
|
225
|
+
- Understand class hierarchies, imports, and module boundaries.
|
|
226
|
+
- Find dead code, hotspots, and unexpected dependencies.
|
|
227
|
+
- Give an AI assistant the same structural context a maintainer would use.
|
|
228
|
+
|
|
229
|
+
### FAQ
|
|
230
|
+
|
|
231
|
+
- **Do I need a remote service?** No. CGC works locally with embedded backends or with external graph databases when you want them.
|
|
232
|
+
- **Is it only for one language?** No. It supports a broad mix of mainstream languages and keeps expanding.
|
|
233
|
+
- **Can I use it with an AI assistant?** Yes. That is one of the main reasons the MCP server exists.
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
193
237
|
## Project Details
|
|
194
238
|
- **Version:** 0.5.1
|
|
195
239
|
- **Authors:** Shashank Shekhar Singh <shashankshekharsingh1205@gmail.com>
|
|
@@ -227,6 +271,29 @@ A powerful **MCP server** and **CLI toolkit** that indexes local code into a gra
|
|
|
227
271
|
- **Flexible Database Backend:** FalkorDB Lite (Default), KuzuDB, LadybugDB, FalkorDB Remote, Nornic DB, or Neo4j (all platforms via Docker/native).
|
|
228
272
|
|
|
229
273
|
|
|
274
|
+
---
|
|
275
|
+
|
|
276
|
+
## 🏗️ Architecture & Workflow
|
|
277
|
+
|
|
278
|
+
CodeGraphContext parses your source code and builds a comprehensive knowledge graph. This graph can be queried directly via the CLI toolkit or exposed to AI assistants through the MCP server.
|
|
279
|
+
|
|
280
|
+
```mermaid
|
|
281
|
+
flowchart TD
|
|
282
|
+
A[Code Repository] -->|Parsed by| B[Tree-sitter / SCIP Indexing]
|
|
283
|
+
B -->|Generates| C[Knowledge Graph]
|
|
284
|
+
C -->|Stored in| D[(Graph Database)]
|
|
285
|
+
D -->|Queried via| E[CLI Toolkit]
|
|
286
|
+
D -->|Served by| F[MCP Server]
|
|
287
|
+
F -->|Provides context to| G[🤖 AI Assistant]
|
|
288
|
+
|
|
289
|
+
classDef default fill:#1f2937,stroke:#8b5cf6,stroke-width:2px,color:#fff;
|
|
290
|
+
classDef db fill:#0f172a,stroke:#3b82f6,stroke-width:2px,color:#fff;
|
|
291
|
+
classDef ai fill:#312e81,stroke:#a855f7,stroke-width:2px,color:#fff;
|
|
292
|
+
|
|
293
|
+
D:::db
|
|
294
|
+
G:::ai
|
|
295
|
+
```
|
|
296
|
+
|
|
230
297
|
---
|
|
231
298
|
|
|
232
299
|
## Supported Programming Languages
|
|
@@ -297,8 +364,8 @@ _If you’re using CodeGraphContext in your project, feel free to open a PR and
|
|
|
297
364
|
- `rich>=13.7.0`
|
|
298
365
|
- `inquirerpy>=0.3.4`
|
|
299
366
|
- `python-dotenv>=1.0.0`
|
|
300
|
-
- `tree-sitter>=0.
|
|
301
|
-
- `tree-sitter-language-pack>=
|
|
367
|
+
- `tree-sitter>=0.24.0,<0.26.0`
|
|
368
|
+
- `tree-sitter-language-pack>=1.6,<2.0`
|
|
302
369
|
- `pyyaml`
|
|
303
370
|
- `pathspec>=0.12.1`
|
|
304
371
|
- `falkordb>=1.0,<1.6`
|
|
@@ -332,6 +399,87 @@ _If you’re using CodeGraphContext in your project, feel free to open a PR and
|
|
|
332
399
|
- **KuzuDB:** Cross-platform embedded backend.
|
|
333
400
|
- **Neo4j:** Run `codegraphcontext neo4j setup` to use an external server.
|
|
334
401
|
|
|
402
|
+
### 🧪 Local Development Setup
|
|
403
|
+
|
|
404
|
+
If you want to run CodeGraphContext from a local clone and contribute changes, use an editable install:
|
|
405
|
+
|
|
406
|
+
```bash
|
|
407
|
+
git clone https://github.com/CodeGraphContext/CodeGraphContext.git
|
|
408
|
+
cd CodeGraphContext
|
|
409
|
+
python -m venv .venv
|
|
410
|
+
source .venv/bin/activate
|
|
411
|
+
pip install -e ".[dev]"
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
Then verify the install and try the local commands:
|
|
415
|
+
|
|
416
|
+
```bash
|
|
417
|
+
cgc --help
|
|
418
|
+
cgc doctor
|
|
419
|
+
cgc index .
|
|
420
|
+
cgc analyze callers main
|
|
421
|
+
```
|
|
422
|
+
|
|
423
|
+
For MCP server work, finish the setup with:
|
|
424
|
+
|
|
425
|
+
```bash
|
|
426
|
+
cgc mcp setup
|
|
427
|
+
cgc mcp start
|
|
428
|
+
```
|
|
429
|
+
|
|
430
|
+
If you are only installing the published package, `pip install codegraphcontext` is enough. If you are developing parser-heavy features and want the optional parsing extras too, install with `pip install -e ".[dev,parsing]"`.
|
|
431
|
+
|
|
432
|
+
---
|
|
433
|
+
|
|
434
|
+
## 🐳 Docker (No Python Required)
|
|
435
|
+
|
|
436
|
+
Run CodeGraphContext without installing Python — pull the image and start indexing:
|
|
437
|
+
|
|
438
|
+
### Quick Start
|
|
439
|
+
```bash
|
|
440
|
+
# Pull the latest image
|
|
441
|
+
docker pull codegraphcontext/codegraphcontext:latest
|
|
442
|
+
|
|
443
|
+
# Index your current directory
|
|
444
|
+
docker run --rm -v "$(pwd):/workspace" codegraphcontext/codegraphcontext cgc index .
|
|
445
|
+
|
|
446
|
+
# List indexed repos
|
|
447
|
+
docker run --rm -v cgc-data:/home/cgc/.codegraphcontext \
|
|
448
|
+
codegraphcontext/codegraphcontext cgc list
|
|
449
|
+
|
|
450
|
+
# Interactive shell
|
|
451
|
+
docker run -it --rm -v "$(pwd):/workspace" \
|
|
452
|
+
-v cgc-data:/home/cgc/.codegraphcontext \
|
|
453
|
+
codegraphcontext/codegraphcontext bash
|
|
454
|
+
```
|
|
455
|
+
|
|
456
|
+
### Docker Compose
|
|
457
|
+
```bash
|
|
458
|
+
# Clone the repo and start with Docker Compose
|
|
459
|
+
git clone https://github.com/CodeGraphContext/CodeGraphContext.git
|
|
460
|
+
cd CodeGraphContext
|
|
461
|
+
|
|
462
|
+
# Start with embedded DB
|
|
463
|
+
docker compose run --rm cgc index .
|
|
464
|
+
|
|
465
|
+
# Start with external FalkorDB
|
|
466
|
+
docker compose --profile falkordb up -d
|
|
467
|
+
|
|
468
|
+
# Start with visualization server
|
|
469
|
+
docker compose --profile viz up -d
|
|
470
|
+
# Open http://localhost:8080
|
|
471
|
+
```
|
|
472
|
+
|
|
473
|
+
### Available Docker Tags
|
|
474
|
+
| Tag | Description |
|
|
475
|
+
|---|---|
|
|
476
|
+
| `latest` | Latest stable release |
|
|
477
|
+
| `edge` | Latest from `main` branch (may be unstable) |
|
|
478
|
+
| `0.4.19` | Specific version |
|
|
479
|
+
| `0.4` | Latest patch in 0.4.x |
|
|
480
|
+
|
|
481
|
+
For more advanced Docker usage, including running the MCP Server or connecting external databases, see our [Comprehensive Docker Guide](docs/DOCKER.md).
|
|
482
|
+
|
|
335
483
|
---
|
|
336
484
|
|
|
337
485
|
## 📋 Prerequisites
|
|
@@ -355,7 +503,7 @@ python --version
|
|
|
355
503
|
### Step 1: Install CodeGraphContext
|
|
356
504
|
|
|
357
505
|
```bash
|
|
358
|
-
pip install codegraphcontext
|
|
506
|
+
pip install codegraphcontext # Installs CodeGraphContext and required dependencies
|
|
359
507
|
```
|
|
360
508
|
|
|
361
509
|
This command installs CodeGraphContext and all required dependencies.
|
|
@@ -379,7 +527,7 @@ CodeGraphContext automatically uses an embedded database by default, so no addit
|
|
|
379
527
|
### Index a Repository
|
|
380
528
|
|
|
381
529
|
```bash
|
|
382
|
-
codegraphcontext index .
|
|
530
|
+
codegraphcontext index . # Scans current directory and builds code graph
|
|
383
531
|
```
|
|
384
532
|
|
|
385
533
|
This scans the current project and creates a searchable code graph.
|
|
@@ -407,7 +555,7 @@ Finds potentially unused code in the indexed repository.
|
|
|
407
555
|
After indexing a repository, run:
|
|
408
556
|
|
|
409
557
|
```bash
|
|
410
|
-
codegraphcontext list
|
|
558
|
+
codegraphcontext list # Shows all indexed repositories in the system
|
|
411
559
|
```
|
|
412
560
|
|
|
413
561
|
If the command executes successfully and displays indexed repositories, your setup is complete and CodeGraphContext is ready to use.
|
|
@@ -536,11 +684,6 @@ Add the following server configuration to your client's settings file (e.g., VS
|
|
|
536
684
|
"mcp",
|
|
537
685
|
"start"
|
|
538
686
|
],
|
|
539
|
-
"env": {
|
|
540
|
-
"NEO4J_URI": "YOUR_NEO4J_URI",
|
|
541
|
-
"NEO4J_USERNAME": "YOUR_NEO4J_USERNAME",
|
|
542
|
-
"NEO4J_PASSWORD": "YOUR_NEO4J_PASSWORD"
|
|
543
|
-
},
|
|
544
687
|
"disabled": false,
|
|
545
688
|
"alwaysAllow": []
|
|
546
689
|
}
|
|
@@ -580,6 +723,35 @@ If you installed CodeGraphContext using `pipx`, use the following configuration
|
|
|
580
723
|
|
|
581
724
|
---
|
|
582
725
|
|
|
726
|
+
## Token-Optimized Output (GCF)
|
|
727
|
+
|
|
728
|
+
Reduce tool response tokens by ~62% with the opt-in [GCF](https://gcformat.com) output format:
|
|
729
|
+
|
|
730
|
+
```bash
|
|
731
|
+
pip install gcf-python
|
|
732
|
+
CGC_OUTPUT_FORMAT=gcf codegraphcontext mcp start
|
|
733
|
+
```
|
|
734
|
+
|
|
735
|
+
Or add it to your MCP client config:
|
|
736
|
+
|
|
737
|
+
```json
|
|
738
|
+
{
|
|
739
|
+
"mcpServers": {
|
|
740
|
+
"CodeGraphContext": {
|
|
741
|
+
"command": "codegraphcontext",
|
|
742
|
+
"args": ["mcp", "start"],
|
|
743
|
+
"env": {
|
|
744
|
+
"CGC_OUTPUT_FORMAT": "gcf"
|
|
745
|
+
}
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
}
|
|
749
|
+
```
|
|
750
|
+
|
|
751
|
+
GCF encodes structured data with positional fields (keys declared once, values pipe-delimited). Code graph query results (symbols, relationships, callers, complexity) are exactly the data shape where GCF saves the most. 100% LLM comprehension on all frontier models. Falls back to JSON if `gcf-python` is not installed.
|
|
752
|
+
|
|
753
|
+
---
|
|
754
|
+
|
|
583
755
|
## Natural Language Interaction Examples
|
|
584
756
|
|
|
585
757
|
Once the server is running, you can interact with it through your AI assistant using plain English. Here are some examples of what you can say:
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
- 🇯🇵 [日本語](docs/translations/README.ja.md)
|
|
12
12
|
- 🇪🇸 Español (Soon)
|
|
13
13
|
|
|
14
|
-
🌍 **Help translate CodeGraphContext to your language by raising an issue & PR on [GitHub Issues](https://github.com/
|
|
14
|
+
🌍 **Help translate CodeGraphContext to your language by raising an issue & PR on [GitHub Issues](https://github.com/CodeGraphContext/CodeGraphContext/issues)!**
|
|
15
15
|
|
|
16
16
|
<p align="center">
|
|
17
17
|
<br>
|
|
@@ -99,6 +99,43 @@ A powerful **MCP server** and **CLI toolkit** that indexes local code into a gra
|
|
|
99
99
|
|
|
100
100
|
---
|
|
101
101
|
|
|
102
|
+
## Why CodeGraphContext?
|
|
103
|
+
|
|
104
|
+
CodeGraphContext is built for the moment when plain text search stops being enough. It turns a repository into a graph of files, symbols, calls, inheritance, imports, and relationships so you can move from "where is this defined?" to "how does this actually connect?" without jumping between tools.
|
|
105
|
+
|
|
106
|
+
```mermaid
|
|
107
|
+
flowchart LR
|
|
108
|
+
A[Source code] --> B[Tree-sitter and SCIP indexers]
|
|
109
|
+
B --> C[Graph database]
|
|
110
|
+
C --> D[CLI queries]
|
|
111
|
+
C --> E[MCP server]
|
|
112
|
+
D --> F[Direct analysis]
|
|
113
|
+
E --> G[AI assistants with repo context]
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
### Comparison at a glance
|
|
117
|
+
|
|
118
|
+
| Approach | Best for | Tradeoff |
|
|
119
|
+
| --- | --- | --- |
|
|
120
|
+
| `grep` / file search | Exact string lookup | Misses relationships and code structure |
|
|
121
|
+
| RAG over code chunks | Natural-language retrieval | Can lose symbol-level precision |
|
|
122
|
+
| CodeGraphContext | Repository-wide reasoning | Requires an indexing step |
|
|
123
|
+
|
|
124
|
+
### Common use cases
|
|
125
|
+
|
|
126
|
+
- Trace call chains across files and packages.
|
|
127
|
+
- Understand class hierarchies, imports, and module boundaries.
|
|
128
|
+
- Find dead code, hotspots, and unexpected dependencies.
|
|
129
|
+
- Give an AI assistant the same structural context a maintainer would use.
|
|
130
|
+
|
|
131
|
+
### FAQ
|
|
132
|
+
|
|
133
|
+
- **Do I need a remote service?** No. CGC works locally with embedded backends or with external graph databases when you want them.
|
|
134
|
+
- **Is it only for one language?** No. It supports a broad mix of mainstream languages and keeps expanding.
|
|
135
|
+
- **Can I use it with an AI assistant?** Yes. That is one of the main reasons the MCP server exists.
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
102
139
|
## Project Details
|
|
103
140
|
- **Version:** 0.5.1
|
|
104
141
|
- **Authors:** Shashank Shekhar Singh <shashankshekharsingh1205@gmail.com>
|
|
@@ -136,6 +173,29 @@ A powerful **MCP server** and **CLI toolkit** that indexes local code into a gra
|
|
|
136
173
|
- **Flexible Database Backend:** FalkorDB Lite (Default), KuzuDB, LadybugDB, FalkorDB Remote, Nornic DB, or Neo4j (all platforms via Docker/native).
|
|
137
174
|
|
|
138
175
|
|
|
176
|
+
---
|
|
177
|
+
|
|
178
|
+
## 🏗️ Architecture & Workflow
|
|
179
|
+
|
|
180
|
+
CodeGraphContext parses your source code and builds a comprehensive knowledge graph. This graph can be queried directly via the CLI toolkit or exposed to AI assistants through the MCP server.
|
|
181
|
+
|
|
182
|
+
```mermaid
|
|
183
|
+
flowchart TD
|
|
184
|
+
A[Code Repository] -->|Parsed by| B[Tree-sitter / SCIP Indexing]
|
|
185
|
+
B -->|Generates| C[Knowledge Graph]
|
|
186
|
+
C -->|Stored in| D[(Graph Database)]
|
|
187
|
+
D -->|Queried via| E[CLI Toolkit]
|
|
188
|
+
D -->|Served by| F[MCP Server]
|
|
189
|
+
F -->|Provides context to| G[🤖 AI Assistant]
|
|
190
|
+
|
|
191
|
+
classDef default fill:#1f2937,stroke:#8b5cf6,stroke-width:2px,color:#fff;
|
|
192
|
+
classDef db fill:#0f172a,stroke:#3b82f6,stroke-width:2px,color:#fff;
|
|
193
|
+
classDef ai fill:#312e81,stroke:#a855f7,stroke-width:2px,color:#fff;
|
|
194
|
+
|
|
195
|
+
D:::db
|
|
196
|
+
G:::ai
|
|
197
|
+
```
|
|
198
|
+
|
|
139
199
|
---
|
|
140
200
|
|
|
141
201
|
## Supported Programming Languages
|
|
@@ -206,8 +266,8 @@ _If you’re using CodeGraphContext in your project, feel free to open a PR and
|
|
|
206
266
|
- `rich>=13.7.0`
|
|
207
267
|
- `inquirerpy>=0.3.4`
|
|
208
268
|
- `python-dotenv>=1.0.0`
|
|
209
|
-
- `tree-sitter>=0.
|
|
210
|
-
- `tree-sitter-language-pack>=
|
|
269
|
+
- `tree-sitter>=0.24.0,<0.26.0`
|
|
270
|
+
- `tree-sitter-language-pack>=1.6,<2.0`
|
|
211
271
|
- `pyyaml`
|
|
212
272
|
- `pathspec>=0.12.1`
|
|
213
273
|
- `falkordb>=1.0,<1.6`
|
|
@@ -241,6 +301,87 @@ _If you’re using CodeGraphContext in your project, feel free to open a PR and
|
|
|
241
301
|
- **KuzuDB:** Cross-platform embedded backend.
|
|
242
302
|
- **Neo4j:** Run `codegraphcontext neo4j setup` to use an external server.
|
|
243
303
|
|
|
304
|
+
### 🧪 Local Development Setup
|
|
305
|
+
|
|
306
|
+
If you want to run CodeGraphContext from a local clone and contribute changes, use an editable install:
|
|
307
|
+
|
|
308
|
+
```bash
|
|
309
|
+
git clone https://github.com/CodeGraphContext/CodeGraphContext.git
|
|
310
|
+
cd CodeGraphContext
|
|
311
|
+
python -m venv .venv
|
|
312
|
+
source .venv/bin/activate
|
|
313
|
+
pip install -e ".[dev]"
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
Then verify the install and try the local commands:
|
|
317
|
+
|
|
318
|
+
```bash
|
|
319
|
+
cgc --help
|
|
320
|
+
cgc doctor
|
|
321
|
+
cgc index .
|
|
322
|
+
cgc analyze callers main
|
|
323
|
+
```
|
|
324
|
+
|
|
325
|
+
For MCP server work, finish the setup with:
|
|
326
|
+
|
|
327
|
+
```bash
|
|
328
|
+
cgc mcp setup
|
|
329
|
+
cgc mcp start
|
|
330
|
+
```
|
|
331
|
+
|
|
332
|
+
If you are only installing the published package, `pip install codegraphcontext` is enough. If you are developing parser-heavy features and want the optional parsing extras too, install with `pip install -e ".[dev,parsing]"`.
|
|
333
|
+
|
|
334
|
+
---
|
|
335
|
+
|
|
336
|
+
## 🐳 Docker (No Python Required)
|
|
337
|
+
|
|
338
|
+
Run CodeGraphContext without installing Python — pull the image and start indexing:
|
|
339
|
+
|
|
340
|
+
### Quick Start
|
|
341
|
+
```bash
|
|
342
|
+
# Pull the latest image
|
|
343
|
+
docker pull codegraphcontext/codegraphcontext:latest
|
|
344
|
+
|
|
345
|
+
# Index your current directory
|
|
346
|
+
docker run --rm -v "$(pwd):/workspace" codegraphcontext/codegraphcontext cgc index .
|
|
347
|
+
|
|
348
|
+
# List indexed repos
|
|
349
|
+
docker run --rm -v cgc-data:/home/cgc/.codegraphcontext \
|
|
350
|
+
codegraphcontext/codegraphcontext cgc list
|
|
351
|
+
|
|
352
|
+
# Interactive shell
|
|
353
|
+
docker run -it --rm -v "$(pwd):/workspace" \
|
|
354
|
+
-v cgc-data:/home/cgc/.codegraphcontext \
|
|
355
|
+
codegraphcontext/codegraphcontext bash
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
### Docker Compose
|
|
359
|
+
```bash
|
|
360
|
+
# Clone the repo and start with Docker Compose
|
|
361
|
+
git clone https://github.com/CodeGraphContext/CodeGraphContext.git
|
|
362
|
+
cd CodeGraphContext
|
|
363
|
+
|
|
364
|
+
# Start with embedded DB
|
|
365
|
+
docker compose run --rm cgc index .
|
|
366
|
+
|
|
367
|
+
# Start with external FalkorDB
|
|
368
|
+
docker compose --profile falkordb up -d
|
|
369
|
+
|
|
370
|
+
# Start with visualization server
|
|
371
|
+
docker compose --profile viz up -d
|
|
372
|
+
# Open http://localhost:8080
|
|
373
|
+
```
|
|
374
|
+
|
|
375
|
+
### Available Docker Tags
|
|
376
|
+
| Tag | Description |
|
|
377
|
+
|---|---|
|
|
378
|
+
| `latest` | Latest stable release |
|
|
379
|
+
| `edge` | Latest from `main` branch (may be unstable) |
|
|
380
|
+
| `0.4.19` | Specific version |
|
|
381
|
+
| `0.4` | Latest patch in 0.4.x |
|
|
382
|
+
|
|
383
|
+
For more advanced Docker usage, including running the MCP Server or connecting external databases, see our [Comprehensive Docker Guide](docs/DOCKER.md).
|
|
384
|
+
|
|
244
385
|
---
|
|
245
386
|
|
|
246
387
|
## 📋 Prerequisites
|
|
@@ -264,7 +405,7 @@ python --version
|
|
|
264
405
|
### Step 1: Install CodeGraphContext
|
|
265
406
|
|
|
266
407
|
```bash
|
|
267
|
-
pip install codegraphcontext
|
|
408
|
+
pip install codegraphcontext # Installs CodeGraphContext and required dependencies
|
|
268
409
|
```
|
|
269
410
|
|
|
270
411
|
This command installs CodeGraphContext and all required dependencies.
|
|
@@ -288,7 +429,7 @@ CodeGraphContext automatically uses an embedded database by default, so no addit
|
|
|
288
429
|
### Index a Repository
|
|
289
430
|
|
|
290
431
|
```bash
|
|
291
|
-
codegraphcontext index .
|
|
432
|
+
codegraphcontext index . # Scans current directory and builds code graph
|
|
292
433
|
```
|
|
293
434
|
|
|
294
435
|
This scans the current project and creates a searchable code graph.
|
|
@@ -316,7 +457,7 @@ Finds potentially unused code in the indexed repository.
|
|
|
316
457
|
After indexing a repository, run:
|
|
317
458
|
|
|
318
459
|
```bash
|
|
319
|
-
codegraphcontext list
|
|
460
|
+
codegraphcontext list # Shows all indexed repositories in the system
|
|
320
461
|
```
|
|
321
462
|
|
|
322
463
|
If the command executes successfully and displays indexed repositories, your setup is complete and CodeGraphContext is ready to use.
|
|
@@ -445,11 +586,6 @@ Add the following server configuration to your client's settings file (e.g., VS
|
|
|
445
586
|
"mcp",
|
|
446
587
|
"start"
|
|
447
588
|
],
|
|
448
|
-
"env": {
|
|
449
|
-
"NEO4J_URI": "YOUR_NEO4J_URI",
|
|
450
|
-
"NEO4J_USERNAME": "YOUR_NEO4J_USERNAME",
|
|
451
|
-
"NEO4J_PASSWORD": "YOUR_NEO4J_PASSWORD"
|
|
452
|
-
},
|
|
453
589
|
"disabled": false,
|
|
454
590
|
"alwaysAllow": []
|
|
455
591
|
}
|
|
@@ -489,6 +625,35 @@ If you installed CodeGraphContext using `pipx`, use the following configuration
|
|
|
489
625
|
|
|
490
626
|
---
|
|
491
627
|
|
|
628
|
+
## Token-Optimized Output (GCF)
|
|
629
|
+
|
|
630
|
+
Reduce tool response tokens by ~62% with the opt-in [GCF](https://gcformat.com) output format:
|
|
631
|
+
|
|
632
|
+
```bash
|
|
633
|
+
pip install gcf-python
|
|
634
|
+
CGC_OUTPUT_FORMAT=gcf codegraphcontext mcp start
|
|
635
|
+
```
|
|
636
|
+
|
|
637
|
+
Or add it to your MCP client config:
|
|
638
|
+
|
|
639
|
+
```json
|
|
640
|
+
{
|
|
641
|
+
"mcpServers": {
|
|
642
|
+
"CodeGraphContext": {
|
|
643
|
+
"command": "codegraphcontext",
|
|
644
|
+
"args": ["mcp", "start"],
|
|
645
|
+
"env": {
|
|
646
|
+
"CGC_OUTPUT_FORMAT": "gcf"
|
|
647
|
+
}
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
}
|
|
651
|
+
```
|
|
652
|
+
|
|
653
|
+
GCF encodes structured data with positional fields (keys declared once, values pipe-delimited). Code graph query results (symbols, relationships, callers, complexity) are exactly the data shape where GCF saves the most. 100% LLM comprehension on all frontier models. Falls back to JSON if `gcf-python` is not installed.
|
|
654
|
+
|
|
655
|
+
---
|
|
656
|
+
|
|
492
657
|
## Natural Language Interaction Examples
|
|
493
658
|
|
|
494
659
|
Once the server is running, you can interact with it through your AI assistant using plain English. Here are some examples of what you can say:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "codegraphcontext"
|
|
3
|
-
version = "0.5.
|
|
3
|
+
version = "0.5.2"
|
|
4
4
|
description = "An MCP server that indexes local code into a graph database to provide context to AI assistants."
|
|
5
5
|
authors = [{ name = "Shashank Shekhar Singh", email = "shashankshekharsingh1205@gmail.com" }]
|
|
6
6
|
readme = "README.md"
|
|
@@ -8,6 +8,11 @@ license = { file = "LICENSE" }
|
|
|
8
8
|
requires-python = ">=3.10"
|
|
9
9
|
classifiers = [
|
|
10
10
|
"Programming Language :: Python :: 3",
|
|
11
|
+
"Programming Language :: Python :: 3.10",
|
|
12
|
+
"Programming Language :: Python :: 3.11",
|
|
13
|
+
"Programming Language :: Python :: 3.12",
|
|
14
|
+
"Programming Language :: Python :: 3.13",
|
|
15
|
+
"Programming Language :: Python :: 3.14",
|
|
11
16
|
"License :: OSI Approved :: MIT License",
|
|
12
17
|
"Operating System :: OS Independent",
|
|
13
18
|
"Development Status :: 3 - Alpha",
|
|
@@ -22,9 +27,9 @@ dependencies = [
|
|
|
22
27
|
"rich>=13.7.0",
|
|
23
28
|
"inquirerpy>=0.3.4",
|
|
24
29
|
"python-dotenv>=1.0.0",
|
|
25
|
-
"tree-sitter>=0.
|
|
26
|
-
"tree-sitter-language-pack>=
|
|
27
|
-
"tree-sitter-c-sharp>=0.21.0
|
|
30
|
+
"tree-sitter>=0.24.0,<0.26.0",
|
|
31
|
+
"tree-sitter-language-pack>=1.6,<2.0",
|
|
32
|
+
"tree-sitter-c-sharp>=0.21.0",
|
|
28
33
|
"pyyaml",
|
|
29
34
|
"nbformat",
|
|
30
35
|
"nbconvert>=7.16.6",
|
|
@@ -62,9 +67,9 @@ dependencies = [
|
|
|
62
67
|
|
|
63
68
|
[project.optional-dependencies]
|
|
64
69
|
parsing = [
|
|
65
|
-
"tree-sitter>=0.
|
|
66
|
-
"tree-sitter-language-pack>=
|
|
67
|
-
"tree-sitter-c-sharp>=0.21.0
|
|
70
|
+
"tree-sitter>=0.24.0,<0.26.0",
|
|
71
|
+
"tree-sitter-language-pack>=1.6,<2.0",
|
|
72
|
+
"tree-sitter-c-sharp>=0.21.0",
|
|
68
73
|
]
|
|
69
74
|
# Named backend extras let users (and CI) opt into a single, tested driver
|
|
70
75
|
# triple instead of inheriting whatever the default install pulls. They
|
|
@@ -88,6 +93,9 @@ ladybug = [
|
|
|
88
93
|
neo4j = [
|
|
89
94
|
"neo4j>=5.15.0",
|
|
90
95
|
]
|
|
96
|
+
gcf = [
|
|
97
|
+
"gcf-python>=1.0.0",
|
|
98
|
+
]
|
|
91
99
|
dev = [
|
|
92
100
|
"pytest>=7.4.0",
|
|
93
101
|
"black>=23.11.0",
|
|
@@ -122,6 +130,13 @@ codegraphcontext = ["viz/dist/**/*"]
|
|
|
122
130
|
where = ["src"]
|
|
123
131
|
include = ["codegraphcontext*"]
|
|
124
132
|
|
|
133
|
+
[tool.ruff]
|
|
134
|
+
line-length = 120
|
|
135
|
+
target-version = "py310"
|
|
136
|
+
|
|
137
|
+
[tool.ruff.lint]
|
|
138
|
+
select = ["E4", "E7", "E9", "F"]
|
|
139
|
+
|
|
125
140
|
[tool.pytest.ini_options]
|
|
126
141
|
testpaths = ["tests"]
|
|
127
142
|
python_files = ["test_*.py"]
|