You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Version: graphifyy 0.9.34 (pip install in a venv), Python 3.14, macOS (arm64)
Summary
The JavaScript extractor captures top-level function declarations but not function expressions assigned to object properties. Modules written in the factory / dependency-injection style — very common in Node — end up nearly empty in the graph, so queries against their symbols return "No matching nodes found."
Repro
// visible.js — extracted finefunctiontopLevel(){return1;}// factory.js — the dominant pattern in our codebasefunctioncreateApi(deps){constapi={};api.sourceClips=asyncfunctionsourceClips(topic){// ← not extractedreturndeps.fetch(topic);};api.renderVideo=functionrenderVideo(clips){// ← not extractedreturnclips.length;};returnapi;}module.exports={ createApi };
graphify update . on a real production backend written this way:
a ~1,400-line pipeline module whose entire surface is api.foo = function foo(...) inside one factory → 8 nodes (the imports, the factory shell, and two top-level helpers); none of the ~100 methods, no call edges between them
a sibling ~3,000-line module written with top-level function declarations → 111 nodes, edges look right
So the graph quality tracks the declaration style, and query "who calls sourceClips" / affected "sourceClips" both no-hit even though the call sites exist.
Expected
Named function expressions assigned to object properties (obj.name = function name() {}, obj.name = async function () {}, arrow equivalents) inside a factory captured as nodes — ideally namespaced like the existing module_symbol ids — with call edges resolved at least within the module.
Why it matters
The factory-with-injected-deps style is what testable Node codebases without classes tend to look like (it's why ours is written that way). Right now the token-saving story ("query the graph instead of reading the file") inverts for exactly those codebases: the better-factored the module, the less the graph sees.
Happy to test a branch against our codebase and report node/edge counts.
Fixed in v0.9.47: https://github.com/Graphify-Labs/graphify/releases/tag/v0.9.47. The JS/TS extractor now captures function expressions assigned to a local factory object (obj.name = function / async / arrow), namespaced under the object, with intra-factory call edges resolved. Your exact repro (createApi with api.sourceClips / api.renderVideo) now produces the method nodes and the renderVideo -> sourceClips call edge. Closing as resolved; if a variant in your codebase still comes up short, reopen with a snippet and we will take another look.
Activity
fix(js): extract methods assigned to factory object APIs (#2745)
safishamsi commentedon Aug 19, 2026
Fixed in v0.9.47: https://github.com/Graphify-Labs/graphify/releases/tag/v0.9.47. The JS/TS extractor now captures function expressions assigned to a local factory object (obj.name = function / async / arrow), namespaced under the object, with intra-factory call edges resolved. Your exact repro (createApi with api.sourceClips / api.renderVideo) now produces the method nodes and the renderVideo -> sourceClips call edge. Closing as resolved; if a variant in your codebase still comes up short, reopen with a snippet and we will take another look.