@nahisaho/musubix-codegraph 2.3.0 → 2.3.3

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 (109) hide show
  1. package/README.md +45 -23
  2. package/dist/cli.d.ts +13 -0
  3. package/dist/cli.d.ts.map +1 -0
  4. package/dist/cli.js +200 -0
  5. package/dist/cli.js.map +1 -0
  6. package/dist/index.d.ts +1 -0
  7. package/dist/index.d.ts.map +1 -1
  8. package/dist/index.js +8 -0
  9. package/dist/index.js.map +1 -1
  10. package/dist/parser/ast-parser.d.ts +29 -1
  11. package/dist/parser/ast-parser.d.ts.map +1 -1
  12. package/dist/parser/ast-parser.js +142 -19
  13. package/dist/parser/ast-parser.js.map +1 -1
  14. package/dist/parser/extractors/base-extractor.d.ts +252 -0
  15. package/dist/parser/extractors/base-extractor.d.ts.map +1 -0
  16. package/dist/parser/extractors/base-extractor.js +267 -0
  17. package/dist/parser/extractors/base-extractor.js.map +1 -0
  18. package/dist/parser/extractors/c-cpp.d.ts +38 -0
  19. package/dist/parser/extractors/c-cpp.d.ts.map +1 -0
  20. package/dist/parser/extractors/c-cpp.js +411 -0
  21. package/dist/parser/extractors/c-cpp.js.map +1 -0
  22. package/dist/parser/extractors/csharp.d.ts +28 -0
  23. package/dist/parser/extractors/csharp.d.ts.map +1 -0
  24. package/dist/parser/extractors/csharp.js +283 -0
  25. package/dist/parser/extractors/csharp.js.map +1 -0
  26. package/dist/parser/extractors/go.d.ts +25 -0
  27. package/dist/parser/extractors/go.d.ts.map +1 -0
  28. package/dist/parser/extractors/go.js +247 -0
  29. package/dist/parser/extractors/go.js.map +1 -0
  30. package/dist/parser/extractors/hcl.d.ts +22 -0
  31. package/dist/parser/extractors/hcl.d.ts.map +1 -0
  32. package/dist/parser/extractors/hcl.js +155 -0
  33. package/dist/parser/extractors/hcl.js.map +1 -0
  34. package/dist/parser/extractors/index.d.ts +68 -0
  35. package/dist/parser/extractors/index.d.ts.map +1 -0
  36. package/dist/parser/extractors/index.js +187 -0
  37. package/dist/parser/extractors/index.js.map +1 -0
  38. package/dist/parser/extractors/java.d.ts +28 -0
  39. package/dist/parser/extractors/java.d.ts.map +1 -0
  40. package/dist/parser/extractors/java.js +294 -0
  41. package/dist/parser/extractors/java.js.map +1 -0
  42. package/dist/parser/extractors/kotlin.d.ts +27 -0
  43. package/dist/parser/extractors/kotlin.d.ts.map +1 -0
  44. package/dist/parser/extractors/kotlin.js +269 -0
  45. package/dist/parser/extractors/kotlin.js.map +1 -0
  46. package/dist/parser/extractors/lua.d.ts +26 -0
  47. package/dist/parser/extractors/lua.d.ts.map +1 -0
  48. package/dist/parser/extractors/lua.js +244 -0
  49. package/dist/parser/extractors/lua.js.map +1 -0
  50. package/dist/parser/extractors/php.d.ts +27 -0
  51. package/dist/parser/extractors/php.d.ts.map +1 -0
  52. package/dist/parser/extractors/php.js +270 -0
  53. package/dist/parser/extractors/php.js.map +1 -0
  54. package/dist/parser/extractors/python.d.ts +22 -0
  55. package/dist/parser/extractors/python.d.ts.map +1 -0
  56. package/dist/parser/extractors/python.js +184 -0
  57. package/dist/parser/extractors/python.js.map +1 -0
  58. package/dist/parser/extractors/ruby.d.ts +25 -0
  59. package/dist/parser/extractors/ruby.d.ts.map +1 -0
  60. package/dist/parser/extractors/ruby.js +193 -0
  61. package/dist/parser/extractors/ruby.js.map +1 -0
  62. package/dist/parser/extractors/rust.d.ts +27 -0
  63. package/dist/parser/extractors/rust.d.ts.map +1 -0
  64. package/dist/parser/extractors/rust.js +262 -0
  65. package/dist/parser/extractors/rust.js.map +1 -0
  66. package/dist/parser/extractors/scala.d.ts +27 -0
  67. package/dist/parser/extractors/scala.d.ts.map +1 -0
  68. package/dist/parser/extractors/scala.js +265 -0
  69. package/dist/parser/extractors/scala.js.map +1 -0
  70. package/dist/parser/extractors/swift.d.ts +30 -0
  71. package/dist/parser/extractors/swift.d.ts.map +1 -0
  72. package/dist/parser/extractors/swift.js +326 -0
  73. package/dist/parser/extractors/swift.js.map +1 -0
  74. package/dist/parser/extractors/typescript.d.ts +30 -0
  75. package/dist/parser/extractors/typescript.d.ts.map +1 -0
  76. package/dist/parser/extractors/typescript.js +230 -0
  77. package/dist/parser/extractors/typescript.js.map +1 -0
  78. package/dist/pr/git-operations.d.ts +186 -0
  79. package/dist/pr/git-operations.d.ts.map +1 -0
  80. package/dist/pr/git-operations.js +441 -0
  81. package/dist/pr/git-operations.js.map +1 -0
  82. package/dist/pr/github-adapter.d.ts +163 -0
  83. package/dist/pr/github-adapter.d.ts.map +1 -0
  84. package/dist/pr/github-adapter.js +467 -0
  85. package/dist/pr/github-adapter.js.map +1 -0
  86. package/dist/pr/index.d.ts +19 -0
  87. package/dist/pr/index.d.ts.map +1 -0
  88. package/dist/pr/index.js +24 -0
  89. package/dist/pr/index.js.map +1 -0
  90. package/dist/pr/pr-creator.d.ts +135 -0
  91. package/dist/pr/pr-creator.d.ts.map +1 -0
  92. package/dist/pr/pr-creator.js +387 -0
  93. package/dist/pr/pr-creator.js.map +1 -0
  94. package/dist/pr/pr-template.d.ts +105 -0
  95. package/dist/pr/pr-template.d.ts.map +1 -0
  96. package/dist/pr/pr-template.js +273 -0
  97. package/dist/pr/pr-template.js.map +1 -0
  98. package/dist/pr/refactoring-applier.d.ts +143 -0
  99. package/dist/pr/refactoring-applier.d.ts.map +1 -0
  100. package/dist/pr/refactoring-applier.js +412 -0
  101. package/dist/pr/refactoring-applier.js.map +1 -0
  102. package/dist/pr/types.d.ts +362 -0
  103. package/dist/pr/types.d.ts.map +1 -0
  104. package/dist/pr/types.js +63 -0
  105. package/dist/pr/types.js.map +1 -0
  106. package/dist/types.d.ts +2 -1
  107. package/dist/types.d.ts.map +1 -1
  108. package/dist/types.js.map +1 -1
  109. package/package.json +26 -2
