@egentica/codemap 0.1.5
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.md +165 -0
- package/README.md +479 -0
- package/dist/adapters/EgenticaMcpAdapter.d.ts +128 -0
- package/dist/adapters/EgenticaMcpAdapter.d.ts.map +1 -0
- package/dist/adapters/EgenticaMcpAdapter.js +218 -0
- package/dist/adapters/EgenticaMcpAdapter.js.map +1 -0
- package/dist/assist/AssistEngine.d.ts +107 -0
- package/dist/assist/AssistEngine.d.ts.map +1 -0
- package/dist/assist/AssistEngine.js +188 -0
- package/dist/assist/AssistEngine.js.map +1 -0
- package/dist/assist/AssistScorer.d.ts +91 -0
- package/dist/assist/AssistScorer.d.ts.map +1 -0
- package/dist/assist/AssistScorer.js +254 -0
- package/dist/assist/AssistScorer.js.map +1 -0
- package/dist/assist/PatternAggregator.d.ts +116 -0
- package/dist/assist/PatternAggregator.d.ts.map +1 -0
- package/dist/assist/PatternAggregator.js +311 -0
- package/dist/assist/PatternAggregator.js.map +1 -0
- package/dist/assist/RelevanceScorer.d.ts +104 -0
- package/dist/assist/RelevanceScorer.d.ts.map +1 -0
- package/dist/assist/RelevanceScorer.js +240 -0
- package/dist/assist/RelevanceScorer.js.map +1 -0
- package/dist/assist/index.d.ts +6 -0
- package/dist/assist/index.d.ts.map +1 -0
- package/dist/assist/index.js +9 -0
- package/dist/assist/index.js.map +1 -0
- package/dist/core/AnnotationStore.d.ts +101 -0
- package/dist/core/AnnotationStore.d.ts.map +1 -0
- package/dist/core/AnnotationStore.js +236 -0
- package/dist/core/AnnotationStore.js.map +1 -0
- package/dist/core/BackupManager.d.ts +92 -0
- package/dist/core/BackupManager.d.ts.map +1 -0
- package/dist/core/BackupManager.js +311 -0
- package/dist/core/BackupManager.js.map +1 -0
- package/dist/core/ChecklistStore.d.ts +66 -0
- package/dist/core/ChecklistStore.d.ts.map +1 -0
- package/dist/core/ChecklistStore.js +199 -0
- package/dist/core/ChecklistStore.js.map +1 -0
- package/dist/core/CodeMap.d.ts +614 -0
- package/dist/core/CodeMap.d.ts.map +1 -0
- package/dist/core/CodeMap.js +880 -0
- package/dist/core/CodeMap.js.map +1 -0
- package/dist/core/DisplayFilter.d.ts +83 -0
- package/dist/core/DisplayFilter.d.ts.map +1 -0
- package/dist/core/DisplayFilter.js +228 -0
- package/dist/core/DisplayFilter.js.map +1 -0
- package/dist/core/EventBus.d.ts +114 -0
- package/dist/core/EventBus.d.ts.map +1 -0
- package/dist/core/EventBus.js +192 -0
- package/dist/core/EventBus.js.map +1 -0
- package/dist/core/ExperienceStore.d.ts +170 -0
- package/dist/core/ExperienceStore.d.ts.map +1 -0
- package/dist/core/ExperienceStore.js +292 -0
- package/dist/core/ExperienceStore.js.map +1 -0
- package/dist/core/ExperienceTracker.d.ts +110 -0
- package/dist/core/ExperienceTracker.d.ts.map +1 -0
- package/dist/core/ExperienceTracker.js +291 -0
- package/dist/core/ExperienceTracker.js.map +1 -0
- package/dist/core/FileSystemGraph.d.ts +157 -0
- package/dist/core/FileSystemGraph.d.ts.map +1 -0
- package/dist/core/FileSystemGraph.js +316 -0
- package/dist/core/FileSystemGraph.js.map +1 -0
- package/dist/core/FileSystemIO.d.ts +222 -0
- package/dist/core/FileSystemIO.d.ts.map +1 -0
- package/dist/core/FileSystemIO.js +403 -0
- package/dist/core/FileSystemIO.js.map +1 -0
- package/dist/core/FuzzyMatcher.d.ts +51 -0
- package/dist/core/FuzzyMatcher.d.ts.map +1 -0
- package/dist/core/FuzzyMatcher.js +280 -0
- package/dist/core/FuzzyMatcher.js.map +1 -0
- package/dist/core/GroupStore.d.ts +114 -0
- package/dist/core/GroupStore.d.ts.map +1 -0
- package/dist/core/GroupStore.js +246 -0
- package/dist/core/GroupStore.js.map +1 -0
- package/dist/core/HelpRegistry.d.ts +116 -0
- package/dist/core/HelpRegistry.d.ts.map +1 -0
- package/dist/core/HelpRegistry.js +160 -0
- package/dist/core/HelpRegistry.js.map +1 -0
- package/dist/core/HintRegistry.d.ts +49 -0
- package/dist/core/HintRegistry.d.ts.map +1 -0
- package/dist/core/HintRegistry.js +81 -0
- package/dist/core/HintRegistry.js.map +1 -0
- package/dist/core/LabelStore.d.ts +88 -0
- package/dist/core/LabelStore.d.ts.map +1 -0
- package/dist/core/LabelStore.js +520 -0
- package/dist/core/LabelStore.js.map +1 -0
- package/dist/core/LineRangeWriter.d.ts +63 -0
- package/dist/core/LineRangeWriter.d.ts.map +1 -0
- package/dist/core/LineRangeWriter.js +179 -0
- package/dist/core/LineRangeWriter.js.map +1 -0
- package/dist/core/ParserRegistry.d.ts +70 -0
- package/dist/core/ParserRegistry.d.ts.map +1 -0
- package/dist/core/ParserRegistry.js +109 -0
- package/dist/core/ParserRegistry.js.map +1 -0
- package/dist/core/PluginRegistry.d.ts +120 -0
- package/dist/core/PluginRegistry.d.ts.map +1 -0
- package/dist/core/PluginRegistry.js +230 -0
- package/dist/core/PluginRegistry.js.map +1 -0
- package/dist/core/QueryEngine.d.ts +134 -0
- package/dist/core/QueryEngine.d.ts.map +1 -0
- package/dist/core/QueryEngine.js +211 -0
- package/dist/core/QueryEngine.js.map +1 -0
- package/dist/core/Scanner.d.ts +84 -0
- package/dist/core/Scanner.d.ts.map +1 -0
- package/dist/core/Scanner.js +184 -0
- package/dist/core/Scanner.js.map +1 -0
- package/dist/core/SessionTransactionLog.d.ts +138 -0
- package/dist/core/SessionTransactionLog.d.ts.map +1 -0
- package/dist/core/SessionTransactionLog.js +397 -0
- package/dist/core/SessionTransactionLog.js.map +1 -0
- package/dist/core/TargetParser.d.ts +85 -0
- package/dist/core/TargetParser.d.ts.map +1 -0
- package/dist/core/TargetParser.js +167 -0
- package/dist/core/TargetParser.js.map +1 -0
- package/dist/core/TargetResolver.d.ts +115 -0
- package/dist/core/TargetResolver.d.ts.map +1 -0
- package/dist/core/TargetResolver.js +237 -0
- package/dist/core/TargetResolver.js.map +1 -0
- package/dist/core/WriteSafetyGuard.d.ts +101 -0
- package/dist/core/WriteSafetyGuard.d.ts.map +1 -0
- package/dist/core/WriteSafetyGuard.js +265 -0
- package/dist/core/WriteSafetyGuard.js.map +1 -0
- package/dist/core/index.d.ts +38 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +51 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/query/DependencyTraversal.d.ts +23 -0
- package/dist/core/query/DependencyTraversal.d.ts.map +1 -0
- package/dist/core/query/DependencyTraversal.js +55 -0
- package/dist/core/query/DependencyTraversal.js.map +1 -0
- package/dist/core/query/ResultProcessor.d.ts +20 -0
- package/dist/core/query/ResultProcessor.d.ts.map +1 -0
- package/dist/core/query/ResultProcessor.js +99 -0
- package/dist/core/query/ResultProcessor.js.map +1 -0
- package/dist/core/query/SymbolSearchEngine.d.ts +20 -0
- package/dist/core/query/SymbolSearchEngine.d.ts.map +1 -0
- package/dist/core/query/SymbolSearchEngine.js +109 -0
- package/dist/core/query/SymbolSearchEngine.js.map +1 -0
- package/dist/core/query/TextSearchEngine.d.ts +23 -0
- package/dist/core/query/TextSearchEngine.d.ts.map +1 -0
- package/dist/core/query/TextSearchEngine.js +69 -0
- package/dist/core/query/TextSearchEngine.js.map +1 -0
- package/dist/core/query/index.d.ts +11 -0
- package/dist/core/query/index.d.ts.map +1 -0
- package/dist/core/query/index.js +18 -0
- package/dist/core/query/index.js.map +1 -0
- package/dist/core/scan/DependencyResolver.d.ts +26 -0
- package/dist/core/scan/DependencyResolver.d.ts.map +1 -0
- package/dist/core/scan/DependencyResolver.js +81 -0
- package/dist/core/scan/DependencyResolver.js.map +1 -0
- package/dist/core/scan/DirectoryWalker.d.ts +39 -0
- package/dist/core/scan/DirectoryWalker.d.ts.map +1 -0
- package/dist/core/scan/DirectoryWalker.js +136 -0
- package/dist/core/scan/DirectoryWalker.js.map +1 -0
- package/dist/core/scan/IgnorePatternMatcher.d.ts +32 -0
- package/dist/core/scan/IgnorePatternMatcher.d.ts.map +1 -0
- package/dist/core/scan/IgnorePatternMatcher.js +120 -0
- package/dist/core/scan/IgnorePatternMatcher.js.map +1 -0
- package/dist/core/scan/index.d.ts +10 -0
- package/dist/core/scan/index.d.ts.map +1 -0
- package/dist/core/scan/index.js +16 -0
- package/dist/core/scan/index.js.map +1 -0
- package/dist/core/utils/packageDiscovery.d.ts +24 -0
- package/dist/core/utils/packageDiscovery.d.ts.map +1 -0
- package/dist/core/utils/packageDiscovery.js +37 -0
- package/dist/core/utils/packageDiscovery.js.map +1 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +37 -0
- package/dist/index.js.map +1 -0
- package/dist/mcp/operations/annotations.d.ts +9 -0
- package/dist/mcp/operations/annotations.d.ts.map +1 -0
- package/dist/mcp/operations/annotations.js +66 -0
- package/dist/mcp/operations/annotations.js.map +1 -0
- package/dist/mcp/operations/files.d.ts +13 -0
- package/dist/mcp/operations/files.d.ts.map +1 -0
- package/dist/mcp/operations/files.js +173 -0
- package/dist/mcp/operations/files.js.map +1 -0
- package/dist/mcp/operations/graph.d.ts +10 -0
- package/dist/mcp/operations/graph.d.ts.map +1 -0
- package/dist/mcp/operations/graph.js +69 -0
- package/dist/mcp/operations/graph.js.map +1 -0
- package/dist/mcp/operations/groups.d.ts +55 -0
- package/dist/mcp/operations/groups.d.ts.map +1 -0
- package/dist/mcp/operations/groups.js +233 -0
- package/dist/mcp/operations/groups.js.map +1 -0
- package/dist/mcp/operations/help.d.ts +36 -0
- package/dist/mcp/operations/help.d.ts.map +1 -0
- package/dist/mcp/operations/help.js +322 -0
- package/dist/mcp/operations/help.js.map +1 -0
- package/dist/mcp/operations/session.d.ts +13 -0
- package/dist/mcp/operations/session.d.ts.map +1 -0
- package/dist/mcp/operations/session.js +169 -0
- package/dist/mcp/operations/session.js.map +1 -0
- package/dist/mcp/operations/writes.d.ts +14 -0
- package/dist/mcp/operations/writes.d.ts.map +1 -0
- package/dist/mcp/operations/writes.js +287 -0
- package/dist/mcp/operations/writes.js.map +1 -0
- package/dist/mcp/registry/ToolRegistry.d.ts +54 -0
- package/dist/mcp/registry/ToolRegistry.d.ts.map +1 -0
- package/dist/mcp/registry/ToolRegistry.js +219 -0
- package/dist/mcp/registry/ToolRegistry.js.map +1 -0
- package/dist/mcp/registry/context-guard.d.ts +13 -0
- package/dist/mcp/registry/context-guard.d.ts.map +1 -0
- package/dist/mcp/registry/context-guard.js +19 -0
- package/dist/mcp/registry/context-guard.js.map +1 -0
- package/dist/mcp/registry/schemas.d.ts +221 -0
- package/dist/mcp/registry/schemas.d.ts.map +1 -0
- package/dist/mcp/registry/schemas.js +217 -0
- package/dist/mcp/registry/schemas.js.map +1 -0
- package/dist/mcp/registry/types.d.ts +50 -0
- package/dist/mcp/registry/types.d.ts.map +1 -0
- package/dist/mcp/registry/types.js +5 -0
- package/dist/mcp/registry/types.js.map +1 -0
- package/dist/mcp/server.d.ts +35 -0
- package/dist/mcp/server.d.ts.map +1 -0
- package/dist/mcp/server.js +264 -0
- package/dist/mcp/server.js.map +1 -0
- package/dist/mcp/tools/annotations/add.tool.d.ts +10 -0
- package/dist/mcp/tools/annotations/add.tool.d.ts.map +1 -0
- package/dist/mcp/tools/annotations/add.tool.js +88 -0
- package/dist/mcp/tools/annotations/add.tool.js.map +1 -0
- package/dist/mcp/tools/annotations/edit.tool.d.ts +10 -0
- package/dist/mcp/tools/annotations/edit.tool.d.ts.map +1 -0
- package/dist/mcp/tools/annotations/edit.tool.js +92 -0
- package/dist/mcp/tools/annotations/edit.tool.js.map +1 -0
- package/dist/mcp/tools/annotations/remove.tool.d.ts +9 -0
- package/dist/mcp/tools/annotations/remove.tool.d.ts.map +1 -0
- package/dist/mcp/tools/annotations/remove.tool.js +87 -0
- package/dist/mcp/tools/annotations/remove.tool.js.map +1 -0
- package/dist/mcp/tools/annotations/search-annotations.tool.d.ts +11 -0
- package/dist/mcp/tools/annotations/search-annotations.tool.d.ts.map +1 -0
- package/dist/mcp/tools/annotations/search-annotations.tool.js +91 -0
- package/dist/mcp/tools/annotations/search-annotations.tool.js.map +1 -0
- package/dist/mcp/tools/backup/list.tool.d.ts +16 -0
- package/dist/mcp/tools/backup/list.tool.d.ts.map +1 -0
- package/dist/mcp/tools/backup/list.tool.js +48 -0
- package/dist/mcp/tools/backup/list.tool.js.map +1 -0
- package/dist/mcp/tools/backup/restore.tool.d.ts +15 -0
- package/dist/mcp/tools/backup/restore.tool.d.ts.map +1 -0
- package/dist/mcp/tools/backup/restore.tool.js +138 -0
- package/dist/mcp/tools/backup/restore.tool.js.map +1 -0
- package/dist/mcp/tools/checklist/add.tool.d.ts +17 -0
- package/dist/mcp/tools/checklist/add.tool.d.ts.map +1 -0
- package/dist/mcp/tools/checklist/add.tool.js +53 -0
- package/dist/mcp/tools/checklist/add.tool.js.map +1 -0
- package/dist/mcp/tools/checklist/list.tool.d.ts +11 -0
- package/dist/mcp/tools/checklist/list.tool.d.ts.map +1 -0
- package/dist/mcp/tools/checklist/list.tool.js +53 -0
- package/dist/mcp/tools/checklist/list.tool.js.map +1 -0
- package/dist/mcp/tools/checklist/remove.tool.d.ts +9 -0
- package/dist/mcp/tools/checklist/remove.tool.d.ts.map +1 -0
- package/dist/mcp/tools/checklist/remove.tool.js +63 -0
- package/dist/mcp/tools/checklist/remove.tool.js.map +1 -0
- package/dist/mcp/tools/graph/get-dependencies.tool.d.ts +8 -0
- package/dist/mcp/tools/graph/get-dependencies.tool.d.ts.map +1 -0
- package/dist/mcp/tools/graph/get-dependencies.tool.js +58 -0
- package/dist/mcp/tools/graph/get-dependencies.tool.js.map +1 -0
- package/dist/mcp/tools/graph/get-related.tool.d.ts +9 -0
- package/dist/mcp/tools/graph/get-related.tool.d.ts.map +1 -0
- package/dist/mcp/tools/graph/get-related.tool.js +63 -0
- package/dist/mcp/tools/graph/get-related.tool.js.map +1 -0
- package/dist/mcp/tools/graph/impact-analysis.tool.d.ts +9 -0
- package/dist/mcp/tools/graph/impact-analysis.tool.d.ts.map +1 -0
- package/dist/mcp/tools/graph/impact-analysis.tool.js +61 -0
- package/dist/mcp/tools/graph/impact-analysis.tool.js.map +1 -0
- package/dist/mcp/tools/graph/traverse.tool.d.ts +13 -0
- package/dist/mcp/tools/graph/traverse.tool.d.ts.map +1 -0
- package/dist/mcp/tools/graph/traverse.tool.js +59 -0
- package/dist/mcp/tools/graph/traverse.tool.js.map +1 -0
- package/dist/mcp/tools/groups/add.tool.d.ts +10 -0
- package/dist/mcp/tools/groups/add.tool.d.ts.map +1 -0
- package/dist/mcp/tools/groups/add.tool.js +85 -0
- package/dist/mcp/tools/groups/add.tool.js.map +1 -0
- package/dist/mcp/tools/groups/notate.tool.d.ts +11 -0
- package/dist/mcp/tools/groups/notate.tool.d.ts.map +1 -0
- package/dist/mcp/tools/groups/notate.tool.js +86 -0
- package/dist/mcp/tools/groups/notate.tool.js.map +1 -0
- package/dist/mcp/tools/groups/search.tool.d.ts +8 -0
- package/dist/mcp/tools/groups/search.tool.d.ts.map +1 -0
- package/dist/mcp/tools/groups/search.tool.js +81 -0
- package/dist/mcp/tools/groups/search.tool.js.map +1 -0
- package/dist/mcp/tools/io/append.tool.d.ts +10 -0
- package/dist/mcp/tools/io/append.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/append.tool.js +103 -0
- package/dist/mcp/tools/io/append.tool.js.map +1 -0
- package/dist/mcp/tools/io/create.tool.d.ts +11 -0
- package/dist/mcp/tools/io/create.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/create.tool.js +119 -0
- package/dist/mcp/tools/io/create.tool.js.map +1 -0
- package/dist/mcp/tools/io/delete.tool.d.ts +9 -0
- package/dist/mcp/tools/io/delete.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/delete.tool.js +129 -0
- package/dist/mcp/tools/io/delete.tool.js.map +1 -0
- package/dist/mcp/tools/io/get-annotations.tool.d.ts +10 -0
- package/dist/mcp/tools/io/get-annotations.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/get-annotations.tool.js +97 -0
- package/dist/mcp/tools/io/get-annotations.tool.js.map +1 -0
- package/dist/mcp/tools/io/get-symbols.tool.d.ts +9 -0
- package/dist/mcp/tools/io/get-symbols.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/get-symbols.tool.js +63 -0
- package/dist/mcp/tools/io/get-symbols.tool.js.map +1 -0
- package/dist/mcp/tools/io/list.tool.d.ts +8 -0
- package/dist/mcp/tools/io/list.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/list.tool.js +68 -0
- package/dist/mcp/tools/io/list.tool.js.map +1 -0
- package/dist/mcp/tools/io/peek.tool.d.ts +11 -0
- package/dist/mcp/tools/io/peek.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/peek.tool.js +74 -0
- package/dist/mcp/tools/io/peek.tool.js.map +1 -0
- package/dist/mcp/tools/io/read-multiple.tool.d.ts +9 -0
- package/dist/mcp/tools/io/read-multiple.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/read-multiple.tool.js +72 -0
- package/dist/mcp/tools/io/read-multiple.tool.js.map +1 -0
- package/dist/mcp/tools/io/read.tool.d.ts +13 -0
- package/dist/mcp/tools/io/read.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/read.tool.js +132 -0
- package/dist/mcp/tools/io/read.tool.js.map +1 -0
- package/dist/mcp/tools/io/rename.tool.d.ts +9 -0
- package/dist/mcp/tools/io/rename.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/rename.tool.js +101 -0
- package/dist/mcp/tools/io/rename.tool.js.map +1 -0
- package/dist/mcp/tools/io/replace-many.tool.d.ts +10 -0
- package/dist/mcp/tools/io/replace-many.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/replace-many.tool.js +114 -0
- package/dist/mcp/tools/io/replace-many.tool.js.map +1 -0
- package/dist/mcp/tools/io/replace-text.tool.d.ts +12 -0
- package/dist/mcp/tools/io/replace-text.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/replace-text.tool.js +213 -0
- package/dist/mcp/tools/io/replace-text.tool.js.map +1 -0
- package/dist/mcp/tools/io/write.tool.d.ts +10 -0
- package/dist/mcp/tools/io/write.tool.d.ts.map +1 -0
- package/dist/mcp/tools/io/write.tool.js +103 -0
- package/dist/mcp/tools/io/write.tool.js.map +1 -0
- package/dist/mcp/tools/labels/assign.tool.d.ts +16 -0
- package/dist/mcp/tools/labels/assign.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/assign.tool.js +52 -0
- package/dist/mcp/tools/labels/assign.tool.js.map +1 -0
- package/dist/mcp/tools/labels/create.tool.d.ts +12 -0
- package/dist/mcp/tools/labels/create.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/create.tool.js +51 -0
- package/dist/mcp/tools/labels/create.tool.js.map +1 -0
- package/dist/mcp/tools/labels/delete.tool.d.ts +9 -0
- package/dist/mcp/tools/labels/delete.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/delete.tool.js +48 -0
- package/dist/mcp/tools/labels/delete.tool.js.map +1 -0
- package/dist/mcp/tools/labels/edit.tool.d.ts +13 -0
- package/dist/mcp/tools/labels/edit.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/edit.tool.js +58 -0
- package/dist/mcp/tools/labels/edit.tool.js.map +1 -0
- package/dist/mcp/tools/labels/list.tool.d.ts +11 -0
- package/dist/mcp/tools/labels/list.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/list.tool.js +47 -0
- package/dist/mcp/tools/labels/list.tool.js.map +1 -0
- package/dist/mcp/tools/labels/migrate.tool.d.ts +10 -0
- package/dist/mcp/tools/labels/migrate.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/migrate.tool.js +50 -0
- package/dist/mcp/tools/labels/migrate.tool.js.map +1 -0
- package/dist/mcp/tools/labels/search.tool.d.ts +16 -0
- package/dist/mcp/tools/labels/search.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/search.tool.js +55 -0
- package/dist/mcp/tools/labels/search.tool.js.map +1 -0
- package/dist/mcp/tools/labels/unassign.tool.d.ts +9 -0
- package/dist/mcp/tools/labels/unassign.tool.d.ts.map +1 -0
- package/dist/mcp/tools/labels/unassign.tool.js +49 -0
- package/dist/mcp/tools/labels/unassign.tool.js.map +1 -0
- package/dist/mcp/tools/search/find-by-name.tool.d.ts +8 -0
- package/dist/mcp/tools/search/find-by-name.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/find-by-name.tool.js +57 -0
- package/dist/mcp/tools/search/find-by-name.tool.js.map +1 -0
- package/dist/mcp/tools/search/find-relevant.tool.d.ts +9 -0
- package/dist/mcp/tools/search/find-relevant.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/find-relevant.tool.js +71 -0
- package/dist/mcp/tools/search/find-relevant.tool.js.map +1 -0
- package/dist/mcp/tools/search/scan.tool.d.ts +8 -0
- package/dist/mcp/tools/search/scan.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/scan.tool.js +103 -0
- package/dist/mcp/tools/search/scan.tool.js.map +1 -0
- package/dist/mcp/tools/search/search-elements.tool.d.ts +11 -0
- package/dist/mcp/tools/search/search-elements.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/search-elements.tool.js +71 -0
- package/dist/mcp/tools/search/search-elements.tool.js.map +1 -0
- package/dist/mcp/tools/search/search-in-files.tool.d.ts +14 -0
- package/dist/mcp/tools/search/search-in-files.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/search-in-files.tool.js +204 -0
- package/dist/mcp/tools/search/search-in-files.tool.js.map +1 -0
- package/dist/mcp/tools/search/search.tool.d.ts +25 -0
- package/dist/mcp/tools/search/search.tool.d.ts.map +1 -0
- package/dist/mcp/tools/search/search.tool.js +109 -0
- package/dist/mcp/tools/search/search.tool.js.map +1 -0
- package/dist/mcp/tools/session/audit.tool.d.ts +6 -0
- package/dist/mcp/tools/session/audit.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/audit.tool.js +64 -0
- package/dist/mcp/tools/session/audit.tool.js.map +1 -0
- package/dist/mcp/tools/session/close.tool.d.ts +11 -0
- package/dist/mcp/tools/session/close.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/close.tool.js +79 -0
- package/dist/mcp/tools/session/close.tool.js.map +1 -0
- package/dist/mcp/tools/session/execute-shell.tool.d.ts +11 -0
- package/dist/mcp/tools/session/execute-shell.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/execute-shell.tool.js +87 -0
- package/dist/mcp/tools/session/execute-shell.tool.js.map +1 -0
- package/dist/mcp/tools/session/help.tool.d.ts +8 -0
- package/dist/mcp/tools/session/help.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/help.tool.js +84 -0
- package/dist/mcp/tools/session/help.tool.js.map +1 -0
- package/dist/mcp/tools/session/list.tool.d.ts +9 -0
- package/dist/mcp/tools/session/list.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/list.tool.js +49 -0
- package/dist/mcp/tools/session/list.tool.js.map +1 -0
- package/dist/mcp/tools/session/next-session.tool.d.ts +8 -0
- package/dist/mcp/tools/session/next-session.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/next-session.tool.js +87 -0
- package/dist/mcp/tools/session/next-session.tool.js.map +1 -0
- package/dist/mcp/tools/session/orient.tool.d.ts +11 -0
- package/dist/mcp/tools/session/orient.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/orient.tool.js +239 -0
- package/dist/mcp/tools/session/orient.tool.js.map +1 -0
- package/dist/mcp/tools/session/read.tool.d.ts +8 -0
- package/dist/mcp/tools/session/read.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/read.tool.js +63 -0
- package/dist/mcp/tools/session/read.tool.js.map +1 -0
- package/dist/mcp/tools/session/reindex.tool.d.ts +6 -0
- package/dist/mcp/tools/session/reindex.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/reindex.tool.js +59 -0
- package/dist/mcp/tools/session/reindex.tool.js.map +1 -0
- package/dist/mcp/tools/session/start.tool.d.ts +8 -0
- package/dist/mcp/tools/session/start.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/start.tool.js +170 -0
- package/dist/mcp/tools/session/start.tool.js.map +1 -0
- package/dist/mcp/tools/session/stats.tool.d.ts +6 -0
- package/dist/mcp/tools/session/stats.tool.d.ts.map +1 -0
- package/dist/mcp/tools/session/stats.tool.js +46 -0
- package/dist/mcp/tools/session/stats.tool.js.map +1 -0
- package/dist/plugins/parser-typescript/index.d.ts +80 -0
- package/dist/plugins/parser-typescript/index.d.ts.map +1 -0
- package/dist/plugins/parser-typescript/index.js +467 -0
- package/dist/plugins/parser-typescript/index.js.map +1 -0
- package/dist/plugins/parser-vue/index.d.ts +20 -0
- package/dist/plugins/parser-vue/index.d.ts.map +1 -0
- package/dist/plugins/parser-vue/index.js +88 -0
- package/dist/plugins/parser-vue/index.js.map +1 -0
- package/dist/plugins/parser-vue/script-parser.d.ts +18 -0
- package/dist/plugins/parser-vue/script-parser.d.ts.map +1 -0
- package/dist/plugins/parser-vue/script-parser.js +100 -0
- package/dist/plugins/parser-vue/script-parser.js.map +1 -0
- package/dist/plugins/parser-vue/template-parser.d.ts +14 -0
- package/dist/plugins/parser-vue/template-parser.d.ts.map +1 -0
- package/dist/plugins/parser-vue/template-parser.js +95 -0
- package/dist/plugins/parser-vue/template-parser.js.map +1 -0
- package/dist/query/SymbolSearch.d.ts +56 -0
- package/dist/query/SymbolSearch.d.ts.map +1 -0
- package/dist/query/SymbolSearch.js +132 -0
- package/dist/query/SymbolSearch.js.map +1 -0
- package/dist/query/TextSearch.d.ts +47 -0
- package/dist/query/TextSearch.d.ts.map +1 -0
- package/dist/query/TextSearch.js +110 -0
- package/dist/query/TextSearch.js.map +1 -0
- package/dist/storage/NodeFsProvider.d.ts +148 -0
- package/dist/storage/NodeFsProvider.d.ts.map +1 -0
- package/dist/storage/NodeFsProvider.js +264 -0
- package/dist/storage/NodeFsProvider.js.map +1 -0
- package/dist/types/annotation.d.ts +79 -0
- package/dist/types/annotation.d.ts.map +1 -0
- package/dist/types/annotation.js +10 -0
- package/dist/types/annotation.js.map +1 -0
- package/dist/types/assist.d.ts +147 -0
- package/dist/types/assist.d.ts.map +1 -0
- package/dist/types/assist.js +12 -0
- package/dist/types/assist.js.map +1 -0
- package/dist/types/contracts/FileSystemProvider.d.ts +24 -0
- package/dist/types/contracts/FileSystemProvider.d.ts.map +1 -0
- package/dist/types/contracts/FileSystemProvider.js +9 -0
- package/dist/types/contracts/FileSystemProvider.js.map +1 -0
- package/dist/types/contracts/LanguageParser.d.ts +146 -0
- package/dist/types/contracts/LanguageParser.d.ts.map +1 -0
- package/dist/types/contracts/LanguageParser.js +43 -0
- package/dist/types/contracts/LanguageParser.js.map +1 -0
- package/dist/types/contracts/Plugin.d.ts +226 -0
- package/dist/types/contracts/Plugin.d.ts.map +1 -0
- package/dist/types/contracts/Plugin.js +21 -0
- package/dist/types/contracts/Plugin.js.map +1 -0
- package/dist/types/contracts/index.d.ts +10 -0
- package/dist/types/contracts/index.d.ts.map +1 -0
- package/dist/types/contracts/index.js +26 -0
- package/dist/types/contracts/index.js.map +1 -0
- package/dist/types/core.d.ts +170 -0
- package/dist/types/core.d.ts.map +1 -0
- package/dist/types/core.js +10 -0
- package/dist/types/core.js.map +1 -0
- package/dist/types/events.d.ts +29 -0
- package/dist/types/events.d.ts.map +1 -0
- package/dist/types/events.js +18 -0
- package/dist/types/events.js.map +1 -0
- package/dist/types/experience.d.ts +153 -0
- package/dist/types/experience.d.ts.map +1 -0
- package/dist/types/experience.js +9 -0
- package/dist/types/experience.js.map +1 -0
- package/dist/types/graph.d.ts +35 -0
- package/dist/types/graph.d.ts.map +1 -0
- package/dist/types/graph.js +8 -0
- package/dist/types/graph.js.map +1 -0
- package/dist/types/index.d.ts +17 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +33 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/label.d.ts +150 -0
- package/dist/types/label.d.ts.map +1 -0
- package/dist/types/label.js +9 -0
- package/dist/types/label.js.map +1 -0
- package/dist/types/query.d.ts +104 -0
- package/dist/types/query.d.ts.map +1 -0
- package/dist/types/query.js +11 -0
- package/dist/types/query.js.map +1 -0
- package/dist/types/response.d.ts +133 -0
- package/dist/types/response.d.ts.map +1 -0
- package/dist/types/response.js +60 -0
- package/dist/types/response.js.map +1 -0
- package/dist/types/target.d.ts +68 -0
- package/dist/types/target.d.ts.map +1 -0
- package/dist/types/target.js +11 -0
- package/dist/types/target.js.map +1 -0
- package/dist/utils/version.d.ts +9 -0
- package/dist/utils/version.d.ts.map +1 -0
- package/dist/utils/version.js +30 -0
- package/dist/utils/version.js.map +1 -0
- package/package.json +53 -0
package/LICENSE.md
ADDED
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
GNU LESSER GENERAL PUBLIC LICENSE
|
|
2
|
+
Version 3, 29 June 2007
|
|
3
|
+
|
|
4
|
+
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
|
|
5
|
+
Everyone is permitted to copy and distribute verbatim copies
|
|
6
|
+
of this license document, but changing it is not allowed.
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
This version of the GNU Lesser General Public License incorporates
|
|
10
|
+
the terms and conditions of version 3 of the GNU General Public
|
|
11
|
+
License, supplemented by the additional permissions listed below.
|
|
12
|
+
|
|
13
|
+
0. Additional Definitions.
|
|
14
|
+
|
|
15
|
+
As used herein, "this License" refers to version 3 of the GNU Lesser
|
|
16
|
+
General Public License, and the "GNU GPL" refers to version 3 of the GNU
|
|
17
|
+
General Public License.
|
|
18
|
+
|
|
19
|
+
"The Library" refers to a covered work governed by this License,
|
|
20
|
+
other than an Application or a Combined Work as defined below.
|
|
21
|
+
|
|
22
|
+
An "Application" is any work that makes use of an interface provided
|
|
23
|
+
by the Library, but which is not otherwise based on the Library.
|
|
24
|
+
Defining a subclass of a class defined by the Library is deemed a mode
|
|
25
|
+
of using an interface provided by the Library.
|
|
26
|
+
|
|
27
|
+
A "Combined Work" is a work produced by combining or linking an
|
|
28
|
+
Application with the Library. The particular version of the Library
|
|
29
|
+
with which the Combined Work was made is also called the "Linked
|
|
30
|
+
Version".
|
|
31
|
+
|
|
32
|
+
The "Minimal Corresponding Source" for a Combined Work means the
|
|
33
|
+
Corresponding Source for the Combined Work, excluding any source code
|
|
34
|
+
for portions of the Combined Work that, considered in isolation, are
|
|
35
|
+
based on the Application, and not on the Linked Version.
|
|
36
|
+
|
|
37
|
+
The "Corresponding Application Code" for a Combined Work means the
|
|
38
|
+
object code and/or source code for the Application, including any data
|
|
39
|
+
and utility programs needed for reproducing the Combined Work from the
|
|
40
|
+
Application, but excluding the System Libraries of the Combined Work.
|
|
41
|
+
|
|
42
|
+
1. Exception to Section 3 of the GNU GPL.
|
|
43
|
+
|
|
44
|
+
You may convey a covered work under sections 3 and 4 of this License
|
|
45
|
+
without being bound by section 3 of the GNU GPL.
|
|
46
|
+
|
|
47
|
+
2. Conveying Modified Versions.
|
|
48
|
+
|
|
49
|
+
If you modify a copy of the Library, and, in your modifications, a
|
|
50
|
+
facility refers to a function or data to be supplied by an Application
|
|
51
|
+
that uses the facility (other than as an argument passed when the
|
|
52
|
+
facility is invoked), then you may convey a copy of the modified
|
|
53
|
+
version:
|
|
54
|
+
|
|
55
|
+
a) under this License, provided that you make a good faith effort to
|
|
56
|
+
ensure that, in the event an Application does not supply the
|
|
57
|
+
function or data, the facility still operates, and performs
|
|
58
|
+
whatever part of its purpose remains meaningful, or
|
|
59
|
+
|
|
60
|
+
b) under the GNU GPL, with none of the additional permissions of
|
|
61
|
+
this License applicable to that copy.
|
|
62
|
+
|
|
63
|
+
3. Object Code Incorporating Material from Library Header Files.
|
|
64
|
+
|
|
65
|
+
The object code form of an Application may incorporate material from
|
|
66
|
+
a header file that is part of the Library. You may convey such object
|
|
67
|
+
code under terms of your choice, provided that, if the incorporated
|
|
68
|
+
material is not limited to numerical parameters, data structure
|
|
69
|
+
layouts and accessors, or small macros, inline functions and templates
|
|
70
|
+
(ten or fewer lines in length), you do both of the following:
|
|
71
|
+
|
|
72
|
+
a) Give prominent notice with each copy of the object code that the
|
|
73
|
+
Library is used in it and that the Library and its use are
|
|
74
|
+
covered by this License.
|
|
75
|
+
|
|
76
|
+
b) Accompany the object code with a copy of the GNU GPL and this license
|
|
77
|
+
document.
|
|
78
|
+
|
|
79
|
+
4. Combined Works.
|
|
80
|
+
|
|
81
|
+
You may convey a Combined Work under terms of your choice that,
|
|
82
|
+
taken together, effectively do not restrict modification of the
|
|
83
|
+
portions of the Library contained in the Combined Work and reverse
|
|
84
|
+
engineering for debugging such modifications, if you also do each of
|
|
85
|
+
the following:
|
|
86
|
+
|
|
87
|
+
a) Give prominent notice with each copy of the Combined Work that
|
|
88
|
+
the Library is used in it and that the Library and its use are
|
|
89
|
+
covered by this License.
|
|
90
|
+
|
|
91
|
+
b) Accompany the Combined Work with a copy of the GNU GPL and this license
|
|
92
|
+
document.
|
|
93
|
+
|
|
94
|
+
c) For a Combined Work that displays copyright notices during
|
|
95
|
+
execution, include the copyright notice for the Library among
|
|
96
|
+
these notices, as well as a reference directing the user to the
|
|
97
|
+
copies of the GNU GPL and this license document.
|
|
98
|
+
|
|
99
|
+
d) Do one of the following:
|
|
100
|
+
|
|
101
|
+
0) Convey the Minimal Corresponding Source under the terms of this
|
|
102
|
+
License, and the Corresponding Application Code in a form
|
|
103
|
+
suitable for, and under terms that permit, the user to
|
|
104
|
+
recombine or relink the Application with a modified version of
|
|
105
|
+
the Linked Version to produce a modified Combined Work, in the
|
|
106
|
+
manner specified by section 6 of the GNU GPL for conveying
|
|
107
|
+
Corresponding Source.
|
|
108
|
+
|
|
109
|
+
1) Use a suitable shared library mechanism for linking with the
|
|
110
|
+
Library. A suitable mechanism is one that (a) uses at run time
|
|
111
|
+
a copy of the Library already present on the user's computer
|
|
112
|
+
system, and (b) will operate properly with a modified version
|
|
113
|
+
of the Library that is interface-compatible with the Linked
|
|
114
|
+
Version.
|
|
115
|
+
|
|
116
|
+
e) Provide Installation Information, but only if you would otherwise
|
|
117
|
+
be required to provide such information under section 6 of the
|
|
118
|
+
GNU GPL, and only to the extent that such information is
|
|
119
|
+
necessary to install and execute a modified version of the
|
|
120
|
+
Combined Work produced by recombining or relinking the
|
|
121
|
+
Application with a modified version of the Linked Version. (If
|
|
122
|
+
you use option 4d0, the Installation Information must accompany
|
|
123
|
+
the Minimal Corresponding Source and Corresponding Application
|
|
124
|
+
Code. If you use option 4d1, you must provide the Installation
|
|
125
|
+
Information in the manner specified by section 6 of the GNU GPL
|
|
126
|
+
for conveying Corresponding Source.)
|
|
127
|
+
|
|
128
|
+
5. Combined Libraries.
|
|
129
|
+
|
|
130
|
+
You may place library facilities that are a work based on the
|
|
131
|
+
Library side by side in a single library together with other library
|
|
132
|
+
facilities that are not Applications and are not covered by this
|
|
133
|
+
License, and convey such a combined library under terms of your
|
|
134
|
+
choice, if you do both of the following:
|
|
135
|
+
|
|
136
|
+
a) Accompany the combined library with a copy of the same work based
|
|
137
|
+
on the Library, uncombined with any other library facilities,
|
|
138
|
+
conveyed under the terms of this License.
|
|
139
|
+
|
|
140
|
+
b) Give prominent notice with the combined library that part of it
|
|
141
|
+
is a work based on the Library, and explaining where to find the
|
|
142
|
+
accompanying uncombined form of the same work.
|
|
143
|
+
|
|
144
|
+
6. Revised Versions of the GNU Lesser General Public License.
|
|
145
|
+
|
|
146
|
+
The Free Software Foundation may publish revised and/or new versions
|
|
147
|
+
of the GNU Lesser General Public License from time to time. Such new
|
|
148
|
+
versions will be similar in spirit to the present version, but may
|
|
149
|
+
differ in detail to address new problems or concerns.
|
|
150
|
+
|
|
151
|
+
Each version is given a distinguishing version number. If the
|
|
152
|
+
Library as you received it specifies that a certain numbered version
|
|
153
|
+
of the GNU Lesser General Public License "or any later version"
|
|
154
|
+
applies to it, you have the option of following the terms and
|
|
155
|
+
conditions either of that published version or of any later version
|
|
156
|
+
published by the Free Software Foundation. If the Library as you
|
|
157
|
+
received it does not specify a version number of the GNU Lesser
|
|
158
|
+
General Public License, you may choose any version of the GNU Lesser
|
|
159
|
+
General Public License ever published by the Free Software Foundation.
|
|
160
|
+
|
|
161
|
+
If the Library as you received it specifies that a proxy can decide
|
|
162
|
+
whether future versions of the GNU Lesser General Public License shall
|
|
163
|
+
apply, that proxy's public statement of acceptance of any version is
|
|
164
|
+
permanent authorization for you to choose that version for the
|
|
165
|
+
Library.
|
package/README.md
ADDED
|
@@ -0,0 +1,479 @@
|
|
|
1
|
+
# @egentica/codemap
|
|
2
|
+
|
|
3
|
+
> Universal code knowledge graph with zero-configuration setup
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/@egentica/codemap)
|
|
6
|
+
[](https://opensource.org/licenses/LGPL-3.0)
|
|
7
|
+
|
|
8
|
+
CodeMap is a language-agnostic code knowledge graph that builds deep understanding of your codebase through AST-based parsing, dependency tracking, and topology-aware navigation.
|
|
9
|
+
|
|
10
|
+
## Features
|
|
11
|
+
|
|
12
|
+
- **🚀 Zero Configuration** - Works out of the box with Node.js, no setup required
|
|
13
|
+
- **🔍 Deep Code Understanding** - AST-based parsing with symbol extraction and dependency tracking
|
|
14
|
+
- **🔌 Bundled Parsers** - TypeScript/JavaScript and Vue support included
|
|
15
|
+
- **📊 Knowledge Graph** - Build relationships between files, symbols, and dependencies
|
|
16
|
+
- **🎯 Smart Search** - Keyword search, symbol search, and hybrid search with relevance ranking
|
|
17
|
+
- **🏷️ Labels & Groups** - Organize code with labels and logical groupings
|
|
18
|
+
- **📝 Session Tracking** - Automatic change tracking and history
|
|
19
|
+
- **🔧 MCP Server** - Built-in Model Context Protocol server for AI integration
|
|
20
|
+
|
|
21
|
+
## Installation
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
npm install @egentica/codemap
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
**Bundled language parsers** (no additional packages needed):
|
|
28
|
+
- ✅ TypeScript/JavaScript (`.ts`, `.tsx`, `.js`, `.jsx`)
|
|
29
|
+
- ✅ Vue (`.vue` single-file components)
|
|
30
|
+
|
|
31
|
+
## Quick Start
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
import { CodeMap } from '@egentica/codemap';
|
|
35
|
+
|
|
36
|
+
// Initialize CodeMap
|
|
37
|
+
const codemap = new CodeMap({
|
|
38
|
+
rootPath: '/path/to/project'
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
// Scan the project
|
|
42
|
+
await codemap.scan();
|
|
43
|
+
|
|
44
|
+
// Search for code
|
|
45
|
+
const results = codemap.query.search({
|
|
46
|
+
query: 'authentication',
|
|
47
|
+
mode: 'hybrid'
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
// Get file dependencies
|
|
51
|
+
const file = codemap.graph.getFile('src/auth/login.ts');
|
|
52
|
+
console.log('Symbols:', file.symbols);
|
|
53
|
+
console.log('Imports:', file.references);
|
|
54
|
+
console.log('Imported by:', file.referencedBy);
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Core Concepts
|
|
58
|
+
|
|
59
|
+
### CodeMap Instance
|
|
60
|
+
|
|
61
|
+
The `CodeMap` class is your main entry point:
|
|
62
|
+
|
|
63
|
+
```typescript
|
|
64
|
+
const codemap = new CodeMap({
|
|
65
|
+
rootPath: '/project',
|
|
66
|
+
ignore: ['node_modules/**', 'dist/**', '.git/**']
|
|
67
|
+
});
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Scanning
|
|
71
|
+
|
|
72
|
+
Build the knowledge graph by scanning your project:
|
|
73
|
+
|
|
74
|
+
```typescript
|
|
75
|
+
// Full project scan
|
|
76
|
+
const stats = await codemap.scan();
|
|
77
|
+
console.log(`Scanned ${stats.filesScanned} files in ${stats.durationMs}ms`);
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Knowledge Graph
|
|
81
|
+
|
|
82
|
+
Direct access to files, symbols, and dependencies:
|
|
83
|
+
|
|
84
|
+
```typescript
|
|
85
|
+
// Get file entry
|
|
86
|
+
const file = codemap.graph.getFile('src/components/Button.tsx');
|
|
87
|
+
|
|
88
|
+
// Get all files
|
|
89
|
+
const allFiles = codemap.graph.getAllFiles();
|
|
90
|
+
|
|
91
|
+
// Get symbols in a file
|
|
92
|
+
const symbols = file.symbols;
|
|
93
|
+
|
|
94
|
+
// Get dependencies
|
|
95
|
+
const imports = file.references; // Files this file imports
|
|
96
|
+
const importedBy = file.referencedBy; // Files that import this file
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
### Querying
|
|
100
|
+
|
|
101
|
+
Multiple search modes for finding code:
|
|
102
|
+
|
|
103
|
+
```typescript
|
|
104
|
+
// Keyword search (file names, paths)
|
|
105
|
+
const files = codemap.query.search({
|
|
106
|
+
query: 'authentication',
|
|
107
|
+
mode: 'text'
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
// Symbol search (functions, classes, interfaces)
|
|
111
|
+
const symbols = codemap.query.search({
|
|
112
|
+
query: 'getUserById',
|
|
113
|
+
mode: 'symbol'
|
|
114
|
+
});
|
|
115
|
+
|
|
116
|
+
// Hybrid search (best of both)
|
|
117
|
+
const results = codemap.query.search({
|
|
118
|
+
query: 'auth login',
|
|
119
|
+
mode: 'hybrid'
|
|
120
|
+
});
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### File Operations
|
|
124
|
+
|
|
125
|
+
All file operations go through the lifecycle-aware gateway:
|
|
126
|
+
|
|
127
|
+
```typescript
|
|
128
|
+
// Read file
|
|
129
|
+
const content = await codemap.fs.read('src/index.ts');
|
|
130
|
+
|
|
131
|
+
// Write file (emits events)
|
|
132
|
+
await codemap.fs.write('src/new.ts', 'export const x = 1;');
|
|
133
|
+
|
|
134
|
+
// Check existence
|
|
135
|
+
const exists = await codemap.fs.exists('src/config.json');
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
## Symbols
|
|
139
|
+
|
|
140
|
+
CodeMap extracts symbols from your code:
|
|
141
|
+
|
|
142
|
+
```typescript
|
|
143
|
+
interface SymbolEntry {
|
|
144
|
+
name: string; // Symbol name
|
|
145
|
+
kind: SymbolKind; // function|class|interface|const|type|enum|etc.
|
|
146
|
+
startLine: number; // Start line number
|
|
147
|
+
startCol: number; // Start column
|
|
148
|
+
exported?: boolean; // Export status
|
|
149
|
+
signature?: string; // Function signature
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// Access symbols
|
|
153
|
+
const file = codemap.graph.getFile('src/api/users.ts');
|
|
154
|
+
const functions = file.symbols.filter(s => s.kind === 'function');
|
|
155
|
+
const exported = file.symbols.filter(s => s.exported);
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
## Labels
|
|
159
|
+
|
|
160
|
+
Organize code with labels:
|
|
161
|
+
|
|
162
|
+
```typescript
|
|
163
|
+
// Create a label
|
|
164
|
+
await codemap.labels.create({
|
|
165
|
+
emoji: '🔒',
|
|
166
|
+
name: 'security-critical',
|
|
167
|
+
description: 'Security-sensitive code requiring review'
|
|
168
|
+
});
|
|
169
|
+
|
|
170
|
+
// Assign labels to files
|
|
171
|
+
await codemap.labels.assign('security-critical', [
|
|
172
|
+
'src/auth/login.ts',
|
|
173
|
+
'src/auth/jwt.ts'
|
|
174
|
+
]);
|
|
175
|
+
|
|
176
|
+
// Search by label
|
|
177
|
+
const labeled = await codemap.labels.search('security-critical');
|
|
178
|
+
|
|
179
|
+
// List all labels
|
|
180
|
+
const allLabels = await codemap.labels.list();
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
## Groups
|
|
184
|
+
|
|
185
|
+
Organize related files and symbols:
|
|
186
|
+
|
|
187
|
+
```typescript
|
|
188
|
+
// Create a group
|
|
189
|
+
await codemap.groups.add({
|
|
190
|
+
name: 'auth-system',
|
|
191
|
+
description: 'Authentication and authorization components',
|
|
192
|
+
members: [
|
|
193
|
+
'src/auth/login.ts',
|
|
194
|
+
'src/auth/jwt.ts',
|
|
195
|
+
'src/auth/permissions.ts$checkPermission' // Symbol reference
|
|
196
|
+
]
|
|
197
|
+
});
|
|
198
|
+
|
|
199
|
+
// Get group details
|
|
200
|
+
const group = await codemap.groups.get('auth-system');
|
|
201
|
+
|
|
202
|
+
// List all groups
|
|
203
|
+
const allGroups = await codemap.groups.list();
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
## Sessions
|
|
207
|
+
|
|
208
|
+
Track changes and history:
|
|
209
|
+
|
|
210
|
+
```typescript
|
|
211
|
+
// Start a session
|
|
212
|
+
await codemap.sessions.start();
|
|
213
|
+
|
|
214
|
+
// Operations are automatically tracked
|
|
215
|
+
await codemap.fs.write('src/new.ts', 'content');
|
|
216
|
+
|
|
217
|
+
// Close session with summary
|
|
218
|
+
await codemap.sessions.close('Added new authentication module');
|
|
219
|
+
|
|
220
|
+
// List session history
|
|
221
|
+
const history = await codemap.sessions.list();
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
## Annotations
|
|
225
|
+
|
|
226
|
+
Add semantic metadata to code:
|
|
227
|
+
|
|
228
|
+
```typescript
|
|
229
|
+
// Add annotation
|
|
230
|
+
await codemap.annotations.add('src/auth/login.ts', {
|
|
231
|
+
key: 'domain.name',
|
|
232
|
+
value: 'Authentication System'
|
|
233
|
+
});
|
|
234
|
+
|
|
235
|
+
// Get annotations
|
|
236
|
+
const file = codemap.graph.getFile('src/auth/login.ts');
|
|
237
|
+
console.log(file.annotations);
|
|
238
|
+
```
|
|
239
|
+
|
|
240
|
+
## Plugins
|
|
241
|
+
|
|
242
|
+
CodeMap is extensible through plugins:
|
|
243
|
+
|
|
244
|
+
### Language Parsers
|
|
245
|
+
|
|
246
|
+
Add support for additional languages:
|
|
247
|
+
|
|
248
|
+
```typescript
|
|
249
|
+
import { LanguageParser, ParseResult } from '@egentica/codemap';
|
|
250
|
+
|
|
251
|
+
class MyParser implements LanguageParser {
|
|
252
|
+
name = 'my-language-parser';
|
|
253
|
+
extensions = ['.mylang'];
|
|
254
|
+
|
|
255
|
+
async parse(content: string, filePath: string): Promise<ParseResult> {
|
|
256
|
+
// Parse AST and extract symbols
|
|
257
|
+
return {
|
|
258
|
+
symbols: [...],
|
|
259
|
+
references: [...]
|
|
260
|
+
};
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
// Register parser
|
|
265
|
+
await codemap.registerPlugin(new MyParser());
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
### Feature Plugins
|
|
269
|
+
|
|
270
|
+
Extend CodeMap with custom analysis:
|
|
271
|
+
|
|
272
|
+
```typescript
|
|
273
|
+
import { Plugin, CodeMapHost } from '@egentica/codemap';
|
|
274
|
+
|
|
275
|
+
class MyPlugin implements Plugin {
|
|
276
|
+
name = 'my-plugin';
|
|
277
|
+
version = '1.0.0';
|
|
278
|
+
|
|
279
|
+
async initialize(codemap: CodeMapHost): Promise<void> {
|
|
280
|
+
// Hook into events
|
|
281
|
+
codemap.on('scan:complete', async () => {
|
|
282
|
+
console.log('Scan complete!');
|
|
283
|
+
});
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
// Register plugin
|
|
288
|
+
await codemap.registerPlugin(new MyPlugin());
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
## Event System
|
|
292
|
+
|
|
293
|
+
Hook into lifecycle events:
|
|
294
|
+
|
|
295
|
+
```typescript
|
|
296
|
+
// File operations
|
|
297
|
+
codemap.on('file:write:before', async (payload) => {
|
|
298
|
+
console.log('About to write:', payload.path);
|
|
299
|
+
});
|
|
300
|
+
|
|
301
|
+
codemap.on('file:write:after', async (payload) => {
|
|
302
|
+
console.log('Wrote:', payload.path);
|
|
303
|
+
});
|
|
304
|
+
|
|
305
|
+
// Scan events
|
|
306
|
+
codemap.on('scan:start', async () => {
|
|
307
|
+
console.log('Scan starting...');
|
|
308
|
+
});
|
|
309
|
+
|
|
310
|
+
codemap.on('scan:file', async (payload) => {
|
|
311
|
+
console.log('Scanned:', payload.file.relativePath);
|
|
312
|
+
});
|
|
313
|
+
|
|
314
|
+
codemap.on('scan:complete', async () => {
|
|
315
|
+
console.log('Scan complete!');
|
|
316
|
+
});
|
|
317
|
+
```
|
|
318
|
+
|
|
319
|
+
## MCP Server
|
|
320
|
+
|
|
321
|
+
CodeMap includes a built-in MCP (Model Context Protocol) server for AI integration:
|
|
322
|
+
|
|
323
|
+
### Installation
|
|
324
|
+
|
|
325
|
+
```bash
|
|
326
|
+
npm install -g @egentica/codemap
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
### Configuration
|
|
330
|
+
|
|
331
|
+
Add to Claude Desktop config file:
|
|
332
|
+
|
|
333
|
+
**macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
|
|
334
|
+
**Windows**: `%APPDATA%\\Claude\\claude_desktop_config.json`
|
|
335
|
+
|
|
336
|
+
```json
|
|
337
|
+
{
|
|
338
|
+
"mcpServers": {
|
|
339
|
+
"codemap": {
|
|
340
|
+
"command": "codemap-server",
|
|
341
|
+
"args": []
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
```
|
|
346
|
+
|
|
347
|
+
### Usage
|
|
348
|
+
|
|
349
|
+
The server provides 50+ tools for AI-assisted code navigation:
|
|
350
|
+
|
|
351
|
+
- **Search & Discovery** - Find files, symbols, text, annotations
|
|
352
|
+
- **File Operations** - Read, write, edit files
|
|
353
|
+
- **Graph & Dependencies** - Analyze relationships and impact
|
|
354
|
+
- **Code Organization** - Groups, annotations, labels
|
|
355
|
+
- **Session Management** - Track changes and workflows
|
|
356
|
+
|
|
357
|
+
## Configuration
|
|
358
|
+
|
|
359
|
+
Create `.codemap/config.json` in your project root:
|
|
360
|
+
|
|
361
|
+
```json
|
|
362
|
+
{
|
|
363
|
+
"version": 1,
|
|
364
|
+
"ignore": [
|
|
365
|
+
"node_modules/**",
|
|
366
|
+
"dist/**",
|
|
367
|
+
"coverage/**",
|
|
368
|
+
".git/**"
|
|
369
|
+
],
|
|
370
|
+
"plugins": [],
|
|
371
|
+
"parsers": [],
|
|
372
|
+
"writeAnnotationsToSource": false,
|
|
373
|
+
"backup": {
|
|
374
|
+
"enabled": true,
|
|
375
|
+
"maxDailyBackups": 7,
|
|
376
|
+
"maxTurnBackups": 20
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
```
|
|
380
|
+
|
|
381
|
+
## API Reference
|
|
382
|
+
|
|
383
|
+
### CodeMap
|
|
384
|
+
|
|
385
|
+
```typescript
|
|
386
|
+
class CodeMap {
|
|
387
|
+
constructor(config: CodeMapConfig);
|
|
388
|
+
|
|
389
|
+
// Lifecycle
|
|
390
|
+
scan(options?: ScanOptions): Promise<ScanStats>;
|
|
391
|
+
|
|
392
|
+
// Plugin management
|
|
393
|
+
registerPlugin(plugin: Plugin): Promise<void>;
|
|
394
|
+
unregisterPlugin(name: string): Promise<boolean>;
|
|
395
|
+
|
|
396
|
+
// Event system
|
|
397
|
+
on(event: CodeMapEvent, handler: EventHandler): void;
|
|
398
|
+
off(event: CodeMapEvent, handler: EventHandler): void;
|
|
399
|
+
|
|
400
|
+
// Public APIs
|
|
401
|
+
graph: FileSystemGraph; // Knowledge graph
|
|
402
|
+
query: QueryEngine; // Search & query
|
|
403
|
+
fs: FileSystemIO; // File operations
|
|
404
|
+
io: FileSystemIO; // Extended I/O operations
|
|
405
|
+
resolver: TargetResolver; // Path resolution
|
|
406
|
+
labels: LabelStore; // Label management
|
|
407
|
+
groups: GroupStore; // Group management
|
|
408
|
+
sessions: SessionLog; // Session tracking
|
|
409
|
+
annotations: AnnotationStore; // Annotation management
|
|
410
|
+
}
|
|
411
|
+
```
|
|
412
|
+
|
|
413
|
+
### QueryEngine
|
|
414
|
+
|
|
415
|
+
```typescript
|
|
416
|
+
class QueryEngine {
|
|
417
|
+
search(request: SearchRequest): SearchResponse;
|
|
418
|
+
findByName(pattern: string): FileEntry[];
|
|
419
|
+
findRelevant(task: string, maxResults?: number): RelevanceMatch[];
|
|
420
|
+
findImporters(path: string): FileEntry[];
|
|
421
|
+
findImports(path: string): FileEntry[];
|
|
422
|
+
traverse(path: string, direction: 'imports'|'importers', depth?: number): FileEntry[];
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
interface SearchRequest {
|
|
426
|
+
query: string;
|
|
427
|
+
mode?: 'text' | 'symbol' | 'hybrid';
|
|
428
|
+
maxResults?: number;
|
|
429
|
+
symbolKinds?: SymbolKind[];
|
|
430
|
+
useRegex?: boolean;
|
|
431
|
+
}
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
### FileSystemGraph
|
|
435
|
+
|
|
436
|
+
```typescript
|
|
437
|
+
class FileSystemGraph {
|
|
438
|
+
getFile(path: string): FileEntry | undefined;
|
|
439
|
+
getAllFiles(): FileEntry[];
|
|
440
|
+
getFilesByDirectory(dir: string): FileEntry[];
|
|
441
|
+
getDependencies(path: string): string[];
|
|
442
|
+
getDependents(path: string): string[];
|
|
443
|
+
}
|
|
444
|
+
```
|
|
445
|
+
|
|
446
|
+
## Advanced Usage
|
|
447
|
+
|
|
448
|
+
### Custom FileSystemProvider
|
|
449
|
+
|
|
450
|
+
For non-Node.js environments or custom storage:
|
|
451
|
+
|
|
452
|
+
```typescript
|
|
453
|
+
import { CodeMap, FileSystemProvider } from '@egentica/codemap';
|
|
454
|
+
|
|
455
|
+
class CustomProvider implements FileSystemProvider {
|
|
456
|
+
async read(path: string): Promise<string> { /* ... */ }
|
|
457
|
+
async write(path: string, content: string): Promise<void> { /* ... */ }
|
|
458
|
+
async exists(path: string): Promise<boolean> { /* ... */ }
|
|
459
|
+
async readdir(path: string): Promise<string[]> { /* ... */ }
|
|
460
|
+
// ... implement other methods
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
const codemap = new CodeMap({
|
|
464
|
+
rootPath: '/project',
|
|
465
|
+
provider: new CustomProvider()
|
|
466
|
+
});
|
|
467
|
+
```
|
|
468
|
+
|
|
469
|
+
## TypeScript Support
|
|
470
|
+
|
|
471
|
+
CodeMap is written in TypeScript and provides full type definitions. All APIs are fully typed.
|
|
472
|
+
|
|
473
|
+
## Contributing
|
|
474
|
+
|
|
475
|
+
We welcome contributions! Please see [CONTRIBUTING.md](../../CONTRIBUTING.md) for guidelines.
|
|
476
|
+
|
|
477
|
+
## License
|
|
478
|
+
|
|
479
|
+
LGPL-3.0 © Egentica
|