Skip to main content

Module model

Module model 

Source
Expand description

The code-graph data model. Serializable so a graph can be persisted as a gonzalo record and shared/synced like any other data.

Structs§

CodeGraph
A code graph: the symbols defined and references found in a single file’s slice. Path-agnostic; a whole view is assembled from many of these keyed by path in a GraphStore.
FileSummary
A file and the number of symbols defined in it.
Located
A query result carried with the assembly path it was found under. The path is not stored in the slice (Symbol/Reference are path-agnostic); it is re-attached at assembly from the manifest, so navigation still resolves to a concrete file.
Page
A bounded slice of a larger result set. total is the untruncated match count, so a caller can always tell what it did not see.
RankedSymbol
A symbol name ranked by some score, with the paths that define it. paths is empty when the name is referenced but never defined in this view (a call into a dependency, or a name the parser saw but no slice declares).
Reference
A name-based reference (e.g. a call) from within from (the enclosing function symbol, if any) to name. References are unresolved: they match by name, not by a resolved definition. This is a heuristic call graph, suitable for navigation; true name resolution is a later milestone.
Symbol
A defined symbol with its in-file location (1-based line numbers).
SymbolFilter
A conjunctive filter for GraphStore::list — every set field must match. All fields unset matches every symbol.
ViewOverview
The aggregate shape of a whole view — what is here, rather than facts about one symbol. by_kind and by_language are keyed by the lowercase names from SymbolKind::as_str and Language::as_str; symbols in files with an unrecognized extension bucket under "unknown", so by_language always sums to symbols.

Enums§

Ranking
What GraphStore::top ranks by.
RefKind
The syntactic shape of a call site.
SymbolKind
What kind of Rust item a symbol is.