raysurfer 0.2.0 → 0.3.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/dist/index.d.ts +12 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +87 -164
- package/dist/sdk-client.d.ts +42 -60
- package/dist/sdk-client.d.ts.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,17 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* RaySurfer TypeScript SDK
|
|
2
|
+
* RaySurfer TypeScript SDK - Drop-in replacement for Claude Agent SDK with caching.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
* and verdict-aware scoring.
|
|
4
|
+
* Simply swap your import:
|
|
6
5
|
*
|
|
7
|
-
*
|
|
6
|
+
* // Before
|
|
7
|
+
* import { query } from "@anthropic-ai/claude-agent-sdk";
|
|
8
|
+
*
|
|
9
|
+
* // After
|
|
10
|
+
* import { query } from "raysurfer";
|
|
11
|
+
*
|
|
12
|
+
* Everything else works exactly the same. Set RAYSURFER_API_KEY to enable caching.
|
|
8
13
|
*/
|
|
14
|
+
export { query, ClaudeSDKClient, RaysurferClient, default as queryDefault, } from "./sdk-client";
|
|
15
|
+
export type { QueryOptions, QueryParams, RaysurferAgentOptions, } from "./sdk-client";
|
|
9
16
|
export { RaySurfer, default as RaySurferDefault } from "./client";
|
|
10
17
|
export type { RaySurferOptions, StoreCodeBlockParams, StoreExecutionParams, RetrieveParams, GetCodeFilesParams, GetTaskPatternsParams, } from "./client";
|
|
11
|
-
export { RaysurferClient } from "./sdk-client";
|
|
12
|
-
export type { RaysurferAgentOptions } from "./sdk-client";
|
|
13
18
|
export { ExecutionState, AgentVerdict } from "./types";
|
|
14
19
|
export type { CodeBlock, ExecutionIO, AgentReview, ExecutionRecord, BestMatch, AlternativeCandidate, FewShotExample, TaskPattern, FileWritten, StoreCodeBlockResponse, StoreExecutionResponse, CodeBlockMatch, RetrieveCodeBlockResponse, RetrieveBestResponse, SubmitExecutionResultRequest, SubmitExecutionResultResponse, CodeFile, GetCodeFilesResponse, } from "./types";
|
|
15
20
|
export { RaySurferError, APIError, AuthenticationError } from "./errors";
|
|
16
|
-
export declare const VERSION = "0.
|
|
21
|
+
export declare const VERSION = "0.3.0";
|
|
17
22
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EACL,KAAK,EACL,eAAe,EACf,eAAe,EACf,OAAO,IAAI,YAAY,GACxB,MAAM,cAAc,CAAC;AACtB,YAAY,EACV,YAAY,EACZ,WAAW,EACX,qBAAqB,GACtB,MAAM,cAAc,CAAC;AAGtB,OAAO,EAAE,SAAS,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAClE,YAAY,EACV,gBAAgB,EAChB,oBAAoB,EACpB,oBAAoB,EACpB,cAAc,EACd,kBAAkB,EAClB,qBAAqB,GACtB,MAAM,UAAU,CAAC;AAGlB,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvD,YAAY,EACV,SAAS,EACT,WAAW,EACX,WAAW,EACX,eAAe,EACf,SAAS,EACT,oBAAoB,EACpB,cAAc,EACd,WAAW,EACX,WAAW,EACX,sBAAsB,EACtB,sBAAsB,EACtB,cAAc,EACd,yBAAyB,EACzB,oBAAoB,EACpB,4BAA4B,EAC5B,6BAA6B,EAC7B,QAAQ,EACR,oBAAoB,GACrB,MAAM,SAAS,CAAC;AAGjB,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAEzE,eAAO,MAAM,OAAO,UAAU,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -21225,196 +21225,116 @@ class RaySurfer {
|
|
|
21225
21225
|
}
|
|
21226
21226
|
}
|
|
21227
21227
|
var client_default = RaySurfer;
|
|
21228
|
-
// src/sdk-client.ts
|
|
21229
|
-
import { mkdir, writeFile, rm, readdir, stat } from "node:fs/promises";
|
|
21230
|
-
import { homedir as homedir2 } from "node:os";
|
|
21231
|
-
import { join as join6 } from "node:path";
|
|
21232
|
-
var DEFAULT_SANDBOX_DIR = join6(homedir2(), ".raysurfer", "sandbox");
|
|
21233
21228
|
|
|
21234
|
-
|
|
21235
|
-
|
|
21236
|
-
|
|
21237
|
-
|
|
21238
|
-
|
|
21239
|
-
|
|
21240
|
-
|
|
21241
|
-
|
|
21242
|
-
|
|
21243
|
-
|
|
21244
|
-
|
|
21245
|
-
|
|
21246
|
-
|
|
21247
|
-
cleanupSandbox: options.cleanupSandbox ?? true,
|
|
21248
|
-
cleanupOnError: options.cleanupOnError ?? false,
|
|
21249
|
-
model: options.model ?? "claude-sonnet-4-5",
|
|
21250
|
-
...options
|
|
21251
|
-
};
|
|
21252
|
-
this.raysurfer = new RaySurfer({
|
|
21253
|
-
apiKey: options.raysurferApiKey,
|
|
21254
|
-
baseUrl: options.raysurferBaseUrl
|
|
21255
|
-
});
|
|
21256
|
-
}
|
|
21257
|
-
async* query(prompt) {
|
|
21258
|
-
this.currentQuery = prompt;
|
|
21259
|
-
this.generatedFiles = [];
|
|
21260
|
-
this.taskSucceeded = false;
|
|
21261
|
-
this.prefetchedFiles = await this.prefetchCodeFiles(prompt);
|
|
21262
|
-
await this.downloadFilesToSandbox();
|
|
21263
|
-
const systemPrompt = this.buildSystemPrompt();
|
|
21264
|
-
let queryFn;
|
|
21229
|
+
// src/sdk-client.ts
|
|
21230
|
+
var DEFAULT_RAYSURFER_URL = "https://web-production-3d338.up.railway.app";
|
|
21231
|
+
async function* query2(params) {
|
|
21232
|
+
const { prompt, options = {} } = params;
|
|
21233
|
+
const apiKey = process.env.RAYSURFER_API_KEY;
|
|
21234
|
+
const baseUrl = process.env.RAYSURFER_BASE_URL || DEFAULT_RAYSURFER_URL;
|
|
21235
|
+
const cacheEnabled = !!apiKey;
|
|
21236
|
+
let raysurfer = null;
|
|
21237
|
+
let cachedFiles = [];
|
|
21238
|
+
const generatedFiles = [];
|
|
21239
|
+
let taskSucceeded = false;
|
|
21240
|
+
if (cacheEnabled) {
|
|
21241
|
+
raysurfer = new RaySurfer({ apiKey, baseUrl });
|
|
21265
21242
|
try {
|
|
21266
|
-
const
|
|
21267
|
-
|
|
21268
|
-
|
|
21269
|
-
|
|
21270
|
-
|
|
21271
|
-
|
|
21272
|
-
|
|
21273
|
-
|
|
21274
|
-
|
|
21275
|
-
|
|
21276
|
-
|
|
21277
|
-
|
|
21278
|
-
|
|
21279
|
-
|
|
21280
|
-
|
|
21281
|
-
|
|
21282
|
-
|
|
21283
|
-
|
|
21284
|
-
|
|
21285
|
-
|
|
21286
|
-
|
|
21287
|
-
|
|
21288
|
-
|
|
21289
|
-
|
|
21290
|
-
|
|
21291
|
-
|
|
21292
|
-
|
|
21293
|
-
|
|
21294
|
-
|
|
21295
|
-
|
|
21296
|
-
|
|
21243
|
+
const response2 = await raysurfer.getCodeFiles({
|
|
21244
|
+
task: prompt,
|
|
21245
|
+
topK: 5,
|
|
21246
|
+
minVerdictScore: 0.3,
|
|
21247
|
+
preferComplete: true
|
|
21248
|
+
});
|
|
21249
|
+
cachedFiles = response2.files;
|
|
21250
|
+
} catch {}
|
|
21251
|
+
}
|
|
21252
|
+
const augmentedPrompt = buildSystemPrompt(options.systemPrompt, cachedFiles);
|
|
21253
|
+
let sdkQuery;
|
|
21254
|
+
try {
|
|
21255
|
+
const sdk = await Promise.resolve().then(() => (init_sdk(), exports_sdk));
|
|
21256
|
+
sdkQuery = sdk.query;
|
|
21257
|
+
} catch {
|
|
21258
|
+
throw new Error("Could not import @anthropic-ai/claude-agent-sdk. Install it with: npm install @anthropic-ai/claude-agent-sdk");
|
|
21259
|
+
}
|
|
21260
|
+
const response = sdkQuery({
|
|
21261
|
+
prompt,
|
|
21262
|
+
options: {
|
|
21263
|
+
...options,
|
|
21264
|
+
systemPrompt: augmentedPrompt
|
|
21265
|
+
}
|
|
21266
|
+
});
|
|
21267
|
+
for await (const message of response) {
|
|
21268
|
+
const msg = message;
|
|
21269
|
+
if (msg.type === "assistant" && Array.isArray(msg.content)) {
|
|
21270
|
+
for (const block of msg.content) {
|
|
21271
|
+
if (block.type === "tool_use" && block.name === "Write") {
|
|
21272
|
+
const input = block.input;
|
|
21273
|
+
if (input?.file_path && input?.content) {
|
|
21274
|
+
generatedFiles.push({
|
|
21275
|
+
path: input.file_path,
|
|
21276
|
+
content: input.content
|
|
21277
|
+
});
|
|
21297
21278
|
}
|
|
21298
21279
|
}
|
|
21299
21280
|
}
|
|
21300
|
-
if (msg.type === "result") {
|
|
21301
|
-
const subtype = msg.subtype;
|
|
21302
|
-
if (subtype === "success") {
|
|
21303
|
-
this.taskSucceeded = true;
|
|
21304
|
-
}
|
|
21305
|
-
}
|
|
21306
|
-
yield message;
|
|
21307
21281
|
}
|
|
21308
|
-
if (
|
|
21309
|
-
|
|
21282
|
+
if (msg.type === "result" && msg.subtype === "success") {
|
|
21283
|
+
taskSucceeded = true;
|
|
21310
21284
|
}
|
|
21311
|
-
|
|
21312
|
-
if (shouldCleanup) {
|
|
21313
|
-
await this.cleanupSandbox();
|
|
21314
|
-
}
|
|
21315
|
-
}
|
|
21316
|
-
get files() {
|
|
21317
|
-
return this.prefetchedFiles;
|
|
21285
|
+
yield message;
|
|
21318
21286
|
}
|
|
21319
|
-
|
|
21320
|
-
return this.options.sandboxDir;
|
|
21321
|
-
}
|
|
21322
|
-
async cleanup() {
|
|
21323
|
-
await this.cleanupSandbox();
|
|
21324
|
-
}
|
|
21325
|
-
async prefetchCodeFiles(task) {
|
|
21287
|
+
if (cacheEnabled && raysurfer && taskSucceeded && generatedFiles.length > 0) {
|
|
21326
21288
|
try {
|
|
21327
|
-
|
|
21328
|
-
|
|
21329
|
-
topK: this.options.prefetchCount,
|
|
21330
|
-
minVerdictScore: this.options.minVerdictScore,
|
|
21331
|
-
preferComplete: this.options.preferComplete
|
|
21332
|
-
});
|
|
21333
|
-
return response.files;
|
|
21334
|
-
} catch {
|
|
21335
|
-
return [];
|
|
21336
|
-
}
|
|
21289
|
+
await raysurfer.submitExecutionResult(prompt, generatedFiles, true);
|
|
21290
|
+
} catch {}
|
|
21337
21291
|
}
|
|
21338
|
-
|
|
21339
|
-
|
|
21340
|
-
|
|
21341
|
-
|
|
21342
|
-
|
|
21343
|
-
|
|
21292
|
+
}
|
|
21293
|
+
|
|
21294
|
+
class ClaudeSDKClient {
|
|
21295
|
+
options;
|
|
21296
|
+
constructor(options = {}) {
|
|
21297
|
+
this.options = options;
|
|
21344
21298
|
}
|
|
21345
|
-
|
|
21346
|
-
|
|
21347
|
-
if (this.prefetchedFiles.length === 0) {
|
|
21348
|
-
return basePrompt;
|
|
21349
|
-
}
|
|
21350
|
-
return basePrompt + this.formatCodeSnippets();
|
|
21299
|
+
async* query(prompt) {
|
|
21300
|
+
yield* query2({ prompt, options: this.options });
|
|
21351
21301
|
}
|
|
21352
|
-
|
|
21353
|
-
|
|
21354
|
-
|
|
21355
|
-
|
|
21302
|
+
}
|
|
21303
|
+
function buildSystemPrompt(basePrompt, files) {
|
|
21304
|
+
const base = basePrompt ?? "";
|
|
21305
|
+
if (files.length === 0)
|
|
21306
|
+
return base;
|
|
21307
|
+
return base + formatCodeSnippets(files);
|
|
21308
|
+
}
|
|
21309
|
+
function formatCodeSnippets(files) {
|
|
21310
|
+
let snippets = `
|
|
21356
21311
|
|
|
21357
|
-
|
|
21358
|
-
snippets += "The following pre-validated code files are available in your working directory. ";
|
|
21359
|
-
snippets += `You can execute them directly using the Bash tool.
|
|
21312
|
+
## Cached Code (from Raysurfer)
|
|
21360
21313
|
|
|
21361
21314
|
`;
|
|
21362
|
-
|
|
21363
|
-
|
|
21315
|
+
snippets += "The following pre-validated code is available for this task. ";
|
|
21316
|
+
snippets += `Use it directly or adapt it as needed.
|
|
21364
21317
|
|
|
21365
21318
|
`;
|
|
21366
|
-
|
|
21367
|
-
|
|
21319
|
+
for (const f of files) {
|
|
21320
|
+
snippets += `### ${f.filename}
|
|
21368
21321
|
`;
|
|
21369
|
-
|
|
21370
|
-
|
|
21322
|
+
snippets += `**Description**: ${f.description}
|
|
21371
21323
|
`;
|
|
21372
|
-
|
|
21373
|
-
|
|
21324
|
+
snippets += `**Entrypoint**: \`${f.entrypoint}\`
|
|
21374
21325
|
`;
|
|
21375
|
-
|
|
21376
|
-
snippets += `**Dependencies**: ${f.dependencies.join(", ")}
|
|
21326
|
+
snippets += `**Confidence**: ${Math.round(f.verdictScore * 100)}%
|
|
21377
21327
|
|
|
21378
21328
|
`;
|
|
21379
|
-
|
|
21380
|
-
snippets += `\`\`\`${f.language}
|
|
21329
|
+
snippets += `\`\`\`${f.language}
|
|
21381
21330
|
${f.source}
|
|
21382
21331
|
\`\`\`
|
|
21383
21332
|
|
|
21384
21333
|
`;
|
|
21385
|
-
snippets += `---
|
|
21386
|
-
|
|
21387
|
-
`;
|
|
21388
|
-
}
|
|
21389
|
-
return snippets;
|
|
21390
|
-
}
|
|
21391
|
-
async storeGeneratedCode() {
|
|
21392
|
-
if (!this.currentQuery)
|
|
21393
|
-
return;
|
|
21394
|
-
try {
|
|
21395
|
-
const result = await this.raysurfer.submitExecutionResult(this.currentQuery, this.generatedFiles, this.taskSucceeded);
|
|
21396
|
-
if (result.codeBlocksStored > 0) {
|
|
21397
|
-
console.log(`Raysurfer: stored ${result.codeBlocksStored} code blocks`);
|
|
21398
|
-
}
|
|
21399
|
-
} catch (error2) {
|
|
21400
|
-
console.warn("Raysurfer: failed to submit execution result:", error2);
|
|
21401
|
-
}
|
|
21402
|
-
}
|
|
21403
|
-
async cleanupSandbox() {
|
|
21404
|
-
try {
|
|
21405
|
-
const items = await readdir(this.options.sandboxDir);
|
|
21406
|
-
for (const item of items) {
|
|
21407
|
-
const itemPath = join6(this.options.sandboxDir, item);
|
|
21408
|
-
const stats = await stat(itemPath);
|
|
21409
|
-
if (stats.isDirectory()) {
|
|
21410
|
-
await rm(itemPath, { recursive: true });
|
|
21411
|
-
} else {
|
|
21412
|
-
await rm(itemPath);
|
|
21413
|
-
}
|
|
21414
|
-
}
|
|
21415
|
-
} catch {}
|
|
21416
21334
|
}
|
|
21335
|
+
return snippets;
|
|
21417
21336
|
}
|
|
21337
|
+
var sdk_client_default = query2;
|
|
21418
21338
|
// src/types.ts
|
|
21419
21339
|
var ExecutionState;
|
|
21420
21340
|
((ExecutionState2) => {
|
|
@@ -21431,14 +21351,17 @@ var AgentVerdict;
|
|
|
21431
21351
|
})(AgentVerdict ||= {});
|
|
21432
21352
|
|
|
21433
21353
|
// src/index.ts
|
|
21434
|
-
var VERSION = "0.
|
|
21354
|
+
var VERSION = "0.3.0";
|
|
21435
21355
|
export {
|
|
21356
|
+
sdk_client_default as queryDefault,
|
|
21357
|
+
query2 as query,
|
|
21436
21358
|
VERSION,
|
|
21437
|
-
RaysurferClient,
|
|
21359
|
+
ClaudeSDKClient as RaysurferClient,
|
|
21438
21360
|
RaySurferError,
|
|
21439
21361
|
client_default as RaySurferDefault,
|
|
21440
21362
|
RaySurfer,
|
|
21441
21363
|
ExecutionState,
|
|
21364
|
+
ClaudeSDKClient,
|
|
21442
21365
|
AuthenticationError,
|
|
21443
21366
|
AgentVerdict,
|
|
21444
21367
|
APIError
|
package/dist/sdk-client.d.ts
CHANGED
|
@@ -1,24 +1,18 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Drop-in replacement for Claude Agent SDK with automatic code caching.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
4
|
+
* Simply swap your import:
|
|
5
|
+
*
|
|
6
|
+
* // Before
|
|
7
|
+
* import { query } from "@anthropic-ai/claude-agent-sdk";
|
|
8
|
+
*
|
|
9
|
+
* // After
|
|
10
|
+
* import { query } from "raysurfer";
|
|
11
|
+
*
|
|
12
|
+
* Everything else works exactly the same. Set RAYSURFER_API_KEY to enable caching.
|
|
10
13
|
*/
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
export interface RaysurferAgentOptions {
|
|
14
|
-
raysurferApiKey?: string;
|
|
15
|
-
raysurferBaseUrl?: string;
|
|
16
|
-
prefetchCount?: number;
|
|
17
|
-
minVerdictScore?: number;
|
|
18
|
-
preferComplete?: boolean;
|
|
19
|
-
sandboxDir?: string;
|
|
20
|
-
cleanupSandbox?: boolean;
|
|
21
|
-
cleanupOnError?: boolean;
|
|
14
|
+
/** Options for the query function - matches Claude Agent SDK */
|
|
15
|
+
export interface QueryOptions {
|
|
22
16
|
model?: string;
|
|
23
17
|
workingDirectory?: string;
|
|
24
18
|
systemPrompt?: string;
|
|
@@ -29,53 +23,41 @@ export interface RaysurferAgentOptions {
|
|
|
29
23
|
maxTurns?: number;
|
|
30
24
|
env?: Record<string, string>;
|
|
31
25
|
}
|
|
26
|
+
/** Query parameters - matches Claude Agent SDK */
|
|
27
|
+
export interface QueryParams {
|
|
28
|
+
prompt: string;
|
|
29
|
+
options?: QueryOptions;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Drop-in replacement for Claude Agent SDK's query function with automatic caching.
|
|
33
|
+
*
|
|
34
|
+
* Usage is identical to the original:
|
|
35
|
+
*
|
|
36
|
+
* import { query } from "raysurfer";
|
|
37
|
+
*
|
|
38
|
+
* for await (const message of query({ prompt: "Hello" })) {
|
|
39
|
+
* console.log(message);
|
|
40
|
+
* }
|
|
41
|
+
*
|
|
42
|
+
* Set RAYSURFER_API_KEY environment variable to enable caching.
|
|
43
|
+
*/
|
|
44
|
+
export declare function query(params: QueryParams): AsyncGenerator<unknown>;
|
|
32
45
|
/**
|
|
33
|
-
*
|
|
46
|
+
* ClaudeSDKClient - Class-based drop-in replacement.
|
|
34
47
|
*
|
|
35
|
-
*
|
|
36
|
-
* ```typescript
|
|
37
|
-
* const client = new RaysurferClient({
|
|
38
|
-
* raysurferApiKey: "rs_...",
|
|
39
|
-
* model: "claude-sonnet-4-5",
|
|
40
|
-
* systemPrompt: "You are a helpful assistant.",
|
|
41
|
-
* });
|
|
48
|
+
* For users who prefer the Python-style class interface:
|
|
42
49
|
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
50
|
+
* const client = new ClaudeSDKClient(options);
|
|
51
|
+
* for await (const msg of client.query("Hello")) {
|
|
52
|
+
* console.log(msg);
|
|
53
|
+
* }
|
|
47
54
|
*/
|
|
48
|
-
export declare class
|
|
55
|
+
export declare class ClaudeSDKClient {
|
|
49
56
|
private options;
|
|
50
|
-
|
|
51
|
-
private prefetchedFiles;
|
|
52
|
-
private currentQuery;
|
|
53
|
-
private generatedFiles;
|
|
54
|
-
private taskSucceeded;
|
|
55
|
-
constructor(options?: RaysurferAgentOptions);
|
|
56
|
-
/**
|
|
57
|
-
* Query Claude with pre-fetched code files from Raysurfer.
|
|
58
|
-
*
|
|
59
|
-
* This method:
|
|
60
|
-
* 1. Pre-fetches relevant code files from Raysurfer backend
|
|
61
|
-
* 2. Downloads files to sandbox directory
|
|
62
|
-
* 3. Injects file contents into system prompt
|
|
63
|
-
* 4. Delegates to Claude Agent SDK
|
|
64
|
-
* 5. Stores generated code back to cache on success
|
|
65
|
-
*/
|
|
57
|
+
constructor(options?: QueryOptions);
|
|
66
58
|
query(prompt: string): AsyncGenerator<unknown>;
|
|
67
|
-
/** Get the list of pre-fetched code files */
|
|
68
|
-
get files(): CodeFile[];
|
|
69
|
-
/** Get the sandbox directory path */
|
|
70
|
-
get sandbox(): string;
|
|
71
|
-
/** Manually clean up the sandbox directory */
|
|
72
|
-
cleanup(): Promise<void>;
|
|
73
|
-
private prefetchCodeFiles;
|
|
74
|
-
private downloadFilesToSandbox;
|
|
75
|
-
private buildSystemPrompt;
|
|
76
|
-
private formatCodeSnippets;
|
|
77
|
-
private storeGeneratedCode;
|
|
78
|
-
private cleanupSandbox;
|
|
79
59
|
}
|
|
80
|
-
export
|
|
60
|
+
export { ClaudeSDKClient as RaysurferClient };
|
|
61
|
+
export type { QueryOptions as RaysurferAgentOptions };
|
|
62
|
+
export default query;
|
|
81
63
|
//# sourceMappingURL=sdk-client.d.ts.map
|
package/dist/sdk-client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk-client.d.ts","sourceRoot":"","sources":["../src/sdk-client.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"sdk-client.d.ts","sourceRoot":"","sources":["../src/sdk-client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAOH,gEAAgE;AAChE,MAAM,WAAW,YAAY;IAC3B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,SAAS,GAAG,aAAa,GAAG,MAAM,GAAG,mBAAmB,CAAC;IAC1E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC9B;AAED,kDAAkD;AAClD,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,YAAY,CAAC;CACxB;AAED;;;;;;;;;;;;GAYG;AACH,wBAAuB,KAAK,CAAC,MAAM,EAAE,WAAW,GAAG,cAAc,CAAC,OAAO,CAAC,CAwFzE;AAED;;;;;;;;;GASG;AACH,qBAAa,eAAe;IAC1B,OAAO,CAAC,OAAO,CAAe;gBAElB,OAAO,GAAE,YAAiB;IAI/B,KAAK,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,CAAC,OAAO,CAAC;CAGtD;AAGD,OAAO,EAAE,eAAe,IAAI,eAAe,EAAE,CAAC;AAC9C,YAAY,EAAE,YAAY,IAAI,qBAAqB,EAAE,CAAC;AAgCtD,eAAe,KAAK,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "raysurfer",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.3.0",
|
|
4
|
+
"description": "Drop-in replacement for Claude Agent SDK with automatic code caching - just swap your import",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"module": "./dist/index.js",
|