homegraph 1.5.0 → 1.5.1
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.
- package/LICENSE +21 -21
- package/README.md +305 -305
- package/dist/bin/command-supervision.d.ts.map +1 -1
- package/dist/bin/command-supervision.js +7 -4
- package/dist/bin/command-supervision.js.map +1 -1
- package/dist/bin/homegraph.js +9 -9
- package/dist/db/index.js +36 -36
- package/dist/db/migrations.js +37 -37
- package/dist/db/queries.js +156 -156
- package/dist/db/schema.sql +203 -203
- package/dist/directory.js +5 -5
- package/dist/extraction/languages/arkts-viewtree.d.ts +2 -4
- package/dist/extraction/languages/arkts-viewtree.d.ts.map +1 -1
- package/dist/extraction/languages/arkts-viewtree.js +6 -21
- package/dist/extraction/languages/arkts-viewtree.js.map +1 -1
- package/dist/extraction/languages/arkts.d.ts +16 -6
- package/dist/extraction/languages/arkts.d.ts.map +1 -1
- package/dist/extraction/languages/arkts.js +174 -21
- package/dist/extraction/languages/arkts.js.map +1 -1
- package/dist/extraction/wasm/tree-sitter-c_sharp.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-cfml.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-cfquery.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-cfscript.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-cobol.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-erlang.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-nix.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-pascal.wasm +0 -0
- package/dist/extraction/wasm/tree-sitter-vbnet.wasm +0 -0
- package/dist/installer/instructions-template.js +9 -9
- package/dist/mcp/liveness-watchdog.d.ts +18 -0
- package/dist/mcp/liveness-watchdog.d.ts.map +1 -1
- package/dist/mcp/liveness-watchdog.js +185 -73
- package/dist/mcp/liveness-watchdog.js.map +1 -1
- package/dist/mcp/server-instructions.js +47 -47
- package/dist/reasoning/reasoner.js +32 -32
- package/dist/spec/db/commit-node.js +4 -4
- package/dist/spec/db/fragment-node.js +10 -10
- package/dist/spec/db/fts.js +8 -8
- package/dist/spec/db/relations.js +88 -88
- package/dist/spec/db/schema.js +6 -6
- package/dist/spec/db/schema.sql +121 -121
- package/dist/spec/db/spec-node.js +4 -4
- package/dist/spec/llm/prompts.js +53 -53
- package/dist/spec/utils.d.ts +16 -4
- package/dist/spec/utils.d.ts.map +1 -1
- package/dist/spec/utils.js +58 -6
- package/dist/spec/utils.js.map +1 -1
- package/package.json +62 -62
- package/scripts/_tmp-cfwk-resolve.log +0 -0
- package/scripts/_tmp-cfwk-sig.log +0 -0
- package/scripts/_tmp-cfwk-vt.log +0 -0
- package/scripts/add-lang/bench.sh +60 -60
- package/scripts/add-lang/check-grammar.mjs +75 -75
- package/scripts/add-lang/dump-ast.mjs +103 -103
- package/scripts/add-lang/verify-extraction.mjs +70 -70
- package/scripts/agent-eval/ab-adoption.sh +91 -91
- package/scripts/agent-eval/ab-hook.sh +86 -86
- package/scripts/agent-eval/ab-impl.sh +78 -78
- package/scripts/agent-eval/ab-new-vs-baseline.sh +102 -102
- package/scripts/agent-eval/ab-sufficiency.sh +78 -78
- package/scripts/agent-eval/arms-F.sh +21 -21
- package/scripts/agent-eval/arms-matrix.sh +37 -37
- package/scripts/agent-eval/audit.sh +68 -68
- package/scripts/agent-eval/bench-readme.sh +28 -28
- package/scripts/agent-eval/bench-why-repo.sh +22 -22
- package/scripts/agent-eval/block-read-hook.sh +19 -19
- package/scripts/agent-eval/hook-settings.json +15 -15
- package/scripts/agent-eval/itrun.sh +120 -120
- package/scripts/agent-eval/offload-eval-3arm.sh +72 -72
- package/scripts/agent-eval/offload-eval-cost.mjs +133 -133
- package/scripts/agent-eval/offload-eval-effort.mjs +108 -108
- package/scripts/agent-eval/offload-eval-frontload-matrix.sh +25 -25
- package/scripts/agent-eval/offload-eval-frontload.sh +47 -47
- package/scripts/agent-eval/offload-eval-ground-truth.json +18 -18
- package/scripts/agent-eval/offload-eval-hook.mjs +84 -84
- package/scripts/agent-eval/offload-eval-judge.mjs +103 -103
- package/scripts/agent-eval/offload-eval-matrix.sh +20 -20
- package/scripts/agent-eval/offload-eval-metrics.mjs +94 -94
- package/scripts/agent-eval/offload-eval-refs1.sh +50 -50
- package/scripts/agent-eval/offload-eval-setup.sh +24 -24
- package/scripts/agent-eval/offload-eval-styles.sh +71 -71
- package/scripts/agent-eval/offload-eval-summarize.mjs +68 -68
- package/scripts/agent-eval/offload-eval.md +76 -76
- package/scripts/agent-eval/parse-arms.mjs +116 -116
- package/scripts/agent-eval/parse-bench-readme.mjs +84 -84
- package/scripts/agent-eval/parse-run.mjs +45 -45
- package/scripts/agent-eval/parse-session.mjs +93 -93
- package/scripts/agent-eval/probe-context.mjs +21 -21
- package/scripts/agent-eval/probe-explore.mjs +40 -40
- package/scripts/agent-eval/probe-node.mjs +20 -20
- package/scripts/agent-eval/probe-sweep.mjs +119 -119
- package/scripts/agent-eval/probe-trace.mjs +20 -20
- package/scripts/agent-eval/redirect-read-hook.sh +38 -38
- package/scripts/agent-eval/repro-concurrent-explore.mjs +119 -119
- package/scripts/agent-eval/repro-daemon-clients.mjs +125 -125
- package/scripts/agent-eval/run-agent.sh +34 -34
- package/scripts/agent-eval/run-all.sh +75 -75
- package/scripts/agent-eval/run-arms.sh +56 -56
- package/scripts/agent-eval/seq-matrix.mjs +137 -137
- package/scripts/bench-arkts-init-rss.log +0 -0
- package/scripts/build-bundle.sh +123 -123
- package/scripts/exp_boundary_eval/README.md +247 -247
- package/scripts/exp_boundary_eval/__pycache__/_utils.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/_utils.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/analyze.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/analyze.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/deveco_arm.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_all.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_all.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_one.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_one.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_session.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/run_session.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/setup.cpython-310.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/setup.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/__pycache__/win_mcp_launcher.cpython-38.pyc +0 -0
- package/scripts/exp_boundary_eval/_test_mcp_chain.py +78 -78
- package/scripts/exp_boundary_eval/_test_stdin.py +8 -8
- package/scripts/exp_boundary_eval/_utils.py +1116 -1116
- package/scripts/exp_boundary_eval/analyze.py +1313 -1313
- package/scripts/exp_boundary_eval/deveco_arm.py +519 -519
- package/scripts/exp_boundary_eval/run_all.py +378 -378
- package/scripts/exp_boundary_eval/run_one.py +165 -165
- package/scripts/exp_boundary_eval/run_session.py +158 -158
- package/scripts/exp_boundary_eval/setup.py +120 -120
- package/scripts/exp_boundary_eval/win_mcp_launcher.py +73 -73
- package/scripts/exp_boundary_eval/win_mcp_stdio_wrap.js +36 -36
- package/scripts/exp_boundary_eval/win_node_launcher.py +24 -24
- package/scripts/extract-release-notes.mjs +130 -130
- package/scripts/local-install.sh +41 -41
- package/scripts/npm-sdk.js +75 -75
- package/scripts/npm-shim.js +275 -275
- package/scripts/ohos-sdk-publish.mjs +133 -133
- package/scripts/pack-npm.sh +119 -119
- package/scripts/prepare-release.mjs +270 -270
- package/scripts/probe-arkts-mem-why-run.log +0 -0
- package/scripts/probe-banner-livecard-ir.log +0 -0
- package/scripts/probe-cfwk-ast.stderr.log +0 -0
- package/scripts/probe-cfwk-ast.stdout.log +0 -0
- package/scripts/probe-cfwk-attr-shape.log +0 -0
- package/scripts/probe-cfwk-cfgdump.stderr.log +0 -0
- package/scripts/probe-cfwk-cfgdump.stdout.log +0 -0
- package/scripts/probe-cfwk-cvc.stderr.log +0 -0
- package/scripts/probe-cfwk-cvc.stdout.log +0 -0
- package/scripts/probe-cfwk-diag2.log +0 -0
- package/scripts/probe-cfwk-diag3.log +0 -0
- package/scripts/probe-cfwk-fedbg.stderr.log +0 -0
- package/scripts/probe-cfwk-fedbg.stdout.log +0 -0
- package/scripts/probe-cfwk-fileresult.log +0 -0
- package/scripts/probe-cfwk-fix.stderr.log +0 -0
- package/scripts/probe-cfwk-fix.stdout.log +0 -0
- package/scripts/probe-cfwk-fix2.stderr.log +0 -0
- package/scripts/probe-cfwk-fix2.stdout.log +0 -0
- package/scripts/probe-cfwk-fix3.stderr.log +0 -0
- package/scripts/probe-cfwk-fix3.stdout.log +0 -0
- package/scripts/probe-cfwk-foreach.log +0 -0
- package/scripts/probe-cfwk-getmethod-throw.log +0 -0
- package/scripts/probe-cfwk-hg-extract.log +0 -0
- package/scripts/probe-cfwk-pr1003-noprior.stderr.log +0 -0
- package/scripts/probe-cfwk-pr1003-noprior.stdout.log +0 -0
- package/scripts/probe-cfwk-pr1003.stderr.log +0 -0
- package/scripts/probe-cfwk-pr1003.stdout.log +0 -0
- package/scripts/probe-cfwk-preroot-noprior.stderr.log +0 -0
- package/scripts/probe-cfwk-preroot-noprior.stdout.log +0 -0
- package/scripts/probe-cfwk-preroot-prior.stderr.log +0 -0
- package/scripts/probe-cfwk-preroot-prior.stdout.log +0 -0
- package/scripts/probe-cfwk-preroot-skipstate.stderr.log +0 -0
- package/scripts/probe-cfwk-preroot-skipstate.stdout.log +0 -0
- package/scripts/probe-cfwk-resolve-sim.log +0 -0
- package/scripts/probe-cfwk-tree-shape.log +0 -0
- package/scripts/probe-cfwk-walk-abort.log +0 -0
- package/scripts/probe-cfwk.log +0 -0
- package/scripts/probe-force-index.log +0 -0
- package/scripts/probe-no-force-index.log +0 -0
- package/scripts/probe-samefile-ir.stderr.log +0 -0
- package/scripts/probe-samefile-ir.stdout.log +224 -0
- package/scripts/probe-sdk-vs-project.log +0 -0
- package/scripts/probe-viewtree-downgrade.log +0 -0
- package/dist/arkts/ohos-api-index.d.ts +0 -15
- package/dist/arkts/ohos-api-index.d.ts.map +0 -1
- package/dist/arkts/ohos-api-index.js +0 -190
- package/dist/arkts/ohos-api-index.js.map +0 -1
- package/dist/arkts/ohos-sdk-input.d.ts +0 -36
- package/dist/arkts/ohos-sdk-input.d.ts.map +0 -1
- package/dist/arkts/ohos-sdk-input.js +0 -214
- package/dist/arkts/ohos-sdk-input.js.map +0 -1
- package/dist/extraction/languages/arkts-state-decorators.d.ts +0 -13
- package/dist/extraction/languages/arkts-state-decorators.d.ts.map +0 -1
- package/dist/extraction/languages/arkts-state-decorators.js +0 -26
- package/dist/extraction/languages/arkts-state-decorators.js.map +0 -1
- package/dist/extraction/languages/ohos-api-consumer.d.ts +0 -34
- package/dist/extraction/languages/ohos-api-consumer.d.ts.map +0 -1
- package/dist/extraction/languages/ohos-api-consumer.js +0 -283
- package/dist/extraction/languages/ohos-api-consumer.js.map +0 -1
- package/dist/spec/build/git-scanner.d.ts +0 -93
- package/dist/spec/build/git-scanner.d.ts.map +0 -1
- package/dist/spec/build/git-scanner.js +0 -254
- package/dist/spec/build/git-scanner.js.map +0 -1
- package/dist/spec/git-utils.d.ts +0 -8
- package/dist/spec/git-utils.d.ts.map +0 -1
- package/dist/spec/git-utils.js +0 -14
- package/dist/spec/git-utils.js.map +0 -1
- package/dist/spec/mine/clusterer.d.ts +0 -63
- package/dist/spec/mine/clusterer.d.ts.map +0 -1
- package/dist/spec/mine/clusterer.js +0 -904
- package/dist/spec/mine/clusterer.js.map +0 -1
- package/dist/spec/mine/progress-handler.d.ts +0 -22
- package/dist/spec/mine/progress-handler.d.ts.map +0 -1
- package/dist/spec/mine/progress-handler.js +0 -108
- package/dist/spec/mine/progress-handler.js.map +0 -1
- package/dist/spec/mine/progress.d.ts +0 -23
- package/dist/spec/mine/progress.d.ts.map +0 -1
- package/dist/spec/mine/progress.js +0 -12
- package/dist/spec/mine/progress.js.map +0 -1
package/dist/db/schema.sql
CHANGED
|
@@ -1,203 +1,203 @@
|
|
|
1
|
-
-- HomeGraph SQLite Schema
|
|
2
|
-
-- Version 1
|
|
3
|
-
|
|
4
|
-
-- Schema version tracking
|
|
5
|
-
CREATE TABLE IF NOT EXISTS schema_versions (
|
|
6
|
-
version INTEGER PRIMARY KEY,
|
|
7
|
-
applied_at INTEGER NOT NULL,
|
|
8
|
-
description TEXT
|
|
9
|
-
);
|
|
10
|
-
|
|
11
|
-
-- Insert initial version
|
|
12
|
-
INSERT INTO schema_versions (version, applied_at, description)
|
|
13
|
-
VALUES (1, strftime('%s', 'now') * 1000, 'Initial schema');
|
|
14
|
-
|
|
15
|
-
-- =============================================================================
|
|
16
|
-
-- Core Tables
|
|
17
|
-
-- =============================================================================
|
|
18
|
-
|
|
19
|
-
-- Nodes: Code symbols (functions, classes, variables, etc.)
|
|
20
|
-
CREATE TABLE IF NOT EXISTS nodes (
|
|
21
|
-
id TEXT PRIMARY KEY,
|
|
22
|
-
kind TEXT NOT NULL,
|
|
23
|
-
name TEXT NOT NULL,
|
|
24
|
-
qualified_name TEXT NOT NULL,
|
|
25
|
-
file_path TEXT NOT NULL,
|
|
26
|
-
language TEXT NOT NULL,
|
|
27
|
-
start_line INTEGER NOT NULL,
|
|
28
|
-
end_line INTEGER NOT NULL,
|
|
29
|
-
start_column INTEGER NOT NULL,
|
|
30
|
-
end_column INTEGER NOT NULL,
|
|
31
|
-
docstring TEXT,
|
|
32
|
-
signature TEXT,
|
|
33
|
-
visibility TEXT,
|
|
34
|
-
is_exported INTEGER DEFAULT 0,
|
|
35
|
-
is_async INTEGER DEFAULT 0,
|
|
36
|
-
is_static INTEGER DEFAULT 0,
|
|
37
|
-
is_abstract INTEGER DEFAULT 0,
|
|
38
|
-
decorators TEXT, -- JSON array
|
|
39
|
-
type_parameters TEXT, -- JSON array
|
|
40
|
-
return_type TEXT, -- normalized return/result type name (e.g. C++ method return, for receiver-type inference)
|
|
41
|
-
updated_at INTEGER NOT NULL
|
|
42
|
-
);
|
|
43
|
-
|
|
44
|
-
-- Edges: Relationships between nodes
|
|
45
|
-
CREATE TABLE IF NOT EXISTS edges (
|
|
46
|
-
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
47
|
-
source TEXT NOT NULL,
|
|
48
|
-
target TEXT NOT NULL,
|
|
49
|
-
kind TEXT NOT NULL,
|
|
50
|
-
metadata TEXT, -- JSON object
|
|
51
|
-
line INTEGER,
|
|
52
|
-
col INTEGER,
|
|
53
|
-
provenance TEXT DEFAULT NULL,
|
|
54
|
-
FOREIGN KEY (source) REFERENCES nodes(id) ON DELETE CASCADE,
|
|
55
|
-
FOREIGN KEY (target) REFERENCES nodes(id) ON DELETE CASCADE
|
|
56
|
-
);
|
|
57
|
-
|
|
58
|
-
-- Files: Tracked source files
|
|
59
|
-
CREATE TABLE IF NOT EXISTS files (
|
|
60
|
-
path TEXT PRIMARY KEY,
|
|
61
|
-
content_hash TEXT NOT NULL,
|
|
62
|
-
language TEXT NOT NULL,
|
|
63
|
-
size INTEGER NOT NULL,
|
|
64
|
-
modified_at INTEGER NOT NULL,
|
|
65
|
-
indexed_at INTEGER NOT NULL,
|
|
66
|
-
node_count INTEGER DEFAULT 0,
|
|
67
|
-
errors TEXT -- JSON array
|
|
68
|
-
);
|
|
69
|
-
|
|
70
|
-
-- Unresolved References: References that need resolution after full indexing.
|
|
71
|
-
-- status lifecycle: rows are inserted 'pending' by extraction; a completed
|
|
72
|
-
-- resolution pass either deletes a row (resolved) or marks it 'failed'
|
|
73
|
-
-- (attempted, no match — kept so a later sync can retry it when a changed
|
|
74
|
-
-- file introduces a symbol that could satisfy it, #1240). name_tail is the
|
|
75
|
-
-- last segment of reference_name ('util.greet' → 'greet'), written when a
|
|
76
|
-
-- row is marked failed, so the retry lookup matches new node names against
|
|
77
|
-
-- dotted refs too. Rows follow their from_node via ON DELETE CASCADE, so
|
|
78
|
-
-- re-extracting or deleting a file clears its stale rows in any status.
|
|
79
|
-
CREATE TABLE IF NOT EXISTS unresolved_refs (
|
|
80
|
-
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
81
|
-
from_node_id TEXT NOT NULL,
|
|
82
|
-
reference_name TEXT NOT NULL,
|
|
83
|
-
reference_kind TEXT NOT NULL,
|
|
84
|
-
line INTEGER NOT NULL,
|
|
85
|
-
col INTEGER NOT NULL,
|
|
86
|
-
candidates TEXT, -- JSON array
|
|
87
|
-
file_path TEXT NOT NULL DEFAULT '',
|
|
88
|
-
language TEXT NOT NULL DEFAULT 'unknown',
|
|
89
|
-
status TEXT NOT NULL DEFAULT 'pending',
|
|
90
|
-
name_tail TEXT NOT NULL DEFAULT '',
|
|
91
|
-
FOREIGN KEY (from_node_id) REFERENCES nodes(id) ON DELETE CASCADE
|
|
92
|
-
);
|
|
93
|
-
|
|
94
|
-
-- =============================================================================
|
|
95
|
-
-- Indexes for Query Performance
|
|
96
|
-
-- =============================================================================
|
|
97
|
-
|
|
98
|
-
-- Node indexes
|
|
99
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_kind ON nodes(kind);
|
|
100
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_name ON nodes(name);
|
|
101
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_qualified_name ON nodes(qualified_name);
|
|
102
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_file_path ON nodes(file_path);
|
|
103
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_language ON nodes(language);
|
|
104
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_file_line ON nodes(file_path, start_line);
|
|
105
|
-
CREATE INDEX IF NOT EXISTS idx_nodes_lower_name ON nodes(lower(name));
|
|
106
|
-
|
|
107
|
-
-- Full-text search index on node names, docstrings, and signatures
|
|
108
|
-
CREATE VIRTUAL TABLE IF NOT EXISTS nodes_fts USING fts5(
|
|
109
|
-
id,
|
|
110
|
-
name,
|
|
111
|
-
qualified_name,
|
|
112
|
-
docstring,
|
|
113
|
-
signature,
|
|
114
|
-
content='nodes',
|
|
115
|
-
content_rowid='rowid'
|
|
116
|
-
);
|
|
117
|
-
|
|
118
|
-
-- Triggers to keep FTS index in sync
|
|
119
|
-
CREATE TRIGGER IF NOT EXISTS nodes_ai AFTER INSERT ON nodes BEGIN
|
|
120
|
-
INSERT INTO nodes_fts(rowid, id, name, qualified_name, docstring, signature)
|
|
121
|
-
VALUES (NEW.rowid, NEW.id, NEW.name, NEW.qualified_name, NEW.docstring, NEW.signature);
|
|
122
|
-
END;
|
|
123
|
-
|
|
124
|
-
CREATE TRIGGER IF NOT EXISTS nodes_ad AFTER DELETE ON nodes BEGIN
|
|
125
|
-
INSERT INTO nodes_fts(nodes_fts, rowid, id, name, qualified_name, docstring, signature)
|
|
126
|
-
VALUES ('delete', OLD.rowid, OLD.id, OLD.name, OLD.qualified_name, OLD.docstring, OLD.signature);
|
|
127
|
-
END;
|
|
128
|
-
|
|
129
|
-
CREATE TRIGGER IF NOT EXISTS nodes_au AFTER UPDATE ON nodes BEGIN
|
|
130
|
-
INSERT INTO nodes_fts(nodes_fts, rowid, id, name, qualified_name, docstring, signature)
|
|
131
|
-
VALUES ('delete', OLD.rowid, OLD.id, OLD.name, OLD.qualified_name, OLD.docstring, OLD.signature);
|
|
132
|
-
INSERT INTO nodes_fts(rowid, id, name, qualified_name, docstring, signature)
|
|
133
|
-
VALUES (NEW.rowid, NEW.id, NEW.name, NEW.qualified_name, NEW.docstring, NEW.signature);
|
|
134
|
-
END;
|
|
135
|
-
|
|
136
|
-
-- Prose-word → symbol-name lookup for the prompt hook's graph-derived gate.
|
|
137
|
-
-- One row per (segment, name): segment is a lowercased word of a symbol name
|
|
138
|
-
-- ("OrderStateMachine" → order, state, machine — see identifier-segments.ts),
|
|
139
|
-
-- which lets natural-language prompt words be verified against the graph in
|
|
140
|
-
-- any language whose technical nouns are Latin script. File nodes are
|
|
141
|
-
-- excluded — a file's basename duplicates the symbols inside it and skews the
|
|
142
|
-
-- singleton-vs-cluster rarity statistics. FTS can't serve this lookup (its
|
|
143
|
-
-- tokenizer keeps camelCase names as single tokens), so segments are
|
|
144
|
-
-- materialized on the node write path.
|
|
145
|
-
-- Deletions leave orphan rows ON PURPOSE: rows are PROPOSALS, always
|
|
146
|
-
-- re-verified against nodes before being surfaced (HomeGraph.getSegmentMatches),
|
|
147
|
-
-- and a full index clears the table at its start. Populated lazily on old
|
|
148
|
-
-- databases (empty until the next index/sync heals it).
|
|
149
|
-
CREATE TABLE IF NOT EXISTS name_segment_vocab (
|
|
150
|
-
segment TEXT NOT NULL,
|
|
151
|
-
name TEXT NOT NULL,
|
|
152
|
-
PRIMARY KEY (segment, name)
|
|
153
|
-
) WITHOUT ROWID;
|
|
154
|
-
|
|
155
|
-
-- Edge indexes.
|
|
156
|
-
-- idx_edges_source / idx_edges_target are intentionally omitted —
|
|
157
|
-
-- the (source, kind) and (target, kind) composites below cover the
|
|
158
|
-
-- corresponding source-only / target-only lookups via SQLite's
|
|
159
|
-
-- left-prefix scan, so the narrow indexes are dead weight on writes.
|
|
160
|
-
-- Migration v4 drops them on existing databases.
|
|
161
|
-
CREATE INDEX IF NOT EXISTS idx_edges_kind ON edges(kind);
|
|
162
|
-
CREATE INDEX IF NOT EXISTS idx_edges_source_kind ON edges(source, kind);
|
|
163
|
-
CREATE INDEX IF NOT EXISTS idx_edges_target_kind ON edges(target, kind);
|
|
164
|
-
|
|
165
|
-
-- Edge identity uniqueness. An edge IS uniquely (source, target, kind, line,
|
|
166
|
-
-- col); insertEdge uses `INSERT OR IGNORE`, but without something UNIQUE to
|
|
167
|
-
-- conflict on it behaved like a plain INSERT, so two passes emitting the same
|
|
168
|
-
-- edge produced byte-identical duplicate rows that inflated counts and flowed
|
|
169
|
-
-- into callers/impact (#1034). IFNULL folds the nullable line/col so
|
|
170
|
-
-- coordinate-less edges (synthesized / file-level) dedup too — SQLite treats
|
|
171
|
-
-- each NULL as distinct otherwise. Migration v6 dedups existing rows + adds
|
|
172
|
-
-- this on older databases.
|
|
173
|
-
CREATE UNIQUE INDEX IF NOT EXISTS idx_edges_identity
|
|
174
|
-
ON edges(source, target, kind, IFNULL(line, -1), IFNULL(col, -1));
|
|
175
|
-
|
|
176
|
-
-- File indexes
|
|
177
|
-
CREATE INDEX IF NOT EXISTS idx_files_language ON files(language);
|
|
178
|
-
CREATE INDEX IF NOT EXISTS idx_files_modified_at ON files(modified_at);
|
|
179
|
-
|
|
180
|
-
-- Unresolved refs indexes
|
|
181
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_from_node ON unresolved_refs(from_node_id);
|
|
182
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_name ON unresolved_refs(reference_name);
|
|
183
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_file_path ON unresolved_refs(file_path);
|
|
184
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_from_name ON unresolved_refs(from_node_id, reference_name);
|
|
185
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_status ON unresolved_refs(status);
|
|
186
|
-
CREATE INDEX IF NOT EXISTS idx_unresolved_failed_tail ON unresolved_refs(name_tail) WHERE status = 'failed';
|
|
187
|
-
CREATE INDEX IF NOT EXISTS idx_edges_provenance ON edges(provenance);
|
|
188
|
-
|
|
189
|
-
-- Project metadata for version/provenance tracking
|
|
190
|
-
CREATE TABLE IF NOT EXISTS project_metadata (
|
|
191
|
-
key TEXT PRIMARY KEY,
|
|
192
|
-
value TEXT NOT NULL,
|
|
193
|
-
updated_at INTEGER NOT NULL
|
|
194
|
-
);
|
|
195
|
-
|
|
196
|
-
-- MCP tool response cache (invalidated wholesale on index stamp change)
|
|
197
|
-
CREATE TABLE IF NOT EXISTS mcp_query_cache (
|
|
198
|
-
cache_key TEXT PRIMARY KEY,
|
|
199
|
-
tool TEXT NOT NULL,
|
|
200
|
-
response TEXT NOT NULL,
|
|
201
|
-
created_at INTEGER NOT NULL
|
|
202
|
-
);
|
|
203
|
-
CREATE INDEX IF NOT EXISTS idx_mcp_query_cache_tool ON mcp_query_cache(tool);
|
|
1
|
+
-- HomeGraph SQLite Schema
|
|
2
|
+
-- Version 1
|
|
3
|
+
|
|
4
|
+
-- Schema version tracking
|
|
5
|
+
CREATE TABLE IF NOT EXISTS schema_versions (
|
|
6
|
+
version INTEGER PRIMARY KEY,
|
|
7
|
+
applied_at INTEGER NOT NULL,
|
|
8
|
+
description TEXT
|
|
9
|
+
);
|
|
10
|
+
|
|
11
|
+
-- Insert initial version
|
|
12
|
+
INSERT INTO schema_versions (version, applied_at, description)
|
|
13
|
+
VALUES (1, strftime('%s', 'now') * 1000, 'Initial schema');
|
|
14
|
+
|
|
15
|
+
-- =============================================================================
|
|
16
|
+
-- Core Tables
|
|
17
|
+
-- =============================================================================
|
|
18
|
+
|
|
19
|
+
-- Nodes: Code symbols (functions, classes, variables, etc.)
|
|
20
|
+
CREATE TABLE IF NOT EXISTS nodes (
|
|
21
|
+
id TEXT PRIMARY KEY,
|
|
22
|
+
kind TEXT NOT NULL,
|
|
23
|
+
name TEXT NOT NULL,
|
|
24
|
+
qualified_name TEXT NOT NULL,
|
|
25
|
+
file_path TEXT NOT NULL,
|
|
26
|
+
language TEXT NOT NULL,
|
|
27
|
+
start_line INTEGER NOT NULL,
|
|
28
|
+
end_line INTEGER NOT NULL,
|
|
29
|
+
start_column INTEGER NOT NULL,
|
|
30
|
+
end_column INTEGER NOT NULL,
|
|
31
|
+
docstring TEXT,
|
|
32
|
+
signature TEXT,
|
|
33
|
+
visibility TEXT,
|
|
34
|
+
is_exported INTEGER DEFAULT 0,
|
|
35
|
+
is_async INTEGER DEFAULT 0,
|
|
36
|
+
is_static INTEGER DEFAULT 0,
|
|
37
|
+
is_abstract INTEGER DEFAULT 0,
|
|
38
|
+
decorators TEXT, -- JSON array
|
|
39
|
+
type_parameters TEXT, -- JSON array
|
|
40
|
+
return_type TEXT, -- normalized return/result type name (e.g. C++ method return, for receiver-type inference)
|
|
41
|
+
updated_at INTEGER NOT NULL
|
|
42
|
+
);
|
|
43
|
+
|
|
44
|
+
-- Edges: Relationships between nodes
|
|
45
|
+
CREATE TABLE IF NOT EXISTS edges (
|
|
46
|
+
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
47
|
+
source TEXT NOT NULL,
|
|
48
|
+
target TEXT NOT NULL,
|
|
49
|
+
kind TEXT NOT NULL,
|
|
50
|
+
metadata TEXT, -- JSON object
|
|
51
|
+
line INTEGER,
|
|
52
|
+
col INTEGER,
|
|
53
|
+
provenance TEXT DEFAULT NULL,
|
|
54
|
+
FOREIGN KEY (source) REFERENCES nodes(id) ON DELETE CASCADE,
|
|
55
|
+
FOREIGN KEY (target) REFERENCES nodes(id) ON DELETE CASCADE
|
|
56
|
+
);
|
|
57
|
+
|
|
58
|
+
-- Files: Tracked source files
|
|
59
|
+
CREATE TABLE IF NOT EXISTS files (
|
|
60
|
+
path TEXT PRIMARY KEY,
|
|
61
|
+
content_hash TEXT NOT NULL,
|
|
62
|
+
language TEXT NOT NULL,
|
|
63
|
+
size INTEGER NOT NULL,
|
|
64
|
+
modified_at INTEGER NOT NULL,
|
|
65
|
+
indexed_at INTEGER NOT NULL,
|
|
66
|
+
node_count INTEGER DEFAULT 0,
|
|
67
|
+
errors TEXT -- JSON array
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
-- Unresolved References: References that need resolution after full indexing.
|
|
71
|
+
-- status lifecycle: rows are inserted 'pending' by extraction; a completed
|
|
72
|
+
-- resolution pass either deletes a row (resolved) or marks it 'failed'
|
|
73
|
+
-- (attempted, no match — kept so a later sync can retry it when a changed
|
|
74
|
+
-- file introduces a symbol that could satisfy it, #1240). name_tail is the
|
|
75
|
+
-- last segment of reference_name ('util.greet' → 'greet'), written when a
|
|
76
|
+
-- row is marked failed, so the retry lookup matches new node names against
|
|
77
|
+
-- dotted refs too. Rows follow their from_node via ON DELETE CASCADE, so
|
|
78
|
+
-- re-extracting or deleting a file clears its stale rows in any status.
|
|
79
|
+
CREATE TABLE IF NOT EXISTS unresolved_refs (
|
|
80
|
+
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
81
|
+
from_node_id TEXT NOT NULL,
|
|
82
|
+
reference_name TEXT NOT NULL,
|
|
83
|
+
reference_kind TEXT NOT NULL,
|
|
84
|
+
line INTEGER NOT NULL,
|
|
85
|
+
col INTEGER NOT NULL,
|
|
86
|
+
candidates TEXT, -- JSON array
|
|
87
|
+
file_path TEXT NOT NULL DEFAULT '',
|
|
88
|
+
language TEXT NOT NULL DEFAULT 'unknown',
|
|
89
|
+
status TEXT NOT NULL DEFAULT 'pending',
|
|
90
|
+
name_tail TEXT NOT NULL DEFAULT '',
|
|
91
|
+
FOREIGN KEY (from_node_id) REFERENCES nodes(id) ON DELETE CASCADE
|
|
92
|
+
);
|
|
93
|
+
|
|
94
|
+
-- =============================================================================
|
|
95
|
+
-- Indexes for Query Performance
|
|
96
|
+
-- =============================================================================
|
|
97
|
+
|
|
98
|
+
-- Node indexes
|
|
99
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_kind ON nodes(kind);
|
|
100
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_name ON nodes(name);
|
|
101
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_qualified_name ON nodes(qualified_name);
|
|
102
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_file_path ON nodes(file_path);
|
|
103
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_language ON nodes(language);
|
|
104
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_file_line ON nodes(file_path, start_line);
|
|
105
|
+
CREATE INDEX IF NOT EXISTS idx_nodes_lower_name ON nodes(lower(name));
|
|
106
|
+
|
|
107
|
+
-- Full-text search index on node names, docstrings, and signatures
|
|
108
|
+
CREATE VIRTUAL TABLE IF NOT EXISTS nodes_fts USING fts5(
|
|
109
|
+
id,
|
|
110
|
+
name,
|
|
111
|
+
qualified_name,
|
|
112
|
+
docstring,
|
|
113
|
+
signature,
|
|
114
|
+
content='nodes',
|
|
115
|
+
content_rowid='rowid'
|
|
116
|
+
);
|
|
117
|
+
|
|
118
|
+
-- Triggers to keep FTS index in sync
|
|
119
|
+
CREATE TRIGGER IF NOT EXISTS nodes_ai AFTER INSERT ON nodes BEGIN
|
|
120
|
+
INSERT INTO nodes_fts(rowid, id, name, qualified_name, docstring, signature)
|
|
121
|
+
VALUES (NEW.rowid, NEW.id, NEW.name, NEW.qualified_name, NEW.docstring, NEW.signature);
|
|
122
|
+
END;
|
|
123
|
+
|
|
124
|
+
CREATE TRIGGER IF NOT EXISTS nodes_ad AFTER DELETE ON nodes BEGIN
|
|
125
|
+
INSERT INTO nodes_fts(nodes_fts, rowid, id, name, qualified_name, docstring, signature)
|
|
126
|
+
VALUES ('delete', OLD.rowid, OLD.id, OLD.name, OLD.qualified_name, OLD.docstring, OLD.signature);
|
|
127
|
+
END;
|
|
128
|
+
|
|
129
|
+
CREATE TRIGGER IF NOT EXISTS nodes_au AFTER UPDATE ON nodes BEGIN
|
|
130
|
+
INSERT INTO nodes_fts(nodes_fts, rowid, id, name, qualified_name, docstring, signature)
|
|
131
|
+
VALUES ('delete', OLD.rowid, OLD.id, OLD.name, OLD.qualified_name, OLD.docstring, OLD.signature);
|
|
132
|
+
INSERT INTO nodes_fts(rowid, id, name, qualified_name, docstring, signature)
|
|
133
|
+
VALUES (NEW.rowid, NEW.id, NEW.name, NEW.qualified_name, NEW.docstring, NEW.signature);
|
|
134
|
+
END;
|
|
135
|
+
|
|
136
|
+
-- Prose-word → symbol-name lookup for the prompt hook's graph-derived gate.
|
|
137
|
+
-- One row per (segment, name): segment is a lowercased word of a symbol name
|
|
138
|
+
-- ("OrderStateMachine" → order, state, machine — see identifier-segments.ts),
|
|
139
|
+
-- which lets natural-language prompt words be verified against the graph in
|
|
140
|
+
-- any language whose technical nouns are Latin script. File nodes are
|
|
141
|
+
-- excluded — a file's basename duplicates the symbols inside it and skews the
|
|
142
|
+
-- singleton-vs-cluster rarity statistics. FTS can't serve this lookup (its
|
|
143
|
+
-- tokenizer keeps camelCase names as single tokens), so segments are
|
|
144
|
+
-- materialized on the node write path.
|
|
145
|
+
-- Deletions leave orphan rows ON PURPOSE: rows are PROPOSALS, always
|
|
146
|
+
-- re-verified against nodes before being surfaced (HomeGraph.getSegmentMatches),
|
|
147
|
+
-- and a full index clears the table at its start. Populated lazily on old
|
|
148
|
+
-- databases (empty until the next index/sync heals it).
|
|
149
|
+
CREATE TABLE IF NOT EXISTS name_segment_vocab (
|
|
150
|
+
segment TEXT NOT NULL,
|
|
151
|
+
name TEXT NOT NULL,
|
|
152
|
+
PRIMARY KEY (segment, name)
|
|
153
|
+
) WITHOUT ROWID;
|
|
154
|
+
|
|
155
|
+
-- Edge indexes.
|
|
156
|
+
-- idx_edges_source / idx_edges_target are intentionally omitted —
|
|
157
|
+
-- the (source, kind) and (target, kind) composites below cover the
|
|
158
|
+
-- corresponding source-only / target-only lookups via SQLite's
|
|
159
|
+
-- left-prefix scan, so the narrow indexes are dead weight on writes.
|
|
160
|
+
-- Migration v4 drops them on existing databases.
|
|
161
|
+
CREATE INDEX IF NOT EXISTS idx_edges_kind ON edges(kind);
|
|
162
|
+
CREATE INDEX IF NOT EXISTS idx_edges_source_kind ON edges(source, kind);
|
|
163
|
+
CREATE INDEX IF NOT EXISTS idx_edges_target_kind ON edges(target, kind);
|
|
164
|
+
|
|
165
|
+
-- Edge identity uniqueness. An edge IS uniquely (source, target, kind, line,
|
|
166
|
+
-- col); insertEdge uses `INSERT OR IGNORE`, but without something UNIQUE to
|
|
167
|
+
-- conflict on it behaved like a plain INSERT, so two passes emitting the same
|
|
168
|
+
-- edge produced byte-identical duplicate rows that inflated counts and flowed
|
|
169
|
+
-- into callers/impact (#1034). IFNULL folds the nullable line/col so
|
|
170
|
+
-- coordinate-less edges (synthesized / file-level) dedup too — SQLite treats
|
|
171
|
+
-- each NULL as distinct otherwise. Migration v6 dedups existing rows + adds
|
|
172
|
+
-- this on older databases.
|
|
173
|
+
CREATE UNIQUE INDEX IF NOT EXISTS idx_edges_identity
|
|
174
|
+
ON edges(source, target, kind, IFNULL(line, -1), IFNULL(col, -1));
|
|
175
|
+
|
|
176
|
+
-- File indexes
|
|
177
|
+
CREATE INDEX IF NOT EXISTS idx_files_language ON files(language);
|
|
178
|
+
CREATE INDEX IF NOT EXISTS idx_files_modified_at ON files(modified_at);
|
|
179
|
+
|
|
180
|
+
-- Unresolved refs indexes
|
|
181
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_from_node ON unresolved_refs(from_node_id);
|
|
182
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_name ON unresolved_refs(reference_name);
|
|
183
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_file_path ON unresolved_refs(file_path);
|
|
184
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_from_name ON unresolved_refs(from_node_id, reference_name);
|
|
185
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_status ON unresolved_refs(status);
|
|
186
|
+
CREATE INDEX IF NOT EXISTS idx_unresolved_failed_tail ON unresolved_refs(name_tail) WHERE status = 'failed';
|
|
187
|
+
CREATE INDEX IF NOT EXISTS idx_edges_provenance ON edges(provenance);
|
|
188
|
+
|
|
189
|
+
-- Project metadata for version/provenance tracking
|
|
190
|
+
CREATE TABLE IF NOT EXISTS project_metadata (
|
|
191
|
+
key TEXT PRIMARY KEY,
|
|
192
|
+
value TEXT NOT NULL,
|
|
193
|
+
updated_at INTEGER NOT NULL
|
|
194
|
+
);
|
|
195
|
+
|
|
196
|
+
-- MCP tool response cache (invalidated wholesale on index stamp change)
|
|
197
|
+
CREATE TABLE IF NOT EXISTS mcp_query_cache (
|
|
198
|
+
cache_key TEXT PRIMARY KEY,
|
|
199
|
+
tool TEXT NOT NULL,
|
|
200
|
+
response TEXT NOT NULL,
|
|
201
|
+
created_at INTEGER NOT NULL
|
|
202
|
+
);
|
|
203
|
+
CREATE INDEX IF NOT EXISTS idx_mcp_query_cache_tool ON mcp_query_cache(tool);
|
package/dist/directory.js
CHANGED
|
@@ -599,11 +599,11 @@ function planFrontload(cwd, prompt) {
|
|
|
599
599
|
* explicit allowlist that never listed `daemon.pid` or the socket, so those
|
|
600
600
|
* runtime files were silently committed.
|
|
601
601
|
*/
|
|
602
|
-
const GITIGNORE_CONTENT = `# HomeGraph data files — local to each machine, not for committing.
|
|
603
|
-
# Ignore everything in .homegraph/ except this file itself, so transient
|
|
604
|
-
# files (the database, daemon.pid, sockets, logs) never show up in git.
|
|
605
|
-
*
|
|
606
|
-
!.gitignore
|
|
602
|
+
const GITIGNORE_CONTENT = `# HomeGraph data files — local to each machine, not for committing.
|
|
603
|
+
# Ignore everything in .homegraph/ except this file itself, so transient
|
|
604
|
+
# files (the database, daemon.pid, sockets, logs) never show up in git.
|
|
605
|
+
*
|
|
606
|
+
!.gitignore
|
|
607
607
|
`;
|
|
608
608
|
/** Header line that prefixes every .gitignore HomeGraph has auto-generated. */
|
|
609
609
|
const GITIGNORE_MARKER = '# HomeGraph data files';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Ingest ArkAnalyzer ViewTree into HomeGraph nodes/edges.
|
|
3
3
|
*
|
|
4
4
|
* Maps declarative UI structure (component tree, event bindings, state usage,
|
|
5
|
-
*
|
|
5
|
+
* prop transfer) to traversable graph edges — no custom runtime heuristics.
|
|
6
6
|
*/
|
|
7
7
|
import { ArkField, ArkMethod, type ArkClass, type Scene } from 'arkanalyzer';
|
|
8
8
|
import type { Edge, ExtractionResult, Language } from '../../types';
|
|
@@ -14,11 +14,9 @@ export interface ViewTreeIndexerContext {
|
|
|
14
14
|
classToId: Map<ArkClass, string>;
|
|
15
15
|
fieldToId: Map<ArkField, string>;
|
|
16
16
|
nodeIds: Set<string>;
|
|
17
|
-
addEdge(result: ExtractionResult, source: string, target: string, kind: Edge['kind'], callerFile: string, via: string, line: number
|
|
17
|
+
addEdge(result: ExtractionResult, source: string, target: string, kind: Edge['kind'], callerFile: string, via: string, line: number): void;
|
|
18
18
|
ensureMethodNode(method: ArkMethod, relativePath: string, result: ExtractionResult, parentId: string): string | null;
|
|
19
19
|
resolveClassNodeId(cls: ArkClass): string | null;
|
|
20
|
-
/** Optional: persist state-decorator kinds on indexed field nodes. */
|
|
21
|
-
markFieldStateDecorators?: (field: ArkField, fieldNodeId: string, result: ExtractionResult) => void;
|
|
22
20
|
}
|
|
23
21
|
export declare function indexViewTreeForClass(ctx: ViewTreeIndexerContext, cls: ArkClass, result: ExtractionResult, relativePath: string): void;
|
|
24
22
|
//# sourceMappingURL=arkts-viewtree.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"arkts-viewtree.d.ts","sourceRoot":"","sources":["../../../src/extraction/languages/arkts-viewtree.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAIL,QAAQ,EACR,SAAS,EACT,KAAK,QAAQ,EACb,KAAK,KAAK,EAGX,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAAE,IAAI,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"arkts-viewtree.d.ts","sourceRoot":"","sources":["../../../src/extraction/languages/arkts-viewtree.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAIL,QAAQ,EACR,SAAS,EACT,KAAK,QAAQ,EACb,KAAK,KAAK,EAGX,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAAE,IAAI,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAIpE,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,EAAE,QAAQ,CAAC;IACnB,UAAU,EAAE,GAAG,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;IACnC,SAAS,EAAE,GAAG,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC;IACjC,SAAS,EAAE,GAAG,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC;IACjC,OAAO,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IACrB,OAAO,CACL,MAAM,EAAE,gBAAgB,EACxB,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,EAClB,UAAU,EAAE,MAAM,EAClB,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,GACX,IAAI,CAAC;IACR,gBAAgB,CACd,MAAM,EAAE,SAAS,EACjB,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,gBAAgB,EACxB,QAAQ,EAAE,MAAM,GACf,MAAM,GAAG,IAAI,CAAC;IACjB,kBAAkB,CAAC,GAAG,EAAE,QAAQ,GAAG,MAAM,GAAG,IAAI,CAAC;CAClD;AA2CD,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,sBAAsB,EAC3B,GAAG,EAAE,QAAQ,EACb,MAAM,EAAE,gBAAgB,EACxB,YAAY,EAAE,MAAM,GACnB,IAAI,CAkGN"}
|
|
@@ -5,10 +5,9 @@ exports.indexViewTreeForClass = indexViewTreeForClass;
|
|
|
5
5
|
* Ingest ArkAnalyzer ViewTree into HomeGraph nodes/edges.
|
|
6
6
|
*
|
|
7
7
|
* Maps declarative UI structure (component tree, event bindings, state usage,
|
|
8
|
-
*
|
|
8
|
+
* prop transfer) to traversable graph edges — no custom runtime heuristics.
|
|
9
9
|
*/
|
|
10
10
|
const arkanalyzer_1 = require("arkanalyzer");
|
|
11
|
-
const arkts_state_decorators_1 = require("./arkts-state-decorators");
|
|
12
11
|
const CALLBACK_ATTRS = new Set(arkanalyzer_1.CALLBACK_METHOD_NAME);
|
|
13
12
|
function lineFromStmt(stmt) {
|
|
14
13
|
return stmt?.getOriginFullPosition()?.getFirstLine() ?? 1;
|
|
@@ -56,23 +55,19 @@ function indexViewTreeForClass(ctx, cls, result, relativePath) {
|
|
|
56
55
|
if (!buildId)
|
|
57
56
|
return;
|
|
58
57
|
const seen = new Set();
|
|
59
|
-
const link = (source, target, kind, via, line
|
|
58
|
+
const link = (source, target, kind, via, line) => {
|
|
60
59
|
const key = `${source}>${target}>${kind}>${via}`;
|
|
61
60
|
if (seen.has(key))
|
|
62
61
|
return;
|
|
63
62
|
seen.add(key);
|
|
64
|
-
ctx.addEdge(result, source, target, kind, relativePath, via, line
|
|
63
|
+
ctx.addEdge(result, source, target, kind, relativePath, via, line);
|
|
65
64
|
};
|
|
66
65
|
// Reverse index: state field → build (UI reads this state in the tree).
|
|
67
66
|
for (const [field] of viewTree.getStateValues()) {
|
|
68
67
|
const fieldId = ctx.fieldToId.get(field);
|
|
69
68
|
if (fieldId) {
|
|
70
|
-
ctx.markFieldStateDecorators?.(field, fieldId, result);
|
|
71
|
-
const kinds = (0, arkts_state_decorators_1.stateDecoratorKinds)(field);
|
|
72
69
|
const line = field.getOriginFullPosition?.()?.getFirstLine?.() ?? buildMethod.getImplOriginFullPosition()?.getFirstLine() ?? 1;
|
|
73
|
-
link(fieldId, buildId, 'references', 'state-binding', line
|
|
74
|
-
...(kinds.length > 0 ? { stateDecorators: kinds.join(',') } : {}),
|
|
75
|
-
});
|
|
70
|
+
link(fieldId, buildId, 'references', 'state-binding', line);
|
|
76
71
|
}
|
|
77
72
|
}
|
|
78
73
|
walkViewTree(root, (node) => {
|
|
@@ -100,24 +95,14 @@ function indexViewTreeForClass(ctx, cls, result, relativePath) {
|
|
|
100
95
|
}
|
|
101
96
|
}
|
|
102
97
|
}
|
|
103
|
-
// Parent → child
|
|
98
|
+
// Parent → child prop transfer on embedded custom components.
|
|
104
99
|
if (node.stateValuesTransfer) {
|
|
105
100
|
for (const [childField, parentValue] of node.stateValuesTransfer) {
|
|
106
101
|
const childFieldId = ctx.fieldToId.get(childField);
|
|
107
102
|
if (parentValue instanceof arkanalyzer_1.ArkField) {
|
|
108
|
-
const via = (0, arkts_state_decorators_1.stateTransferViaForField)(childField);
|
|
109
|
-
if (!via || !childFieldId)
|
|
110
|
-
continue;
|
|
111
|
-
ctx.markFieldStateDecorators?.(childField, childFieldId, result);
|
|
112
103
|
const parentFieldId = ctx.fieldToId.get(parentValue);
|
|
113
|
-
if (parentFieldId) {
|
|
114
|
-
ctx.markFieldStateDecorators?.(parentValue, parentFieldId, result);
|
|
115
|
-
}
|
|
116
104
|
if (childFieldId && parentFieldId) {
|
|
117
|
-
link(parentFieldId, childFieldId, 'references',
|
|
118
|
-
stateDecorators: via,
|
|
119
|
-
transferDirection: (0, arkts_state_decorators_1.transferDirectionForVia)(via),
|
|
120
|
-
});
|
|
105
|
+
link(parentFieldId, childFieldId, 'references', 'prop-transfer', childField.getOriginFullPosition()?.getFirstLine() ?? 1);
|
|
121
106
|
}
|
|
122
107
|
}
|
|
123
108
|
else if (parentValue instanceof arkanalyzer_1.ArkMethod) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"arkts-viewtree.js","sourceRoot":"","sources":["../../../src/extraction/languages/arkts-viewtree.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"arkts-viewtree.js","sourceRoot":"","sources":["../../../src/extraction/languages/arkts-viewtree.ts"],"names":[],"mappings":";;AAwFA,sDAuGC;AA/LD;;;;;GAKG;AACH,6CAUqB;AAGrB,MAAM,cAAc,GAAG,IAAI,GAAG,CAAS,kCAAoB,CAAC,CAAC;AA4B7D,SAAS,YAAY,CAAC,IAAsB;IAC1C,OAAO,IAAI,EAAE,qBAAqB,EAAE,EAAE,YAAY,EAAE,IAAI,CAAC,CAAC;AAC5D,CAAC;AAED,SAAS,gBAAgB,CAAC,GAAqC;IAC7D,OAAO,GAAG,YAAY,4BAAc,CAAC;AACvC,CAAC;AAED,SAAS,0BAA0B,CACjC,GAA2B,EAC3B,GAAoB;IAEpB,OAAO,GAAG,CAAC,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;AAClC,CAAC;AAED,SAAS,yBAAyB,CAChC,GAA2B,E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M,EAAE,WAAW,CAAC,CAAC;gBACnF,IAAI,SAAS,EAAE,CAAC;oBACd,IAAI,CAAC,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;gBACrD,CAAC;YACH,CAAC;QACH,CAAC;IACH,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -10,18 +10,21 @@
|
|
|
10
10
|
* HarmonyOS multi-module projects (`build-profile.json5`) use
|
|
11
11
|
* `Scene.analyseByModule` so each HAP/HSP/HAR is the atomic unit (like a file
|
|
12
12
|
* for tree-sitter languages): symbols + ViewTree + **intra-module RTA** while
|
|
13
|
-
* the module has BODIES.
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
13
|
+
* the module has BODIES. Per-module RTA entries = DummyMain (Ability/Component
|
|
14
|
+
* lifecycle) **plus the module export surface** (exported functions and methods
|
|
15
|
+
* of exported classes), so non-UI libraries still grow reachable call edges.
|
|
16
|
+
* CFG does **not** stitch same-module calls (that densified past unlimited RTA).
|
|
17
|
+
* Cross-module edges come from RTA with an exact MethodSignature map, plus a
|
|
18
|
+
* CFG `%unk` bridge that recovers Class.method / free functions from stmt text,
|
|
19
|
+
* UnclearReferenceType names, or PascalCase base locals (import + unique target
|
|
20
|
+
* + fan-out blocklist). Deps load to SIGNATURES.
|
|
18
21
|
*
|
|
19
22
|
* Sync can re-index a **dirty module subset** (`primeArkTSBatch` + `changedFiles`)
|
|
20
23
|
* via `ModuleAnalysisConfig.setTargetModuleIds`, instead of rebuilding every
|
|
21
24
|
* PROJECT module. Unchanged modules stay in the DB; incoming cross-file edges
|
|
22
25
|
* into dirty files are snapshotted and re-bound like file-level sync (#899).
|
|
23
26
|
*/
|
|
24
|
-
import { ArkField, ArkMethod, ClassSignature, MethodSignature } from 'arkanalyzer';
|
|
27
|
+
import { ArkField, ArkFile, ArkMethod, ClassSignature, MethodSignature } from 'arkanalyzer';
|
|
25
28
|
import { ExtractionError, ExtractionResult } from '../../types';
|
|
26
29
|
import type { QueryBuilder } from '../../db/queries';
|
|
27
30
|
import type { IndexProgress, IndexResult } from '../index';
|
|
@@ -104,6 +107,13 @@ export declare class ArkTSExtractor {
|
|
|
104
107
|
constructor(filePath: string, _source: string);
|
|
105
108
|
extract(): ExtractionResult;
|
|
106
109
|
}
|
|
110
|
+
/**
|
|
111
|
+
* Methods another module can call into: module `export` surface as RTA entries.
|
|
112
|
+
* - exported function/method → itself
|
|
113
|
+
* - exported class/struct → all of its non-skip methods (with body)
|
|
114
|
+
* Skips `export … from` re-exports (not this module's IR).
|
|
115
|
+
*/
|
|
116
|
+
export declare function collectExportedRtaEntryPointsFromFiles(files: Iterable<ArkFile>): MethodSignature[];
|
|
107
117
|
/** State decorator kinds on a field (@State, @Prop, @Link, …) from arkanalyzer. */
|
|
108
118
|
export declare function stateDecoratorKinds(field: ArkField): string[];
|
|
109
119
|
/** Child @Prop / @Link — edge `via` uses the decorator name as-is. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"arkts.d.ts","sourceRoot":"","sources":["../../../src/extraction/languages/arkts.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"arkts.d.ts","sourceRoot":"","sources":["../../../src/extraction/languages/arkts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AAQH,OAAO,EAIL,QAAQ,EACR,OAAO,EACP,SAAS,EAgBT,cAAc,EACd,eAAe,EAChB,MAAM,aAAa,CAAC;AAErB,OAAO,EAEL,eAAe,EACf,gBAAgB,EAKjB,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAMrD,OAAO,KAAK,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAwB3D,+FAA+F;AAC/F,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAEtD;AAED;;;GAGG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