agentool 1.0.0 → 1.1.1
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/README.md +132 -21
- package/dist/ask-user/index.cjs +5 -2
- package/dist/ask-user/index.d.cts +10 -1
- package/dist/ask-user/index.d.ts +10 -1
- package/dist/ask-user/index.js +5 -2
- package/dist/bash/index.cjs +5 -2
- package/dist/bash/index.d.cts +14 -1
- package/dist/bash/index.d.ts +14 -1
- package/dist/bash/index.js +5 -2
- package/dist/chunk-2JBLVFB7.cjs +74 -0
- package/dist/{chunk-K77GC2QI.js → chunk-2JF3ZF2J.js} +32 -2
- package/dist/{chunk-XKG2A3EW.js → chunk-2WSZCOJP.js} +54 -18
- package/dist/chunk-3FT4ZPB2.cjs +65 -0
- package/dist/{chunk-VLNDEVKS.js → chunk-3LGXZLBH.js} +46 -8
- package/dist/{chunk-G3ITTPGX.js → chunk-4MXDQEPA.js} +12 -1
- package/dist/{chunk-CGTPF6IS.js → chunk-4UUSERSH.js} +31 -7
- package/dist/{chunk-I6KFFQPV.cjs → chunk-5T3SQYI4.cjs} +34 -4
- package/dist/chunk-6ULQG2W2.cjs +99 -0
- package/dist/chunk-ABXTBB2N.cjs +67 -0
- package/dist/{chunk-CAEVLIQB.cjs → chunk-BIAODQ2P.cjs} +17 -1
- package/dist/chunk-CJA76MKM.js +59 -0
- package/dist/chunk-CM3VRCNX.cjs +59 -0
- package/dist/{chunk-SUSAPI5W.cjs → chunk-CXBWF5ON.cjs} +51 -4
- package/dist/{chunk-U2YMJM25.cjs → chunk-G6ZVJA4V.cjs} +31 -8
- package/dist/chunk-GPHCXS2S.js +99 -0
- package/dist/chunk-HG5T47NA.cjs +77 -0
- package/dist/chunk-HO4NIRU5.js +65 -0
- package/dist/{chunk-HZAQRHBT.js → chunk-IBC4QCGR.js} +27 -2
- package/dist/chunk-JYTOARJV.cjs +69 -0
- package/dist/chunk-KONXT2SF.cjs +8 -0
- package/dist/chunk-KUFZFNPT.cjs +61 -0
- package/dist/chunk-L7R4UZSK.js +61 -0
- package/dist/{chunk-FV2R5FFQ.cjs → chunk-LNAR3NJQ.cjs} +47 -9
- package/dist/chunk-M74OQYNK.js +69 -0
- package/dist/{chunk-IMZQ7ELK.cjs → chunk-NQIV6LBH.cjs} +51 -14
- package/dist/chunk-NTGDU5X3.js +67 -0
- package/dist/{chunk-ONBH74ZV.cjs → chunk-OYLTQJXT.cjs} +32 -8
- package/dist/{chunk-6PQLFDGT.js → chunk-PWBVB6MN.js} +17 -1
- package/dist/{chunk-QEJV2KZ4.cjs → chunk-RIGL3JTS.cjs} +55 -19
- package/dist/chunk-SFDZRLSX.cjs +91 -0
- package/dist/chunk-T6STO7PS.cjs +126 -0
- package/dist/{chunk-LPV5CN2K.js → chunk-TI4ZZ3IJ.js} +32 -2
- package/dist/chunk-TM5L4HA5.js +126 -0
- package/dist/{chunk-4YI2H55A.js → chunk-TXZ3BMMR.js} +49 -2
- package/dist/chunk-UCA6LURO.js +74 -0
- package/dist/{chunk-EA3YV7ZG.js → chunk-VE4U27HI.js} +35 -15
- package/dist/chunk-VHLY7LQE.js +53 -0
- package/dist/{chunk-FW3UJ622.cjs → chunk-VPRUYL4T.cjs} +34 -4
- package/dist/{chunk-3VO6NETR.cjs → chunk-VPV6WG5V.cjs} +41 -21
- package/dist/chunk-VQSWMGG7.cjs +53 -0
- package/dist/{chunk-Y7KOKDFP.js → chunk-VZRXTFS4.js} +29 -6
- package/dist/chunk-WCR62UZ3.js +67 -0
- package/dist/chunk-X6ZY2KFU.js +8 -0
- package/dist/chunk-XGDE7S2D.cjs +67 -0
- package/dist/chunk-XPTW45XY.js +77 -0
- package/dist/{chunk-YPPPGGLA.cjs → chunk-YCWJVQYO.cjs} +28 -3
- package/dist/chunk-YGXLT6SS.js +91 -0
- package/dist/{chunk-5NW4OGRI.cjs → chunk-YTPZHJDC.cjs} +12 -1
- package/dist/{chunk-6MDPYALY.js → chunk-ZHVRP3EH.js} +49 -12
- package/dist/context-compaction/index.cjs +5 -2
- package/dist/context-compaction/index.d.cts +11 -1
- package/dist/context-compaction/index.d.ts +11 -1
- package/dist/context-compaction/index.js +5 -2
- package/dist/diff/index.cjs +6 -2
- package/dist/diff/index.d.cts +12 -2
- package/dist/diff/index.d.ts +12 -2
- package/dist/diff/index.js +7 -3
- package/dist/edit/index.cjs +7 -3
- package/dist/edit/index.d.cts +15 -5
- package/dist/edit/index.d.ts +15 -5
- package/dist/edit/index.js +8 -4
- package/dist/glob/index.cjs +5 -2
- package/dist/glob/index.d.cts +13 -3
- package/dist/glob/index.d.ts +13 -3
- package/dist/glob/index.js +5 -2
- package/dist/grep/index.cjs +6 -2
- package/dist/grep/index.d.cts +13 -3
- package/dist/grep/index.d.ts +13 -3
- package/dist/grep/index.js +6 -2
- package/dist/http-request/index.cjs +5 -2
- package/dist/http-request/index.d.cts +11 -1
- package/dist/http-request/index.d.ts +11 -1
- package/dist/http-request/index.js +5 -2
- package/dist/index.cjs +93 -19
- package/dist/index.d.cts +21 -16
- package/dist/index.d.ts +21 -16
- package/dist/index.js +113 -39
- package/dist/lsp/index.cjs +6 -2
- package/dist/lsp/index.d.cts +16 -10
- package/dist/lsp/index.d.ts +16 -10
- package/dist/lsp/index.js +6 -2
- package/dist/memory/index.cjs +6 -2
- package/dist/memory/index.d.cts +10 -1
- package/dist/memory/index.d.ts +10 -1
- package/dist/memory/index.js +6 -2
- package/dist/multi-edit/index.cjs +7 -4
- package/dist/multi-edit/index.d.cts +12 -2
- package/dist/multi-edit/index.d.ts +12 -2
- package/dist/multi-edit/index.js +7 -4
- package/dist/read/index.cjs +6 -3
- package/dist/read/index.d.cts +11 -1
- package/dist/read/index.d.ts +11 -1
- package/dist/read/index.js +6 -3
- package/dist/sleep/index.cjs +5 -2
- package/dist/sleep/index.d.cts +11 -1
- package/dist/sleep/index.d.ts +11 -1
- package/dist/sleep/index.js +5 -2
- package/dist/task-create/index.cjs +13 -0
- package/dist/task-create/index.d.cts +28 -0
- package/dist/task-create/index.d.ts +28 -0
- package/dist/task-create/index.js +13 -0
- package/dist/task-get/index.cjs +13 -0
- package/dist/task-get/index.d.cts +24 -0
- package/dist/task-get/index.d.ts +24 -0
- package/dist/task-get/index.js +13 -0
- package/dist/task-list/index.cjs +13 -0
- package/dist/task-list/index.d.cts +20 -0
- package/dist/task-list/index.d.ts +20 -0
- package/dist/task-list/index.js +13 -0
- package/dist/task-update/index.cjs +13 -0
- package/dist/task-update/index.d.cts +40 -0
- package/dist/task-update/index.d.ts +40 -0
- package/dist/task-update/index.js +13 -0
- package/dist/tool-search/index.cjs +11 -0
- package/dist/tool-search/index.d.cts +27 -0
- package/dist/tool-search/index.d.ts +27 -0
- package/dist/tool-search/index.js +11 -0
- package/dist/web-fetch/index.cjs +5 -2
- package/dist/web-fetch/index.d.cts +11 -3
- package/dist/web-fetch/index.d.ts +11 -3
- package/dist/web-fetch/index.js +5 -2
- package/dist/web-search/index.cjs +11 -0
- package/dist/web-search/index.d.cts +30 -0
- package/dist/web-search/index.d.ts +30 -0
- package/dist/web-search/index.js +11 -0
- package/dist/write/index.cjs +6 -3
- package/dist/write/index.d.cts +13 -3
- package/dist/write/index.d.ts +13 -3
- package/dist/write/index.js +6 -3
- package/package.json +31 -6
- package/dist/chunk-3EPGFWZV.cjs +0 -30
- package/dist/chunk-7QL4BQCH.js +0 -40
- package/dist/chunk-FAEGCFTO.js +0 -136
- package/dist/chunk-HDKXSKMO.js +0 -30
- package/dist/chunk-JCTBB7H2.cjs +0 -40
- package/dist/chunk-MF7CJVIZ.js +0 -40
- package/dist/chunk-MXFW3XY6.cjs +0 -73
- package/dist/chunk-OXLQ7QVL.cjs +0 -40
- package/dist/chunk-S6QEY7UY.js +0 -73
- package/dist/chunk-TBVHHF3H.cjs +0 -47
- package/dist/chunk-XLD2Y3SS.cjs +0 -136
- package/dist/chunk-ZHCMEQJJ.js +0 -47
- package/dist/task/index.cjs +0 -8
- package/dist/task/index.d.cts +0 -67
- package/dist/task/index.d.ts +0 -67
- package/dist/task/index.js +0 -8
package/dist/index.js
CHANGED
|
@@ -1,75 +1,121 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
createMemory,
|
|
7
|
-
memory
|
|
8
|
-
} from "./chunk-VLNDEVKS.js";
|
|
9
|
-
import {
|
|
10
|
-
createMultiEdit,
|
|
11
|
-
multiEdit
|
|
12
|
-
} from "./chunk-EA3YV7ZG.js";
|
|
13
|
-
import {
|
|
14
|
-
createDiff,
|
|
15
|
-
diff
|
|
16
|
-
} from "./chunk-CGTPF6IS.js";
|
|
17
|
-
import {
|
|
18
|
-
createTask,
|
|
19
|
-
task
|
|
20
|
-
} from "./chunk-FAEGCFTO.js";
|
|
2
|
+
createToolSearch,
|
|
3
|
+
getPrompt as getPrompt16,
|
|
4
|
+
toolSearch
|
|
5
|
+
} from "./chunk-UCA6LURO.js";
|
|
21
6
|
import {
|
|
22
7
|
createLsp,
|
|
8
|
+
getPrompt as getPrompt17,
|
|
23
9
|
lsp
|
|
24
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-ZHVRP3EH.js";
|
|
25
11
|
import {
|
|
26
12
|
createHttpRequest,
|
|
13
|
+
getPrompt as getPrompt18,
|
|
27
14
|
httpRequest
|
|
28
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-TI4ZZ3IJ.js";
|
|
29
16
|
import {
|
|
30
17
|
contextCompaction,
|
|
31
|
-
createContextCompaction
|
|
32
|
-
|
|
18
|
+
createContextCompaction,
|
|
19
|
+
getPrompt as getPrompt19
|
|
20
|
+
} from "./chunk-2JF3ZF2J.js";
|
|
33
21
|
import {
|
|
34
22
|
askUser,
|
|
35
|
-
createAskUser
|
|
36
|
-
|
|
23
|
+
createAskUser,
|
|
24
|
+
getPrompt as getPrompt20
|
|
25
|
+
} from "./chunk-L7R4UZSK.js";
|
|
26
|
+
import {
|
|
27
|
+
createSleep,
|
|
28
|
+
getPrompt as getPrompt21,
|
|
29
|
+
sleep
|
|
30
|
+
} from "./chunk-M74OQYNK.js";
|
|
31
|
+
import {
|
|
32
|
+
createMemory,
|
|
33
|
+
getPrompt as getPrompt8,
|
|
34
|
+
memory
|
|
35
|
+
} from "./chunk-3LGXZLBH.js";
|
|
36
|
+
import {
|
|
37
|
+
createMultiEdit,
|
|
38
|
+
getPrompt as getPrompt9,
|
|
39
|
+
multiEdit
|
|
40
|
+
} from "./chunk-VE4U27HI.js";
|
|
41
|
+
import {
|
|
42
|
+
createDiff,
|
|
43
|
+
diff,
|
|
44
|
+
getPrompt as getPrompt10
|
|
45
|
+
} from "./chunk-4UUSERSH.js";
|
|
46
|
+
import {
|
|
47
|
+
createTaskCreate,
|
|
48
|
+
getPrompt as getPrompt11,
|
|
49
|
+
taskCreate
|
|
50
|
+
} from "./chunk-YGXLT6SS.js";
|
|
51
|
+
import {
|
|
52
|
+
createTaskGet,
|
|
53
|
+
getPrompt as getPrompt12,
|
|
54
|
+
taskGet
|
|
55
|
+
} from "./chunk-WCR62UZ3.js";
|
|
56
|
+
import {
|
|
57
|
+
createTaskUpdate,
|
|
58
|
+
getPrompt as getPrompt13,
|
|
59
|
+
taskUpdate
|
|
60
|
+
} from "./chunk-TM5L4HA5.js";
|
|
61
|
+
import {
|
|
62
|
+
createTaskList,
|
|
63
|
+
getPrompt as getPrompt14,
|
|
64
|
+
taskList
|
|
65
|
+
} from "./chunk-HO4NIRU5.js";
|
|
66
|
+
import "./chunk-VHLY7LQE.js";
|
|
67
|
+
import {
|
|
68
|
+
createWebSearch,
|
|
69
|
+
getPrompt as getPrompt15,
|
|
70
|
+
webSearch
|
|
71
|
+
} from "./chunk-CJA76MKM.js";
|
|
37
72
|
import {
|
|
38
73
|
bash,
|
|
39
|
-
createBash
|
|
40
|
-
|
|
74
|
+
createBash,
|
|
75
|
+
getPrompt
|
|
76
|
+
} from "./chunk-TXZ3BMMR.js";
|
|
41
77
|
import {
|
|
42
78
|
createGrep,
|
|
79
|
+
getPrompt as getPrompt2,
|
|
43
80
|
grep
|
|
44
|
-
} from "./chunk-
|
|
81
|
+
} from "./chunk-2WSZCOJP.js";
|
|
45
82
|
import {
|
|
46
83
|
createGlob,
|
|
84
|
+
getPrompt as getPrompt3,
|
|
47
85
|
glob
|
|
48
|
-
} from "./chunk-
|
|
86
|
+
} from "./chunk-IBC4QCGR.js";
|
|
49
87
|
import "./chunk-MJCAXASI.js";
|
|
50
88
|
import {
|
|
51
89
|
createRead,
|
|
90
|
+
getPrompt as getPrompt4,
|
|
52
91
|
read
|
|
53
|
-
} from "./chunk-
|
|
92
|
+
} from "./chunk-XPTW45XY.js";
|
|
54
93
|
import {
|
|
55
94
|
createEdit,
|
|
56
|
-
edit
|
|
57
|
-
|
|
58
|
-
|
|
95
|
+
edit,
|
|
96
|
+
getPrompt as getPrompt5
|
|
97
|
+
} from "./chunk-GPHCXS2S.js";
|
|
98
|
+
import "./chunk-4MXDQEPA.js";
|
|
59
99
|
import {
|
|
60
100
|
createWrite,
|
|
101
|
+
getPrompt as getPrompt6,
|
|
61
102
|
write
|
|
62
|
-
} from "./chunk-
|
|
63
|
-
import "./chunk-
|
|
103
|
+
} from "./chunk-NTGDU5X3.js";
|
|
104
|
+
import "./chunk-PWBVB6MN.js";
|
|
64
105
|
import "./chunk-I3ONDY7P.js";
|
|
65
106
|
import {
|
|
66
107
|
createWebFetch,
|
|
108
|
+
getPrompt as getPrompt7,
|
|
67
109
|
webFetch
|
|
68
|
-
} from "./chunk-
|
|
110
|
+
} from "./chunk-VZRXTFS4.js";
|
|
111
|
+
import "./chunk-X6ZY2KFU.js";
|
|
69
112
|
export {
|
|
70
113
|
askUser,
|
|
114
|
+
getPrompt20 as askUserPrompt,
|
|
71
115
|
bash,
|
|
116
|
+
getPrompt as bashPrompt,
|
|
72
117
|
contextCompaction,
|
|
118
|
+
getPrompt19 as contextCompactionPrompt,
|
|
73
119
|
createAskUser,
|
|
74
120
|
createBash,
|
|
75
121
|
createContextCompaction,
|
|
@@ -83,20 +129,48 @@ export {
|
|
|
83
129
|
createMultiEdit,
|
|
84
130
|
createRead,
|
|
85
131
|
createSleep,
|
|
86
|
-
|
|
132
|
+
createTaskCreate,
|
|
133
|
+
createTaskGet,
|
|
134
|
+
createTaskList,
|
|
135
|
+
createTaskUpdate,
|
|
136
|
+
createToolSearch,
|
|
87
137
|
createWebFetch,
|
|
138
|
+
createWebSearch,
|
|
88
139
|
createWrite,
|
|
89
140
|
diff,
|
|
141
|
+
getPrompt10 as diffPrompt,
|
|
90
142
|
edit,
|
|
143
|
+
getPrompt5 as editPrompt,
|
|
91
144
|
glob,
|
|
145
|
+
getPrompt3 as globPrompt,
|
|
92
146
|
grep,
|
|
147
|
+
getPrompt2 as grepPrompt,
|
|
93
148
|
httpRequest,
|
|
149
|
+
getPrompt18 as httpRequestPrompt,
|
|
94
150
|
lsp,
|
|
151
|
+
getPrompt17 as lspPrompt,
|
|
95
152
|
memory,
|
|
153
|
+
getPrompt8 as memoryPrompt,
|
|
96
154
|
multiEdit,
|
|
155
|
+
getPrompt9 as multiEditPrompt,
|
|
97
156
|
read,
|
|
157
|
+
getPrompt4 as readPrompt,
|
|
98
158
|
sleep,
|
|
99
|
-
|
|
159
|
+
getPrompt21 as sleepPrompt,
|
|
160
|
+
taskCreate,
|
|
161
|
+
getPrompt11 as taskCreatePrompt,
|
|
162
|
+
taskGet,
|
|
163
|
+
getPrompt12 as taskGetPrompt,
|
|
164
|
+
taskList,
|
|
165
|
+
getPrompt14 as taskListPrompt,
|
|
166
|
+
taskUpdate,
|
|
167
|
+
getPrompt13 as taskUpdatePrompt,
|
|
168
|
+
toolSearch,
|
|
169
|
+
getPrompt16 as toolSearchPrompt,
|
|
100
170
|
webFetch,
|
|
101
|
-
|
|
171
|
+
getPrompt7 as webFetchPrompt,
|
|
172
|
+
webSearch,
|
|
173
|
+
getPrompt15 as webSearchPrompt,
|
|
174
|
+
write,
|
|
175
|
+
getPrompt6 as writePrompt
|
|
102
176
|
};
|
package/dist/lsp/index.cjs
CHANGED
|
@@ -2,9 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var _chunkIMZQ7ELKcjs = require('../chunk-IMZQ7ELK.cjs');
|
|
6
5
|
|
|
6
|
+
var _chunkNQIV6LBHcjs = require('../chunk-NQIV6LBH.cjs');
|
|
7
|
+
require('../chunk-BIAODQ2P.cjs');
|
|
8
|
+
require('../chunk-KONXT2SF.cjs');
|
|
7
9
|
|
|
8
10
|
|
|
9
11
|
|
|
10
|
-
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
exports.createLsp = _chunkNQIV6LBHcjs.createLsp; exports.executeLspOperation = _chunkNQIV6LBHcjs.executeLspOperation; exports.lsp = _chunkNQIV6LBHcjs.lsp; exports.lspPrompt = _chunkNQIV6LBHcjs.getPrompt;
|
package/dist/lsp/index.d.cts
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the LSP tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the LSP tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
interface LspServerConfig {
|
|
5
12
|
command: string;
|
|
6
13
|
args?: string[];
|
|
@@ -8,31 +15,30 @@ interface LspServerConfig {
|
|
|
8
15
|
interface LspConfig extends BaseToolConfig {
|
|
9
16
|
servers?: Record<string, LspServerConfig>;
|
|
10
17
|
timeout?: number;
|
|
18
|
+
/** Override the default tool description. */
|
|
19
|
+
description?: string;
|
|
11
20
|
}
|
|
12
21
|
interface LspRequest {
|
|
13
22
|
operation: string;
|
|
14
23
|
filePath: string;
|
|
15
24
|
line?: number;
|
|
16
25
|
character?: number;
|
|
17
|
-
query?: string;
|
|
18
26
|
cwd: string;
|
|
19
27
|
}
|
|
20
28
|
declare function executeLspOperation(serverConfig: LspServerConfig, params: LspRequest, timeoutMs: number): Promise<string>;
|
|
21
29
|
/** Creates an LSP tool that performs language server operations. */
|
|
22
30
|
declare function createLsp(config?: LspConfig): ai.Tool<{
|
|
23
|
-
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "incomingCalls" | "outgoingCalls";
|
|
31
|
+
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "prepareCallHierarchy" | "incomingCalls" | "outgoingCalls";
|
|
24
32
|
filePath: string;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
character?: number | undefined;
|
|
33
|
+
line: number;
|
|
34
|
+
character: number;
|
|
28
35
|
}, string>;
|
|
29
36
|
/** Default LSP tool instance with no servers configured. */
|
|
30
37
|
declare const lsp: ai.Tool<{
|
|
31
|
-
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "incomingCalls" | "outgoingCalls";
|
|
38
|
+
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "prepareCallHierarchy" | "incomingCalls" | "outgoingCalls";
|
|
32
39
|
filePath: string;
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
character?: number | undefined;
|
|
40
|
+
line: number;
|
|
41
|
+
character: number;
|
|
36
42
|
}, string>;
|
|
37
43
|
|
|
38
|
-
export { type LspConfig, type LspServerConfig, createLsp, executeLspOperation, lsp };
|
|
44
|
+
export { type LspConfig, type LspServerConfig, createLsp, executeLspOperation, lsp, getPrompt as lspPrompt };
|
package/dist/lsp/index.d.ts
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the LSP tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the LSP tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
interface LspServerConfig {
|
|
5
12
|
command: string;
|
|
6
13
|
args?: string[];
|
|
@@ -8,31 +15,30 @@ interface LspServerConfig {
|
|
|
8
15
|
interface LspConfig extends BaseToolConfig {
|
|
9
16
|
servers?: Record<string, LspServerConfig>;
|
|
10
17
|
timeout?: number;
|
|
18
|
+
/** Override the default tool description. */
|
|
19
|
+
description?: string;
|
|
11
20
|
}
|
|
12
21
|
interface LspRequest {
|
|
13
22
|
operation: string;
|
|
14
23
|
filePath: string;
|
|
15
24
|
line?: number;
|
|
16
25
|
character?: number;
|
|
17
|
-
query?: string;
|
|
18
26
|
cwd: string;
|
|
19
27
|
}
|
|
20
28
|
declare function executeLspOperation(serverConfig: LspServerConfig, params: LspRequest, timeoutMs: number): Promise<string>;
|
|
21
29
|
/** Creates an LSP tool that performs language server operations. */
|
|
22
30
|
declare function createLsp(config?: LspConfig): ai.Tool<{
|
|
23
|
-
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "incomingCalls" | "outgoingCalls";
|
|
31
|
+
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "prepareCallHierarchy" | "incomingCalls" | "outgoingCalls";
|
|
24
32
|
filePath: string;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
character?: number | undefined;
|
|
33
|
+
line: number;
|
|
34
|
+
character: number;
|
|
28
35
|
}, string>;
|
|
29
36
|
/** Default LSP tool instance with no servers configured. */
|
|
30
37
|
declare const lsp: ai.Tool<{
|
|
31
|
-
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "incomingCalls" | "outgoingCalls";
|
|
38
|
+
operation: "goToDefinition" | "findReferences" | "hover" | "documentSymbol" | "workspaceSymbol" | "goToImplementation" | "prepareCallHierarchy" | "incomingCalls" | "outgoingCalls";
|
|
32
39
|
filePath: string;
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
character?: number | undefined;
|
|
40
|
+
line: number;
|
|
41
|
+
character: number;
|
|
36
42
|
}, string>;
|
|
37
43
|
|
|
38
|
-
export { type LspConfig, type LspServerConfig, createLsp, executeLspOperation, lsp };
|
|
44
|
+
export { type LspConfig, type LspServerConfig, createLsp, executeLspOperation, lsp, getPrompt as lspPrompt };
|
package/dist/lsp/index.js
CHANGED
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createLsp,
|
|
3
3
|
executeLspOperation,
|
|
4
|
+
getPrompt,
|
|
4
5
|
lsp
|
|
5
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-ZHVRP3EH.js";
|
|
7
|
+
import "../chunk-PWBVB6MN.js";
|
|
8
|
+
import "../chunk-X6ZY2KFU.js";
|
|
6
9
|
export {
|
|
7
10
|
createLsp,
|
|
8
11
|
executeLspOperation,
|
|
9
|
-
lsp
|
|
12
|
+
lsp,
|
|
13
|
+
getPrompt as lspPrompt
|
|
10
14
|
};
|
package/dist/memory/index.cjs
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
|
|
5
|
+
var _chunkLNAR3NJQcjs = require('../chunk-LNAR3NJQ.cjs');
|
|
6
|
+
require('../chunk-BIAODQ2P.cjs');
|
|
5
7
|
require('../chunk-QZ5GS6HW.cjs');
|
|
8
|
+
require('../chunk-KONXT2SF.cjs');
|
|
9
|
+
|
|
6
10
|
|
|
7
11
|
|
|
8
12
|
|
|
9
|
-
exports.createMemory =
|
|
13
|
+
exports.createMemory = _chunkLNAR3NJQcjs.createMemory; exports.memory = _chunkLNAR3NJQcjs.memory; exports.memoryPrompt = _chunkLNAR3NJQcjs.getPrompt;
|
package/dist/memory/index.d.cts
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the memory tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the memory tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
/**
|
|
5
12
|
* Configuration for the memory tool.
|
|
6
13
|
* Extends {@link BaseToolConfig} with an optional memory directory path.
|
|
@@ -14,6 +21,8 @@ import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
|
14
21
|
interface MemoryConfig extends BaseToolConfig {
|
|
15
22
|
/** Directory for memory files. Defaults to `<cwd>/.agentool/memory`. */
|
|
16
23
|
memoryDir?: string;
|
|
24
|
+
/** Override the default tool description. */
|
|
25
|
+
description?: string;
|
|
17
26
|
}
|
|
18
27
|
/**
|
|
19
28
|
* Creates a memory tool that provides file-based key-value storage.
|
|
@@ -60,4 +69,4 @@ declare const memory: ai.Tool<{
|
|
|
60
69
|
key?: string | undefined;
|
|
61
70
|
}, string>;
|
|
62
71
|
|
|
63
|
-
export { type MemoryConfig, createMemory, memory };
|
|
72
|
+
export { type MemoryConfig, createMemory, memory, getPrompt as memoryPrompt };
|
package/dist/memory/index.d.ts
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the memory tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the memory tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
/**
|
|
5
12
|
* Configuration for the memory tool.
|
|
6
13
|
* Extends {@link BaseToolConfig} with an optional memory directory path.
|
|
@@ -14,6 +21,8 @@ import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
|
14
21
|
interface MemoryConfig extends BaseToolConfig {
|
|
15
22
|
/** Directory for memory files. Defaults to `<cwd>/.agentool/memory`. */
|
|
16
23
|
memoryDir?: string;
|
|
24
|
+
/** Override the default tool description. */
|
|
25
|
+
description?: string;
|
|
17
26
|
}
|
|
18
27
|
/**
|
|
19
28
|
* Creates a memory tool that provides file-based key-value storage.
|
|
@@ -60,4 +69,4 @@ declare const memory: ai.Tool<{
|
|
|
60
69
|
key?: string | undefined;
|
|
61
70
|
}, string>;
|
|
62
71
|
|
|
63
|
-
export { type MemoryConfig, createMemory, memory };
|
|
72
|
+
export { type MemoryConfig, createMemory, memory, getPrompt as memoryPrompt };
|
package/dist/memory/index.js
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createMemory,
|
|
3
|
+
getPrompt,
|
|
3
4
|
memory
|
|
4
|
-
} from "../chunk-
|
|
5
|
+
} from "../chunk-3LGXZLBH.js";
|
|
6
|
+
import "../chunk-PWBVB6MN.js";
|
|
5
7
|
import "../chunk-I3ONDY7P.js";
|
|
8
|
+
import "../chunk-X6ZY2KFU.js";
|
|
6
9
|
export {
|
|
7
10
|
createMemory,
|
|
8
|
-
memory
|
|
11
|
+
memory,
|
|
12
|
+
getPrompt as memoryPrompt
|
|
9
13
|
};
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
require('../chunk-
|
|
6
|
-
require('../chunk-
|
|
4
|
+
|
|
5
|
+
var _chunkVPV6WG5Vcjs = require('../chunk-VPV6WG5V.cjs');
|
|
6
|
+
require('../chunk-YTPZHJDC.cjs');
|
|
7
|
+
require('../chunk-BIAODQ2P.cjs');
|
|
7
8
|
require('../chunk-QZ5GS6HW.cjs');
|
|
9
|
+
require('../chunk-KONXT2SF.cjs');
|
|
10
|
+
|
|
8
11
|
|
|
9
12
|
|
|
10
13
|
|
|
11
|
-
exports.createMultiEdit =
|
|
14
|
+
exports.createMultiEdit = _chunkVPV6WG5Vcjs.createMultiEdit; exports.multiEdit = _chunkVPV6WG5Vcjs.multiEdit; exports.multiEditPrompt = _chunkVPV6WG5Vcjs.getPrompt;
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the multi-edit tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the multi-edit tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
/**
|
|
5
12
|
* Configuration for the multi-edit tool.
|
|
6
13
|
*
|
|
@@ -10,7 +17,10 @@ import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
|
10
17
|
* const config: MultiEditConfig = { cwd: '/my/project' };
|
|
11
18
|
* ```
|
|
12
19
|
*/
|
|
13
|
-
type MultiEditConfig = BaseToolConfig
|
|
20
|
+
type MultiEditConfig = BaseToolConfig & {
|
|
21
|
+
/** Override the default tool description. */
|
|
22
|
+
description?: string;
|
|
23
|
+
};
|
|
14
24
|
/**
|
|
15
25
|
* Creates a multi-edit tool that atomically applies multiple string
|
|
16
26
|
* replacements to a single file.
|
|
@@ -69,4 +79,4 @@ declare const multiEdit: ai.Tool<{
|
|
|
69
79
|
}[];
|
|
70
80
|
}, string>;
|
|
71
81
|
|
|
72
|
-
export { type MultiEditConfig, createMultiEdit, multiEdit };
|
|
82
|
+
export { type MultiEditConfig, createMultiEdit, multiEdit, getPrompt as multiEditPrompt };
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the multi-edit tool.
|
|
6
|
+
*
|
|
7
|
+
* @returns The full description string for the multi-edit tool.
|
|
8
|
+
*/
|
|
9
|
+
declare function getPrompt(): string;
|
|
10
|
+
|
|
4
11
|
/**
|
|
5
12
|
* Configuration for the multi-edit tool.
|
|
6
13
|
*
|
|
@@ -10,7 +17,10 @@ import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
|
10
17
|
* const config: MultiEditConfig = { cwd: '/my/project' };
|
|
11
18
|
* ```
|
|
12
19
|
*/
|
|
13
|
-
type MultiEditConfig = BaseToolConfig
|
|
20
|
+
type MultiEditConfig = BaseToolConfig & {
|
|
21
|
+
/** Override the default tool description. */
|
|
22
|
+
description?: string;
|
|
23
|
+
};
|
|
14
24
|
/**
|
|
15
25
|
* Creates a multi-edit tool that atomically applies multiple string
|
|
16
26
|
* replacements to a single file.
|
|
@@ -69,4 +79,4 @@ declare const multiEdit: ai.Tool<{
|
|
|
69
79
|
}[];
|
|
70
80
|
}, string>;
|
|
71
81
|
|
|
72
|
-
export { type MultiEditConfig, createMultiEdit, multiEdit };
|
|
82
|
+
export { type MultiEditConfig, createMultiEdit, multiEdit, getPrompt as multiEditPrompt };
|
package/dist/multi-edit/index.js
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createMultiEdit,
|
|
3
|
+
getPrompt,
|
|
3
4
|
multiEdit
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-VE4U27HI.js";
|
|
6
|
+
import "../chunk-4MXDQEPA.js";
|
|
7
|
+
import "../chunk-PWBVB6MN.js";
|
|
7
8
|
import "../chunk-I3ONDY7P.js";
|
|
9
|
+
import "../chunk-X6ZY2KFU.js";
|
|
8
10
|
export {
|
|
9
11
|
createMultiEdit,
|
|
10
|
-
multiEdit
|
|
12
|
+
multiEdit,
|
|
13
|
+
getPrompt as multiEditPrompt
|
|
11
14
|
};
|
package/dist/read/index.cjs
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
require('../chunk-
|
|
4
|
+
|
|
5
|
+
var _chunkHG5T47NAcjs = require('../chunk-HG5T47NA.cjs');
|
|
6
|
+
require('../chunk-BIAODQ2P.cjs');
|
|
6
7
|
require('../chunk-QZ5GS6HW.cjs');
|
|
8
|
+
require('../chunk-KONXT2SF.cjs');
|
|
9
|
+
|
|
7
10
|
|
|
8
11
|
|
|
9
12
|
|
|
10
|
-
exports.createRead =
|
|
13
|
+
exports.createRead = _chunkHG5T47NAcjs.createRead; exports.read = _chunkHG5T47NAcjs.read; exports.readPrompt = _chunkHG5T47NAcjs.getPrompt;
|
package/dist/read/index.d.cts
CHANGED
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.cjs';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the read tool based on its configuration.
|
|
6
|
+
*
|
|
7
|
+
* @param config - The same config passed to {@link createRead}.
|
|
8
|
+
* @returns The full description string for the read tool.
|
|
9
|
+
*/
|
|
10
|
+
declare function getPrompt(config?: Pick<ReadConfig, 'maxLines'>): string;
|
|
11
|
+
|
|
4
12
|
/**
|
|
5
13
|
* Configuration for the read tool.
|
|
6
14
|
* Extends {@link BaseToolConfig} with an optional maximum line count.
|
|
@@ -17,6 +25,8 @@ interface ReadConfig extends BaseToolConfig {
|
|
|
17
25
|
* @default 2000
|
|
18
26
|
*/
|
|
19
27
|
maxLines?: number;
|
|
28
|
+
/** Override the default tool description. */
|
|
29
|
+
description?: string;
|
|
20
30
|
}
|
|
21
31
|
/**
|
|
22
32
|
* Creates a read tool that reads file contents with line numbers.
|
|
@@ -64,4 +74,4 @@ declare const read: ai.Tool<{
|
|
|
64
74
|
limit?: number | undefined;
|
|
65
75
|
}, string>;
|
|
66
76
|
|
|
67
|
-
export { type ReadConfig, createRead, read };
|
|
77
|
+
export { type ReadConfig, createRead, read, getPrompt as readPrompt };
|
package/dist/read/index.d.ts
CHANGED
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import * as ai from 'ai';
|
|
2
2
|
import { B as BaseToolConfig } from '../types-3QPDuCXN.js';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Generate the description prompt for the read tool based on its configuration.
|
|
6
|
+
*
|
|
7
|
+
* @param config - The same config passed to {@link createRead}.
|
|
8
|
+
* @returns The full description string for the read tool.
|
|
9
|
+
*/
|
|
10
|
+
declare function getPrompt(config?: Pick<ReadConfig, 'maxLines'>): string;
|
|
11
|
+
|
|
4
12
|
/**
|
|
5
13
|
* Configuration for the read tool.
|
|
6
14
|
* Extends {@link BaseToolConfig} with an optional maximum line count.
|
|
@@ -17,6 +25,8 @@ interface ReadConfig extends BaseToolConfig {
|
|
|
17
25
|
* @default 2000
|
|
18
26
|
*/
|
|
19
27
|
maxLines?: number;
|
|
28
|
+
/** Override the default tool description. */
|
|
29
|
+
description?: string;
|
|
20
30
|
}
|
|
21
31
|
/**
|
|
22
32
|
* Creates a read tool that reads file contents with line numbers.
|
|
@@ -64,4 +74,4 @@ declare const read: ai.Tool<{
|
|
|
64
74
|
limit?: number | undefined;
|
|
65
75
|
}, string>;
|
|
66
76
|
|
|
67
|
-
export { type ReadConfig, createRead, read };
|
|
77
|
+
export { type ReadConfig, createRead, read, getPrompt as readPrompt };
|
package/dist/read/index.js
CHANGED
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createRead,
|
|
3
|
+
getPrompt,
|
|
3
4
|
read
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-XPTW45XY.js";
|
|
6
|
+
import "../chunk-PWBVB6MN.js";
|
|
6
7
|
import "../chunk-I3ONDY7P.js";
|
|
8
|
+
import "../chunk-X6ZY2KFU.js";
|
|
7
9
|
export {
|
|
8
10
|
createRead,
|
|
9
|
-
read
|
|
11
|
+
read,
|
|
12
|
+
getPrompt as readPrompt
|
|
10
13
|
};
|
package/dist/sleep/index.cjs
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var _chunkOXLQ7QVLcjs = require('../chunk-OXLQ7QVL.cjs');
|
|
5
4
|
|
|
5
|
+
var _chunkJYTOARJVcjs = require('../chunk-JYTOARJV.cjs');
|
|
6
|
+
require('../chunk-KONXT2SF.cjs');
|
|
6
7
|
|
|
7
8
|
|
|
8
|
-
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
exports.createSleep = _chunkJYTOARJVcjs.createSleep; exports.sleep = _chunkJYTOARJVcjs.sleep; exports.sleepPrompt = _chunkJYTOARJVcjs.getPrompt;
|