@venizia/ignis-docs 0.0.1-4 → 0.0.1-6
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/mcp-server/dist/common/config.d.ts +58 -21
- package/mcp-server/dist/common/config.d.ts.map +1 -1
- package/mcp-server/dist/common/config.js +67 -12
- package/mcp-server/dist/common/config.js.map +1 -1
- package/mcp-server/dist/helpers/docs.helper.d.ts +5 -5
- package/mcp-server/dist/helpers/docs.helper.d.ts.map +1 -1
- package/mcp-server/dist/helpers/docs.helper.js +31 -27
- package/mcp-server/dist/helpers/docs.helper.js.map +1 -1
- package/mcp-server/dist/helpers/github.helper.d.ts +37 -0
- package/mcp-server/dist/helpers/github.helper.d.ts.map +1 -0
- package/mcp-server/dist/helpers/github.helper.js +100 -0
- package/mcp-server/dist/helpers/github.helper.js.map +1 -0
- package/mcp-server/dist/helpers/index.d.ts +1 -0
- package/mcp-server/dist/helpers/index.d.ts.map +1 -1
- package/mcp-server/dist/helpers/index.js +1 -0
- package/mcp-server/dist/helpers/index.js.map +1 -1
- package/mcp-server/dist/index.js +60 -32
- package/mcp-server/dist/index.js.map +1 -1
- package/mcp-server/dist/tools/base.tool.d.ts +6 -10
- package/mcp-server/dist/tools/base.tool.d.ts.map +1 -1
- package/mcp-server/dist/tools/base.tool.js +3 -5
- package/mcp-server/dist/tools/base.tool.js.map +1 -1
- package/mcp-server/dist/tools/{get-doc-content.tool.d.ts → docs/get-document-content.tool.d.ts} +4 -4
- package/mcp-server/dist/tools/docs/get-document-content.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/{get-doc-content.tool.js → docs/get-document-content.tool.js} +12 -11
- package/mcp-server/dist/tools/docs/get-document-content.tool.js.map +1 -0
- package/mcp-server/dist/tools/{get-doc-metadata.tool.d.ts → docs/get-document-metadata.tool.d.ts} +4 -4
- package/mcp-server/dist/tools/docs/get-document-metadata.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/{get-doc-metadata.tool.js → docs/get-document-metadata.tool.js} +11 -10
- package/mcp-server/dist/tools/docs/get-document-metadata.tool.js.map +1 -0
- package/mcp-server/dist/tools/docs/get-package-overview.tool.d.ts +50 -0
- package/mcp-server/dist/tools/docs/get-package-overview.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/docs/get-package-overview.tool.js +221 -0
- package/mcp-server/dist/tools/docs/get-package-overview.tool.js.map +1 -0
- package/mcp-server/dist/tools/docs/index.d.ts +7 -0
- package/mcp-server/dist/tools/docs/index.d.ts.map +1 -0
- package/mcp-server/dist/tools/docs/index.js +23 -0
- package/mcp-server/dist/tools/docs/index.js.map +1 -0
- package/mcp-server/dist/tools/{list-categories.tool.d.ts → docs/list-categories.tool.d.ts} +2 -2
- package/mcp-server/dist/tools/docs/list-categories.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/{list-categories.tool.js → docs/list-categories.tool.js} +7 -6
- package/mcp-server/dist/tools/docs/list-categories.tool.js.map +1 -0
- package/mcp-server/dist/tools/{list-docs.tool.d.ts → docs/list-documents.tool.d.ts} +4 -4
- package/mcp-server/dist/tools/docs/list-documents.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/{list-docs.tool.js → docs/list-documents.tool.js} +10 -9
- package/mcp-server/dist/tools/docs/list-documents.tool.js.map +1 -0
- package/mcp-server/dist/tools/{search-docs.tool.d.ts → docs/search-documents.tool.d.ts} +4 -4
- package/mcp-server/dist/tools/docs/search-documents.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/{search-docs.tool.js → docs/search-documents.tool.js} +19 -18
- package/mcp-server/dist/tools/docs/search-documents.tool.js.map +1 -0
- package/mcp-server/dist/tools/github/index.d.ts +5 -0
- package/mcp-server/dist/tools/github/index.d.ts.map +1 -0
- package/mcp-server/dist/tools/github/index.js +21 -0
- package/mcp-server/dist/tools/github/index.js.map +1 -0
- package/mcp-server/dist/tools/github/list-project-files.tool.d.ts +28 -0
- package/mcp-server/dist/tools/github/list-project-files.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/github/list-project-files.tool.js +98 -0
- package/mcp-server/dist/tools/github/list-project-files.tool.js.map +1 -0
- package/mcp-server/dist/tools/github/search-code.tool.d.ts +42 -0
- package/mcp-server/dist/tools/github/search-code.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/github/search-code.tool.js +194 -0
- package/mcp-server/dist/tools/github/search-code.tool.js.map +1 -0
- package/mcp-server/dist/tools/github/verify-dependencies.tool.d.ts +55 -0
- package/mcp-server/dist/tools/github/verify-dependencies.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/github/verify-dependencies.tool.js +167 -0
- package/mcp-server/dist/tools/github/verify-dependencies.tool.js.map +1 -0
- package/mcp-server/dist/tools/github/view-source-file.tool.d.ts +26 -0
- package/mcp-server/dist/tools/github/view-source-file.tool.d.ts.map +1 -0
- package/mcp-server/dist/tools/github/view-source-file.tool.js +91 -0
- package/mcp-server/dist/tools/github/view-source-file.tool.js.map +1 -0
- package/mcp-server/dist/tools/index.d.ts +3 -7
- package/mcp-server/dist/tools/index.d.ts.map +1 -1
- package/mcp-server/dist/tools/index.js +17 -13
- package/mcp-server/dist/tools/index.js.map +1 -1
- package/package.json +25 -6
- package/wiki/get-started/best-practices/api-usage-examples.md +42 -0
- package/wiki/get-started/best-practices/architectural-patterns.md +42 -1
- package/wiki/get-started/best-practices/code-style-standards.md +41 -0
- package/wiki/get-started/best-practices/contribution-workflow.md +40 -6
- package/wiki/get-started/best-practices/data-modeling.md +126 -0
- package/wiki/get-started/core-concepts/dependency-injection.md +13 -1
- package/wiki/get-started/mcp-docs-server.md +130 -32
- package/wiki/get-started/philosophy.md +198 -25
- package/wiki/public/logo.svg +1 -0
- package/wiki/references/base/application.md +5 -5
- package/wiki/references/base/controllers.md +3 -1
- package/wiki/references/base/dependency-injection.md +6 -5
- package/wiki/references/base/models.md +319 -1
- package/wiki/references/components/index.md +3 -1
- package/wiki/references/components/static-asset.md +1289 -0
- package/wiki/references/helpers/inversion.md +21 -11
- package/wiki/references/helpers/storage.md +538 -11
- package/wiki/references/src-details/core.md +15 -1
- package/wiki/references/src-details/docs.md +19 -9
- package/wiki/references/src-details/mcp-server.md +185 -234
- package/wiki/references/utilities/index.md +1 -1
- package/wiki/references/utilities/request.md +150 -0
- package/mcp-server/dist/tools/get-doc-content.tool.d.ts.map +0 -1
- package/mcp-server/dist/tools/get-doc-content.tool.js.map +0 -1
- package/mcp-server/dist/tools/get-doc-metadata.tool.d.ts.map +0 -1
- package/mcp-server/dist/tools/get-doc-metadata.tool.js.map +0 -1
- package/mcp-server/dist/tools/list-categories.tool.d.ts.map +0 -1
- package/mcp-server/dist/tools/list-categories.tool.js.map +0 -1
- package/mcp-server/dist/tools/list-docs.tool.d.ts.map +0 -1
- package/mcp-server/dist/tools/list-docs.tool.js.map +0 -1
- package/mcp-server/dist/tools/search-docs.tool.d.ts.map +0 -1
- package/mcp-server/dist/tools/search-docs.tool.js.map +0 -1
|
@@ -0,0 +1,221 @@
|
|
|
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.GetPackageOverviewTool = void 0;
|
|
7
|
+
const tools_1 = require("@mastra/core/tools");
|
|
8
|
+
const fast_glob_1 = __importDefault(require("fast-glob"));
|
|
9
|
+
const gray_matter_1 = __importDefault(require("gray-matter"));
|
|
10
|
+
const promises_1 = __importDefault(require("node:fs/promises"));
|
|
11
|
+
const node_path_1 = __importDefault(require("node:path"));
|
|
12
|
+
const zod_1 = require("zod");
|
|
13
|
+
const common_1 = require("../../common");
|
|
14
|
+
const helpers_1 = require("../../helpers");
|
|
15
|
+
const base_tool_1 = require("../base.tool");
|
|
16
|
+
// ----------------------------------------------------------------------------
|
|
17
|
+
// DESCRIPTIONS
|
|
18
|
+
// ----------------------------------------------------------------------------
|
|
19
|
+
const TOOL_DESCRIPTION = `
|
|
20
|
+
Returns an overview of Ignis packages from the source details documentation.
|
|
21
|
+
|
|
22
|
+
PURPOSE:
|
|
23
|
+
Provides AI agents with comprehensive understanding of the Ignis monorepo structure,
|
|
24
|
+
package purposes, main exports, and directory layouts. This is essential for helping
|
|
25
|
+
users understand which package to use for specific features.
|
|
26
|
+
|
|
27
|
+
WHEN TO USE:
|
|
28
|
+
- When user asks "what packages does Ignis have?"
|
|
29
|
+
- When user needs to understand project structure
|
|
30
|
+
- When user asks which package provides a specific feature
|
|
31
|
+
- Before helping user implement a feature (to know where code should go)
|
|
32
|
+
- When user asks about imports or package dependencies
|
|
33
|
+
|
|
34
|
+
WHEN NOT TO USE:
|
|
35
|
+
- For specific API documentation (use getDocContent with references/ docs)
|
|
36
|
+
- For code examples (use searchCode or getDocContent)
|
|
37
|
+
- For troubleshooting (use searchDocs)
|
|
38
|
+
|
|
39
|
+
OUTPUT:
|
|
40
|
+
Returns package name, description, main directories, and key components.
|
|
41
|
+
The content comes from wiki/references/src-details/ documentation.
|
|
42
|
+
`;
|
|
43
|
+
const PACKAGE_NAME_DESCRIPTION = `
|
|
44
|
+
Optional: Name of specific package to get details for.
|
|
45
|
+
|
|
46
|
+
VALID VALUES:
|
|
47
|
+
- "core" - @venizia/ignis main framework
|
|
48
|
+
- "helpers" - @venizia/ignis-helpers utility helpers
|
|
49
|
+
- "inversion" - @venizia/ignis-inversion DI container
|
|
50
|
+
- "dev-configs" - @venizia/dev-configs ESLint, Prettier, TSConfig
|
|
51
|
+
- "docs" - Documentation package
|
|
52
|
+
- "mcp-server" - MCP documentation server
|
|
53
|
+
|
|
54
|
+
If not provided, returns overview of ALL packages.
|
|
55
|
+
`;
|
|
56
|
+
// ----------------------------------------------------------------------------
|
|
57
|
+
// SCHEMAS
|
|
58
|
+
// ----------------------------------------------------------------------------
|
|
59
|
+
const PackageInfoSchema = zod_1.z.object({
|
|
60
|
+
name: zod_1.z.string().describe('Package name (e.g., "core", "helpers")'),
|
|
61
|
+
npmName: zod_1.z.string().describe('NPM package name (e.g., "@venizia/ignis")'),
|
|
62
|
+
description: zod_1.z.string().describe('Brief description of package purpose'),
|
|
63
|
+
directories: zod_1.z
|
|
64
|
+
.array(zod_1.z.object({
|
|
65
|
+
name: zod_1.z.string(),
|
|
66
|
+
purpose: zod_1.z.string(),
|
|
67
|
+
}))
|
|
68
|
+
.describe('Main directories and their purposes'),
|
|
69
|
+
content: zod_1.z.string().optional().describe('Full markdown content if single package requested'),
|
|
70
|
+
});
|
|
71
|
+
const InputSchema = zod_1.z.object({
|
|
72
|
+
packageName: zod_1.z.string().optional().describe(PACKAGE_NAME_DESCRIPTION),
|
|
73
|
+
});
|
|
74
|
+
const OutputSchema = zod_1.z.object({
|
|
75
|
+
packages: zod_1.z.array(PackageInfoSchema).describe('List of package overviews'),
|
|
76
|
+
error: zod_1.z.string().optional().describe('Error message if operation failed'),
|
|
77
|
+
});
|
|
78
|
+
// ----------------------------------------------------------------------------
|
|
79
|
+
// PACKAGE MAPPING
|
|
80
|
+
// ----------------------------------------------------------------------------
|
|
81
|
+
const PACKAGE_NPM_NAMES = {
|
|
82
|
+
core: '@venizia/ignis',
|
|
83
|
+
helpers: '@venizia/ignis-helpers',
|
|
84
|
+
inversion: '@venizia/ignis-inversion',
|
|
85
|
+
'dev-configs': '@venizia/dev-configs',
|
|
86
|
+
docs: '@venizia/ignis-docs',
|
|
87
|
+
'mcp-server': '@venizia/ignis-docs (MCP Server)',
|
|
88
|
+
};
|
|
89
|
+
// ----------------------------------------------------------------------------
|
|
90
|
+
// TOOL CLASS
|
|
91
|
+
// ----------------------------------------------------------------------------
|
|
92
|
+
class GetPackageOverviewTool extends base_tool_1.BaseTool {
|
|
93
|
+
constructor() {
|
|
94
|
+
super(...arguments);
|
|
95
|
+
this.id = 'getPackageOverview';
|
|
96
|
+
this.description = TOOL_DESCRIPTION;
|
|
97
|
+
this.inputSchema = InputSchema;
|
|
98
|
+
this.outputSchema = OutputSchema;
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* Extracts package description from first paragraph after title
|
|
102
|
+
*/
|
|
103
|
+
extractDescription(opts) {
|
|
104
|
+
const lines = opts.content.split('\n');
|
|
105
|
+
let bFoundTitle = false;
|
|
106
|
+
const descLines = [];
|
|
107
|
+
for (const line of lines) {
|
|
108
|
+
if (line.startsWith('# ')) {
|
|
109
|
+
bFoundTitle = true;
|
|
110
|
+
continue;
|
|
111
|
+
}
|
|
112
|
+
if (bFoundTitle && line.trim() === '') {
|
|
113
|
+
if (descLines.length > 0) {
|
|
114
|
+
break;
|
|
115
|
+
}
|
|
116
|
+
continue;
|
|
117
|
+
}
|
|
118
|
+
if (bFoundTitle && !line.startsWith('#') && !line.startsWith('|') && !line.startsWith('-')) {
|
|
119
|
+
descLines.push(line.trim());
|
|
120
|
+
if (descLines.length >= 2) {
|
|
121
|
+
break;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
return descLines.join(' ').slice(0, 300) || 'No description available';
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Extracts directory table from markdown content
|
|
129
|
+
*/
|
|
130
|
+
extractDirectories(opts) {
|
|
131
|
+
const directories = [];
|
|
132
|
+
const lines = opts.content.split('\n');
|
|
133
|
+
let isInTable = false;
|
|
134
|
+
let isHeaderPassed = false;
|
|
135
|
+
for (const line of lines) {
|
|
136
|
+
// Look for tables with Directory/Folder column
|
|
137
|
+
if (line.includes('| Directory') || line.includes('| Folder') || line.includes('| **`')) {
|
|
138
|
+
isInTable = true;
|
|
139
|
+
continue;
|
|
140
|
+
}
|
|
141
|
+
if (isInTable && line.startsWith('|---')) {
|
|
142
|
+
isHeaderPassed = true;
|
|
143
|
+
continue;
|
|
144
|
+
}
|
|
145
|
+
if (isInTable && isHeaderPassed && line.startsWith('|')) {
|
|
146
|
+
const cells = line
|
|
147
|
+
.split('|')
|
|
148
|
+
.map(c => c.trim())
|
|
149
|
+
.filter(Boolean);
|
|
150
|
+
if (cells.length >= 2) {
|
|
151
|
+
const dirName = cells[0].replace(/\*\*/g, '').replace(/`/g, '').trim();
|
|
152
|
+
const purpose = cells[1].replace(/\*\*/g, '').slice(0, 150);
|
|
153
|
+
if (dirName && !dirName.includes('---')) {
|
|
154
|
+
directories.push({ name: dirName, purpose });
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
// Stop at next section
|
|
159
|
+
if (isInTable && isHeaderPassed && (line.startsWith('##') || line.startsWith('---'))) {
|
|
160
|
+
break;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
return directories.slice(0, 10); // Limit to top 10 directories
|
|
164
|
+
}
|
|
165
|
+
async execute(opts) {
|
|
166
|
+
const srcDetailsPath = common_1.Paths.SOURCE_DETAILS;
|
|
167
|
+
try {
|
|
168
|
+
// Get specific package or all packages
|
|
169
|
+
const pattern = opts.packageName ? `${opts.packageName}.md` : '*.md';
|
|
170
|
+
const files = await (0, fast_glob_1.default)(pattern, {
|
|
171
|
+
cwd: srcDetailsPath,
|
|
172
|
+
absolute: true,
|
|
173
|
+
});
|
|
174
|
+
if (files.length === 0) {
|
|
175
|
+
return {
|
|
176
|
+
packages: [],
|
|
177
|
+
error: opts.packageName
|
|
178
|
+
? `Package "${opts.packageName}" not found. Valid: core, helpers, inversion, dev-configs, docs, mcp-server`
|
|
179
|
+
: 'No package documentation found',
|
|
180
|
+
};
|
|
181
|
+
}
|
|
182
|
+
const packages = await Promise.all(files.map(async (file) => {
|
|
183
|
+
const rawContent = await promises_1.default.readFile(file, 'utf-8');
|
|
184
|
+
const { content } = (0, gray_matter_1.default)(rawContent);
|
|
185
|
+
const baseName = node_path_1.default.basename(file, '.md');
|
|
186
|
+
const packageInfo = {
|
|
187
|
+
name: baseName,
|
|
188
|
+
npmName: PACKAGE_NPM_NAMES[baseName] || `@venizia/ignis-${baseName}`,
|
|
189
|
+
description: this.extractDescription({ content }),
|
|
190
|
+
directories: this.extractDirectories({ content }),
|
|
191
|
+
};
|
|
192
|
+
// Include full content only if single package requested
|
|
193
|
+
if (opts.packageName) {
|
|
194
|
+
packageInfo.content = content;
|
|
195
|
+
}
|
|
196
|
+
return packageInfo;
|
|
197
|
+
}));
|
|
198
|
+
// Sort by package name
|
|
199
|
+
packages.sort((a, b) => a.name.localeCompare(b.name));
|
|
200
|
+
return { packages };
|
|
201
|
+
}
|
|
202
|
+
catch (error) {
|
|
203
|
+
helpers_1.Logger.error('Failed to get package overview:', error);
|
|
204
|
+
return {
|
|
205
|
+
packages: [],
|
|
206
|
+
error: `Failed to load package overview: ${error instanceof Error ? error.message : 'Unknown error'}`,
|
|
207
|
+
};
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
getTool() {
|
|
211
|
+
return (0, tools_1.createTool)({
|
|
212
|
+
id: this.id,
|
|
213
|
+
description: this.description,
|
|
214
|
+
inputSchema: this.inputSchema,
|
|
215
|
+
outputSchema: this.outputSchema,
|
|
216
|
+
execute: async ({ context }) => this.execute(context),
|
|
217
|
+
});
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
exports.GetPackageOverviewTool = GetPackageOverviewTool;
|
|
221
|
+
//# sourceMappingURL=get-package-overview.tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-package-overview.tool.js","sourceRoot":"","sources":["../../../tools/docs/get-package-overview.tool.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAgD;AAChD,0DAA2B;AAC3B,8DAAiC;AACjC,gEAAkC;AAClC,0DAA6B;AAC7B,6BAAwB;AACxB,yCAAqC;AACrC,2CAAuC;AACvC,4CAA0D;AAE1D,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;CAuBxB,CAAC;AAEF,MAAM,wBAAwB,GAAG;;;;;;;;;;;;CAYhC,CAAC;AAEF,+EAA+E;AAC/E,UAAU;AACV,+EAA+E;AAE/E,MAA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ACX,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,OAAO,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;SACtD,CAAC,CAAC;IACL,CAAC;CACF;AApJD,wDAoJC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './get-document-content.tool';
|
|
2
|
+
export * from './get-document-metadata.tool';
|
|
3
|
+
export * from './get-package-overview.tool';
|
|
4
|
+
export * from './list-categories.tool';
|
|
5
|
+
export * from './list-documents.tool';
|
|
6
|
+
export * from './search-documents.tool';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../tools/docs/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./get-document-content.tool"), exports);
|
|
18
|
+
__exportStar(require("./get-document-metadata.tool"), exports);
|
|
19
|
+
__exportStar(require("./get-package-overview.tool"), exports);
|
|
20
|
+
__exportStar(require("./list-categories.tool"), exports);
|
|
21
|
+
__exportStar(require("./list-documents.tool"), exports);
|
|
22
|
+
__exportStar(require("./search-documents.tool"), exports);
|
|
23
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../tools/docs/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8DAA4C;AAC5C,+DAA6C;AAC7C,8DAA4C;AAC5C,yDAAuC;AACvC,wDAAsC;AACtC,0DAAwC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { BaseTool,
|
|
2
|
+
import { BaseTool, TMastraTool } from '../base.tool';
|
|
3
3
|
declare const InputSchema: z.ZodObject<{}, z.core.$strip>;
|
|
4
4
|
declare const OutputSchema: z.ZodObject<{
|
|
5
5
|
count: z.ZodNumber;
|
|
@@ -13,7 +13,7 @@ export declare class ListCategoriesTool extends BaseTool<typeof InputSchema, typ
|
|
|
13
13
|
count: z.ZodNumber;
|
|
14
14
|
categories: z.ZodArray<z.ZodString>;
|
|
15
15
|
}, z.core.$strip>;
|
|
16
|
-
execute(
|
|
16
|
+
execute(_opts: z.infer<typeof InputSchema>): Promise<z.infer<typeof OutputSchema>>;
|
|
17
17
|
getTool(): TMastraTool;
|
|
18
18
|
}
|
|
19
19
|
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-categories.tool.d.ts","sourceRoot":"","sources":["../../../tools/docs/list-categories.tool.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAsErD,QAAA,MAAM,WAAW,gCAAyD,CAAC;AAE3E,QAAA,MAAM,YAAY;;;iBAGhB,CAAC;AAMH,qBAAa,kBAAmB,SAAQ,QAAQ,CAAC,OAAO,WAAW,EAAE,OAAO,YAAY,CAAC;IACvF,QAAQ,CAAC,EAAE,oBAAoB;IAC/B,QAAQ,CAAC,WAAW,i7CAAoB;IACxC,QAAQ,CAAC,WAAW,iCAAe;IACnC,QAAQ,CAAC,YAAY;;;sBAAgB;IAE/B,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;IASxF,OAAO,IAAI,WAAW;CASvB"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ListCategoriesTool = void 0;
|
|
4
|
+
const helpers_1 = require("@/mcp-server/helpers");
|
|
5
|
+
const tools_1 = require("@mastra/core/tools");
|
|
4
6
|
const zod_1 = require("zod");
|
|
5
|
-
const
|
|
6
|
-
const base_tool_1 = require("./base.tool");
|
|
7
|
+
const base_tool_1 = require("../base.tool");
|
|
7
8
|
// ----------------------------------------------------------------------------
|
|
8
9
|
// DESCRIPTIONS
|
|
9
10
|
// ----------------------------------------------------------------------------
|
|
@@ -84,7 +85,7 @@ class ListCategoriesTool extends base_tool_1.BaseTool {
|
|
|
84
85
|
this.inputSchema = InputSchema;
|
|
85
86
|
this.outputSchema = OutputSchema;
|
|
86
87
|
}
|
|
87
|
-
async execute(
|
|
88
|
+
async execute(_opts) {
|
|
88
89
|
const categories = await helpers_1.DocsHelper.listCategories();
|
|
89
90
|
return {
|
|
90
91
|
count: categories.length,
|
|
@@ -92,11 +93,11 @@ class ListCategoriesTool extends base_tool_1.BaseTool {
|
|
|
92
93
|
};
|
|
93
94
|
}
|
|
94
95
|
getTool() {
|
|
95
|
-
return (0,
|
|
96
|
+
return (0, tools_1.createTool)({
|
|
96
97
|
id: this.id,
|
|
97
98
|
description: this.description,
|
|
98
|
-
inputSchema:
|
|
99
|
-
outputSchema:
|
|
99
|
+
inputSchema: this.inputSchema,
|
|
100
|
+
outputSchema: this.outputSchema,
|
|
100
101
|
execute: async ({ context }) => this.execute(context),
|
|
101
102
|
});
|
|
102
103
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-categories.tool.js","sourceRoot":"","sources":["../../../tools/docs/list-categories.tool.ts"],"names":[],"mappings":";;;AAAA,kDAAkD;AAClD,8CAAgD;AAChD,6BAAwB;AACxB,4CAAqD;AAErD,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsCxB,CAAC;AAEF,MAAM,sBAAsB,GAAG;;;;;;;;;;;;;;;;;;CAkB9B,CAAC;AAEF,+EAA+E;AAC/E,UAAU;AACV,+EAA+E;AAE/E,MAAM,WAAW,GAAG,OAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,+BAA+B,CAAC,CAAC;AAE3E,MAAM,YAAY,GAAG,OAAC,CAAC,MAAM,CAAC;IAC5B,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,oCAAoC,CAAC;IACtE,UAAU,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,CAAC,sBAAsB,CAAC;CACjE,CAAC,CAAC;AAEH,+EAA+E;AAC/E,aAAa;AACb,+EAA+E;AAE/E,MAAa,kBAAmB,SAAQ,oBAAiD;IAAzF;;QACW,OAAE,GAAG,gBAAgB,CAAC;QACtB,gBAAW,GAAG,gBAAgB,CAAC;QAC/B,gBAAW,GAAG,WAAW,CAAC;QAC1B,iBAAY,GAAG,YAAY,CAAC;IAoBvC,CAAC;IAlBC,KAAK,CAAC,OAAO,CAAC,KAAkC;QAC9C,MAAM,UAAU,GAAG,MAAM,oBAAU,CAAC,cAAc,EAAE,CAAC;QAErD,OAAO;YACL,KAAK,EAAE,UAAU,CAAC,MAAM;YACxB,UAAU;SACX,CAAC;IACJ,CAAC;IAED,OAAO;QACL,OAAO,IAAA,kBAAU,EAAC;YAChB,EAAE,EAAE,IAAI,CAAC,EAAE;YACX,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,OAAO,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;SACtD,CAAC,CAAC;IACL,CAAC;CACF;AAxBD,gDAwBC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { BaseTool,
|
|
2
|
+
import { BaseTool, TMastraTool } from '../base.tool';
|
|
3
3
|
declare const InputSchema: z.ZodObject<{
|
|
4
4
|
category: z.ZodOptional<z.ZodString>;
|
|
5
5
|
}, z.core.$strip>;
|
|
@@ -12,7 +12,7 @@ declare const OutputSchema: z.ZodObject<{
|
|
|
12
12
|
}, z.core.$strip>>;
|
|
13
13
|
}, z.core.$strip>;
|
|
14
14
|
export declare class ListDocsTool extends BaseTool<typeof InputSchema, typeof OutputSchema> {
|
|
15
|
-
readonly id = "
|
|
15
|
+
readonly id = "listDocuments";
|
|
16
16
|
readonly description = "\nLists all available Ignis Framework documentation files with their identifiers, titles, and categories.\n\nPURPOSE:\nUse this tool to discover what documentation is available. It provides a complete catalog\nof all documents, optionally filtered by category. Essential for understanding the documentation\nstructure and finding specific pages.\n\nWHEN TO USE:\n- To explore what documentation exists\n- To find document IDs for use with getDocContent\n- To browse documents within a specific category\n- When searchDocs doesn't find what you're looking for\n- To understand the overall documentation structure\n- To provide users with a list of available resources\n\nWHEN NOT TO USE:\n- When you know what you're looking for (use searchDocs instead)\n- When you need document content (use getDocContent after getting IDs)\n\nCATEGORY FILTERING:\n- Omit 'category' parameter to get ALL documents\n- Provide exact category name to filter (case-sensitive)\n- Use listCategories first to see available category names\n\nCOMMON CATEGORIES IN IGNIS DOCS:\n- \"Getting Started\" - Introductory guides, quickstart, philosophy\n- \"Core Concepts\" - DI, lifecycle, configuration fundamentals\n- \"Best Practices\" - Recommended patterns and approaches\n- \"References\" - API documentation, component details\n- \"Helpers\" - Utility libraries documentation\n- \"Utilities\" - Utility function references\n\nWORKFLOW EXAMPLES:\n1. Browse all docs:\n listDocs() \u2192 Review titles \u2192 getDocContent(id)\n\n2. Explore a category:\n listCategories() \u2192 Pick category \u2192 listDocs(category) \u2192 getDocContent(id)\n\n3. Find specific documentation:\n searchDocs(query) \u2192 If not found \u2192 listDocs() to browse manually\n";
|
|
17
17
|
readonly inputSchema: z.ZodObject<{
|
|
18
18
|
category: z.ZodOptional<z.ZodString>;
|
|
@@ -25,8 +25,8 @@ export declare class ListDocsTool extends BaseTool<typeof InputSchema, typeof Ou
|
|
|
25
25
|
category: z.ZodString;
|
|
26
26
|
}, z.core.$strip>>;
|
|
27
27
|
}, z.core.$strip>;
|
|
28
|
-
execute(
|
|
28
|
+
execute(opts: z.infer<typeof InputSchema>): Promise<z.infer<typeof OutputSchema>>;
|
|
29
29
|
getTool(): TMastraTool;
|
|
30
30
|
}
|
|
31
31
|
export {};
|
|
32
|
-
//# sourceMappingURL=list-
|
|
32
|
+
//# sourceMappingURL=list-documents.tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-documents.tool.d.ts","sourceRoot":"","sources":["../../../tools/docs/list-documents.tool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAsFrD,QAAA,MAAM,WAAW;;iBAEf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;;;iBAGhB,CAAC;AAMH,qBAAa,YAAa,SAAQ,QAAQ,CAAC,OAAO,WAAW,EAAE,OAAO,YAAY,CAAC;IACjF,QAAQ,CAAC,EAAE,mBAAmB;IAC9B,QAAQ,CAAC,WAAW,+sDAAoB;IACxC,QAAQ,CAAC,WAAW;;sBAAe;IACnC,QAAQ,CAAC,YAAY;;;;;;;sBAAgB;IAE/B,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;IASvF,OAAO,IAAI,WAAW;CASvB"}
|
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ListDocsTool = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
|
-
const
|
|
6
|
-
const base_tool_1 = require("
|
|
5
|
+
const tools_1 = require("@mastra/core/tools");
|
|
6
|
+
const base_tool_1 = require("../base.tool");
|
|
7
|
+
const helpers_1 = require("@/mcp-server/helpers");
|
|
7
8
|
// ----------------------------------------------------------------------------
|
|
8
9
|
// DESCRIPTIONS
|
|
9
10
|
// ----------------------------------------------------------------------------
|
|
@@ -95,27 +96,27 @@ const OutputSchema = zod_1.z.object({
|
|
|
95
96
|
class ListDocsTool extends base_tool_1.BaseTool {
|
|
96
97
|
constructor() {
|
|
97
98
|
super(...arguments);
|
|
98
|
-
this.id = '
|
|
99
|
+
this.id = 'listDocuments';
|
|
99
100
|
this.description = TOOL_DESCRIPTION;
|
|
100
101
|
this.inputSchema = InputSchema;
|
|
101
102
|
this.outputSchema = OutputSchema;
|
|
102
103
|
}
|
|
103
|
-
async execute(
|
|
104
|
-
const docs = await helpers_1.DocsHelper.
|
|
104
|
+
async execute(opts) {
|
|
105
|
+
const docs = await helpers_1.DocsHelper.listDocumentFiles({ category: opts.category });
|
|
105
106
|
return {
|
|
106
107
|
count: docs.length,
|
|
107
108
|
docs,
|
|
108
109
|
};
|
|
109
110
|
}
|
|
110
111
|
getTool() {
|
|
111
|
-
return (0,
|
|
112
|
+
return (0, tools_1.createTool)({
|
|
112
113
|
id: this.id,
|
|
113
114
|
description: this.description,
|
|
114
|
-
inputSchema:
|
|
115
|
-
outputSchema:
|
|
115
|
+
inputSchema: this.inputSchema,
|
|
116
|
+
outputSchema: this.outputSchema,
|
|
116
117
|
execute: async ({ context }) => this.execute(context),
|
|
117
118
|
});
|
|
118
119
|
}
|
|
119
120
|
}
|
|
120
121
|
exports.ListDocsTool = ListDocsTool;
|
|
121
|
-
//# sourceMappingURL=list-
|
|
122
|
+
//# sourceMappingURL=list-documents.tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-documents.tool.js","sourceRoot":"","sources":["../../../tools/docs/list-documents.tool.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,8CAAgD;AAChD,4CAAqD;AACrD,kDAAkD;AAElD,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,MAAM,gBAAgB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0CxB,CAAC;AAEF,MAAM,oBAAoB,GAAG;;;;;;;;;;;;;;;;;;;;;CAqB5B,CAAC;AAEF,+EAA+E;AAC/E,UAAU;AACV,+EAA+E;AAE/E,MAAM,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9B,EAAE,EAAE,OAAC;SACF,MAAM,EAAE;SACR,QAAQ,CAAC,6EAA6E,CAAC;IAC1F,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,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AAE,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC;SACtD,CAAC,CAAC;IACL,CAAC;CACF;AAxBD,oCAwBC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { BaseTool,
|
|
2
|
+
import { BaseTool, TMastraTool } from '../base.tool';
|
|
3
3
|
declare const InputSchema: z.ZodObject<{
|
|
4
4
|
query: z.ZodString;
|
|
5
5
|
limit: z.ZodDefault<z.ZodNumber>;
|
|
@@ -14,7 +14,7 @@ declare const OutputSchema: z.ZodObject<{
|
|
|
14
14
|
}, z.core.$strip>>;
|
|
15
15
|
}, z.core.$strip>;
|
|
16
16
|
export declare class SearchDocsTool extends BaseTool<typeof InputSchema, typeof OutputSchema> {
|
|
17
|
-
readonly id = "
|
|
17
|
+
readonly id = "searchDocuments";
|
|
18
18
|
readonly description = "\nPerforms intelligent fuzzy search across the entire Ignis Framework documentation corpus.\n\nPURPOSE:\nUse this tool to find documentation pages relevant to a user's question or topic.\nIt searches both document titles (weighted higher) and content body using the Fuse.js fuzzy matching algorithm.\n\nWHEN TO USE:\n- User asks \"how do I...\" or \"what is...\" questions about Ignis\n- You need to find documentation about a specific feature, concept, or API\n- You want to discover related documentation before diving into specifics\n- User mentions keywords that might appear in documentation\n\nSEARCH BEHAVIOR:\n- Fuzzy matching tolerates typos and partial matches\n- Title matches are weighted 70%, content matches 30%\n- Results sorted by relevance score (lower = better match)\n- Returns snippet previews for quick assessment\n\nWORKFLOW RECOMMENDATION:\n1. Start with searchDocs to find relevant pages\n2. Review returned snippets to identify best matches\n3. Use getDocContent with specific IDs to retrieve full content\n4. Use getDocMetadata if you need document statistics\n\nOUTPUT STRUCTURE:\nReturns array of {id, title, category, snippet, score} objects.\nUse the 'id' field with getDocContent to fetch full document content.\n";
|
|
19
19
|
readonly inputSchema: z.ZodObject<{
|
|
20
20
|
query: z.ZodString;
|
|
@@ -29,8 +29,8 @@ export declare class SearchDocsTool extends BaseTool<typeof InputSchema, typeof
|
|
|
29
29
|
score: z.ZodOptional<z.ZodNumber>;
|
|
30
30
|
}, z.core.$strip>>;
|
|
31
31
|
}, z.core.$strip>;
|
|
32
|
-
execute(
|
|
32
|
+
execute(opts: z.infer<typeof InputSchema>): Promise<z.infer<typeof OutputSchema>>;
|
|
33
33
|
getTool(): TMastraTool;
|
|
34
34
|
}
|
|
35
35
|
export {};
|
|
36
|
-
//# sourceMappingURL=search-
|
|
36
|
+
//# sourceMappingURL=search-documents.tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-documents.tool.d.ts","sourceRoot":"","sources":["../../../tools/docs/search-documents.tool.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAiFrD,QAAA,MAAM,WAAW;;;iBASf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;;;;iBAIhB,CAAC;AAMH,qBAAa,cAAe,SAAQ,QAAQ,CAAC,OAAO,WAAW,EAAE,OAAO,YAAY,CAAC;IACnF,QAAQ,CAAC,EAAE,qBAAqB;IAChC,QAAQ,CAAC,WAAW,kuCAAoB;IACxC,QAAQ,CAAC,WAAW;;;sBAAe;IACnC,QAAQ,CAAC,YAAY;;;;;;;;sBAAgB;IAE/B,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;IAQvF,OAAO,IAAI,WAAW;CASvB"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SearchDocsTool = void 0;
|
|
4
|
+
const common_1 = require("@/mcp-server/common");
|
|
5
|
+
const helpers_1 = require("@/mcp-server/helpers");
|
|
6
|
+
const tools_1 = require("@mastra/core/tools");
|
|
4
7
|
const zod_1 = require("zod");
|
|
5
|
-
const
|
|
6
|
-
const helpers_1 = require("../helpers");
|
|
7
|
-
const base_tool_1 = require("./base.tool");
|
|
8
|
+
const base_tool_1 = require("../base.tool");
|
|
8
9
|
// ----------------------------------------------------------------------------
|
|
9
10
|
// DESCRIPTIONS
|
|
10
11
|
// ----------------------------------------------------------------------------
|
|
@@ -41,7 +42,7 @@ const QUERY_DESCRIPTION = `
|
|
|
41
42
|
Search query string to match against documentation titles and content.
|
|
42
43
|
|
|
43
44
|
REQUIREMENTS:
|
|
44
|
-
- Minimum ${common_1.
|
|
45
|
+
- Minimum ${common_1.MCPConfigs.search.minQueryLength} characters required
|
|
45
46
|
- Supports natural language queries (e.g., "dependency injection setup")
|
|
46
47
|
- Supports technical terms (e.g., "HttpServer middleware")
|
|
47
48
|
- Case-insensitive matching
|
|
@@ -56,8 +57,8 @@ Maximum number of results to return.
|
|
|
56
57
|
|
|
57
58
|
CONSTRAINTS:
|
|
58
59
|
- Minimum: 1
|
|
59
|
-
- Maximum: ${common_1.
|
|
60
|
-
- Default: ${common_1.
|
|
60
|
+
- Maximum: ${common_1.MCPConfigs.search.maxLimit}
|
|
61
|
+
- Default: ${common_1.MCPConfigs.search.defaultLimit}
|
|
61
62
|
|
|
62
63
|
RECOMMENDATIONS:
|
|
63
64
|
- Use default (10) for general queries
|
|
@@ -77,13 +78,13 @@ const SearchResultSchema = zod_1.z.object({
|
|
|
77
78
|
score: zod_1.z.number().optional().describe('Relevance score 0-1 (lower = better match).'),
|
|
78
79
|
});
|
|
79
80
|
const InputSchema = zod_1.z.object({
|
|
80
|
-
query: zod_1.z.string().min(common_1.
|
|
81
|
+
query: zod_1.z.string().min(common_1.MCPConfigs.search.minQueryLength).describe(QUERY_DESCRIPTION),
|
|
81
82
|
limit: zod_1.z
|
|
82
83
|
.number()
|
|
83
84
|
.int()
|
|
84
85
|
.min(1)
|
|
85
|
-
.max(common_1.
|
|
86
|
-
.default(common_1.
|
|
86
|
+
.max(common_1.MCPConfigs.search.maxLimit)
|
|
87
|
+
.default(common_1.MCPConfigs.search.defaultLimit)
|
|
87
88
|
.describe(LIMIT_DESCRIPTION),
|
|
88
89
|
});
|
|
89
90
|
const OutputSchema = zod_1.z.object({
|
|
@@ -97,27 +98,27 @@ const OutputSchema = zod_1.z.object({
|
|
|
97
98
|
class SearchDocsTool extends base_tool_1.BaseTool {
|
|
98
99
|
constructor() {
|
|
99
100
|
super(...arguments);
|
|
100
|
-
this.id = '
|
|
101
|
+
this.id = 'searchDocuments';
|
|
101
102
|
this.description = TOOL_DESCRIPTION;
|
|
102
103
|
this.inputSchema = InputSchema;
|
|
103
104
|
this.outputSchema = OutputSchema;
|
|
104
105
|
}
|
|
105
|
-
async execute(
|
|
106
|
-
const results = await helpers_1.DocsHelper.
|
|
107
|
-
query:
|
|
108
|
-
limit:
|
|
106
|
+
async execute(opts) {
|
|
107
|
+
const results = await helpers_1.DocsHelper.searchDocuments({
|
|
108
|
+
query: opts.query,
|
|
109
|
+
limit: opts.limit,
|
|
109
110
|
});
|
|
110
111
|
return { results };
|
|
111
112
|
}
|
|
112
113
|
getTool() {
|
|
113
|
-
return (0,
|
|
114
|
+
return (0, tools_1.createTool)({
|
|
114
115
|
id: this.id,
|
|
115
116
|
description: this.description,
|
|
116
|
-
inputSchema:
|
|
117
|
-
outputSchema:
|
|
117
|
+
inputSchema: this.inputSchema,
|
|
118
|
+
outputSchema: this.outputSchema,
|
|
118
119
|
execute: async ({ context }) => this.execute(context),
|
|
119
120
|
});
|
|
120
121
|
}
|
|
121
122
|
}
|
|
122
123
|
exports.SearchDocsTool = SearchDocsTool;
|
|
123
|
-
//# sourceMappingURL=search-
|
|
124
|
+
//# sourceMappingURL=search-documents.tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-documents.tool.js","sourceRoot":"","sources":["../../../tools/docs/search-documents.tool.ts"],"names":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,CAAC;AACnC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./list-project-files.tool"), exports);
|
|
18
|
+
__exportStar(require("./search-code.tool"), exports);
|
|
19
|
+
__exportStar(require("./verify-dependencies.tool"), exports);
|
|
20
|
+
__exportStar(require("./view-source-file.tool"), exports);
|
|
21
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../tools/github/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4DAA0C;AAC1C,qDAAmC;AACnC,6DAA2C;AAC3C,0DAAwC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { BaseTool, TMastraTool } from '../base.tool';
|
|
3
|
+
declare const InputSchema: z.ZodObject<{
|
|
4
|
+
directoryPath: z.ZodDefault<z.ZodString>;
|
|
5
|
+
}, z.core.$strip>;
|
|
6
|
+
declare const OutputSchema: z.ZodObject<{
|
|
7
|
+
directoryPath: z.ZodString;
|
|
8
|
+
files: z.ZodArray<z.ZodString>;
|
|
9
|
+
directories: z.ZodArray<z.ZodString>;
|
|
10
|
+
error: z.ZodOptional<z.ZodString>;
|
|
11
|
+
}, z.core.$strip>;
|
|
12
|
+
export declare class ListProjectFilesTool extends BaseTool<typeof InputSchema, typeof OutputSchema> {
|
|
13
|
+
readonly id = "listProjectFiles";
|
|
14
|
+
readonly description = "\nLists files and directories within the Ignis GitHub repository.\n\nPURPOSE:\nExplore the project structure, discover source code files, and navigate the monorepo.\nPrimary tool for understanding codebase layout before reading specific files.\n\nWHEN TO USE:\n- To understand overall project structure\n- To find location of specific modules (e.g., \"where are the controllers?\")\n- To get list of files in a directory before using viewSourceFile\n- To find configuration files, examples, or documentation\n\nWHEN NOT TO USE:\n- When searching for specific code patterns or keywords (use searchCode instead)\n- When you need to read a file's content (use viewSourceFile instead)\n- For documentation content (use searchDocs, listDocs, getDocContent instead)\n\nWORKFLOW:\n1. Start at root: listProjectFiles()\n2. Explore a package: listProjectFiles({ directoryPath: \"packages/core/src\" })\n3. Identify a file of interest\n4. Read the file: viewSourceFile({ filePath: \"packages/core/src/application.ts\" })\n";
|
|
15
|
+
readonly inputSchema: z.ZodObject<{
|
|
16
|
+
directoryPath: z.ZodDefault<z.ZodString>;
|
|
17
|
+
}, z.core.$strip>;
|
|
18
|
+
readonly outputSchema: z.ZodObject<{
|
|
19
|
+
directoryPath: z.ZodString;
|
|
20
|
+
files: z.ZodArray<z.ZodString>;
|
|
21
|
+
directories: z.ZodArray<z.ZodString>;
|
|
22
|
+
error: z.ZodOptional<z.ZodString>;
|
|
23
|
+
}, z.core.$strip>;
|
|
24
|
+
execute(opts: z.infer<typeof InputSchema>): Promise<z.infer<typeof OutputSchema>>;
|
|
25
|
+
getTool(): TMastraTool;
|
|
26
|
+
}
|
|
27
|
+
export {};
|
|
28
|
+
//# sourceMappingURL=list-project-files.tool.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-project-files.tool.d.ts","sourceRoot":"","sources":["../../../tools/github/list-project-files.tool.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AA8CrD,QAAA,MAAM,WAAW;;iBAEf,CAAC;AAEH,QAAA,MAAM,YAAY;;;;;iBAOhB,CAAC;AAMH,qBAAa,oBAAqB,SAAQ,QAAQ,CAAC,OAAO,WAAW,EAAE,OAAO,YAAY,CAAC;IACzF,QAAQ,CAAC,EAAE,sBAAsB;IACjC,QAAQ,CAAC,WAAW,0/BAAoB;IACxC,QAAQ,CAAC,WAAW;;sBAAe;IACnC,QAAQ,CAAC,YAAY;;;;;sBAAgB;IAE/B,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;IAuBvF,OAAO,IAAI,WAAW;CASvB"}
|