@codemap-ai/code-index 1.0.0

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.
Files changed (41) hide show
  1. package/LICENSE +21 -0
  2. package/dist/file-discovery.d.ts +36 -0
  3. package/dist/file-discovery.d.ts.map +1 -0
  4. package/dist/file-discovery.js +204 -0
  5. package/dist/index.d.ts +6 -0
  6. package/dist/index.d.ts.map +1 -0
  7. package/dist/index.js +26 -0
  8. package/dist/language-utils.d.ts +10 -0
  9. package/dist/language-utils.d.ts.map +1 -0
  10. package/dist/language-utils.js +75 -0
  11. package/dist/parsers/dart.d.ts +4 -0
  12. package/dist/parsers/dart.d.ts.map +1 -0
  13. package/dist/parsers/dart.js +353 -0
  14. package/dist/parsers/index.d.ts +11 -0
  15. package/dist/parsers/index.d.ts.map +1 -0
  16. package/dist/parsers/index.js +32 -0
  17. package/dist/parsers/java.d.ts +4 -0
  18. package/dist/parsers/java.d.ts.map +1 -0
  19. package/dist/parsers/java.js +222 -0
  20. package/dist/parsers/kotlin.d.ts +4 -0
  21. package/dist/parsers/kotlin.d.ts.map +1 -0
  22. package/dist/parsers/kotlin.js +221 -0
  23. package/dist/parsers/php.d.ts +4 -0
  24. package/dist/parsers/php.d.ts.map +1 -0
  25. package/dist/parsers/php.js +215 -0
  26. package/dist/parsers/python.d.ts +4 -0
  27. package/dist/parsers/python.d.ts.map +1 -0
  28. package/dist/parsers/python.js +200 -0
  29. package/dist/parsers/shared.d.ts +30 -0
  30. package/dist/parsers/shared.d.ts.map +1 -0
  31. package/dist/parsers/shared.js +200 -0
  32. package/dist/parsers/types.d.ts +93 -0
  33. package/dist/parsers/types.d.ts.map +1 -0
  34. package/dist/parsers/types.js +12 -0
  35. package/dist/parsers/typescript.d.ts +5 -0
  36. package/dist/parsers/typescript.d.ts.map +1 -0
  37. package/dist/parsers/typescript.js +549 -0
  38. package/dist/ts-resolver.d.ts +17 -0
  39. package/dist/ts-resolver.d.ts.map +1 -0
  40. package/dist/ts-resolver.js +110 -0
  41. package/package.json +30 -0
