graphyn-core
Language-agnostic graph engine for Graphyn.
graphyn-core owns the canonical IR, graph structure, alias resolution, and query algorithms. It does not parse source code directly and does not contain language-specific logic.
Responsibilities
- Defines the frozen IR contract (
Symbol,Relationship,FileIR,RepoIR) - Stores a directed symbol graph (
GraphynGraph) - Resolves alias chains (import aliases, re-exports, barrel/default alias metadata)
- Provides query APIs:
blast_radiusdependenciessymbol_usages
- Supports incremental graph update plumbing
- Provides the shared symbol-id and AST-traversal helpers every adapter builds on
Public modules
ir: shared IR contract used by all adaptersgraph: graph container + indexesindex: symbol lookup indexesresolver: alias chain ingestion and canonicalization helpersquery: traversal-based query functionsincremental: file-level replacement/update helpersscan: source-file discovery, filtering and extension-to-language detectionsymbol_id: canonicalSymbolIdconstruction, shared by every adapterast: iterative, depth-bounded tree-sitter traversal helpers (featureast)error:GraphynError
Features
ast(default): shared tree-sitter traversal helpers used by every language adapter. Graph-only consumers such asgraphyn-storeturn this off so they do not link a parser.
Minimal usage
use GraphynGraph;
use query;
let graph = new;
let _ = blast_radius;
Notes
- This crate is deterministic by design and contains no LLM logic.
- Language parsing belongs in adapter crates (
graphyn-adapter-ts,-python,-rust,-go,-c), routed bygraphyn-adapter-dispatch.