@tangle-network/agent-provider-tangle 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +12 -0
- package/dist/index.d.ts +51 -0
- package/dist/index.js +321 -0
- package/package.json +55 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Tangle Network
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# @tangle-network/agent-provider-tangle
|
|
2
|
+
|
|
3
|
+
Wraps `@tangle-network/sandbox` as an `AgentEnvironmentProvider`.
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
import { Sandbox } from '@tangle-network/sandbox'
|
|
7
|
+
import { createTangleProvider } from '@tangle-network/agent-provider-tangle'
|
|
8
|
+
|
|
9
|
+
const provider = createTangleProvider({
|
|
10
|
+
client: new Sandbox({ apiKey: process.env.TANGLE_API_KEY }),
|
|
11
|
+
})
|
|
12
|
+
```
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import type { BackendType, CreateSandboxOptions, ExecResult as SandboxExecResult, PromptOptions, PromptResult, SandboxEvent } from "@tangle-network/sandbox";
|
|
2
|
+
import type { AgentEnvironmentCapabilities, AgentEnvironmentProvider, CreateAgentEnvironmentInput } from "@tangle-network/agent-interface/environment-provider";
|
|
3
|
+
import type { InputPart } from "@tangle-network/agent-interface";
|
|
4
|
+
export interface SandboxClientLike {
|
|
5
|
+
create(options?: CreateSandboxOptions): Promise<SandboxInstanceLike>;
|
|
6
|
+
get?(id: string): Promise<SandboxInstanceLike | null>;
|
|
7
|
+
list?(options?: unknown): Promise<SandboxInstanceLike[]>;
|
|
8
|
+
describePlacement?(box: SandboxInstanceLike): unknown;
|
|
9
|
+
}
|
|
10
|
+
export interface SandboxInstanceLike {
|
|
11
|
+
id: string;
|
|
12
|
+
name?: string;
|
|
13
|
+
status?: unknown;
|
|
14
|
+
metadata?: Record<string, unknown>;
|
|
15
|
+
streamPrompt(message: string | InputPart[], options?: PromptOptions): AsyncIterable<SandboxEvent>;
|
|
16
|
+
prompt?(message: string | InputPart[], options?: PromptOptions): Promise<PromptResult>;
|
|
17
|
+
dispatchPrompt?(message: string | InputPart[], options?: PromptOptions): Promise<unknown>;
|
|
18
|
+
session?(id: string): SandboxSessionLike;
|
|
19
|
+
read?(path: string, options?: {
|
|
20
|
+
sessionId?: string;
|
|
21
|
+
}): Promise<string>;
|
|
22
|
+
write?(path: string, content: string, options?: {
|
|
23
|
+
sessionId?: string;
|
|
24
|
+
}): Promise<void>;
|
|
25
|
+
exec?(command: string, options?: unknown): Promise<SandboxExecResult>;
|
|
26
|
+
checkpoint?(options?: unknown): Promise<unknown>;
|
|
27
|
+
fork?(checkpointId: string, options?: unknown): Promise<SandboxInstanceLike>;
|
|
28
|
+
refresh?(): Promise<void>;
|
|
29
|
+
delete?(): Promise<void>;
|
|
30
|
+
}
|
|
31
|
+
export interface SandboxSessionLike {
|
|
32
|
+
readonly id: string;
|
|
33
|
+
status(): Promise<unknown | null>;
|
|
34
|
+
events(options?: {
|
|
35
|
+
since?: string;
|
|
36
|
+
signal?: AbortSignal;
|
|
37
|
+
}): AsyncIterable<SandboxEvent>;
|
|
38
|
+
result(): Promise<PromptResult>;
|
|
39
|
+
prompt(message: string | InputPart[], options?: PromptOptions): Promise<PromptResult>;
|
|
40
|
+
cancel(): Promise<void>;
|
|
41
|
+
}
|
|
42
|
+
export interface TangleProviderOptions {
|
|
43
|
+
client: SandboxClientLike;
|
|
44
|
+
name?: string;
|
|
45
|
+
defaultBackend?: BackendType;
|
|
46
|
+
capabilities?: AgentEnvironmentCapabilities | (() => AgentEnvironmentCapabilities | Promise<AgentEnvironmentCapabilities>);
|
|
47
|
+
validateProfile?: AgentEnvironmentProvider["validateProfile"];
|
|
48
|
+
mapCreateInput?: (input: CreateAgentEnvironmentInput) => CreateSandboxOptions;
|
|
49
|
+
}
|
|
50
|
+
export declare function createTangleProvider(options: TangleProviderOptions): AgentEnvironmentProvider;
|
|
51
|
+
export declare function defaultTangleSandboxCapabilities(): AgentEnvironmentCapabilities;
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,321 @@
|
|
|
1
|
+
export function createTangleProvider(options) {
|
|
2
|
+
const providerName = options.name ?? "tangle-sandbox";
|
|
3
|
+
return {
|
|
4
|
+
name: providerName,
|
|
5
|
+
capabilities: async () => {
|
|
6
|
+
if (!options.capabilities)
|
|
7
|
+
return defaultTangleSandboxCapabilities();
|
|
8
|
+
return typeof options.capabilities === "function" ? options.capabilities() : options.capabilities;
|
|
9
|
+
},
|
|
10
|
+
...(options.validateProfile ? { validateProfile: options.validateProfile } : {}),
|
|
11
|
+
async create(input) {
|
|
12
|
+
const createOptions = options.mapCreateInput?.(input) ??
|
|
13
|
+
sandboxOptionsFromCreateInput(input, options.defaultBackend ?? "opencode");
|
|
14
|
+
const box = await options.client.create(createOptions);
|
|
15
|
+
return sandboxInstanceAsEnvironment(box, providerName, options.client);
|
|
16
|
+
},
|
|
17
|
+
...(options.client.get
|
|
18
|
+
? {
|
|
19
|
+
async get(id) {
|
|
20
|
+
const box = await options.client.get?.(id);
|
|
21
|
+
return box ? sandboxInstanceAsEnvironment(box, providerName, options.client) : null;
|
|
22
|
+
},
|
|
23
|
+
}
|
|
24
|
+
: {}),
|
|
25
|
+
...(options.client.list
|
|
26
|
+
? {
|
|
27
|
+
async list(query) {
|
|
28
|
+
const boxes = await options.client.list?.(query?.providerOptions);
|
|
29
|
+
return (boxes ?? []).map((box) => ({
|
|
30
|
+
id: String(box.id),
|
|
31
|
+
provider: providerName,
|
|
32
|
+
...(box.name ? { name: box.name } : {}),
|
|
33
|
+
status: statusFromUnknown(box.status),
|
|
34
|
+
...(box.metadata ? { metadata: box.metadata } : {}),
|
|
35
|
+
}));
|
|
36
|
+
},
|
|
37
|
+
}
|
|
38
|
+
: {}),
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function sandboxInstanceAsEnvironment(box, providerName, client) {
|
|
42
|
+
return {
|
|
43
|
+
id: String(box.id),
|
|
44
|
+
provider: providerName,
|
|
45
|
+
...(box.name ? { name: box.name } : {}),
|
|
46
|
+
async status() {
|
|
47
|
+
await box.refresh?.();
|
|
48
|
+
return statusFromUnknown(box.status);
|
|
49
|
+
},
|
|
50
|
+
async *stream(input) {
|
|
51
|
+
for await (const event of box.streamPrompt(promptFromTurnInput(input), promptOptionsFromTurnInput(input))) {
|
|
52
|
+
yield environmentEventFromSandboxEvent(event);
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
...(box.dispatchPrompt
|
|
56
|
+
? {
|
|
57
|
+
async dispatch(input) {
|
|
58
|
+
const dispatched = await box.dispatchPrompt?.(promptFromTurnInput(input), promptOptionsFromTurnInput(input));
|
|
59
|
+
return sessionRefFromSandboxDispatch(dispatched, providerName);
|
|
60
|
+
},
|
|
61
|
+
}
|
|
62
|
+
: {}),
|
|
63
|
+
...(box.session
|
|
64
|
+
? {
|
|
65
|
+
session(id) {
|
|
66
|
+
const session = box.session?.(id);
|
|
67
|
+
if (!session)
|
|
68
|
+
throw new Error("sandbox session(id) returned undefined");
|
|
69
|
+
return sandboxSessionAsAgentSession(session);
|
|
70
|
+
},
|
|
71
|
+
}
|
|
72
|
+
: {}),
|
|
73
|
+
...(box.read ? { read: box.read.bind(box) } : {}),
|
|
74
|
+
...(box.write ? { write: box.write.bind(box) } : {}),
|
|
75
|
+
...(box.exec
|
|
76
|
+
? {
|
|
77
|
+
async exec(command, options) {
|
|
78
|
+
return execResultFromSandboxExecResult(await box.exec?.(command, options));
|
|
79
|
+
},
|
|
80
|
+
}
|
|
81
|
+
: {}),
|
|
82
|
+
...(box.checkpoint
|
|
83
|
+
? {
|
|
84
|
+
async checkpoint(options) {
|
|
85
|
+
const result = await box.checkpoint?.(options);
|
|
86
|
+
return { id: checkpointIdFromResult(result), provider: providerName };
|
|
87
|
+
},
|
|
88
|
+
}
|
|
89
|
+
: {}),
|
|
90
|
+
...(box.fork
|
|
91
|
+
? {
|
|
92
|
+
async fork(checkpoint, options) {
|
|
93
|
+
const forked = await box.fork?.(checkpoint.id, options);
|
|
94
|
+
if (!forked)
|
|
95
|
+
throw new Error("sandbox fork returned no environment");
|
|
96
|
+
return sandboxInstanceAsEnvironment(forked, providerName, client);
|
|
97
|
+
},
|
|
98
|
+
}
|
|
99
|
+
: {}),
|
|
100
|
+
async placement() {
|
|
101
|
+
return placementInfoFromLoopPlacement(client.describePlacement?.(box), box);
|
|
102
|
+
},
|
|
103
|
+
async refresh() {
|
|
104
|
+
await box.refresh?.();
|
|
105
|
+
},
|
|
106
|
+
async destroy() {
|
|
107
|
+
await box.delete?.();
|
|
108
|
+
},
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
function sandboxSessionAsAgentSession(session) {
|
|
112
|
+
return {
|
|
113
|
+
id: session.id,
|
|
114
|
+
async status() {
|
|
115
|
+
const status = await session.status();
|
|
116
|
+
if (!status)
|
|
117
|
+
return null;
|
|
118
|
+
return sessionStatusFromUnknown(status.status);
|
|
119
|
+
},
|
|
120
|
+
async *events(options) {
|
|
121
|
+
for await (const event of session.events(options))
|
|
122
|
+
yield environmentEventFromSandboxEvent(event);
|
|
123
|
+
},
|
|
124
|
+
async result() {
|
|
125
|
+
return agentTurnResultFromPromptResult(await session.result());
|
|
126
|
+
},
|
|
127
|
+
async prompt(input) {
|
|
128
|
+
return agentTurnResultFromPromptResult(await session.prompt(promptFromTurnInput(input), promptOptionsFromTurnInput(input)));
|
|
129
|
+
},
|
|
130
|
+
cancel: session.cancel.bind(session),
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
function sandboxOptionsFromCreateInput(input, defaultBackend) {
|
|
134
|
+
const workspace = input.workspace ?? {};
|
|
135
|
+
const providerOptions = input.providerOptions?.sandboxCreateOptions;
|
|
136
|
+
const base = providerOptions && typeof providerOptions === "object"
|
|
137
|
+
? { ...providerOptions }
|
|
138
|
+
: {};
|
|
139
|
+
return {
|
|
140
|
+
...base,
|
|
141
|
+
...(workspace.environment ? { environment: workspace.environment } : {}),
|
|
142
|
+
...(workspace.image ? { image: workspace.image } : {}),
|
|
143
|
+
...(workspace.repoUrl ? { git: { url: workspace.repoUrl, ref: workspace.gitRef } } : {}),
|
|
144
|
+
...(input.resources ? { resources: input.resources } : {}),
|
|
145
|
+
...(input.env ? { env: input.env } : {}),
|
|
146
|
+
...(Array.isArray(input.secrets) ? { secrets: input.secrets } : {}),
|
|
147
|
+
...(input.metadata ? { metadata: input.metadata } : {}),
|
|
148
|
+
...(input.name ? { name: input.name } : {}),
|
|
149
|
+
...(input.idempotencyKey ? { idempotencyKey: input.idempotencyKey } : {}),
|
|
150
|
+
backend: {
|
|
151
|
+
...(base.backend ?? {}),
|
|
152
|
+
type: (input.backend ?? defaultBackend),
|
|
153
|
+
profile: input.profile,
|
|
154
|
+
},
|
|
155
|
+
};
|
|
156
|
+
}
|
|
157
|
+
function environmentEventFromSandboxEvent(event) {
|
|
158
|
+
const data = event.data && typeof event.data === "object"
|
|
159
|
+
? event.data
|
|
160
|
+
: {};
|
|
161
|
+
return {
|
|
162
|
+
type: String(event.type),
|
|
163
|
+
data,
|
|
164
|
+
...(event.id ? { id: event.id } : {}),
|
|
165
|
+
usage: tokenUsageFromData(data),
|
|
166
|
+
providerEvent: event,
|
|
167
|
+
};
|
|
168
|
+
}
|
|
169
|
+
function promptFromTurnInput(input) {
|
|
170
|
+
if (input.parts)
|
|
171
|
+
return input.parts;
|
|
172
|
+
return input.prompt ?? "";
|
|
173
|
+
}
|
|
174
|
+
function promptOptionsFromTurnInput(input) {
|
|
175
|
+
return {
|
|
176
|
+
...(input.sessionId ? { sessionId: input.sessionId } : {}),
|
|
177
|
+
...(input.model ? { model: input.model } : {}),
|
|
178
|
+
...(input.timeoutMs ? { timeoutMs: input.timeoutMs } : {}),
|
|
179
|
+
...(input.context ? { context: input.context } : {}),
|
|
180
|
+
...(input.signal ? { signal: input.signal } : {}),
|
|
181
|
+
...(input.executionId ? { executionId: input.executionId } : {}),
|
|
182
|
+
...(input.lastEventId ? { lastEventId: input.lastEventId } : {}),
|
|
183
|
+
...(input.turnId ? { turnId: input.turnId } : {}),
|
|
184
|
+
...(input.detach !== undefined ? { detach: input.detach } : {}),
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
function agentTurnResultFromPromptResult(result) {
|
|
188
|
+
const record = result;
|
|
189
|
+
const text = typeof record.response === "string"
|
|
190
|
+
? record.response
|
|
191
|
+
: typeof record.text === "string"
|
|
192
|
+
? record.text
|
|
193
|
+
: typeof record.finalText === "string"
|
|
194
|
+
? record.finalText
|
|
195
|
+
: "";
|
|
196
|
+
const success = typeof record.success === "boolean" ? record.success : true;
|
|
197
|
+
return {
|
|
198
|
+
text,
|
|
199
|
+
success,
|
|
200
|
+
...(typeof record.error === "string" ? { error: record.error } : {}),
|
|
201
|
+
usage: tokenUsageFromData(record),
|
|
202
|
+
};
|
|
203
|
+
}
|
|
204
|
+
function sessionRefFromSandboxDispatch(dispatched, providerName) {
|
|
205
|
+
const record = dispatched && typeof dispatched === "object"
|
|
206
|
+
? dispatched
|
|
207
|
+
: undefined;
|
|
208
|
+
const id = record?.sessionId ?? record?.id;
|
|
209
|
+
if (typeof id !== "string" || id.length === 0 || !record) {
|
|
210
|
+
throw new Error("sandbox dispatch returned no session id");
|
|
211
|
+
}
|
|
212
|
+
return {
|
|
213
|
+
id,
|
|
214
|
+
provider: providerName,
|
|
215
|
+
metadata: {
|
|
216
|
+
...(record.status ? { status: record.status } : {}),
|
|
217
|
+
...(record.alreadyExisted !== undefined ? { alreadyExisted: record.alreadyExisted } : {}),
|
|
218
|
+
},
|
|
219
|
+
};
|
|
220
|
+
}
|
|
221
|
+
function execResultFromSandboxExecResult(result) {
|
|
222
|
+
const record = (result ?? {});
|
|
223
|
+
return {
|
|
224
|
+
exitCode: finiteNumber(record.exitCode) ?? finiteNumber(record.code) ?? 0,
|
|
225
|
+
stdout: typeof record.stdout === "string" ? record.stdout : "",
|
|
226
|
+
stderr: typeof record.stderr === "string" ? record.stderr : "",
|
|
227
|
+
};
|
|
228
|
+
}
|
|
229
|
+
function checkpointIdFromResult(result) {
|
|
230
|
+
const record = result && typeof result === "object" ? result : {};
|
|
231
|
+
const id = record.checkpointId ?? record.id;
|
|
232
|
+
if (typeof id !== "string" || id.length === 0) {
|
|
233
|
+
throw new Error("sandbox checkpoint returned no checkpoint id");
|
|
234
|
+
}
|
|
235
|
+
return id;
|
|
236
|
+
}
|
|
237
|
+
function placementInfoFromLoopPlacement(placement, box) {
|
|
238
|
+
if (!placement || typeof placement !== "object")
|
|
239
|
+
return { kind: "sandbox", sandboxId: String(box.id) };
|
|
240
|
+
const record = placement;
|
|
241
|
+
return {
|
|
242
|
+
kind: record.kind === "fleet" ? "fleet" : "sandbox",
|
|
243
|
+
sandboxId: typeof record.sandboxId === "string" ? record.sandboxId : String(box.id),
|
|
244
|
+
...(typeof record.fleetId === "string" ? { fleetId: record.fleetId } : {}),
|
|
245
|
+
...(typeof record.machineId === "string" ? { machineId: record.machineId } : {}),
|
|
246
|
+
};
|
|
247
|
+
}
|
|
248
|
+
function tokenUsageFromData(data) {
|
|
249
|
+
const usageRecord = data.usage && typeof data.usage === "object"
|
|
250
|
+
? data.usage
|
|
251
|
+
: data.tokenUsage && typeof data.tokenUsage === "object"
|
|
252
|
+
? data.tokenUsage
|
|
253
|
+
: data;
|
|
254
|
+
const inputTokens = finiteNumber(usageRecord.inputTokens) ??
|
|
255
|
+
finiteNumber(usageRecord.tokensIn) ??
|
|
256
|
+
finiteNumber(usageRecord.prompt_tokens);
|
|
257
|
+
const outputTokens = finiteNumber(usageRecord.outputTokens) ??
|
|
258
|
+
finiteNumber(usageRecord.tokensOut) ??
|
|
259
|
+
finiteNumber(usageRecord.completion_tokens);
|
|
260
|
+
const cost = finiteNumber(usageRecord.cost) ??
|
|
261
|
+
finiteNumber(usageRecord.costUsd) ??
|
|
262
|
+
finiteNumber(usageRecord.totalCostUsd) ??
|
|
263
|
+
finiteNumber(data.costUsd) ??
|
|
264
|
+
finiteNumber(data.totalCostUsd);
|
|
265
|
+
if (inputTokens === undefined && outputTokens === undefined && cost === undefined)
|
|
266
|
+
return undefined;
|
|
267
|
+
return {
|
|
268
|
+
inputTokens: inputTokens ?? 0,
|
|
269
|
+
outputTokens: outputTokens ?? 0,
|
|
270
|
+
...(cost !== undefined ? { cost } : {}),
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
function statusFromUnknown(status) {
|
|
274
|
+
if (status === "pending" || status === "provisioning" || status === "running")
|
|
275
|
+
return status;
|
|
276
|
+
if (status === "stopped" || status === "failed" || status === "expired")
|
|
277
|
+
return status;
|
|
278
|
+
if (status === "completed" || status === "cancelled")
|
|
279
|
+
return "stopped";
|
|
280
|
+
return "unknown";
|
|
281
|
+
}
|
|
282
|
+
function sessionStatusFromUnknown(status) {
|
|
283
|
+
if (status === "completed" || status === "cancelled")
|
|
284
|
+
return status;
|
|
285
|
+
return statusFromUnknown(status);
|
|
286
|
+
}
|
|
287
|
+
function finiteNumber(value) {
|
|
288
|
+
return typeof value === "number" && Number.isFinite(value) ? value : undefined;
|
|
289
|
+
}
|
|
290
|
+
export function defaultTangleSandboxCapabilities() {
|
|
291
|
+
return {
|
|
292
|
+
profile: {
|
|
293
|
+
namedProfiles: true,
|
|
294
|
+
systemPrompt: true,
|
|
295
|
+
instructions: true,
|
|
296
|
+
tools: true,
|
|
297
|
+
permissions: true,
|
|
298
|
+
mcp: true,
|
|
299
|
+
subagents: true,
|
|
300
|
+
resources: {
|
|
301
|
+
files: true,
|
|
302
|
+
instructions: true,
|
|
303
|
+
tools: true,
|
|
304
|
+
skills: true,
|
|
305
|
+
agents: true,
|
|
306
|
+
commands: true,
|
|
307
|
+
},
|
|
308
|
+
hooks: true,
|
|
309
|
+
modes: true,
|
|
310
|
+
runtimeUpdate: true,
|
|
311
|
+
validation: true,
|
|
312
|
+
},
|
|
313
|
+
streaming: { live: true, replay: true, detach: true, turnIdempotency: true },
|
|
314
|
+
sessions: { continue: true, list: true, messages: true },
|
|
315
|
+
workspace: { read: true, write: true, exec: true, git: true, upload: true, download: true },
|
|
316
|
+
branching: { checkpoint: true, fork: true },
|
|
317
|
+
placement: true,
|
|
318
|
+
usage: true,
|
|
319
|
+
confidential: true,
|
|
320
|
+
};
|
|
321
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@tangle-network/agent-provider-tangle",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "AgentEnvironmentProvider adapter for Tangle sandboxes",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"main": "./dist/index.js",
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"import": "./dist/index.js",
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
|
+
"default": "./dist/index.js"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"repository": {
|
|
17
|
+
"type": "git",
|
|
18
|
+
"url": "git+https://github.com/tangle-network/agent-sdk.git",
|
|
19
|
+
"directory": "packages/agent-provider-tangle"
|
|
20
|
+
},
|
|
21
|
+
"publishConfig": {
|
|
22
|
+
"access": "public",
|
|
23
|
+
"registry": "https://registry.npmjs.org"
|
|
24
|
+
},
|
|
25
|
+
"files": [
|
|
26
|
+
"dist/index.d.ts",
|
|
27
|
+
"dist/index.js",
|
|
28
|
+
"README.md",
|
|
29
|
+
"LICENSE"
|
|
30
|
+
],
|
|
31
|
+
"dependencies": {
|
|
32
|
+
"@tangle-network/agent-interface": "0.14.0"
|
|
33
|
+
},
|
|
34
|
+
"peerDependencies": {
|
|
35
|
+
"@tangle-network/sandbox": ">=0.8.0 <1.0.0"
|
|
36
|
+
},
|
|
37
|
+
"peerDependenciesMeta": {
|
|
38
|
+
"@tangle-network/sandbox": {
|
|
39
|
+
"optional": false
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"devDependencies": {
|
|
43
|
+
"@tangle-network/sandbox": "^0.8.2",
|
|
44
|
+
"@types/node": "25.6.0",
|
|
45
|
+
"typescript": "^6.0.3",
|
|
46
|
+
"vitest": "^4.1.5",
|
|
47
|
+
"@tangle-network/agent-provider-testkit": "0.2.0"
|
|
48
|
+
},
|
|
49
|
+
"scripts": {
|
|
50
|
+
"build": "tsc -p tsconfig.json",
|
|
51
|
+
"check-types": "tsc --noEmit",
|
|
52
|
+
"clean": "rm -rf dist",
|
|
53
|
+
"test": "vitest run"
|
|
54
|
+
}
|
|
55
|
+
}
|