@@ -0,0 +1,30 @@
1
+ import type { TypeScriptResolverConfig } from "../ts-resolver.js";
2
+ import type { ParsedExternalSymbolDraft } from "./types.js";
3
+ export declare const JS_TS_EXTENSIONS: string[];
4
+ export declare const DART_EXTENSIONS: string[];
5
+ export declare const PHP_EXTENSIONS: string[];
6
+ export declare const PYTHON_EXTENSIONS: string[];
7
+ export declare const JAVA_EXTENSIONS: string[];
8
+ export declare const KOTLIN_EXTENSIONS: string[];
9
+ export declare function buildLocalSymbolKey(filePath: string, kind: string, displayName: string): string;
10
+ export declare function buildStableSymbolKey(filePath: string, kind: string, displayName: string, line: number): string;
11
+ export declare function buildImportLocalKey(filePath: string, importKind: string, moduleSpecifier: string, line: number, col: number): string;
12
+ export declare function resolveRelativeTargetPath(sourceFilePath: string, moduleSpecifier: string, language: string, filePathSet: Set<string>): {
13
+ resolvedPath: string | null;
14
+ attemptedPath: string;
15
+ };
16
+ export declare function findBestResolverConfig(sourceFilePath: string, resolverConfigs: TypeScriptResolverConfig[]): TypeScriptResolverConfig | null;
17
+ export declare function resolveTsconfigAliasTargetPath(workspacePath: string, sourceFilePath: string, moduleSpecifier: string, language: string, filePathSet: Set<string>, resolverConfigs: TypeScriptResolverConfig[]): {
18
+ matched: boolean;
19
+ resolvedPath: string;
20
+ attemptedPath: string;
21
+ } | {
22
+ matched: boolean;
23
+ resolvedPath: null;
24
+ attemptedPath: string;
25
+ } | null;
26
+ export declare function maskCommentsAndTemplateLiterals(content: string, options?: {
27
+ hashLineComments?: boolean;
28
+ }): string;
29
+ export declare function createExternalSymbolDraft(projectImportId: string, language: string, moduleSpecifier: string): ParsedExternalSymbolDraft;
30
+ //# sourceMappingURL=shared.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/parsers/shared.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,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C;AAED,wBAAgB,yBAAyB,CACvC,eAAe,EAAE,MAAM,EACvB,QAAQ,EAAE,MAAM,EAChB,eAAe,EAAE,MAAM,GACtB,yBAAyB,CAa3B"}
@@ -0,0 +1,200 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.KOTLIN_EXTENSIONS = exports.JAVA_EXTENSIONS = exports.PYTHON_EXTENSIONS = exports.PHP_EXTENSIONS = exports.DART_EXTENSIONS = exports.JS_TS_EXTENSIONS = void 0;
7
+ exports.buildLocalSymbolKey = buildLocalSymbolKey;
8
+ exports.buildStableSymbolKey = buildStableSymbolKey;
9
+ exports.buildImportLocalKey = buildImportLocalKey;
10
+ exports.resolveRelativeTargetPath = resolveRelativeTargetPath;
11
+ exports.findBestResolverConfig = findBestResolverConfig;
12
+ exports.resolveTsconfigAliasTargetPath = resolveTsconfigAliasTargetPath;
13
+ exports.maskCommentsAndTemplateLiterals = maskCommentsAndTemplateLiterals;
14
+ exports.createExternalSymbolDraft = createExternalSymbolDraft;
15
+ const node_path_1 = __importDefault(require("node:path"));
16
+ exports.JS_TS_EXTENSIONS = ["ts", "tsx", "js", "jsx"];
17
+ exports.DART_EXTENSIONS = ["dart"];
18
+ exports.PHP_EXTENSIONS = ["php"];
19
+ exports.PYTHON_EXTENSIONS = ["py"];
20
+ exports.JAVA_EXTENSIONS = ["java"];
21
+ exports.KOTLIN_EXTENSIONS = ["kt", "kts"];
22
+ function buildLocalSymbolKey(filePath, kind, displayName) {
23
+ return `${filePath}#${kind}:${displayName}`;
24
+ }
25
+ function buildStableSymbolKey(filePath, kind, displayName, line) {
26
+ return `${filePath}#${kind}:${displayName}:${line}`;
27
+ }
28
+ function buildImportLocalKey(filePath, importKind, moduleSpecifier, line, col) {
29
+ return `${filePath}#${importKind}:${moduleSpecifier}:${line}:${col}`;
30
+ }
31
+ function resolveRelativeTargetPath(sourceFilePath, moduleSpecifier, language, filePathSet) {
32
+ const basePath = node_path_1.default.posix.normalize(node_path_1.default.posix.join(node_path_1.default.posix.dirname(sourceFilePath), moduleSpecifier));
33
+ const extensions = language === "Dart" ? exports.DART_EXTENSIONS
34
+ : language === "PHP" ? exports.PHP_EXTENSIONS
35
+ : language === "Python" ? exports.PYTHON_EXTENSIONS
36
+ : language === "Java" ? exports.JAVA_EXTENSIONS
37
+ : language === "Kotlin" ? exports.KOTLIN_EXTENSIONS
38
+ : exports.JS_TS_EXTENSIONS;
39
+ const candidates = [basePath];
40
+ if (!node_path_1.default.posix.extname(basePath)) {
41
+ for (const extension of extensions) {
42
+ candidates.push(`${basePath}.${extension}`);
43
+ candidates.push(`${basePath}/index.${extension}`);
44
+ }
45
+ }
46
+ else if (node_path_1.default.posix.extname(basePath) === ".js") {
47
+ const stem = basePath.slice(0, -3);
48
+ candidates.push(`${stem}.ts`, `${stem}.tsx`);
49
+ }
50
+ const resolvedPath = candidates.find((candidate) => filePathSet.has(candidate));
51
+ return { resolvedPath: resolvedPath ?? null, attemptedPath: basePath };
52
+ }
53
+ function findBestResolverConfig(sourceFilePath, resolverConfigs) {
54
+ return (resolverConfigs.find((config) => {
55
+ const configRelativeDir = config.configDirRelativePath;
56
+ if (!configRelativeDir)
57
+ return true;
58
+ return (node_path_1.default.posix.dirname(sourceFilePath).startsWith(`${configRelativeDir}/`) ||
59
+ node_path_1.default.posix.dirname(sourceFilePath) === configRelativeDir);
60
+ }) ?? null);
61
+ }
62
+ function resolveTsconfigAliasTargetPath(workspacePath, sourceFilePath, moduleSpecifier, language, filePathSet, resolverConfigs) {
63
+ const resolverConfig = findBestResolverConfig(sourceFilePath, resolverConfigs);
64
+ if (!resolverConfig)
65
+ return null;
66
+ const extensions = language === "TypeScript" || language === "JavaScript" ? exports.JS_TS_EXTENSIONS
67
+ : language === "Dart" ? exports.DART_EXTENSIONS
68
+ : language === "Python" ? exports.PYTHON_EXTENSIONS
69
+ : language === "Java" ? exports.JAVA_EXTENSIONS
70
+ : language === "Kotlin" ? exports.KOTLIN_EXTENSIONS
71
+ : exports.PHP_EXTENSIONS;
72
+ for (const alias of resolverConfig.pathAliases) {
73
+ let wildcardValue = "";
74
+ if (alias.hasWildcard) {
75
+ if (!moduleSpecifier.startsWith(alias.prefix) || !moduleSpecifier.endsWith(alias.suffix))
76
+ continue;
77
+ wildcardValue = moduleSpecifier.slice(alias.prefix.length, moduleSpecifier.length - alias.suffix.length);
78
+ }
79
+ else if (moduleSpecifier !== alias.pattern) {
80
+ continue;
81
+ }
82
+ for (const targetPattern of alias.targets) {
83
+ const targetValue = alias.hasWildcard ? targetPattern.replace(/\*/g, wildcardValue) : targetPattern;
84
+ const candidateBasePath = node_path_1.default.resolve(resolverConfig.baseUrlPath, targetValue);
85
+ // normalizeWorkspaceRelativePath inline to avoid circular dep
86
+ const relativePath = node_path_1.default.relative(workspacePath, candidateBasePath);
87
+ const candidateRelativeBasePath = relativePath
88
+ ? relativePath.split(node_path_1.default.sep).join("/").replace(/^\.\//, "")
89
+ : "";
90
+ const candidates = [candidateRelativeBasePath];
91
+ if (!node_path_1.default.posix.extname(candidateRelativeBasePath)) {
92
+ for (const extension of extensions) {
93
+ candidates.push(`${candidateRelativeBasePath}.${extension}`);
94
+ candidates.push(`${candidateRelativeBasePath}/index.${extension}`);
95
+ }
96
+ }
97
+ const resolvedPath = candidates.find((candidate) => filePathSet.has(candidate));
98
+ if (resolvedPath) {
99
+ return { matched: true, resolvedPath, attemptedPath: candidateRelativeBasePath };
100
+ }
101
+ return { matched: true, resolvedPath: null, attemptedPath: candidateRelativeBasePath };
102
+ }
103
+ }
104
+ return null;
105
+ }
106
+ function maskCommentsAndTemplateLiterals(content, options = {}) {
107
+ const chars = content.split("");
108
+ let index = 0;
109
+ let state = "code";
110
+ function maskChar(position) {
111
+ if (chars[position] !== "\n" && chars[position] !== "\r") {
112
+ chars[position] = " ";
113
+ }
114
+ }
115
+ while (index < chars.length) {
116
+ const char = chars[index];
117
+ const nextChar = chars[index + 1];
118
+ if (state === "line-comment") {
119
+ if (char === "\n" || char === "\r") {
120
+ state = "code";
121
+ }
122
+ else {
123
+ maskChar(index);
124
+ }
125
+ index += 1;
126
+ continue;
127
+ }
128
+ if (state === "block-comment") {
129
+ if (char === "*" && nextChar === "/") {
130
+ maskChar(index);
131
+ maskChar(index + 1);
132
+ index += 2;
133
+ state = "code";
134
+ continue;
135
+ }
136
+ maskChar(index);
137
+ index += 1;
138
+ continue;
139
+ }
140
+ if (state === "single" || state === "double" || state === "template") {
141
+ if (state === "template")
142
+ maskChar(index);
143
+ if (char === "\\") {
144
+ if (state === "template")
145
+ maskChar(index + 1);
146
+ index += 2;
147
+ continue;
148
+ }
149
+ if ((state === "single" && char === "'") || (state === "double" && char === '"') || (state === "template" && char === "`")) {
150
+ state = "code";
151
+ }
152
+ index += 1;
153
+ continue;
154
+ }
155
+ if (char === "/" && nextChar === "/") {
156
+ maskChar(index);
157
+ maskChar(index + 1);
158
+ index += 2;
159
+ state = "line-comment";
160
+ continue;
161
+ }
162
+ if (options.hashLineComments && char === "#") {
163
+ maskChar(index);
164
+ index += 1;
165
+ state = "line-comment";
166
+ continue;
167
+ }
168
+ if (char === "/" && nextChar === "*") {
169
+ maskChar(index);
170
+ maskChar(index + 1);
171
+ index += 2;
172
+ state = "block-comment";
173
+ continue;
174
+ }
175
+ if (char === "'")
176
+ state = "single";
177
+ else if (char === '"')
178
+ state = "double";
179
+ else if (char === "`") {
180
+ maskChar(index);
181
+ state = "template";
182
+ }
183
+ index += 1;
184
+ }
185
+ return chars.join("");
186
+ }
187
+ function createExternalSymbolDraft(projectImportId, language, moduleSpecifier) {
188
+ return {
189
+ projectImportId,
190
+ symbolKey: `${language.toLowerCase()}:${moduleSpecifier}`,
191
+ packageManager: language === "Dart" ? "pub" : language === "PHP" ? "composer" : language === "Python" ? "pip" : language === "Java" || language === "Kotlin" ? "gradle" : "npm",
192
+ packageName: moduleSpecifier,
193
+ packageVersion: null,
194
+ language,
195
+ displayName: moduleSpecifier,
196
+ kind: language === "PHP" ? "namespace" : "module",
197
+ documentationJson: null,
198
+ extraJson: null,
199
+ };
200
+ }
@@ -0,0 +1,93 @@
1
+ export type RepoFileParseStatus = "parsed" | "skipped" | "too_large" | "binary" | "unsupported" | "error";
2
+ export type RepoSymbolKind = "module" | "namespace" | "class" | "interface" | "trait" | "mixin" | "enum" | "enum_member" | "function" | "component" | "method" | "constructor" | "property" | "field" | "variable" | "constant" | "type_alias" | "parameter";
3
+ export type RepoSymbolRelationshipKind = "implements" | "extends" | "type_of" | "calls" | "references" | "overrides" | "exports_from" | "imports_from" | "defines";
4
+ export type RepoImportKind = "import" | "require" | "dynamic_import" | "export_from" | "include" | "use";
5
+ export type RepoImportResolutionKind = "relative_path" | "tsconfig_alias" | "package" | "unresolved" | "builtin";
6
+ export type RepoExportKind = "named" | "default" | "wildcard" | "re_export";
7
+ export type RepoParseIssueSeverity = "info" | "warning" | "error";
8
+ export interface ParsedParseIssueDraft {
9
+ projectImportId: string;
10
+ fileId?: string | null;
11
+ severity: RepoParseIssueSeverity;
12
+ code?: string | null;
13
+ message: string;
14
+ detailJson?: unknown;
15
+ }
16
+ export interface ParsedExternalSymbolDraft {
17
+ projectImportId: string;
18
+ symbolKey: string;
19
+ packageManager: string | null;
20
+ packageName: string | null;
21
+ packageVersion: string | null;
22
+ language: string | null;
23
+ displayName: string | null;
24
+ kind: string | null;
25
+ documentationJson: unknown;
26
+ extraJson: unknown;
27
+ }
28
+ export interface ParsedSymbolDraft {
29
+ localKey: string;
30
+ stableKey: string;
31
+ displayName: string;
32
+ kind: RepoSymbolKind;
33
+ language: string;
34
+ signature: string | null;
35
+ returnType: string | null;
36
+ doc: string | null;
37
+ isExported: boolean;
38
+ isDefaultExport: boolean;
39
+ line: number;
40
+ col: number;
41
+ endLine: number;
42
+ endCol: number;
43
+ parentSymbolLocalKey?: string;
44
+ }
45
+ export interface ParsedImportDraft {
46
+ localKey: string;
47
+ moduleSpecifier: string;
48
+ importKind: RepoImportKind;
49
+ isTypeOnly: boolean;
50
+ importedNames: string[];
51
+ namespaceName?: string;
52
+ line: number;
53
+ col: number;
54
+ endLine: number;
55
+ endCol: number;
56
+ resolutionKind: RepoImportResolutionKind;
57
+ targetPathText: string | null;
58
+ targetExternalSymbolKey: string | null;
59
+ }
60
+ export interface ParsedExportDraft {
61
+ exportName: string;
62
+ exportKind: RepoExportKind;
63
+ line: number;
64
+ col: number;
65
+ endLine: number;
66
+ endCol: number;
67
+ symbolLocalKey?: string;
68
+ sourceImportLocalKey?: string;
69
+ targetExternalSymbolKey?: string | null;
70
+ }
71
+ export interface ParsedRelationshipDraft {
72
+ fromSymbolLocalKey: string;
73
+ toSymbolName: string;
74
+ relationshipKind: RepoSymbolRelationshipKind;
75
+ }
76
+ export interface ParsedCallDraft {
77
+ calleeName: string;
78
+ namespaceName?: string;
79
+ line: number;
80
+ col: number;
81
+ endCol: number;
82
+ }
83
+ export interface ParsedWorkspaceSemantics {
84
+ symbols: ParsedSymbolDraft[];
85
+ imports: ParsedImportDraft[];
86
+ exports: ParsedExportDraft[];
87
+ relationships: ParsedRelationshipDraft[];
88
+ calls: ParsedCallDraft[];
89
+ issues: ParsedParseIssueDraft[];
90
+ externalSymbols: ParsedExternalSymbolDraft[];
91
+ }
92
+ export declare const EMPTY_SEMANTICS: ParsedWorkspaceSemantics;
93
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/parsers/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAC3B,QAAQ,GACR,SAAS,GACT,WAAW,GACX,QAAQ,GACR,aAAa,GACb,OAAO,CAAC;AAEZ,MAAM,MAAM,cAAc,GACtB,QAAQ,GACR,WAAW,GACX,OAAO,GACP,WAAW,GACX,OAAO,GACP,OAAO,GACP,MAAM,GACN,aAAa,GACb,UAAU,GACV,WAAW,GACX,QA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AC;IACxB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,uBAAuB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACzC;AAED,MAAM,WAAW,uBAAuB;IACtC,kBAAkB,EAAE,MAAM,CAAC;IAC3B,YAAY,EAAE,MAAM,CAAC;IACrB,gBAAgB,EAAE,0BAA0B,CAAC;CAC9C;AAED,MAAM,WAAW,eAAe;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,wBAAwB;IACvC,OAAO,EAAE,iBAAiB,EAAE,CAAC;IAC7B,OAAO,EAAE,iBAAiB,EAAE,CAAC;IAC7B,OAAO,EAAE,iBAAiB,EAAE,CAAC;IAC7B,aAAa,EAAE,uBAAuB,EAAE,CAAC;IACzC,KAAK,EAAE,eAAe,EAAE,CAAC;IACzB,MAAM,EAAE,qBAAqB,EAAE,CAAC;IAChC,eAAe,EAAE,yBAAyB,EAAE,CAAC;CAC9C;AAED,eAAO,MAAM,eAAe,EAAE,wBAQ7B,CAAC"}
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.EMPTY_SEMANTICS = void 0;
4
+ exports.EMPTY_SEMANTICS = {
5
+ symbols: [],
6
+ imports: [],
7
+ exports: [],
8
+ relationships: [],
9
+ calls: [],
10
+ issues: [],
11
+ externalSymbols: [],
12
+ };
@@ -0,0 +1,5 @@
1
+ import type { WorkspaceFileCandidate } from "../file-discovery.js";
2
+ import type { TypeScriptResolverConfig } from "../ts-resolver.js";
3
+ import type { ParsedWorkspaceSemantics } from "./types.js";
4
+ export declare function parseTypeScriptOrJavaScriptFile(file: WorkspaceFileCandidate, filePathSet: Set<string>, projectImportId: string, workspacePath: string, resolverConfigs: TypeScriptResolverConfig[]): ParsedWorkspaceSemantics;
5
+ //# sourceMappingURL=typescript.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"typescript.d.ts","sourceRoot":"","sources":["../../src/parsers/typescript.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AASnE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAClE,OAAO,KAAK,EAKV,wBAAwB,EACzB,MAAM,YAAY,CAAC;AAumBpB,wBAAgB,+BAA+B,CAC7C,IAAI,EAAE,sBAAsB,EAC5B,WAAW,EAAE,GAAG,CAAC,MAAM,CAAC,EACxB,eAAe,EAAE,MAAM,EACvB,aAAa,EAAE,MAAM,EACrB,eAAe,EAAE,wBAAwB,EAAE,GAC1C,wBAAwB,CA+B1B"}