@xpert-ai/xpert-sdk 0.1.0 → 0.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/dist/client.d.ts +2 -2
- package/dist/client.js +2 -2
- package/dist/client.mjs +2 -2
- package/dist/schema.d.ts +2 -0
- package/dist/schema.js.map +1 -1
- package/dist/schema.mjs.map +1 -1
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -253,11 +253,11 @@ export declare class ThreadsClient<TStateType = DefaultValues, TUpdateType = TSt
|
|
|
253
253
|
*/
|
|
254
254
|
get<ValuesType = TStateType>(threadId: string): Promise<Thread<ValuesType>>;
|
|
255
255
|
/**
|
|
256
|
-
* Get
|
|
256
|
+
* Get the last measured context usage for an agent in a thread.
|
|
257
257
|
*
|
|
258
258
|
* @param threadId ID of the thread.
|
|
259
259
|
* @param options.agentKey Agent key for usage filtering.
|
|
260
|
-
* @returns
|
|
260
|
+
* @returns Usage and freshness; run_id and updated_at identify the measurement.
|
|
261
261
|
*/
|
|
262
262
|
getContextUsage(threadId: string, options?: {
|
|
263
263
|
agentKey?: string;
|
package/dist/client.js
CHANGED
|
@@ -529,11 +529,11 @@ export class ThreadsClient extends BaseClient {
|
|
|
529
529
|
return this.fetch(`/threads/${threadId}`);
|
|
530
530
|
}
|
|
531
531
|
/**
|
|
532
|
-
* Get
|
|
532
|
+
* Get the last measured context usage for an agent in a thread.
|
|
533
533
|
*
|
|
534
534
|
* @param threadId ID of the thread.
|
|
535
535
|
* @param options.agentKey Agent key for usage filtering.
|
|
536
|
-
* @returns
|
|
536
|
+
* @returns Usage and freshness; run_id and updated_at identify the measurement.
|
|
537
537
|
*/
|
|
538
538
|
async getContextUsage(threadId, options) {
|
|
539
539
|
return this.fetch(`/threads/${threadId}/context-usage`, {
|
package/dist/client.mjs
CHANGED
|
@@ -529,11 +529,11 @@ export class ThreadsClient extends BaseClient {
|
|
|
529
529
|
return this.fetch(`/threads/${threadId}`);
|
|
530
530
|
}
|
|
531
531
|
/**
|
|
532
|
-
* Get
|
|
532
|
+
* Get the last measured context usage for an agent in a thread.
|
|
533
533
|
*
|
|
534
534
|
* @param threadId ID of the thread.
|
|
535
535
|
* @param options.agentKey Agent key for usage filtering.
|
|
536
|
-
* @returns
|
|
536
|
+
* @returns Usage and freshness; run_id and updated_at identify the measurement.
|
|
537
537
|
*/
|
|
538
538
|
async getContextUsage(threadId, options) {
|
|
539
539
|
return this.fetch(`/threads/${threadId}/context-usage`, {
|
package/dist/schema.d.ts
CHANGED
|
@@ -179,6 +179,8 @@ export interface ThreadContextUsage {
|
|
|
179
179
|
agent_key: string | null;
|
|
180
180
|
run_id: string | null;
|
|
181
181
|
updated_at: string | null;
|
|
182
|
+
/** Freshness of the measurement. Optional for older servers. */
|
|
183
|
+
status?: "current" | "stale" | "unavailable";
|
|
182
184
|
usage: {
|
|
183
185
|
context_tokens: number;
|
|
184
186
|
input_tokens: number;
|
package/dist/schema.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AA4dA;;GAEG;AACH,MAAM,CAAN,IAAY,uBAcX;AAdD,WAAY,uBAAuB;IACjC;;;OAGG;IACH,8CAAmB,CAAA;IACnB;;OAEG;IACH,wDAA6B,CAAA;IAC7B;;OAEG;IACH,4CAAiB,CAAA;AACnB,CAAC,EAdW,uBAAuB,KAAvB,uBAAuB,QAclC;AA+BD,MAAM,CAAN,IAAY,eAQX;AARD,WAAY,eAAe;IACzB,8BAAW,CAAA;IACX,oDAAiC,CAAA;IACjC,oCAAiB,CAAA;IACjB,8CAA2B,CAAA;IAC3B,4CAAyB,CAAA;IACzB,8BAAW,CAAA;IACX,wCAAqB,CAAA;AACvB,CAAC,EARW,eAAe,KAAf,eAAe,QAQ1B"}
|
package/dist/schema.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.mjs","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"schema.mjs","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AA4dA;;GAEG;AACH,MAAM,CAAN,IAAY,uBAcX;AAdD,WAAY,uBAAuB;IACjC;;;OAGG;IACH,8CAAmB,CAAA;IACnB;;OAEG;IACH,wDAA6B,CAAA;IAC7B;;OAEG;IACH,4CAAiB,CAAA;AACnB,CAAC,EAdW,uBAAuB,KAAvB,uBAAuB,QAclC;AA+BD,MAAM,CAAN,IAAY,eAQX;AARD,WAAY,eAAe;IACzB,8BAAW,CAAA;IACX,oDAAiC,CAAA;IACjC,oCAAiB,CAAA;IACjB,8CAA2B,CAAA;IAC3B,4CAAyB,CAAA;IACzB,8BAAW,CAAA;IACX,wCAAqB,CAAA;AACvB,CAAC,EARW,eAAe,KAAf,eAAe,QAQ1B"}
|