package/README.md CHANGED
@@ -9,7 +9,7 @@
9
9
 
10
10
  `@nahisaho/musubix-codegraph` is a high-performance code graph analysis library that provides:
11
11
 
12
- - **AST Parsing**: Tree-sitter based multi-language code parsing (16 languages)
12
+ - **AST Parsing**: Tree-sitter based multi-language code parsing (**16 languages** in v2.3.2)
13
13
  - **Graph Engine**: Code entity and relationship graph construction
14
14
  - **GraphRAG**: Graph-based Retrieval Augmented Generation for code search
15
15
  - **YATA Integration**: Seamless integration with YATA knowledge graph
@@ -66,22 +66,35 @@ const search = new GraphRAGSearch(graph);
66
66
  const communities = await search.detectCommunities();
67
67
  ```
68
68
 
69
- ## Supported Languages
70
-
71
- | Language | Extensions | Status |
72
- |----------|-----------|--------|
73
- | TypeScript | `.ts`, `.tsx` | ✅ |
74
- | JavaScript | `.js`, `.jsx`, `.mjs` | ✅ |
75
- | Python | `.py` | ✅ |
76
- | Rust | `.rs` | ✅ |
77
- | Go | `.go` | ✅ |
78
- | Java | `.java` | ✅ |
79
- | PHP | `.php` | ✅ |
80
- | C# | `.cs` | ✅ |
81
- | C | `.c`, `.h` | ✅ |
82
- | C++ | `.cpp`, `.hpp`, `.cc` | ✅ |
83
- | Ruby | `.rb` | ✅ |
84
- | HCL | `.tf`, `.hcl` | ✅ |
69
+ ## Supported Languages (16 languages - v2.3.2)
70
+
71
+ | Priority | Language | Extensions | Status |
72
+ |----------|----------|-----------|--------|
73
+ | **Existing** | TypeScript | `.ts`, `.tsx` | ✅ Full Support |
74
+ | **Existing** | JavaScript | `.js`, `.jsx`, `.mjs` | ✅ Full Support |
75
+ | **Existing** | Python | `.py`, `.pyw` | ✅ Full Support |
76
+ | **P0** | Rust | `.rs` | ✅ Full Support |
77
+ | **P0** | Go | `.go` | ✅ Full Support |
78
+ | **P0** | Java | `.java` | ✅ Full Support |
79
+ | **P1** | PHP | `.php` | ✅ Full Support |
80
+ | **P1** | C# | `.cs` | ✅ Full Support |
81
+ | **P1** | C | `.c`, `.h` | ✅ Full Support |
82
+ | **P1** | C++ | `.cpp`, `.hpp`, `.cc`, `.hh` | ✅ Full Support |
83
+ | **P1** | Ruby | `.rb` | ✅ Full Support |
84
+ | **P2** | HCL/Terraform | `.tf`, `.hcl` | ✅ Full Support |
85
+ | **P2** | Kotlin | `.kt`, `.kts` | ✅ Full Support |
86
+ | **P2** | Swift | `.swift` | ✅ Full Support |
87
+ | **P2** | Scala | `.scala`, `.sc` | ✅ Full Support |
88
+ | **P2** | Lua | `.lua` | ✅ Full Support |
89
+
90
+ **Entity Types Extracted:**
91
+ - Functions, Methods, Constructors
92
+ - Classes, Interfaces, Traits, Protocols
93
+ - Structs, Enums, Records, Unions
94
+ - Modules, Packages, Namespaces
95
+ - Variables, Constants, Properties
96
+ - Type Definitions, Templates
97
+ - Language-specific constructs (Terraform resources, Swift extensions, etc.)
85
98
 
86
99
  ## API Reference
87
100
 
@@ -147,19 +160,28 @@ When used with MUSUBIX CLI:
147
160
 
148
161
  ```bash
