erosolar-cli 1.7.76 → 1.7.78
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/dist/capabilities/filesystemCapability.d.ts.map +1 -1
- package/dist/capabilities/filesystemCapability.js +2 -1
- package/dist/capabilities/filesystemCapability.js.map +1 -1
- package/dist/shell/systemPrompt.d.ts.map +1 -1
- package/dist/shell/systemPrompt.js +6 -2
- package/dist/shell/systemPrompt.js.map +1 -1
- package/dist/tools/exploreTools.d.ts +7 -0
- package/dist/tools/exploreTools.d.ts.map +1 -0
- package/dist/tools/exploreTools.js +322 -0
- package/dist/tools/exploreTools.js.map +1 -0
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filesystemCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/filesystemCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"filesystemCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/filesystemCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAI3G,MAAM,WAAW,2BAA2B;IAC1C,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,qBAAa,0BAA2B,YAAW,gBAAgB;IACjE,QAAQ,CAAC,EAAE,2BAA2B;IACtC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA8B;gBAE1C,OAAO,GAAE,2BAAgC;IAI/C,MAAM,CAAC,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,sBAAsB,CAAC;CAe1E"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { createFileTools } from '../tools/fileTools.js';
|
|
2
|
+
import { createExploreTools } from '../tools/exploreTools.js';
|
|
2
3
|
export class FilesystemCapabilityModule {
|
|
3
4
|
id = 'capability.filesystem';
|
|
4
5
|
options;
|
|
@@ -13,7 +14,7 @@ export class FilesystemCapabilityModule {
|
|
|
13
14
|
toolSuite: {
|
|
14
15
|
id: 'fs',
|
|
15
16
|
description: 'File operations',
|
|
16
|
-
tools: createFileTools(workingDir),
|
|
17
|
+
tools: [...createFileTools(workingDir), ...createExploreTools(workingDir)],
|
|
17
18
|
},
|
|
18
19
|
metadata: {
|
|
19
20
|
workingDir,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filesystemCapability.js","sourceRoot":"","sources":["../../src/capabilities/filesystemCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"filesystemCapability.js","sourceRoot":"","sources":["../../src/capabilities/filesystemCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAQ9D,MAAM,OAAO,0BAA0B;IAC5B,EAAE,GAAG,uBAAuB,CAAC;IACrB,OAAO,CAA8B;IAEtD,YAAY,UAAuC,EAAE;QACnD,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,MAAM,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,IAAI,OAAO,CAAC,UAAU,CAAC;QACjE,OAAO;YACL,EAAE,EAAE,IAAI,CAAC,OAAO,CAAC,EAAE,IAAI,wBAAwB;YAC/C,WAAW,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,IAAI,6DAA6D;YACtG,SAAS,EAAE;gBACT,EAAE,EAAE,IAAI;gBACR,WAAW,EAAE,iBAAiB;gBAC9B,KAAK,EAAE,CAAC,GAAG,eAAe,CAAC,UAAU,CAAC,EAAE,GAAG,kBAAkB,CAAC,UAAU,CAAC,CAAC;aAC3E;YACD,QAAQ,EAAE;gBACR,UAAU;aACX;SACF,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"systemPrompt.d.ts","sourceRoot":"","sources":["../../src/shell/systemPrompt.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAE/D,wBAAgB,4BAA4B,CAC1C,UAAU,EAAE,MAAM,EAClB,YAAY,EAAE,MAAM,EACpB,KAAK,EAAE,sBAAsB,EAAE,EAC/B,YAAY,CAAC,EAAE,MAAM,GACpB,MAAM,
|
|
1
|
+
{"version":3,"file":"systemPrompt.d.ts","sourceRoot":"","sources":["../../src/shell/systemPrompt.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAE/D,wBAAgB,4BAA4B,CAC1C,UAAU,EAAE,MAAM,EAClB,YAAY,EAAE,MAAM,EACpB,KAAK,EAAE,sBAAsB,EAAE,EAC/B,YAAY,CAAC,EAAE,MAAM,GACpB,MAAM,CAmBR"}
|
|
@@ -2,7 +2,7 @@ export function buildInteractiveSystemPrompt(basePrompt, profileLabel, tools, wo
|
|
|
2
2
|
const name = profileLabel || 'Agent';
|
|
3
3
|
const toolNames = tools.map(t => t.name).join(', ');
|
|
4
4
|
const workspace = workspaceDir || process.cwd();
|
|
5
|
-
//
|
|
5
|
+
// Balanced prompt - efficient for simple tasks, thorough for complex ones
|
|
6
6
|
return `${basePrompt}
|
|
7
7
|
|
|
8
8
|
You are ${name}. Workspace: ${workspace}
|
|
@@ -10,7 +10,11 @@ Tools: ${toolNames}
|
|
|
10
10
|
|
|
11
11
|
RULES:
|
|
12
12
|
- Act immediately. No preamble.
|
|
13
|
-
-
|
|
13
|
+
- Use 'explore' tool first for repo questions - it returns README, package info, and structure in ONE call.
|
|
14
|
+
- Scale effort to task complexity:
|
|
15
|
+
• Simple questions → explore tool or 1-2 reads
|
|
16
|
+
• Code changes → read relevant files, implement thoroughly
|
|
17
|
+
• Complex tasks → explore, plan if needed, execute completely
|
|
14
18
|
- Read before edit, combine commands`;
|
|
15
19
|
}
|
|
16
20
|
//# sourceMappingURL=systemPrompt.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"systemPrompt.js","sourceRoot":"","sources":["../../src/shell/systemPrompt.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,4BAA4B,CAC1C,UAAkB,EAClB,YAAoB,EACpB,KAA+B,EAC/B,YAAqB;IAErB,MAAM,IAAI,GAAG,YAAY,IAAI,OAAO,CAAC;IACrC,MAAM,SAAS,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACpD,MAAM,SAAS,GAAG,YAAY,IAAI,OAAO,CAAC,GAAG,EAAE,CAAC;IAEhD,
|
|
1
|
+
{"version":3,"file":"systemPrompt.js","sourceRoot":"","sources":["../../src/shell/systemPrompt.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,4BAA4B,CAC1C,UAAkB,EAClB,YAAoB,EACpB,KAA+B,EAC/B,YAAqB;IAErB,MAAM,IAAI,GAAG,YAAY,IAAI,OAAO,CAAC;IACrC,MAAM,SAAS,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACpD,MAAM,SAAS,GAAG,YAAY,IAAI,OAAO,CAAC,GAAG,EAAE,CAAC;IAEhD,0EAA0E;IAC1E,OAAO,GAAG,UAAU;;UAEZ,IAAI,gBAAgB,SAAS;SAC9B,SAAS;;;;;;;;;qCASmB,CAAC;AACtC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ToolDefinition } from '../core/toolRuntime.js';
|
|
2
|
+
/**
|
|
3
|
+
* Creates an Explore tool for efficient codebase discovery.
|
|
4
|
+
* Single tool call to understand a repo's structure, purpose, and key files.
|
|
5
|
+
*/
|
|
6
|
+
export declare function createExploreTools(workingDir: string): ToolDefinition[];
|
|
7
|
+
//# sourceMappingURL=exploreTools.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exploreTools.d.ts","sourceRoot":"","sources":["../../src/tools/exploreTools.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAE7D;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,MAAM,GAAG,cAAc,EAAE,CAkEvE"}
|
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
import { readFileSync, readdirSync, statSync, existsSync } from 'node:fs';
|
|
2
|
+
import { join, relative, extname } from 'node:path';
|
|
3
|
+
/**
|
|
4
|
+
* Creates an Explore tool for efficient codebase discovery.
|
|
5
|
+
* Single tool call to understand a repo's structure, purpose, and key files.
|
|
6
|
+
*/
|
|
7
|
+
export function createExploreTools(workingDir) {
|
|
8
|
+
return [
|
|
9
|
+
{
|
|
10
|
+
name: 'explore',
|
|
11
|
+
description: 'Quickly understand a codebase. Returns structure, README summary, package info, and key entry points in ONE call. Use this first when asked about a repo.',
|
|
12
|
+
parameters: {
|
|
13
|
+
type: 'object',
|
|
14
|
+
properties: {
|
|
15
|
+
depth: {
|
|
16
|
+
type: 'string',
|
|
17
|
+
enum: ['quick', 'normal', 'deep'],
|
|
18
|
+
description: 'quick: README + package.json only. normal: + structure + entry points. deep: + sample code from key files.',
|
|
19
|
+
},
|
|
20
|
+
focus: {
|
|
21
|
+
type: 'string',
|
|
22
|
+
description: 'Optional: focus area (e.g., "api", "tests", "config"). Filters results to relevant paths.',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
additionalProperties: false,
|
|
26
|
+
},
|
|
27
|
+
handler: async (args) => {
|
|
28
|
+
const depth = normalizeDepth(args['depth']);
|
|
29
|
+
const focus = typeof args['focus'] === 'string' ? args['focus'].toLowerCase() : undefined;
|
|
30
|
+
const sections = [];
|
|
31
|
+
// Always include README summary
|
|
32
|
+
const readme = findAndSummarizeReadme(workingDir);
|
|
33
|
+
if (readme) {
|
|
34
|
+
sections.push(`## README Summary\n${readme}`);
|
|
35
|
+
}
|
|
36
|
+
// Always include package info
|
|
37
|
+
const pkgInfo = getPackageInfo(workingDir);
|
|
38
|
+
if (pkgInfo) {
|
|
39
|
+
sections.push(`## Package Info\n${pkgInfo}`);
|
|
40
|
+
}
|
|
41
|
+
// Normal and deep: add structure
|
|
42
|
+
if (depth !== 'quick') {
|
|
43
|
+
const structure = getDirectoryStructure(workingDir, focus);
|
|
44
|
+
sections.push(`## Structure\n${structure}`);
|
|
45
|
+
// Find entry points
|
|
46
|
+
const entryPoints = findEntryPoints(workingDir);
|
|
47
|
+
if (entryPoints.length > 0) {
|
|
48
|
+
sections.push(`## Entry Points\n${entryPoints.join('\n')}`);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
// Deep: add code samples
|
|
52
|
+
if (depth === 'deep') {
|
|
53
|
+
const samples = getCodeSamples(workingDir, focus);
|
|
54
|
+
if (samples) {
|
|
55
|
+
sections.push(`## Key Code\n${samples}`);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
if (sections.length === 0) {
|
|
59
|
+
return 'No information found. This may not be a standard code repository.';
|
|
60
|
+
}
|
|
61
|
+
return sections.join('\n\n');
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
];
|
|
65
|
+
}
|
|
66
|
+
function normalizeDepth(value) {
|
|
67
|
+
if (value === 'quick' || value === 'deep') {
|
|
68
|
+
return value;
|
|
69
|
+
}
|
|
70
|
+
return 'normal';
|
|
71
|
+
}
|
|
72
|
+
function findAndSummarizeReadme(dir) {
|
|
73
|
+
const readmeNames = ['README.md', 'readme.md', 'README', 'README.txt', 'README.rst'];
|
|
74
|
+
for (const name of readmeNames) {
|
|
75
|
+
const path = join(dir, name);
|
|
76
|
+
if (existsSync(path)) {
|
|
77
|
+
try {
|
|
78
|
+
const content = readFileSync(path, 'utf-8');
|
|
79
|
+
// Return first 1500 chars (usually contains purpose and getting started)
|
|
80
|
+
const summary = content.slice(0, 1500);
|
|
81
|
+
return summary.length < content.length ? summary + '\n...(truncated)' : summary;
|
|
82
|
+
}
|
|
83
|
+
catch {
|
|
84
|
+
return null;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
return null;
|
|
89
|
+
}
|
|
90
|
+
function getPackageInfo(dir) {
|
|
91
|
+
const packagePath = join(dir, 'package.json');
|
|
92
|
+
if (!existsSync(packagePath)) {
|
|
93
|
+
// Try pyproject.toml, Cargo.toml, go.mod
|
|
94
|
+
return getAlternativePackageInfo(dir);
|
|
95
|
+
}
|
|
96
|
+
try {
|
|
97
|
+
const pkg = JSON.parse(readFileSync(packagePath, 'utf-8'));
|
|
98
|
+
const lines = [];
|
|
99
|
+
if (pkg.name)
|
|
100
|
+
lines.push(`Name: ${pkg.name}`);
|
|
101
|
+
if (pkg.version)
|
|
102
|
+
lines.push(`Version: ${pkg.version}`);
|
|
103
|
+
if (pkg.description)
|
|
104
|
+
lines.push(`Description: ${pkg.description}`);
|
|
105
|
+
if (pkg.scripts) {
|
|
106
|
+
const scripts = Object.keys(pkg.scripts).slice(0, 8);
|
|
107
|
+
lines.push(`Scripts: ${scripts.join(', ')}`);
|
|
108
|
+
}
|
|
109
|
+
if (pkg.dependencies) {
|
|
110
|
+
const deps = Object.keys(pkg.dependencies).slice(0, 10);
|
|
111
|
+
lines.push(`Dependencies: ${deps.join(', ')}${Object.keys(pkg.dependencies).length > 10 ? '...' : ''}`);
|
|
112
|
+
}
|
|
113
|
+
return lines.join('\n');
|
|
114
|
+
}
|
|
115
|
+
catch {
|
|
116
|
+
return null;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
function getAlternativePackageInfo(dir) {
|
|
120
|
+
// Python
|
|
121
|
+
const pyproject = join(dir, 'pyproject.toml');
|
|
122
|
+
if (existsSync(pyproject)) {
|
|
123
|
+
try {
|
|
124
|
+
const content = readFileSync(pyproject, 'utf-8');
|
|
125
|
+
const nameMatch = content.match(/name\s*=\s*"([^"]+)"/);
|
|
126
|
+
const versionMatch = content.match(/version\s*=\s*"([^"]+)"/);
|
|
127
|
+
const lines = ['Type: Python project'];
|
|
128
|
+
if (nameMatch)
|
|
129
|
+
lines.push(`Name: ${nameMatch[1]}`);
|
|
130
|
+
if (versionMatch)
|
|
131
|
+
lines.push(`Version: ${versionMatch[1]}`);
|
|
132
|
+
return lines.join('\n');
|
|
133
|
+
}
|
|
134
|
+
catch {
|
|
135
|
+
return null;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
// Rust
|
|
139
|
+
const cargoToml = join(dir, 'Cargo.toml');
|
|
140
|
+
if (existsSync(cargoToml)) {
|
|
141
|
+
try {
|
|
142
|
+
const content = readFileSync(cargoToml, 'utf-8');
|
|
143
|
+
const nameMatch = content.match(/name\s*=\s*"([^"]+)"/);
|
|
144
|
+
return `Type: Rust project${nameMatch ? `\nName: ${nameMatch[1]}` : ''}`;
|
|
145
|
+
}
|
|
146
|
+
catch {
|
|
147
|
+
return null;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
// Go
|
|
151
|
+
const goMod = join(dir, 'go.mod');
|
|
152
|
+
if (existsSync(goMod)) {
|
|
153
|
+
try {
|
|
154
|
+
const content = readFileSync(goMod, 'utf-8');
|
|
155
|
+
const moduleMatch = content.match(/module\s+(\S+)/);
|
|
156
|
+
return `Type: Go project${moduleMatch ? `\nModule: ${moduleMatch[1]}` : ''}`;
|
|
157
|
+
}
|
|
158
|
+
catch {
|
|
159
|
+
return null;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
return null;
|
|
163
|
+
}
|
|
164
|
+
function getDirectoryStructure(dir, focus) {
|
|
165
|
+
const ignored = new Set(['.git', 'node_modules', 'dist', '.next', 'build', 'coverage', '__pycache__', '.venv', 'venv', 'target']);
|
|
166
|
+
const lines = [];
|
|
167
|
+
const maxEntries = 50;
|
|
168
|
+
let count = 0;
|
|
169
|
+
function walk(currentDir, depth, prefix) {
|
|
170
|
+
if (depth > 3 || count >= maxEntries)
|
|
171
|
+
return;
|
|
172
|
+
try {
|
|
173
|
+
const entries = readdirSync(currentDir, { withFileTypes: true })
|
|
174
|
+
.filter(e => !ignored.has(e.name) && !e.name.startsWith('.'))
|
|
175
|
+
.sort((a, b) => {
|
|
176
|
+
// Directories first
|
|
177
|
+
if (a.isDirectory() && !b.isDirectory())
|
|
178
|
+
return -1;
|
|
179
|
+
if (!a.isDirectory() && b.isDirectory())
|
|
180
|
+
return 1;
|
|
181
|
+
return a.name.localeCompare(b.name);
|
|
182
|
+
});
|
|
183
|
+
for (const entry of entries) {
|
|
184
|
+
if (count >= maxEntries) {
|
|
185
|
+
lines.push(`${prefix}... (truncated)`);
|
|
186
|
+
return;
|
|
187
|
+
}
|
|
188
|
+
const fullPath = join(currentDir, entry.name);
|
|
189
|
+
const relPath = relative(dir, fullPath);
|
|
190
|
+
// Focus filter
|
|
191
|
+
if (focus && !relPath.toLowerCase().includes(focus) && !entry.name.toLowerCase().includes(focus)) {
|
|
192
|
+
if (entry.isDirectory()) {
|
|
193
|
+
// Still walk into directories to find focused content
|
|
194
|
+
walk(fullPath, depth + 1, prefix + ' ');
|
|
195
|
+
}
|
|
196
|
+
continue;
|
|
197
|
+
}
|
|
198
|
+
count++;
|
|
199
|
+
if (entry.isDirectory()) {
|
|
200
|
+
lines.push(`${prefix}${entry.name}/`);
|
|
201
|
+
walk(fullPath, depth + 1, prefix + ' ');
|
|
202
|
+
}
|
|
203
|
+
else {
|
|
204
|
+
const stats = statSync(fullPath);
|
|
205
|
+
const size = formatSize(stats.size);
|
|
206
|
+
lines.push(`${prefix}${entry.name} (${size})`);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
catch {
|
|
211
|
+
// Ignore errors
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
walk(dir, 0, '');
|
|
215
|
+
return lines.length > 0 ? lines.join('\n') : '(empty or no accessible files)';
|
|
216
|
+
}
|
|
217
|
+
function findEntryPoints(dir) {
|
|
218
|
+
const entryPoints = [];
|
|
219
|
+
// Check package.json for main/bin
|
|
220
|
+
const packagePath = join(dir, 'package.json');
|
|
221
|
+
if (existsSync(packagePath)) {
|
|
222
|
+
try {
|
|
223
|
+
const pkg = JSON.parse(readFileSync(packagePath, 'utf-8'));
|
|
224
|
+
if (pkg.main)
|
|
225
|
+
entryPoints.push(`main: ${pkg.main}`);
|
|
226
|
+
if (pkg.bin) {
|
|
227
|
+
if (typeof pkg.bin === 'string') {
|
|
228
|
+
entryPoints.push(`bin: ${pkg.bin}`);
|
|
229
|
+
}
|
|
230
|
+
else {
|
|
231
|
+
entryPoints.push(`bin: ${Object.values(pkg.bin).slice(0, 3).join(', ')}`);
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
catch {
|
|
236
|
+
// Ignore
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
// Look for common entry files
|
|
240
|
+
const commonEntries = [
|
|
241
|
+
'src/index.ts', 'src/index.js', 'src/main.ts', 'src/main.js',
|
|
242
|
+
'index.ts', 'index.js', 'main.ts', 'main.js',
|
|
243
|
+
'src/app.ts', 'src/app.js', 'app.ts', 'app.js',
|
|
244
|
+
'src/bin/cli.ts', 'src/bin/cli.js', 'bin/cli.ts', 'bin/cli.js',
|
|
245
|
+
'lib/index.ts', 'lib/index.js',
|
|
246
|
+
];
|
|
247
|
+
for (const entry of commonEntries) {
|
|
248
|
+
if (existsSync(join(dir, entry))) {
|
|
249
|
+
entryPoints.push(`file: ${entry}`);
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
return [...new Set(entryPoints)].slice(0, 5);
|
|
253
|
+
}
|
|
254
|
+
function getCodeSamples(dir, focus) {
|
|
255
|
+
const samples = [];
|
|
256
|
+
const codeExtensions = new Set(['.ts', '.js', '.tsx', '.jsx', '.py', '.go', '.rs']);
|
|
257
|
+
// Find key files to sample
|
|
258
|
+
const targetFiles = [];
|
|
259
|
+
// Focus-specific or entry point files
|
|
260
|
+
if (focus) {
|
|
261
|
+
findFilesWithPattern(dir, focus, codeExtensions, targetFiles, 3);
|
|
262
|
+
}
|
|
263
|
+
// Always try to include main entry
|
|
264
|
+
const mainFiles = ['src/index.ts', 'src/main.ts', 'index.ts', 'main.ts', 'src/index.js'];
|
|
265
|
+
for (const f of mainFiles) {
|
|
266
|
+
const path = join(dir, f);
|
|
267
|
+
if (existsSync(path) && !targetFiles.includes(path)) {
|
|
268
|
+
targetFiles.push(path);
|
|
269
|
+
break;
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
// Sample each file
|
|
273
|
+
for (const file of targetFiles.slice(0, 2)) {
|
|
274
|
+
try {
|
|
275
|
+
const content = readFileSync(file, 'utf-8');
|
|
276
|
+
const lines = content.split('\n').slice(0, 30); // First 30 lines
|
|
277
|
+
const relPath = relative(dir, file);
|
|
278
|
+
samples.push(`### ${relPath}\n\`\`\`\n${lines.join('\n')}\n\`\`\``);
|
|
279
|
+
}
|
|
280
|
+
catch {
|
|
281
|
+
// Ignore
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
return samples.length > 0 ? samples.join('\n\n') : null;
|
|
285
|
+
}
|
|
286
|
+
function findFilesWithPattern(dir, pattern, extensions, results, max) {
|
|
287
|
+
const ignored = new Set(['.git', 'node_modules', 'dist', '.next', 'build', 'coverage']);
|
|
288
|
+
function walk(currentDir, depth) {
|
|
289
|
+
if (depth > 4 || results.length >= max)
|
|
290
|
+
return;
|
|
291
|
+
try {
|
|
292
|
+
const entries = readdirSync(currentDir, { withFileTypes: true });
|
|
293
|
+
for (const entry of entries) {
|
|
294
|
+
if (ignored.has(entry.name))
|
|
295
|
+
continue;
|
|
296
|
+
if (results.length >= max)
|
|
297
|
+
return;
|
|
298
|
+
const fullPath = join(currentDir, entry.name);
|
|
299
|
+
if (entry.isDirectory()) {
|
|
300
|
+
walk(fullPath, depth + 1);
|
|
301
|
+
}
|
|
302
|
+
else if (extensions.has(extname(entry.name)) &&
|
|
303
|
+
(entry.name.toLowerCase().includes(pattern) ||
|
|
304
|
+
relative(dir, fullPath).toLowerCase().includes(pattern))) {
|
|
305
|
+
results.push(fullPath);
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
catch {
|
|
310
|
+
// Ignore
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
walk(dir, 0);
|
|
314
|
+
}
|
|
315
|
+
function formatSize(bytes) {
|
|
316
|
+
if (bytes < 1024)
|
|
317
|
+
return `${bytes}B`;
|
|
318
|
+
if (bytes < 1024 * 1024)
|
|
319
|
+
return `${(bytes / 1024).toFixed(1)}KB`;
|
|
320
|
+
return `${(bytes / (1024 * 1024)).toFixed(1)}MB`;
|
|
321
|
+
}
|
|
322
|
+
//# sourceMappingURL=exploreTools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exploreTools.js","sourceRoot":"","sources":["../../src/tools/exploreTools.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAGpD;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,UAAkB;IACnD,OAAO;QACL;YACE,IAAI,EAAE,SAAS;YACf,WAAW,EAAE,2JAA2J;YACxK,UAAU,EAAE;gBACV,IAAI,EAAE,QAAQ;gBACd,UAAU,EAAE;oB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C,CAAC,CAAC;gBAC5B,CAAC;qBAAM,IACL,UAAU,CAAC,GAAG,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;oBACnC,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,OAAO,CAAC;wBACzC,QAAQ,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,EAC1D,CAAC;oBACD,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACzB,CAAC;YACH,CAAC;QACH,CAAC;QAAC,MAAM,CAAC;YACP,SAAS;QACX,CAAC;IACH,CAAC;IAED,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;AACf,CAAC;AAED,SAAS,UAAU,CAAC,KAAa;IAC/B,IAAI,KAAK,GAAG,IAAI;QAAE,OAAO,GAAG,KAAK,GAAG,CAAC;IACrC,IAAI,KAAK,GAAG,IAAI,GAAG,IAAI;QAAE,OAAO,GAAG,CAAC,KAAK,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC;IACjE,OAAO,GAAG,CAAC,KAAK,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC;AACnD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "erosolar-cli",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.78",
|
|
4
4
|
"description": "Unified AI agent framework for the command line - Multi-provider support with schema-driven tools, code intelligence, and transparent reasoning",
|
|
5
5
|
"main": "dist/bin/erosolar.js",
|
|
6
6
|
"type": "module",
|