opik 2.1.21 → 2.1.23
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/chunk-EVP4RLIU.js +404 -0
- package/dist/index.cjs +36 -36
- package/dist/index.d.cts +54 -0
- package/dist/index.d.ts +54 -0
- package/dist/index.js +1 -1
- package/dist/{suite-FNWKXIIP.js → suite-CXJIINJ3.js} +1 -1
- package/package.json +1 -1
- package/dist/chunk-D3NTBFFR.js +0 -404
package/dist/index.d.cts
CHANGED
|
@@ -2880,6 +2880,16 @@ interface SpanSearchStreamRequestPublic {
|
|
|
2880
2880
|
toTime?: Date;
|
|
2881
2881
|
}
|
|
2882
2882
|
|
|
2883
|
+
/**
|
|
2884
|
+
* @example
|
|
2885
|
+
* {}
|
|
2886
|
+
*/
|
|
2887
|
+
interface SpansExistRequest {
|
|
2888
|
+
projectId?: string;
|
|
2889
|
+
projectName?: string;
|
|
2890
|
+
source?: string;
|
|
2891
|
+
}
|
|
2892
|
+
|
|
2883
2893
|
/**
|
|
2884
2894
|
* @example
|
|
2885
2895
|
* {
|
|
@@ -3227,6 +3237,17 @@ interface TraceSearchStreamRequestPublic {
|
|
|
3227
3237
|
toTime?: Date;
|
|
3228
3238
|
}
|
|
3229
3239
|
|
|
3240
|
+
/**
|
|
3241
|
+
* @example
|
|
3242
|
+
* {}
|
|
3243
|
+
*/
|
|
3244
|
+
interface TracesExistRequest {
|
|
3245
|
+
projectId?: string;
|
|
3246
|
+
projectName?: string;
|
|
3247
|
+
source?: string;
|
|
3248
|
+
threadOnly?: boolean;
|
|
3249
|
+
}
|
|
3250
|
+
|
|
3230
3251
|
/**
|
|
3231
3252
|
* @example
|
|
3232
3253
|
* {}
|
|
@@ -5139,6 +5160,11 @@ interface ExecutionPolicyWrite {
|
|
|
5139
5160
|
passThreshold?: number;
|
|
5140
5161
|
}
|
|
5141
5162
|
|
|
5163
|
+
interface ExistenceResponse {
|
|
5164
|
+
/** Whether the project has at least one matching entity for the given scope */
|
|
5165
|
+
exists?: boolean;
|
|
5166
|
+
}
|
|
5167
|
+
|
|
5142
5168
|
interface ExperimentExecutionResponse {
|
|
5143
5169
|
experiments?: ExperimentInfo[];
|
|
5144
5170
|
totalItems?: number;
|
|
@@ -5840,6 +5866,7 @@ interface LlmAsJudgeCode {
|
|
|
5840
5866
|
messages: LlmAsJudgeMessage[];
|
|
5841
5867
|
variables: Record<string, string>;
|
|
5842
5868
|
schema: LlmAsJudgeOutputSchema[];
|
|
5869
|
+
maxCostUsd?: number;
|
|
5843
5870
|
}
|
|
5844
5871
|
|
|
5845
5872
|
interface LlmAsJudgeCodePublic {
|
|
@@ -5847,6 +5874,7 @@ interface LlmAsJudgeCodePublic {
|
|
|
5847
5874
|
messages: LlmAsJudgeMessagePublic[];
|
|
5848
5875
|
variables: Record<string, string>;
|
|
5849
5876
|
schema: LlmAsJudgeOutputSchemaPublic[];
|
|
5877
|
+
maxCostUsd?: number;
|
|
5850
5878
|
}
|
|
5851
5879
|
|
|
5852
5880
|
interface LlmAsJudgeCodeWrite {
|
|
@@ -5854,6 +5882,7 @@ interface LlmAsJudgeCodeWrite {
|
|
|
5854
5882
|
messages: LlmAsJudgeMessageWrite[];
|
|
5855
5883
|
variables: Record<string, string>;
|
|
5856
5884
|
schema: LlmAsJudgeOutputSchemaWrite[];
|
|
5885
|
+
maxCostUsd?: number;
|
|
5857
5886
|
}
|
|
5858
5887
|
|
|
5859
5888
|
interface LlmAsJudgeMessage {
|
|
@@ -7763,18 +7792,21 @@ interface TraceThreadLlmAsJudgeCode {
|
|
|
7763
7792
|
model: LlmAsJudgeModelParameters;
|
|
7764
7793
|
messages: LlmAsJudgeMessage[];
|
|
7765
7794
|
schema: LlmAsJudgeOutputSchema[];
|
|
7795
|
+
maxCostUsd?: number;
|
|
7766
7796
|
}
|
|
7767
7797
|
|
|
7768
7798
|
interface TraceThreadLlmAsJudgeCodePublic {
|
|
7769
7799
|
model: LlmAsJudgeModelParametersPublic;
|
|
7770
7800
|
messages: LlmAsJudgeMessagePublic[];
|
|
7771
7801
|
schema: LlmAsJudgeOutputSchemaPublic[];
|
|
7802
|
+
maxCostUsd?: number;
|
|
7772
7803
|
}
|
|
7773
7804
|
|
|
7774
7805
|
interface TraceThreadLlmAsJudgeCodeWrite {
|
|
7775
7806
|
model: LlmAsJudgeModelParametersWrite;
|
|
7776
7807
|
messages: LlmAsJudgeMessageWrite[];
|
|
7777
7808
|
schema: LlmAsJudgeOutputSchemaWrite[];
|
|
7809
|
+
maxCostUsd?: number;
|
|
7778
7810
|
}
|
|
7779
7811
|
|
|
7780
7812
|
interface TraceThreadPage {
|
|
@@ -12354,6 +12386,17 @@ declare class SpansClient {
|
|
|
12354
12386
|
*/
|
|
12355
12387
|
searchSpans(request?: SpanSearchStreamRequestPublic, requestOptions?: SpansClient.RequestOptions): HttpResponsePromise<ReadableStream<Uint8Array>>;
|
|
12356
12388
|
private __searchSpans;
|
|
12389
|
+
/**
|
|
12390
|
+
* Returns whether the project has at least one span matching the given scope. Cheap existence probe (LIMIT 1) used to drive empty-state decisions without scanning or aggregating the whole project.
|
|
12391
|
+
*
|
|
12392
|
+
* @param {OpikApi.SpansExistRequest} request
|
|
12393
|
+
* @param {SpansClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12394
|
+
*
|
|
12395
|
+
* @example
|
|
12396
|
+
* await client.spans.exist()
|
|
12397
|
+
*/
|
|
12398
|
+
exist(request?: SpansExistRequest, requestOptions?: SpansClient.RequestOptions): HttpResponsePromise<ExistenceResponse>;
|
|
12399
|
+
private __exist;
|
|
12357
12400
|
/**
|
|
12358
12401
|
* Update span comment by id
|
|
12359
12402
|
*
|
|
@@ -12916,6 +12959,17 @@ declare class TracesClient {
|
|
|
12916
12959
|
*/
|
|
12917
12960
|
searchTraces(request?: TraceSearchStreamRequestPublic, requestOptions?: TracesClient.RequestOptions): HttpResponsePromise<ReadableStream<Uint8Array>>;
|
|
12918
12961
|
private __searchTraces;
|
|
12962
|
+
/**
|
|
12963
|
+
* Returns whether the project has at least one trace matching the given scope. Cheap existence probe (LIMIT 1) used to drive empty-state decisions without scanning or aggregating the whole project.
|
|
12964
|
+
*
|
|
12965
|
+
* @param {OpikApi.TracesExistRequest} request
|
|
12966
|
+
* @param {TracesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12967
|
+
*
|
|
12968
|
+
* @example
|
|
12969
|
+
* await client.traces.exist()
|
|
12970
|
+
*/
|
|
12971
|
+
exist(request?: TracesExistRequest, requestOptions?: TracesClient.RequestOptions): HttpResponsePromise<ExistenceResponse>;
|
|
12972
|
+
private __exist;
|
|
12919
12973
|
/**
|
|
12920
12974
|
* Update thread
|
|
12921
12975
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -2880,6 +2880,16 @@ interface SpanSearchStreamRequestPublic {
|
|
|
2880
2880
|
toTime?: Date;
|
|
2881
2881
|
}
|
|
2882
2882
|
|
|
2883
|
+
/**
|
|
2884
|
+
* @example
|
|
2885
|
+
* {}
|
|
2886
|
+
*/
|
|
2887
|
+
interface SpansExistRequest {
|
|
2888
|
+
projectId?: string;
|
|
2889
|
+
projectName?: string;
|
|
2890
|
+
source?: string;
|
|
2891
|
+
}
|
|
2892
|
+
|
|
2883
2893
|
/**
|
|
2884
2894
|
* @example
|
|
2885
2895
|
* {
|
|
@@ -3227,6 +3237,17 @@ interface TraceSearchStreamRequestPublic {
|
|
|
3227
3237
|
toTime?: Date;
|
|
3228
3238
|
}
|
|
3229
3239
|
|
|
3240
|
+
/**
|
|
3241
|
+
* @example
|
|
3242
|
+
* {}
|
|
3243
|
+
*/
|
|
3244
|
+
interface TracesExistRequest {
|
|
3245
|
+
projectId?: string;
|
|
3246
|
+
projectName?: string;
|
|
3247
|
+
source?: string;
|
|
3248
|
+
threadOnly?: boolean;
|
|
3249
|
+
}
|
|
3250
|
+
|
|
3230
3251
|
/**
|
|
3231
3252
|
* @example
|
|
3232
3253
|
* {}
|
|
@@ -5139,6 +5160,11 @@ interface ExecutionPolicyWrite {
|
|
|
5139
5160
|
passThreshold?: number;
|
|
5140
5161
|
}
|
|
5141
5162
|
|
|
5163
|
+
interface ExistenceResponse {
|
|
5164
|
+
/** Whether the project has at least one matching entity for the given scope */
|
|
5165
|
+
exists?: boolean;
|
|
5166
|
+
}
|
|
5167
|
+
|
|
5142
5168
|
interface ExperimentExecutionResponse {
|
|
5143
5169
|
experiments?: ExperimentInfo[];
|
|
5144
5170
|
totalItems?: number;
|
|
@@ -5840,6 +5866,7 @@ interface LlmAsJudgeCode {
|
|
|
5840
5866
|
messages: LlmAsJudgeMessage[];
|
|
5841
5867
|
variables: Record<string, string>;
|
|
5842
5868
|
schema: LlmAsJudgeOutputSchema[];
|
|
5869
|
+
maxCostUsd?: number;
|
|
5843
5870
|
}
|
|
5844
5871
|
|
|
5845
5872
|
interface LlmAsJudgeCodePublic {
|
|
@@ -5847,6 +5874,7 @@ interface LlmAsJudgeCodePublic {
|
|
|
5847
5874
|
messages: LlmAsJudgeMessagePublic[];
|
|
5848
5875
|
variables: Record<string, string>;
|
|
5849
5876
|
schema: LlmAsJudgeOutputSchemaPublic[];
|
|
5877
|
+
maxCostUsd?: number;
|
|
5850
5878
|
}
|
|
5851
5879
|
|
|
5852
5880
|
interface LlmAsJudgeCodeWrite {
|
|
@@ -5854,6 +5882,7 @@ interface LlmAsJudgeCodeWrite {
|
|
|
5854
5882
|
messages: LlmAsJudgeMessageWrite[];
|
|
5855
5883
|
variables: Record<string, string>;
|
|
5856
5884
|
schema: LlmAsJudgeOutputSchemaWrite[];
|
|
5885
|
+
maxCostUsd?: number;
|
|
5857
5886
|
}
|
|
5858
5887
|
|
|
5859
5888
|
interface LlmAsJudgeMessage {
|
|
@@ -7763,18 +7792,21 @@ interface TraceThreadLlmAsJudgeCode {
|
|
|
7763
7792
|
model: LlmAsJudgeModelParameters;
|
|
7764
7793
|
messages: LlmAsJudgeMessage[];
|
|
7765
7794
|
schema: LlmAsJudgeOutputSchema[];
|
|
7795
|
+
maxCostUsd?: number;
|
|
7766
7796
|
}
|
|
7767
7797
|
|
|
7768
7798
|
interface TraceThreadLlmAsJudgeCodePublic {
|
|
7769
7799
|
model: LlmAsJudgeModelParametersPublic;
|
|
7770
7800
|
messages: LlmAsJudgeMessagePublic[];
|
|
7771
7801
|
schema: LlmAsJudgeOutputSchemaPublic[];
|
|
7802
|
+
maxCostUsd?: number;
|
|
7772
7803
|
}
|
|
7773
7804
|
|
|
7774
7805
|
interface TraceThreadLlmAsJudgeCodeWrite {
|
|
7775
7806
|
model: LlmAsJudgeModelParametersWrite;
|
|
7776
7807
|
messages: LlmAsJudgeMessageWrite[];
|
|
7777
7808
|
schema: LlmAsJudgeOutputSchemaWrite[];
|
|
7809
|
+
maxCostUsd?: number;
|
|
7778
7810
|
}
|
|
7779
7811
|
|
|
7780
7812
|
interface TraceThreadPage {
|
|
@@ -12354,6 +12386,17 @@ declare class SpansClient {
|
|
|
12354
12386
|
*/
|
|
12355
12387
|
searchSpans(request?: SpanSearchStreamRequestPublic, requestOptions?: SpansClient.RequestOptions): HttpResponsePromise<ReadableStream<Uint8Array>>;
|
|
12356
12388
|
private __searchSpans;
|
|
12389
|
+
/**
|
|
12390
|
+
* Returns whether the project has at least one span matching the given scope. Cheap existence probe (LIMIT 1) used to drive empty-state decisions without scanning or aggregating the whole project.
|
|
12391
|
+
*
|
|
12392
|
+
* @param {OpikApi.SpansExistRequest} request
|
|
12393
|
+
* @param {SpansClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12394
|
+
*
|
|
12395
|
+
* @example
|
|
12396
|
+
* await client.spans.exist()
|
|
12397
|
+
*/
|
|
12398
|
+
exist(request?: SpansExistRequest, requestOptions?: SpansClient.RequestOptions): HttpResponsePromise<ExistenceResponse>;
|
|
12399
|
+
private __exist;
|
|
12357
12400
|
/**
|
|
12358
12401
|
* Update span comment by id
|
|
12359
12402
|
*
|
|
@@ -12916,6 +12959,17 @@ declare class TracesClient {
|
|
|
12916
12959
|
*/
|
|
12917
12960
|
searchTraces(request?: TraceSearchStreamRequestPublic, requestOptions?: TracesClient.RequestOptions): HttpResponsePromise<ReadableStream<Uint8Array>>;
|
|
12918
12961
|
private __searchTraces;
|
|
12962
|
+
/**
|
|
12963
|
+
* Returns whether the project has at least one trace matching the given scope. Cheap existence probe (LIMIT 1) used to drive empty-state decisions without scanning or aggregating the whole project.
|
|
12964
|
+
*
|
|
12965
|
+
* @param {OpikApi.TracesExistRequest} request
|
|
12966
|
+
* @param {TracesClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12967
|
+
*
|
|
12968
|
+
* @example
|
|
12969
|
+
* await client.traces.exist()
|
|
12970
|
+
*/
|
|
12971
|
+
exist(request?: TracesExistRequest, requestOptions?: TracesClient.RequestOptions): HttpResponsePromise<ExistenceResponse>;
|
|
12972
|
+
private __exist;
|
|
12919
12973
|
/**
|
|
12920
12974
|
* Update thread
|
|
12921
12975
|
*
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import {Ia}from'./chunk-
|
|
1
|
+
import {Ia}from'./chunk-EVP4RLIU.js';export{va as AgentTaskCompletionJudge,ua as AgentToolCorrectnessJudge,ia as AnswerRelevance,ea as BaseLLMJudgeMetric,F as BaseMetric,G as BaseSuiteEvaluator,s as ChatPrompt,xa as ComplianceRiskJudge,l as ConfigMismatchError,k as ConfigNotFoundError,ba as Contains,B as DEFAULT_EXECUTION_POLICY,m as Dataset,i as DatasetVersion,j as DatasetVersionNotFoundError,pa as DemographicBiasJudge,na as DialogueHelpfulnessJudge,aa as ExactMatch,ja as GEval,ka as GEvalPreset,ra as GenderBiasJudge,ha as Hallucination,da as IsJson,T as LLMJudge,K as ModelConfigurationError,I as ModelError,J as ModelGenerationError,fa as Moderation,Fa as OPIK_PARENT_SPAN_ID_HEADER,Ea as OPIK_TRACE_ID_HEADER,Da as Opik,H as OpikBaseModel,t as OpikQueryLanguage,g as OpikSpanType,qa as PoliticalBiasJudge,r as Prompt,n as PromptType,wa as PromptUncertaintyJudge,oa as QARelevanceJudge,ca as RegexMatch,ta as RegionalBiasJudge,sa as ReligiousBiasJudge,S as ResponseSchema,Q as SYSTEM_PROMPT,ma as SummarizationCoherenceJudge,la as SummarizationConsistencyJudge,E as TASK_ERROR_SCORE_NAME,Ba as TestSuite,C as TestSuiteResult,v as ThreadsAnnotationQueue,u as TracesAnnotationQueue,R as USER_PROMPT_TEMPLATE,ga as Usefulness,M as VercelAIChatModel,y as activateRunner,w as agentConfigContext,D as buildSuiteResult,N as createModel,O as createModelFromInstance,V as deserializeEvaluators,L as detectProvider,c as disableLogger,_ as evaluate,$ as evaluatePrompt,Y as evaluateTestSuite,x as flushAll,h as generateId,Ga as getDistributedTraceHeaders,o as getGlobalClient,z as getTrackContext,e as isTracingActive,a as logger,q as resetGlobalClient,f as resetTracingToConfigDefault,ya as resolveEvaluators,W as resolveExecutionPolicy,X as resolveItemExecutionPolicy,P as resolveModel,Z as runTests,U as serializeEvaluators,p as setGlobalClient,b as setLoggerLevel,d as setTracingActive,A as track,za as validateEvaluators,Aa as validateExecutionPolicy,Ha as z}from'./chunk-EVP4RLIU.js';Ia();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {Ca}from'./chunk-
|
|
1
|
+
import {Ca}from'./chunk-EVP4RLIU.js';export{B as DEFAULT_EXECUTION_POLICY,Ba as TestSuite,C as TestSuiteResult,D as buildSuiteResult,V as deserializeEvaluators,Y as evaluateTestSuite,W as resolveExecutionPolicy,X as resolveItemExecutionPolicy,Z as runTests,U as serializeEvaluators}from'./chunk-EVP4RLIU.js';Ca();
|