149
162
  # Index repository
150
- musubix codegraph index /path/to/repo
163
+ musubix cg index /path/to/repo
151
164
 
152
165
  # Query graph
153
- musubix codegraph query "UserService"
166
+ musubix cg query "UserService"
154
167
 
155
168
  # Find dependencies
156
- musubix codegraph find-deps UserService --depth 3
169
+ musubix cg deps UserService
170
+
171
+ # Find callers/callees
172
+ musubix cg callers functionName
173
+ musubix cg callees functionName
174
+
175
+ # Semantic search
176
+ musubix cg search "authentication flow"
157
177
 
158
178
  # Show statistics
159
- musubix codegraph stats
179
+ musubix cg stats
160
180
 
161
- # Start MCP server
162
- musubix codegraph serve
181
+ # Show supported languages (v2.3.2)
182
+ musubix cg languages # Table format
183
+ musubix cg languages --json # JSON format
184
+ musubix cg langs # Alias
163
185
  ```
164
186
 
165
187
  ## Performance
package/dist/cli.d.ts ADDED
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * @nahisaho/musubix-codegraph CLI
4
+ *
5
+ * Command-line interface for CodeGraph operations
6
+ *
7
+ * @packageDocumentation
8
+ * @module @nahisaho/musubix-codegraph/cli
9
+ *
10
+ * @see REQ-CG-PR-009 - CLI Integration
11
+ */
12
+ export {};
13
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;GASG"}
package/dist/cli.js ADDED
@@ -0,0 +1,200 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * @nahisaho/musubix-codegraph CLI
4
+ *
5
+ * Command-line interface for CodeGraph operations
6
+ *
7
+ * @packageDocumentation
8
+ * @module @nahisaho/musubix-codegraph/cli
9
+ *
10
+ * @see REQ-CG-PR-009 - CLI Integration
11
+ */
12
+ import { program } from 'commander';
13
+ import { readFileSync, existsSync } from 'node:fs';
14
+ import { resolve } from 'node:path';
15
+ // Read package.json for version
16
+ const packageJsonPath = new URL('../package.json', import.meta.url);
17
+ const packageJson = JSON.parse(readFileSync(packageJsonPath, 'utf-8'));
18
+ program
19
+ .name('cg')
20
+ .description('MUSUBIX CodeGraph - Code Graph Analysis CLI')
21
+ .version(packageJson.version);
22
+ // ============================================================================
23
+ // PR Commands
24
+ // ============================================================================
25
+ const prCommand = program
26
+ .command('pr')
27
+ .description('PR creation from refactoring suggestions');
28
+ /**
29
+ * cg pr create
30
+ */
31
+ prCommand
32
+ .command('create <suggestionFile>')
33
+ .description('Create a PR from a refactoring suggestion JSON file')
34
+ .option('-b, --branch <name>', 'Custom branch name')
35
+ .option('-t, --title <title>', 'Custom PR title')
36
+ .option('--base <branch>', 'Base branch (default: main/master)')
37
+ .option('-l, --labels <labels>', 'Comma-separated labels')
38
+ .option('-r, --reviewers <reviewers>', 'Comma-separated reviewers')
39
+ .option('-a, --assignees <assignees>', 'Comma-separated assignees')
40
+ .option('--draft', 'Create as draft PR')
41
+ .option('--dry-run', 'Preview changes without creating PR')
42
+ .option('--repo <path>', 'Repository path (default: current directory)')
43
+ .action(async (suggestionFile, options) => {
44
+ try {
45
+ const { createPRCreator } = await import('./pr/index.js');
46
+ // Read suggestion file
47
+ const filePath = resolve(suggestionFile);
48
+ if (!existsSync(filePath)) {
49
+ console.error(`❌ Suggestion file not found: ${filePath}`);
50
+ process.exit(1);
51
+ }
52
+ const suggestion = JSON.parse(readFileSync(filePath, 'utf-8'));
53
+ const repoPath = options.repo ?? process.cwd();
54
+ console.log('🚀 Initializing PR Creator...');
55
+ const creator = createPRCreator(repoPath);
56
+ // Event listeners for progress
57
+ creator.on('pr:start', () => console.log('📋 Starting PR creation...'));
58
+ creator.on('pr:branch', ({ name }) => console.log(`🌿 Creating branch: ${name}`));
59
+ creator.on('pr:applying', ({ file }) => console.log(`📝 Applying changes to: ${file}`));
60
+ creator.on('pr:commit', ({ message }) => console.log(`💾 Committing: ${message.split('\n')[0]}`));
61
+ creator.on('pr:push', ({ branch }) => console.log(`⬆️ Pushing branch: ${branch}`));
62
+ creator.on('pr:created', ({ pr }) => console.log(`✅ PR created: ${pr.url}`));
63
+ const initResult = await creator.initialize();
64
+ if (!initResult.success) {
65
+ console.error(`❌ Initialization failed: ${initResult.error}`);
66
+ process.exit(1);
67
+ }
68
+ const result = await creator.create({
69
+ suggestion,
70
+ branchName: options.branch,
71
+ title: options.title,
72
+ baseBranch: options.base,
73
+ labels: options.labels?.split(',').map((s) => s.trim()),
74
+ reviewers: options.reviewers?.split(',').map((s) => s.trim()),
75
+ assignees: options.assignees?.split(',').map((s) => s.trim()),
76
+ draft: options.draft,
77
+ dryRun: options.dryRun,
78
+ });
79
+ if (result.success) {
80
+ if (options.dryRun) {
81
+ console.log('\n📋 Dry Run Preview:');
82
+ console.log(` Branch: ${result.branchName}`);
83
+ console.log(` Files: ${result.filesChanged.length}`);
84
+ console.log(` +${result.linesAdded} / -${result.linesDeleted} lines`);
85
+ if (result.preview) {
86
+ console.log(`\n📝 PR Title: ${result.preview.title}`);
87
+ console.log(`\n📄 Commit Message:\n${result.preview.commitMessage}`);
88
+ }
89
+ }
90
+ else {
91
+ console.log('\n🎉 PR created successfully!');
92
+ console.log(` URL: ${result.pr?.url}`);
93
+ console.log(` Branch: ${result.branchName}`);
94
+ console.log(` Commit: ${result.commitHash}`);
95
+ }
96
+ }
97
+ else {
98
+ console.error(`\n❌ PR creation failed: ${result.error}`);
99
+ process.exit(1);
100
+ }
101
+ if (result.warnings && result.warnings.length > 0) {
102
+ console.log('\n⚠️ Warnings:');
103
+ result.warnings.forEach(w => console.log(` - ${w}`));
104
+ }
105
+ }
106
+ catch (error) {
107
+ console.error('❌ Error:', error instanceof Error ? error.message : error);
108
+ process.exit(1);
109
+ }
110
+ });
111
+ /**
112
+ * cg pr preview
113
+ */
114
+ prCommand
115
+ .command('preview <suggestionFile>')
116
+ .description('Preview PR changes without creating')
117
+ .option('--repo <path>', 'Repository path (default: current directory)')
118
+ .option('--json', 'Output as JSON')
119
+ .action(async (suggestionFile, options) => {
120
+ try {
121
+ const { createPRCreator } = await import('./pr/index.js');
122
+ // Read suggestion file
123
+ const filePath = resolve(suggestionFile);
124
+ if (!existsSync(filePath)) {
125
+ console.error(`❌ Suggestion file not found: ${filePath}`);
126
+ process.exit(1);
127
+ }
128
+ const suggestion = JSON.parse(readFileSync(filePath, 'utf-8'));
129
+ const repoPath = options.repo ?? process.cwd();
130
+ const creator = createPRCreator(repoPath);
131
+ const initResult = await creator.initialize();
132
+ if (!initResult.success) {
133
+ console.error(`❌ Initialization failed: ${initResult.error}`);
134
+ process.exit(1);
135
+ }
136
+ const preview = await creator.preview({ suggestion });
137
+ if (options.json) {
138
+ console.log(JSON.stringify(preview, null, 2));
139
+ }
140
+ else {
141
+ console.log('📋 PR Preview\n');
142
+ console.log(`Branch: ${preview.branchName}`);
143
+ console.log(`Title: ${preview.title}`);
144
+ console.log(`\n📝 Commit Message:\n${preview.commitMessage}`);
145
+ console.log(`\n📄 Files Changed (${preview.diffs.length}):`);
146
+ for (const diff of preview.diffs) {
147
+ console.log(` ${diff.changeType === 'added' ? '➕' : '📝'} ${diff.filePath} (+${diff.additions}/-${diff.deletions})`);
148
+ }
149
+ console.log('\n📋 PR Body Preview:\n');
150
+ console.log(preview.body.slice(0, 500) + (preview.body.length > 500 ? '...' : ''));
151
+ }
152
+ }
153
+ catch (error) {
154
+ console.error('❌ Error:', error instanceof Error ? error.message : error);
155
+ process.exit(1);
156
+ }
157
+ });
158
+ /**
159
+ * cg pr validate
160
+ */
161
+ prCommand
162
+ .command('validate <suggestionFile>')
163
+ .description('Validate that a suggestion can be applied')
164
+ .option('--repo <path>', 'Repository path (default: current directory)')
165
+ .action(async (suggestionFile, options) => {
166
+ try {
167
+ const { createPRCreator } = await import('./pr/index.js');
168
+ // Read suggestion file
169
+ const filePath = resolve(suggestionFile);
170
+ if (!existsSync(filePath)) {
171
+ console.error(`❌ Suggestion file not found: ${filePath}`);
172
+ process.exit(1);
173
+ }
174
+ const suggestion = JSON.parse(readFileSync(filePath, 'utf-8'));
175
+ const repoPath = options.repo ?? process.cwd();
176
+ const creator = createPRCreator(repoPath);
177
+ const initResult = await creator.initialize();
178
+ if (!initResult.success) {
179
+ console.error(`❌ Initialization failed: ${initResult.error}`);
180
+ process.exit(1);
181
+ }
182
+ const result = creator.validate(suggestion);
183
+ if (result.valid) {
184
+ console.log('✅ Suggestion is valid and can be applied');
185
+ }
186
+ else {
187
+ console.error(`❌ Suggestion validation failed: ${result.reason}`);
188
+ process.exit(1);
189
+ }
190
+ }
191
+ catch (error) {
192
+ console.error('❌ Error:', error instanceof Error ? error.message : error);
193
+ process.exit(1);
194
+ }
195
+ });
196
+ // ============================================================================
197
+ // Parse and Execute
198
+ // ============================================================================
199
+ program.parse();
200
+ //# sourceMappingURL=cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;GASG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,gCAAgC;AAChC,MAAM,eAAe,GAAG,IAAI,GAAG,CAAC,iBAAiB,EAAE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,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;QAE5C,IAAI,MAAM,CAAC,KAAK,EAAE,CAAC;YACjB,OAAO,CAAC,GAAG,CAAC,0CAA0C,CAAC,CAAC;QAC1D,CAAC;aAAM,CAAC;YACN,OAAO,CAAC,KAAK,CAAC,mCAAmC,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC;YAClE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC;IACH,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,UAAU,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;QAC1E,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC,CAAC,CAAC;AAEL,+EAA+E;AAC/E,oBAAoB;AACpB,+EAA+E;AAE/E,OAAO,CAAC,KAAK,EAAE,CAAC"}
package/dist/index.d.ts CHANGED
@@ -15,4 +15,5 @@ export { CodeGraph, createCodeGraph } from './codegraph.js';
15
15
  export { TypedEventEmitter, CodeGraphEventEmitter, } from './events/index.js';
16
16
  export type { Language, EntityType, Entity, EntityInput, RelationType, Relation, RelationInput, CodeGraphOptions, ParserOptions, GraphOptions, IndexerOptions, GraphRAGOptions, StorageAdapter, StorageStats, CodeGraphEvents, IndexProgress, QueryResult, IndexResult, CallPath, ModuleAnalysis, CodeSnippet, FileStructure, SearchResult, Community, GraphStatistics, ParseResult, GraphQuery, DependencyOptions, LocalSearchOptions, GlobalSearchOptions, } from './types.js';
17
17
  export { LANGUAGE_EXTENSIONS, DEFAULT_CODEGRAPH_OPTIONS, generateEntityId, generateRelationId, isSupportedLanguage, getLanguageFromExtension, } from './types.js';
18
+ export { createPRCreator, PRCreator, GitOperations, GitHubAdapter, RefactoringApplier, PRTemplateGenerator, type RefactoringSuggestion, type CodeChange, type PRCreateOptions, type PRCreateResult, type PRPreview, type GitHubConfig, type PRInfo, type FileDiff, type PRCreatorEvents, generateBranchName, generateCommitMessage, } from './pr/index.js';
18
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAG5D,OAAO,EACL,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,mBAAmB,CAAC;AAG3B,YAAY,EAEV,QAAQ,EAGR,UAAU,EACV,MAAM,EACN,WAAW,EAGX,YAAY,EACZ,QAAQ,EACR,aAAa,EAGb,gBAAgB,EAChB,aAAa,EACb,YAAY,EACZ,cAAc,EACd,eAAe,EAGf,cAAc,EACd,YAAY,EAGZ,eAAe,EACf,aAAa,EAGb,WAAW,EACX,WAAW,EACX,QAAQ,EACR,cAAc,EACd,WAAW,EACX,aAAa,EACb,YAAY,EACZ,SAAS,EACT,eAAe,EACf,WAAW,EAGX,UAAU,EACV,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,YAAY,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAG5D,OAAO,EACL,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,mBAAmB,CAAC;AAG3B,YAAY,EAEV,QAAQ,EAGR,UAAU,EACV,MAAM,EACN,WAAW,EAGX,YAAY,EACZ,QAAQ,EACR,aAAa,EAGb,gBAAgB,EAChB,aAAa,EACb,YAAY,EACZ,cAAc,EACd,eAAe,EAGf,cAAc,EACd,YAAY,EAGZ,eAAe,EACf,aAAa,EAGb,WAAW,EACX,WAAW,EACX,QAAQ,EACR,cAAc,EACd,WAAW,EACX,aAAa,EACb,YAAY,EACZ,SAAS,EACT,eAAe,EACf,WAAW,EAGX,UAAU,EACV,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,YAAY,CAAC;AAGpB,OAAO,EAEL,eAAe,EAGf,SAAS,EACT,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,mBAAmB,EAGnB,KAAK,qBAAqB,EAC1B,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,SAAS,EACd,KAAK,YAAY,EACjB,KAAK,MAAM,EACX,KAAK,QAAQ,EACb,KAAK,eAAe,EAGpB,kBAAkB,EAClB,qBAAqB,GACtB,MAAM,eAAe,CAAC"}
package/dist/index.js CHANGED
@@ -17,4 +17,12 @@ export { CodeGraph, createCodeGraph } from './codegraph.js';
17
17
  export { TypedEventEmitter, CodeGraphEventEmitter, } from './events/index.js';
18
18
  // Constants
19
19
  export { LANGUAGE_EXTENSIONS, DEFAULT_CODEGRAPH_OPTIONS, generateEntityId, generateRelationId, isSupportedLanguage, getLanguageFromExtension, } from './types.js';
20
+ // PR Creation Module (v2.3.3 NEW!)
21
+ export {
22
+ // Main factory
23
+ createPRCreator,
24
+ // Classes
25
+ PRCreator, GitOperations, GitHubAdapter, RefactoringApplier, PRTemplateGenerator,
26
+ // Utilities
27
+ generateBranchName, generateCommitMessage, } from './pr/index.js';
20
28
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,cAAc;AACd,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAE5D,eAAe;AACf,OAAO,EACL,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,mBAAmB,CAAC;AAmD3B,YAAY;AACZ,OAAO,EACL,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,YAAY,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,cAAc;AACd,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAE5D,eAAe;AACf,OAAO,EACL,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,mBAAmB,CAAC;AAmD3B,YAAY;AACZ,OAAO,EACL,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,YAAY,CAAC;AAEpB,mCAAmC;AACnC,OAAO;AACL,eAAe;AACf,eAAe;AAEf,UAAU;AACV,SAAS,EACT,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,mBAAmB;AAanB,YAAY;AACZ,kBAAkB,EAClB,qBAAqB,GACtB,MAAM,eAAe,CAAC"}
@@ -2,35 +2,54 @@
2
2
  * @nahisaho/musubix-codegraph - AST Parser
3
3
  *
4
4
  * Tree-sitter based AST parser for code entity extraction
5
+ * Enhanced with ExtractorRegistry for 16-language support (v2.3.2)
5
6
  *
6
7
  * @see REQ-CG-AST-001 - Multi-language support
7
8
  * @see REQ-CG-AST-002 - Entity extraction
8
9
  * @see REQ-CG-AST-003 - Relation extraction
10
+ * @see REQ-CG-MULTILANG-001 to REQ-CG-MULTILANG-013 (v2.3.2)
9
11
  * @see DES-CG-002
10
- * @see TSK-CG-010
12
+ * @see TSK-CG-003, TSK-CG-010
11
13
  */
12
14
  import type { Language, ParseResult, ParserOptions } from '../types.js';
13
15
  /**
14
16
  * AST Parser using Tree-sitter
17
+ * Enhanced with ExtractorRegistry for multi-language support (v2.3.2)
15
18
  */
16
19
  export declare class ASTParser {
17
20
  private options;
18
21
  private parser;
19
22
  private languages;
20
23
  private initialized;
24
+ private useExtractors;
21
25
  constructor(options?: Partial<ParserOptions>);
22
26
  /**
23
27
  * Initialize tree-sitter and load language grammars
28
+ * Now supports 16 languages via ExtractorRegistry
24
29
  */
25
30
  private ensureInitialized;
31
+ /**
32
+ * Load grammar for a specific language
33
+ */
34
+ private loadGrammar;
35
+ /**
36
+ * Load all available grammars
37
+ */
38
+ private loadAvailableGrammars;
26
39
  /**
27
40
  * Parse a source file
28
41
  */
29
42
  parseFile(filePath: string): Promise<ParseResult>;
30
43
  /**
31
44
  * Parse source code content
45
+ * Enhanced to use ExtractorRegistry for 16-language support
32
46
  */
33
47
  parseContent(content: string, language: Language, filePath?: string): Promise<ParseResult>;
48
+ /**
49
+ * Parse using ExtractorRegistry (v2.3.2)
50
+ * Supports 16 languages with unified interface
51
+ */
52
+ private parseWithExtractor;
34
53
  /**
35
54
  * Parse using tree-sitter
36
55
  */
@@ -73,7 +92,16 @@ export declare class ASTParser {
73
92
  private parseWithRegex;
74
93
  /**
75
94
  * Get supported languages
95
+ * Now returns all 16 supported languages (v2.3.2)
76
96
  */
77
97
  getSupportedLanguages(): Language[];
98
+ /**
99
+ * Check if a language is supported
100
+ */
101
+ isLanguageSupported(language: Language): boolean;
102
+ /**
103
+ * Preload all extractors for faster parsing
104
+ */
105
+ preloadExtractors(): Promise<void>;
78
106
  }
79
107
  //# sourceMappingURL=ast-parser.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ast-parser.d.ts","sourceRoot":"","sources":["../../src/parser/ast-parser.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EACV,QAAQ,EAGR,WAAW,EACX,aAA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