-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathindex.js
More file actions
145 lines (143 loc) · 3.45 KB
/
Copy pathindex.js
File metadata and controls
145 lines (143 loc) · 3.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
/**
* codegraph — Programmatic API
*
* Usage:
* import { buildGraph, queryNameData, findCycles, exportDOT } from 'codegraph';
*/
// Audit (composite report)
export { audit, auditData } from './audit.js';
// Batch querying
export { BATCH_COMMANDS, batch, batchData } from './batch.js';
// Branch comparison
export { branchCompareData, branchCompareMermaid } from './branch-compare.js';
// Graph building
export { buildGraph, collectFiles, loadPathAliases, resolveImportPath } from './builder.js';
// Co-change analysis
export {
analyzeCoChanges,
coChangeData,
coChangeForFiles,
coChangeTopData,
computeCoChanges,
scanGitHistory,
} from './cochange.js';
// Community detection
export { communities, communitiesData, communitySummaryForStats } from './communities.js';
// Complexity metrics
export {
COMPLEXITY_RULES,
complexity,
complexityData,
computeFunctionComplexity,
computeHalsteadMetrics,
computeLOCMetrics,
computeMaintainabilityIndex,
HALSTEAD_RULES,
iterComplexity,
} from './complexity.js';
// Configuration
export { loadConfig } from './config.js';
// Shared constants
export { EXTENSIONS, IGNORE_DIRS, normalizePath } from './constants.js';
// Circular dependency detection
export { findCycles, formatCycles } from './cycles.js';
// Database utilities
export {
findDbPath,
getBuildMeta,
initSchema,
openDb,
openReadonlyOrFail,
setBuildMeta,
} from './db.js';
// Embeddings
export {
buildEmbeddings,
cosineSim,
DEFAULT_MODEL,
disposeModel,
EMBEDDING_STRATEGIES,
embed,
estimateTokens,
ftsSearchData,
hybridSearchData,
MODELS,
multiSearchData,
search,
searchData,
} from './embedder.js';
// Export (DOT/Mermaid/JSON)
export { exportDOT, exportJSON, exportMermaid } from './export.js';
// Execution flow tracing
export { entryPointType, flowData, listEntryPointsData } from './flow.js';
// Logger
export { setVerbose } from './logger.js';
// Manifesto rule engine
export { manifesto, manifestoData, RULE_DEFS } from './manifesto.js';
// Native engine
export { isNativeAvailable } from './native.js';
// Ownership (CODEOWNERS)
export { matchOwners, owners, ownersData, ownersForFiles, parseCodeowners } from './owners.js';
// Pagination utilities
export { MCP_DEFAULTS, MCP_MAX_LIMIT, paginate, paginateResult, printNdjson } from './paginate.js';
// Unified parser API
export { getActiveEngine, parseFileAuto, parseFilesAuto } from './parser.js';
// Query functions (data-returning)
export {
ALL_SYMBOL_KINDS,
contextData,
diffImpactData,
diffImpactMermaid,
explainData,
FALSE_POSITIVE_CALLER_THRESHOLD,
FALSE_POSITIVE_NAMES,
fileDepsData,
fnDepsData,
fnImpactData,
impactAnalysisData,
iterListFunctions,
iterRoles,
iterWhere,
kindIcon,
moduleMapData,
pathData,
queryNameData,
rolesData,
statsData,
VALID_ROLES,
whereData,
} from './queries.js';
// Registry (multi-repo)
export {
listRepos,
loadRegistry,
pruneRegistry,
REGISTRY_PATH,
registerRepo,
resolveRepoDbPath,
saveRegistry,
unregisterRepo,
} from './registry.js';
// Snapshot management
export {
snapshotDelete,
snapshotList,
snapshotRestore,
snapshotSave,
snapshotsDir,
validateSnapshotName,
} from './snapshot.js';
// Structure analysis
export {
buildStructure,
classifyNodeRoles,
FRAMEWORK_ENTRY_PREFIXES,
formatHotspots,
formatModuleBoundaries,
formatStructure,
hotspotsData,
moduleBoundariesData,
structureData,
} from './structure.js';
// Watch mode
export { watchProject } from './watcher.js';