@augmentcode/auggie-sdk 0.1.6 → 0.1.7
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/auggie/sdk-acp-client.d.ts +0 -102
- package/dist/auggie/sdk-acp-client.d.ts.map +1 -1
- package/dist/auggie/sdk-acp-client.js +1 -32
- package/dist/auggie/sdk-acp-client.js.map +1 -1
- package/dist/context/direct-context.d.ts +287 -0
- package/dist/context/direct-context.d.ts.map +1 -0
- package/dist/context/direct-context.js +624 -0
- package/dist/context/direct-context.js.map +1 -0
- package/dist/context/filesystem-context.d.ts +84 -0
- package/dist/context/filesystem-context.d.ts.map +1 -0
- package/dist/context/filesystem-context.js +198 -0
- package/dist/context/filesystem-context.js.map +1 -0
- package/dist/context/internal/__mocks__/api-client.d.ts +54 -0
- package/dist/context/internal/__mocks__/api-client.d.ts.map +1 -0
- package/dist/context/internal/__mocks__/api-client.js +96 -0
- package/dist/context/internal/__mocks__/api-client.js.map +1 -0
- package/dist/context/internal/api-client.d.ts +75 -0
- package/dist/context/internal/api-client.d.ts.map +1 -0
- package/dist/context/internal/api-client.js +218 -0
- package/dist/context/internal/api-client.js.map +1 -0
- package/dist/context/internal/blob-name-calculator.d.ts +14 -0
- package/dist/context/internal/blob-name-calculator.d.ts.map +1 -0
- package/dist/context/internal/blob-name-calculator.js +44 -0
- package/dist/context/internal/blob-name-calculator.js.map +1 -0
- package/dist/context/internal/retry-utils.d.ts +22 -0
- package/dist/context/internal/retry-utils.d.ts.map +1 -0
- package/dist/context/internal/retry-utils.js +88 -0
- package/dist/context/internal/retry-utils.js.map +1 -0
- package/dist/context/internal/search-utils.d.ts +8 -0
- package/dist/context/internal/search-utils.d.ts.map +1 -0
- package/dist/context/internal/search-utils.js +10 -0
- package/dist/context/internal/search-utils.js.map +1 -0
- package/dist/context/internal/session-reader.d.ts +17 -0
- package/dist/context/internal/session-reader.d.ts.map +1 -0
- package/dist/context/internal/session-reader.js +27 -0
- package/dist/context/internal/session-reader.js.map +1 -0
- package/dist/context/types.d.ts +113 -0
- package/dist/context/types.d.ts.map +1 -0
- package/dist/context/types.js +5 -0
- package/dist/context/types.js.map +1 -0
- package/dist/index.d.ts +6 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -1
- package/dist/version.js.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,624 @@
|
|
|
1
|
+
import { readFile, writeFile } from "node:fs/promises";
|
|
2
|
+
import { Mutex } from "async-mutex";
|
|
3
|
+
import { ContextAPIClient } from "./internal/api-client";
|
|
4
|
+
import { BlobNameCalculator } from "./internal/blob-name-calculator";
|
|
5
|
+
import { retryWithBackoff } from "./internal/retry-utils";
|
|
6
|
+
import { formatSearchPrompt } from "./internal/search-utils";
|
|
7
|
+
import { readSessionFile } from "./internal/session-reader";
|
|
8
|
+
/**
|
|
9
|
+
* Direct Context - API-based indexing with import/export state
|
|
10
|
+
*
|
|
11
|
+
* ⚠️ **EXPERIMENTAL API** - This API is experimental and may change without notice.
|
|
12
|
+
*
|
|
13
|
+
* @experimental
|
|
14
|
+
*
|
|
15
|
+
* This class provides explicit file indexing via API calls with the ability
|
|
16
|
+
* to export and restore state to avoid re-indexing between sessions.
|
|
17
|
+
*
|
|
18
|
+
* ## Creating a Context
|
|
19
|
+
*
|
|
20
|
+
* **Start fresh:**
|
|
21
|
+
* ```typescript
|
|
22
|
+
* const context = await DirectContext.create();
|
|
23
|
+
* ```
|
|
24
|
+
*
|
|
25
|
+
* **Restore from saved state:**
|
|
26
|
+
* ```typescript
|
|
27
|
+
* const context = await DirectContext.importFromFile("state.json");
|
|
28
|
+
* // or
|
|
29
|
+
* const context = await DirectContext.import(stateObject);
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* ## Indexing Flow
|
|
33
|
+
*
|
|
34
|
+
* Files are uploaded to the backend and then indexed asynchronously. You have
|
|
35
|
+
* explicit control over when to wait for indexing:
|
|
36
|
+
*
|
|
37
|
+
* **Option 1: Wait after each upload**
|
|
38
|
+
* ```typescript
|
|
39
|
+
* await context.addToIndex(files); // waits for indexing by default
|
|
40
|
+
* await context.search("query"); // files are already indexed
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* **Option 2: Batch uploads then wait**
|
|
44
|
+
* ```typescript
|
|
45
|
+
* await context.addToIndex(files1, { waitForIndexing: false });
|
|
46
|
+
* await context.addToIndex(files2, { waitForIndexing: false });
|
|
47
|
+
* await context.waitForIndexing(); // wait for all files to be indexed
|
|
48
|
+
* await context.search("query"); // files are now indexed
|
|
49
|
+
* ```
|
|
50
|
+
*
|
|
51
|
+
* Note: `search()` and `searchAndAsk()` do not wait for indexing automatically.
|
|
52
|
+
*
|
|
53
|
+
* ## State Persistence
|
|
54
|
+
*
|
|
55
|
+
* **Export state:**
|
|
56
|
+
* ```typescript
|
|
57
|
+
* const state = context.export();
|
|
58
|
+
* // or save to file
|
|
59
|
+
* await context.exportToFile("state.json");
|
|
60
|
+
* ```
|
|
61
|
+
*
|
|
62
|
+
* **Import state:**
|
|
63
|
+
* ```typescript
|
|
64
|
+
* const context = await DirectContext.importFromFile("state.json");
|
|
65
|
+
* ```
|
|
66
|
+
*/
|
|
67
|
+
export class DirectContext {
|
|
68
|
+
/**
|
|
69
|
+
* Create and initialize a new DirectContext instance
|
|
70
|
+
*
|
|
71
|
+
* Authentication priority:
|
|
72
|
+
* 1. options.apiKey / options.apiUrl
|
|
73
|
+
* 2. AUGMENT_API_TOKEN / AUGMENT_API_URL environment variables
|
|
74
|
+
* 3. ~/.augment/session.json (created by `auggie login`)
|
|
75
|
+
*
|
|
76
|
+
* @param options Configuration options
|
|
77
|
+
* @returns Promise that resolves to a DirectContext instance
|
|
78
|
+
*/
|
|
79
|
+
static async create(options = {}) {
|
|
80
|
+
const { apiKey, apiUrl } = await DirectContext.resolveCredentials(options);
|
|
81
|
+
return new DirectContext(apiKey, apiUrl, options.debug ?? false);
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Import a DirectContext instance from a saved state object
|
|
85
|
+
*
|
|
86
|
+
* @param state The state object to restore from
|
|
87
|
+
* @param options Configuration options
|
|
88
|
+
* @returns Promise that resolves to a DirectContext instance with restored state
|
|
89
|
+
*/
|
|
90
|
+
static async import(state, options = {}) {
|
|
91
|
+
const { apiKey, apiUrl } = await DirectContext.resolveCredentials(options);
|
|
92
|
+
const instance = new DirectContext(apiKey, apiUrl, options.debug ?? false);
|
|
93
|
+
await instance.doImport(state);
|
|
94
|
+
return instance;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Import a DirectContext instance from a saved state file (Node.js only)
|
|
98
|
+
*
|
|
99
|
+
* @param filePath Path to the state file
|
|
100
|
+
* @param options Configuration options
|
|
101
|
+
* @returns Promise that resolves to a DirectContext instance with restored state
|
|
102
|
+
*/
|
|
103
|
+
static async importFromFile(filePath, options = {}) {
|
|
104
|
+
const content = await readFile(filePath, "utf-8");
|
|
105
|
+
const state = JSON.parse(content);
|
|
106
|
+
return DirectContext.import(state, options);
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Resolve API credentials from options, environment, or session file
|
|
110
|
+
*/
|
|
111
|
+
static async resolveCredentials(options) {
|
|
112
|
+
let apiKey = options.apiKey || process.env.AUGMENT_API_TOKEN;
|
|
113
|
+
let apiUrl = options.apiUrl || process.env.AUGMENT_API_URL;
|
|
114
|
+
// If credentials not provided, try session.json
|
|
115
|
+
if (!(apiKey && apiUrl)) {
|
|
116
|
+
const session = await readSessionFile();
|
|
117
|
+
if (session) {
|
|
118
|
+
apiKey = apiKey || session.accessToken;
|
|
119
|
+
apiUrl = apiUrl || session.tenantURL;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
// Validate we have credentials
|
|
123
|
+
if (!apiKey) {
|
|
124
|
+
throw new Error("API key is required. Provide it via:\n" +
|
|
125
|
+
"1. options.apiKey parameter\n" +
|
|
126
|
+
"2. AUGMENT_API_TOKEN environment variable\n" +
|
|
127
|
+
"3. Run 'auggie login' to create ~/.augment/session.json");
|
|
128
|
+
}
|
|
129
|
+
if (!apiUrl) {
|
|
130
|
+
throw new Error("API URL is required. Provide it via:\n" +
|
|
131
|
+
"1. options.apiUrl parameter\n" +
|
|
132
|
+
"2. AUGMENT_API_URL environment variable\n" +
|
|
133
|
+
"3. Run 'auggie login' to create ~/.augment/session.json");
|
|
134
|
+
}
|
|
135
|
+
return { apiKey, apiUrl };
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Private constructor - use DirectContext.create() instead
|
|
139
|
+
* @param apiKey API key for authentication
|
|
140
|
+
* @param apiUrl API URL for the tenant
|
|
141
|
+
* @param debug Enable debug logging
|
|
142
|
+
*/
|
|
143
|
+
constructor(apiKey, apiUrl, debug) {
|
|
144
|
+
/**
|
|
145
|
+
* State management:
|
|
146
|
+
*
|
|
147
|
+
* blobMap: Tracks all files that have been uploaded (path -> blobName).
|
|
148
|
+
* This includes both indexed and non-indexed blobs.
|
|
149
|
+
* Also, includes both checkpointed and non-checkpointed blobs.
|
|
150
|
+
*
|
|
151
|
+
* checkpointId: The current checkpoint ID from the backend.
|
|
152
|
+
* Checkpoints are named snapshots of the blob set for performance.
|
|
153
|
+
* Updated after each successful checkpoint operation.
|
|
154
|
+
*
|
|
155
|
+
* pendingAdded: Blob names that have been uploaded but not yet checkpointed.
|
|
156
|
+
* Accumulated until CHECKPOINT_THRESHOLD is reached.
|
|
157
|
+
*
|
|
158
|
+
* pendingDeleted: Blob names that have been removed but not yet checkpointed.
|
|
159
|
+
* Accumulated until CHECKPOINT_THRESHOLD is reached.
|
|
160
|
+
*
|
|
161
|
+
* Note: Checkpointing and indexing are independent operations.
|
|
162
|
+
* A blob can be checkpointed but not indexed, indexed but not checkpointed,
|
|
163
|
+
* both, or neither.
|
|
164
|
+
*/
|
|
165
|
+
this.blobMap = new Map();
|
|
166
|
+
this.pendingAdded = new Set();
|
|
167
|
+
this.pendingDeleted = new Set();
|
|
168
|
+
// Mutex for serializing state-modifying operations (upload, checkpoint, etc.)
|
|
169
|
+
this.mutex = new Mutex();
|
|
170
|
+
// Mutex for serializing polling operations to prevent unbounded concurrent requests
|
|
171
|
+
// to the backend's findMissing endpoint. Without this, concurrent addToIndex() calls
|
|
172
|
+
// could result in many simultaneous polling loops hitting the backend.
|
|
173
|
+
this.pollingMutex = new Mutex();
|
|
174
|
+
this.debug = debug;
|
|
175
|
+
// Initialize API client
|
|
176
|
+
this.apiClient = new ContextAPIClient({
|
|
177
|
+
apiKey,
|
|
178
|
+
apiUrl,
|
|
179
|
+
debug,
|
|
180
|
+
});
|
|
181
|
+
// Initialize blob calculator
|
|
182
|
+
this.blobCalculator = new BlobNameCalculator(DirectContext.MAX_FILE_SIZE_BYTES);
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Log a debug message if debug mode is enabled
|
|
186
|
+
*/
|
|
187
|
+
log(message) {
|
|
188
|
+
if (this.debug) {
|
|
189
|
+
console.log(`[DirectContext] ${message}`);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
/**
|
|
193
|
+
* Create a checkpoint if threshold is reached
|
|
194
|
+
*/
|
|
195
|
+
async maybeCheckpoint() {
|
|
196
|
+
const pendingChanges = this.pendingAdded.size + this.pendingDeleted.size;
|
|
197
|
+
if (pendingChanges < DirectContext.CHECKPOINT_THRESHOLD) {
|
|
198
|
+
this.log(`Skipping checkpoint: ${pendingChanges} pending changes (threshold: ${DirectContext.CHECKPOINT_THRESHOLD})`);
|
|
199
|
+
return;
|
|
200
|
+
}
|
|
201
|
+
// Get blob names for checkpoint (both sets already contain blob names)
|
|
202
|
+
const addedBlobs = Array.from(this.pendingAdded);
|
|
203
|
+
const deletedBlobs = Array.from(this.pendingDeleted);
|
|
204
|
+
this.log(`Creating checkpoint: ${addedBlobs.length} added, ${deletedBlobs.length} deleted blobs`);
|
|
205
|
+
const blobs = {
|
|
206
|
+
checkpointId: this.checkpointId,
|
|
207
|
+
addedBlobs: addedBlobs.sort(),
|
|
208
|
+
deletedBlobs: deletedBlobs.sort(),
|
|
209
|
+
};
|
|
210
|
+
const result = await retryWithBackoff(() => this.apiClient.checkpointBlobs(blobs), this.debug);
|
|
211
|
+
this.checkpointId = result.newCheckpointId;
|
|
212
|
+
this.log(`Checkpoint created: ${this.checkpointId}`);
|
|
213
|
+
// Clear pending changes after successful checkpoint
|
|
214
|
+
this.pendingAdded.clear();
|
|
215
|
+
this.pendingDeleted.clear();
|
|
216
|
+
}
|
|
217
|
+
/**
|
|
218
|
+
* Get the list of indexed file paths
|
|
219
|
+
*/
|
|
220
|
+
getIndexedPaths() {
|
|
221
|
+
return Array.from(this.blobMap.keys());
|
|
222
|
+
}
|
|
223
|
+
/**
|
|
224
|
+
* Add files to the index by uploading them to the backend.
|
|
225
|
+
*
|
|
226
|
+
* By default, this method waits for the uploaded files to be fully indexed
|
|
227
|
+
* on the backend before returning. Set `waitForIndexing: false` to return
|
|
228
|
+
* immediately after upload completes (indexing will continue asynchronously).
|
|
229
|
+
*
|
|
230
|
+
* @param files - Array of files to add to the index
|
|
231
|
+
* @param options - Optional configuration
|
|
232
|
+
* @param options.waitForIndexing - If true (default), waits for the newly added files to be indexed before returning
|
|
233
|
+
* @returns Result indicating which files were newly uploaded vs already uploaded
|
|
234
|
+
*/
|
|
235
|
+
async addToIndex(files, options) {
|
|
236
|
+
const waitForIndexing = options?.waitForIndexing ?? true;
|
|
237
|
+
const result = await this.mutex.runExclusive(() => this.doAddToIndex(files));
|
|
238
|
+
if (waitForIndexing && result.newlyUploaded.length > 0) {
|
|
239
|
+
// Wait for the newly uploaded files to be indexed
|
|
240
|
+
// These paths are guaranteed to be in blobMap since they were just added in doAddToIndex
|
|
241
|
+
const newlyUploadedBlobNames = result.newlyUploaded
|
|
242
|
+
.map((path) => this.blobMap.get(path))
|
|
243
|
+
.filter((blobName) => blobName !== undefined);
|
|
244
|
+
await this.waitForSpecificBlobs(newlyUploadedBlobNames);
|
|
245
|
+
}
|
|
246
|
+
return result;
|
|
247
|
+
}
|
|
248
|
+
/**
|
|
249
|
+
* Check which blobs are missing or not yet indexed on the server
|
|
250
|
+
*
|
|
251
|
+
* @param blobNames - Array of blob names to check
|
|
252
|
+
* @param includeNonIndexed - If true, includes blobs that are uploaded but not yet indexed.
|
|
253
|
+
* If false, only returns blobs that need to be uploaded.
|
|
254
|
+
* @returns Array of blob names that are either missing or not indexed (depending on flag)
|
|
255
|
+
*/
|
|
256
|
+
async findMissingBlobs(blobNames, includeNonIndexed = false) {
|
|
257
|
+
const allMissing = [];
|
|
258
|
+
for (let i = 0; i < blobNames.length; i += DirectContext.MAX_FIND_MISSING_SIZE) {
|
|
259
|
+
const batch = blobNames.slice(i, i + DirectContext.MAX_FIND_MISSING_SIZE);
|
|
260
|
+
const result = await retryWithBackoff(() => this.apiClient.findMissing(batch), this.debug);
|
|
261
|
+
allMissing.push(...result.unknownBlobNames);
|
|
262
|
+
if (includeNonIndexed) {
|
|
263
|
+
allMissing.push(...result.nonindexedBlobNames);
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
return allMissing;
|
|
267
|
+
}
|
|
268
|
+
/**
|
|
269
|
+
* Upload files in batches respecting backend limits
|
|
270
|
+
*/
|
|
271
|
+
async batchUploadFiles(filesToUpload) {
|
|
272
|
+
const batches = [];
|
|
273
|
+
let currentBatch = [];
|
|
274
|
+
let currentBatchSize = 0;
|
|
275
|
+
for (const file of filesToUpload) {
|
|
276
|
+
const fileSize = Buffer.byteLength(file.text, "utf-8");
|
|
277
|
+
const wouldExceedCount = currentBatch.length >= DirectContext.MAX_BATCH_UPLOAD_SIZE;
|
|
278
|
+
const wouldExceedSize = currentBatchSize + fileSize > DirectContext.MAX_BATCH_CONTENT_BYTES;
|
|
279
|
+
if (wouldExceedCount || wouldExceedSize) {
|
|
280
|
+
if (currentBatch.length > 0) {
|
|
281
|
+
batches.push(currentBatch);
|
|
282
|
+
}
|
|
283
|
+
currentBatch = [file];
|
|
284
|
+
currentBatchSize = fileSize;
|
|
285
|
+
}
|
|
286
|
+
else {
|
|
287
|
+
currentBatch.push(file);
|
|
288
|
+
currentBatchSize += fileSize;
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
if (currentBatch.length > 0) {
|
|
292
|
+
batches.push(currentBatch);
|
|
293
|
+
}
|
|
294
|
+
for (const batch of batches) {
|
|
295
|
+
await retryWithBackoff(() => this.apiClient.batchUpload(batch), this.debug);
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
/**
|
|
299
|
+
* Validate that all files are within size limits
|
|
300
|
+
*/
|
|
301
|
+
validateFileSizes(files) {
|
|
302
|
+
for (const file of files) {
|
|
303
|
+
const sizeBytes = Buffer.byteLength(file.contents, "utf-8");
|
|
304
|
+
if (sizeBytes > DirectContext.MAX_FILE_SIZE_BYTES) {
|
|
305
|
+
throw new Error(`File ${file.path} is too large (${sizeBytes} bytes). Maximum size is ${DirectContext.MAX_FILE_SIZE_BYTES} bytes (1MB).`);
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
/**
|
|
310
|
+
* Calculate blob names and prepare upload data for files
|
|
311
|
+
* Returns files that need uploading, new blob entries, and already uploaded files
|
|
312
|
+
*/
|
|
313
|
+
prepareBlobsForUpload(files) {
|
|
314
|
+
const filesToUpload = [];
|
|
315
|
+
const newBlobEntries = [];
|
|
316
|
+
const alreadyUploaded = [];
|
|
317
|
+
for (const file of files) {
|
|
318
|
+
const blobName = this.blobCalculator.calculate(file.path, file.contents);
|
|
319
|
+
if (blobName) {
|
|
320
|
+
const existingBlobName = this.blobMap.get(file.path);
|
|
321
|
+
if (existingBlobName && existingBlobName === blobName) {
|
|
322
|
+
// File content hasn't changed
|
|
323
|
+
alreadyUploaded.push(file.path);
|
|
324
|
+
continue;
|
|
325
|
+
}
|
|
326
|
+
// Handle file replacement: if a file with this path already exists
|
|
327
|
+
if (existingBlobName) {
|
|
328
|
+
this.handleBlobReplacement(existingBlobName);
|
|
329
|
+
}
|
|
330
|
+
newBlobEntries.push([file.path, blobName]);
|
|
331
|
+
filesToUpload.push({
|
|
332
|
+
blobName,
|
|
333
|
+
pathName: file.path,
|
|
334
|
+
text: file.contents,
|
|
335
|
+
metadata: [],
|
|
336
|
+
});
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
return { filesToUpload, newBlobEntries, alreadyUploaded };
|
|
340
|
+
}
|
|
341
|
+
/**
|
|
342
|
+
* Handle replacing an existing blob (track deletion of old blob)
|
|
343
|
+
*/
|
|
344
|
+
handleBlobReplacement(oldBlobName) {
|
|
345
|
+
// Check if the old blob is in pendingAdded
|
|
346
|
+
if (this.pendingAdded.has(oldBlobName)) {
|
|
347
|
+
// Old blob was added in this session, just remove it from pendingAdded
|
|
348
|
+
this.pendingAdded.delete(oldBlobName);
|
|
349
|
+
}
|
|
350
|
+
else {
|
|
351
|
+
// Old blob was from a previous checkpoint, add to deletedBlobs
|
|
352
|
+
this.pendingDeleted.add(oldBlobName);
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
/**
|
|
356
|
+
* Categorize files into newly uploaded vs already on server based on server response
|
|
357
|
+
*/
|
|
358
|
+
categorizeFiles(newBlobEntries, // [path, blobName]
|
|
359
|
+
missingBlobSet) {
|
|
360
|
+
const newlyUploaded = [];
|
|
361
|
+
const alreadyOnServer = [];
|
|
362
|
+
for (const [path, blobName] of newBlobEntries) {
|
|
363
|
+
if (missingBlobSet.has(blobName)) {
|
|
364
|
+
newlyUploaded.push(path);
|
|
365
|
+
}
|
|
366
|
+
else {
|
|
367
|
+
alreadyOnServer.push(path);
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
return { newlyUploaded, alreadyOnServer };
|
|
371
|
+
}
|
|
372
|
+
/**
|
|
373
|
+
* Internal implementation of addToIndex
|
|
374
|
+
*/
|
|
375
|
+
async doAddToIndex(files) {
|
|
376
|
+
this.log(`Adding ${files.length} files to index`);
|
|
377
|
+
// Validate file sizes
|
|
378
|
+
this.validateFileSizes(files);
|
|
379
|
+
// Calculate blob names and prepare uploads
|
|
380
|
+
const { filesToUpload, newBlobEntries, alreadyUploaded } = this.prepareBlobsForUpload(files);
|
|
381
|
+
if (newBlobEntries.length === 0) {
|
|
382
|
+
return { newlyUploaded: [], alreadyUploaded };
|
|
383
|
+
}
|
|
384
|
+
// Check which blobs the server already has
|
|
385
|
+
const blobNamesToCheck = newBlobEntries.map(([_, blobName]) => blobName);
|
|
386
|
+
this.log(`Checking ${blobNamesToCheck.length} blobs with server`);
|
|
387
|
+
const missingBlobNames = await this.findMissingBlobs(blobNamesToCheck);
|
|
388
|
+
const missingBlobSet = new Set(missingBlobNames);
|
|
389
|
+
this.log(`Server is missing ${missingBlobNames.length} blobs`);
|
|
390
|
+
// Categorize files
|
|
391
|
+
const { newlyUploaded, alreadyOnServer } = this.categorizeFiles(newBlobEntries, missingBlobSet);
|
|
392
|
+
// Upload only missing files
|
|
393
|
+
const filesToActuallyUpload = filesToUpload.filter((file) => missingBlobSet.has(file.blobName));
|
|
394
|
+
if (filesToActuallyUpload.length > 0) {
|
|
395
|
+
this.log(`Uploading ${filesToActuallyUpload.length} files to backend`);
|
|
396
|
+
await this.batchUploadFiles(filesToActuallyUpload);
|
|
397
|
+
this.log("Upload complete");
|
|
398
|
+
}
|
|
399
|
+
// Update blob tracking state
|
|
400
|
+
for (const [path, blobName] of newBlobEntries) {
|
|
401
|
+
this.pendingAdded.add(blobName);
|
|
402
|
+
this.pendingDeleted.delete(blobName);
|
|
403
|
+
this.blobMap.set(path, blobName);
|
|
404
|
+
}
|
|
405
|
+
await this.maybeCheckpoint();
|
|
406
|
+
return {
|
|
407
|
+
newlyUploaded,
|
|
408
|
+
alreadyUploaded: [...alreadyUploaded, ...alreadyOnServer],
|
|
409
|
+
};
|
|
410
|
+
}
|
|
411
|
+
/**
|
|
412
|
+
* Remove paths from the index
|
|
413
|
+
*/
|
|
414
|
+
async removeFromIndex(paths) {
|
|
415
|
+
return await this.mutex.runExclusive(() => this.doRemoveFromIndex(paths));
|
|
416
|
+
}
|
|
417
|
+
/**
|
|
418
|
+
* Internal implementation of removeFromIndex
|
|
419
|
+
*/
|
|
420
|
+
async doRemoveFromIndex(paths) {
|
|
421
|
+
for (const path of paths) {
|
|
422
|
+
const blobName = this.blobMap.get(path);
|
|
423
|
+
if (blobName) {
|
|
424
|
+
if (this.pendingAdded.has(blobName)) {
|
|
425
|
+
this.pendingAdded.delete(blobName);
|
|
426
|
+
}
|
|
427
|
+
else {
|
|
428
|
+
this.pendingDeleted.add(blobName);
|
|
429
|
+
}
|
|
430
|
+
this.blobMap.delete(path);
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
await this.maybeCheckpoint();
|
|
434
|
+
}
|
|
435
|
+
/**
|
|
436
|
+
* Clear the entire index
|
|
437
|
+
*/
|
|
438
|
+
async clearIndex() {
|
|
439
|
+
return await this.mutex.runExclusive(() => this.doClearIndex());
|
|
440
|
+
}
|
|
441
|
+
/**
|
|
442
|
+
* Internal implementation of clearIndex
|
|
443
|
+
*/
|
|
444
|
+
doClearIndex() {
|
|
445
|
+
this.log(`Clearing index (${this.blobMap.size} files)`);
|
|
446
|
+
this.checkpointId = undefined;
|
|
447
|
+
this.blobMap.clear();
|
|
448
|
+
this.pendingAdded.clear();
|
|
449
|
+
this.pendingDeleted.clear();
|
|
450
|
+
this.log("Index cleared");
|
|
451
|
+
return Promise.resolve();
|
|
452
|
+
}
|
|
453
|
+
/**
|
|
454
|
+
* Wait for specific blobs to be indexed on the backend
|
|
455
|
+
*
|
|
456
|
+
* This method is serialized via pollingMutex to prevent unbounded concurrent
|
|
457
|
+
* polling requests to the backend.
|
|
458
|
+
*/
|
|
459
|
+
waitForSpecificBlobs(blobNames) {
|
|
460
|
+
return this.pollingMutex.runExclusive(async () => {
|
|
461
|
+
if (blobNames.length === 0) {
|
|
462
|
+
this.log("No blobs to wait for");
|
|
463
|
+
return;
|
|
464
|
+
}
|
|
465
|
+
this.log(`Waiting for ${blobNames.length} blobs to be indexed on backend`);
|
|
466
|
+
const initialPollIntervalMs = 3000;
|
|
467
|
+
const backoffThresholdMs = 60000;
|
|
468
|
+
const backoffPollIntervalMs = 60000;
|
|
469
|
+
const maxWaitTimeMs = 600000;
|
|
470
|
+
const startTime = Date.now();
|
|
471
|
+
while (true) {
|
|
472
|
+
// Check for blobs that are not yet indexed (either not uploaded or uploaded but not indexed)
|
|
473
|
+
const stillPending = await this.findMissingBlobs(blobNames, true);
|
|
474
|
+
if (stillPending.length === 0) {
|
|
475
|
+
this.log("All blobs indexed successfully");
|
|
476
|
+
return;
|
|
477
|
+
}
|
|
478
|
+
const elapsedMs = Date.now() - startTime;
|
|
479
|
+
this.log(`Still waiting for ${stillPending.length} blobs to be indexed (elapsed: ${Math.round(elapsedMs / 1000)}s)`);
|
|
480
|
+
if (elapsedMs >= maxWaitTimeMs) {
|
|
481
|
+
throw new Error(`Indexing timeout: Backend did not finish indexing within ${maxWaitTimeMs / 1000} seconds`);
|
|
482
|
+
}
|
|
483
|
+
const pollIntervalMs = elapsedMs < backoffThresholdMs
|
|
484
|
+
? initialPollIntervalMs
|
|
485
|
+
: backoffPollIntervalMs;
|
|
486
|
+
await new Promise((resolve) => setTimeout(resolve, pollIntervalMs));
|
|
487
|
+
}
|
|
488
|
+
});
|
|
489
|
+
}
|
|
490
|
+
/**
|
|
491
|
+
* Wait for all indexed files to be fully indexed on the backend.
|
|
492
|
+
*
|
|
493
|
+
* This method polls the backend until all files that have been added to the index
|
|
494
|
+
* are confirmed to be indexed and searchable.
|
|
495
|
+
*
|
|
496
|
+
* @returns Promise that resolves when all files are indexed
|
|
497
|
+
* @throws Error if indexing times out (default: 10 minutes)
|
|
498
|
+
*/
|
|
499
|
+
async waitForIndexing() {
|
|
500
|
+
const blobNames = Array.from(this.blobMap.values());
|
|
501
|
+
await this.waitForSpecificBlobs(blobNames);
|
|
502
|
+
}
|
|
503
|
+
/**
|
|
504
|
+
* Search the codebase using natural language and return formatted results.
|
|
505
|
+
*
|
|
506
|
+
* The results are returned as a formatted string designed for use in LLM prompts.
|
|
507
|
+
* The format includes file paths, line numbers, and code content in a structured,
|
|
508
|
+
* readable format that can be passed directly to LLM APIs like `generate()`.
|
|
509
|
+
*
|
|
510
|
+
* Note: This method does not wait for indexing. Ensure files are indexed before
|
|
511
|
+
* searching by either:
|
|
512
|
+
* - Using `addToIndex()` with `waitForIndexing: true` (default)
|
|
513
|
+
* - Calling `waitForIndexing()` explicitly before searching
|
|
514
|
+
*
|
|
515
|
+
* @param query - The search query describing what code you're looking for
|
|
516
|
+
* @param options - Optional search options
|
|
517
|
+
* @param options.maxOutputLength - Maximum character length of the formatted output (default: 20000, max: 80000)
|
|
518
|
+
* @returns A formatted string containing the search results, ready for LLM consumption
|
|
519
|
+
*/
|
|
520
|
+
async search(query, options) {
|
|
521
|
+
this.log(`Searching for: "${query}"`);
|
|
522
|
+
if (this.blobMap.size === 0) {
|
|
523
|
+
throw new Error("Index not initialized. Add files to index first using addToIndex().");
|
|
524
|
+
}
|
|
525
|
+
const blobs = {
|
|
526
|
+
checkpointId: this.checkpointId,
|
|
527
|
+
addedBlobs: Array.from(this.pendingAdded).sort(),
|
|
528
|
+
deletedBlobs: Array.from(this.pendingDeleted).sort(),
|
|
529
|
+
};
|
|
530
|
+
this.log(`Executing search with checkpoint ${this.checkpointId || "(none)"}, ${this.blobMap.size} indexed files`);
|
|
531
|
+
const requestId = this.apiClient.createRequestId();
|
|
532
|
+
const result = await this.apiClient.agentCodebaseRetrieval(requestId, query, blobs, options?.maxOutputLength);
|
|
533
|
+
this.log("Search completed successfully");
|
|
534
|
+
return result.formattedRetrieval;
|
|
535
|
+
}
|
|
536
|
+
/**
|
|
537
|
+
* Search the indexed codebase and ask an LLM a question about the results.
|
|
538
|
+
*
|
|
539
|
+
* This is a convenience method that combines search() with an LLM call to answer
|
|
540
|
+
* questions about your codebase.
|
|
541
|
+
*
|
|
542
|
+
* Note: This method does not wait for indexing. Ensure files are indexed before
|
|
543
|
+
* searching by either:
|
|
544
|
+
* - Using `addToIndex()` with `waitForIndexing: true` (default)
|
|
545
|
+
* - Calling `waitForIndexing()` explicitly before searching
|
|
546
|
+
*
|
|
547
|
+
* @param searchQuery - The semantic search query to find relevant code (also used as the prompt if no separate prompt is provided)
|
|
548
|
+
* @param prompt - Optional prompt to ask the LLM about the search results. If not provided, searchQuery is used as the prompt.
|
|
549
|
+
* @returns The LLM's answer to your question
|
|
550
|
+
*
|
|
551
|
+
* @example
|
|
552
|
+
* ```typescript
|
|
553
|
+
* const answer = await context.searchAndAsk(
|
|
554
|
+
* "How does the authentication flow work?"
|
|
555
|
+
* );
|
|
556
|
+
* console.log(answer);
|
|
557
|
+
* ```
|
|
558
|
+
*/
|
|
559
|
+
async searchAndAsk(searchQuery, prompt) {
|
|
560
|
+
const results = await this.search(searchQuery);
|
|
561
|
+
const llmPrompt = formatSearchPrompt(prompt ?? searchQuery, results);
|
|
562
|
+
return await this.apiClient.chat(llmPrompt);
|
|
563
|
+
}
|
|
564
|
+
/**
|
|
565
|
+
* Export the current state to a JSON object
|
|
566
|
+
*/
|
|
567
|
+
export() {
|
|
568
|
+
// Convert blobMap to array of [blobName, path] tuples
|
|
569
|
+
const blobs = [];
|
|
570
|
+
for (const [path, blobName] of this.blobMap.entries()) {
|
|
571
|
+
blobs.push([blobName, path]);
|
|
572
|
+
}
|
|
573
|
+
// Export pending added blobs (blobs added since last checkpoint)
|
|
574
|
+
const addedBlobs = Array.from(this.pendingAdded);
|
|
575
|
+
// Export pending deleted blobs (blobs deleted since last checkpoint)
|
|
576
|
+
const deletedBlobs = Array.from(this.pendingDeleted);
|
|
577
|
+
return {
|
|
578
|
+
checkpointId: this.checkpointId,
|
|
579
|
+
addedBlobs,
|
|
580
|
+
deletedBlobs,
|
|
581
|
+
blobs,
|
|
582
|
+
};
|
|
583
|
+
}
|
|
584
|
+
/**
|
|
585
|
+
* Internal method to import state from a JSON object
|
|
586
|
+
*/
|
|
587
|
+
async doImport(state) {
|
|
588
|
+
return await this.mutex.runExclusive(() => {
|
|
589
|
+
this.checkpointId = state.checkpointId;
|
|
590
|
+
this.blobMap.clear();
|
|
591
|
+
this.pendingAdded.clear();
|
|
592
|
+
this.pendingDeleted.clear();
|
|
593
|
+
// Restore blobMap from blobs array [blobName, path]
|
|
594
|
+
if (state.blobs) {
|
|
595
|
+
for (const [blobName, path] of state.blobs) {
|
|
596
|
+
this.blobMap.set(path, blobName);
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
// Restore pending added blobs - directly copy the array to set
|
|
600
|
+
if (state.addedBlobs && state.addedBlobs.length > 0) {
|
|
601
|
+
this.pendingAdded = new Set(state.addedBlobs);
|
|
602
|
+
}
|
|
603
|
+
// Restore pending deleted blobs - directly copy the array to set
|
|
604
|
+
if (state.deletedBlobs && state.deletedBlobs.length > 0) {
|
|
605
|
+
this.pendingDeleted = new Set(state.deletedBlobs);
|
|
606
|
+
}
|
|
607
|
+
this.log(`State imported: checkpoint ${this.checkpointId}, ${this.blobMap.size} files, ${this.pendingAdded.size} pending added, ${this.pendingDeleted.size} pending deleted`);
|
|
608
|
+
});
|
|
609
|
+
}
|
|
610
|
+
/**
|
|
611
|
+
* Export state to a file (Node.js only)
|
|
612
|
+
*/
|
|
613
|
+
async exportToFile(filePath) {
|
|
614
|
+
const state = this.export();
|
|
615
|
+
await writeFile(filePath, JSON.stringify(state, null, 2), "utf-8");
|
|
616
|
+
this.log(`State saved to ${filePath}`);
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
DirectContext.MAX_FILE_SIZE_BYTES = 1048576; // 1MB
|
|
620
|
+
DirectContext.MAX_BATCH_UPLOAD_SIZE = 1000;
|
|
621
|
+
DirectContext.MAX_BATCH_CONTENT_BYTES = 2 * 1024 * 1024; // 2MB
|
|
622
|
+
DirectContext.MAX_FIND_MISSING_SIZE = 1000;
|
|
623
|
+
DirectContext.CHECKPOINT_THRESHOLD = 1000;
|
|
624
|
+
//# sourceMappingURL=direct-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"direct-context.js","sourceRoot":"","sources":["../../src/context/direct-context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,gBAAgB,EAAmB,MAAM,uBAAuB,CAAC;AAC1E,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AACrE,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAS5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0DG;AACH,MAAM,OAAO,aAAa;IA6CxB;;;;;;;;;;OAUG;IACH,MAAM,CAAC,KAAK,CAAC,MAAM,CACjB,UAAgC,EAAE;QAElC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,aAAa,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC;QAC3E,OAAO,IAAI,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,KAAK,CAAC,CAAC;IACnE,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CAAC,KAAK,CAAC,MAAM,CACjB,KAAyB,EACzB,UAAgC,EAAE;QAElC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,aAAa,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC;QAC3E,MAAM,QAAQ,GAAG,IAAI,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,KAAK,CAAC,CAAC;QAC3E,MAAM,QAAQ,CAAC,QAAQ,CAAC,K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