opik 2.1.0 → 2.1.2
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-EM6ZX2PJ.js +404 -0
- package/dist/index.cjs +36 -36
- package/dist/index.d.cts +42 -0
- package/dist/index.d.ts +42 -0
- package/dist/index.js +1 -1
- package/dist/{suite-UZCSOVKO.js → suite-FN42NVCE.js} +1 -1
- package/package.json +1 -1
- package/dist/chunk-SX7GKKBP.js +0 -404
package/dist/index.d.cts
CHANGED
|
@@ -2082,6 +2082,7 @@ interface ProjectMetricRequestPublic {
|
|
|
2082
2082
|
*/
|
|
2083
2083
|
interface ProjectRetrieveDetailed {
|
|
2084
2084
|
name: string;
|
|
2085
|
+
includeStats?: boolean;
|
|
2085
2086
|
}
|
|
2086
2087
|
|
|
2087
2088
|
/**
|
|
@@ -7342,6 +7343,10 @@ interface SpendBreakdownResponse {
|
|
|
7342
7343
|
items?: Item[];
|
|
7343
7344
|
}
|
|
7344
7345
|
|
|
7346
|
+
interface SpendBreakdownsResponse {
|
|
7347
|
+
breakdowns?: SpendBreakdownResponse[];
|
|
7348
|
+
}
|
|
7349
|
+
|
|
7345
7350
|
interface SpendCompositionResponse {
|
|
7346
7351
|
input?: Side;
|
|
7347
7352
|
harness?: HarnessEntry[];
|
|
@@ -7944,6 +7949,10 @@ interface Usage {
|
|
|
7944
7949
|
completionTokensDetails?: CompletionTokensDetails;
|
|
7945
7950
|
}
|
|
7946
7951
|
|
|
7952
|
+
interface UsageByWorkspaceProjectUserResponse {
|
|
7953
|
+
breakdown?: WorkspaceProjectUserCount[];
|
|
7954
|
+
}
|
|
7955
|
+
|
|
7947
7956
|
interface UserDefinedMetricPythonCode {
|
|
7948
7957
|
metric: string;
|
|
7949
7958
|
arguments: Record<string, string>;
|
|
@@ -8121,6 +8130,13 @@ interface WorkspaceNameHolder {
|
|
|
8121
8130
|
workspaceName?: string;
|
|
8122
8131
|
}
|
|
8123
8132
|
|
|
8133
|
+
interface WorkspaceProjectUserCount {
|
|
8134
|
+
workspaceId?: string;
|
|
8135
|
+
projectId?: string;
|
|
8136
|
+
user?: string;
|
|
8137
|
+
count?: number;
|
|
8138
|
+
}
|
|
8139
|
+
|
|
8124
8140
|
interface WorkspaceSpansCount {
|
|
8125
8141
|
workspace?: string;
|
|
8126
8142
|
spanCount?: number;
|
|
@@ -8615,6 +8631,22 @@ declare namespace AiSpendClient {
|
|
|
8615
8631
|
declare class AiSpendClient {
|
|
8616
8632
|
protected readonly _options: NormalizedClientOptions<AiSpendClient.Options>;
|
|
8617
8633
|
constructor(options?: AiSpendClient.Options);
|
|
8634
|
+
/**
|
|
8635
|
+
* Get the per-item breakdown for every composition lane in one request
|
|
8636
|
+
*
|
|
8637
|
+
* @param {OpikApi.SpendMetricRequest} request
|
|
8638
|
+
* @param {AiSpendClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
8639
|
+
*
|
|
8640
|
+
* @throws {@link OpikApi.BadRequestError}
|
|
8641
|
+
*
|
|
8642
|
+
* @example
|
|
8643
|
+
* await client.aiSpend.getSpendAllBreakdowns({
|
|
8644
|
+
* intervalStart: new Date("2024-01-15T09:30:00.000Z"),
|
|
8645
|
+
* intervalEnd: new Date("2024-01-15T09:30:00.000Z")
|
|
8646
|
+
* })
|
|
8647
|
+
*/
|
|
8648
|
+
getSpendAllBreakdowns(request: SpendMetricRequest, requestOptions?: AiSpendClient.RequestOptions): HttpResponsePromise<SpendBreakdownsResponse>;
|
|
8649
|
+
private __getSpendAllBreakdowns;
|
|
8618
8650
|
/**
|
|
8619
8651
|
* Get coding-agent token-flow composition (Sankey)
|
|
8620
8652
|
*
|
|
@@ -12522,6 +12554,16 @@ declare class SystemUsageClient {
|
|
|
12522
12554
|
*/
|
|
12523
12555
|
getSpansBiInfo(requestOptions?: SystemUsageClient.RequestOptions): HttpResponsePromise<BiInformationResponse>;
|
|
12524
12556
|
private __getSpansBiInfo;
|
|
12557
|
+
/**
|
|
12558
|
+
* Get spans count on previous day grouped by workspace, project and user
|
|
12559
|
+
*
|
|
12560
|
+
* @param {SystemUsageClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12561
|
+
*
|
|
12562
|
+
* @example
|
|
12563
|
+
* await client.systemUsage.getSpansCountBreakdownForWorkspaces()
|
|
12564
|
+
*/
|
|
12565
|
+
getSpansCountBreakdownForWorkspaces(requestOptions?: SystemUsageClient.RequestOptions): HttpResponsePromise<UsageByWorkspaceProjectUserResponse>;
|
|
12566
|
+
private __getSpansCountBreakdownForWorkspaces;
|
|
12525
12567
|
/**
|
|
12526
12568
|
* Get spans count on previous day for all available workspaces
|
|
12527
12569
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -2082,6 +2082,7 @@ interface ProjectMetricRequestPublic {
|
|
|
2082
2082
|
*/
|
|
2083
2083
|
interface ProjectRetrieveDetailed {
|
|
2084
2084
|
name: string;
|
|
2085
|
+
includeStats?: boolean;
|
|
2085
2086
|
}
|
|
2086
2087
|
|
|
2087
2088
|
/**
|
|
@@ -7342,6 +7343,10 @@ interface SpendBreakdownResponse {
|
|
|
7342
7343
|
items?: Item[];
|
|
7343
7344
|
}
|
|
7344
7345
|
|
|
7346
|
+
interface SpendBreakdownsResponse {
|
|
7347
|
+
breakdowns?: SpendBreakdownResponse[];
|
|
7348
|
+
}
|
|
7349
|
+
|
|
7345
7350
|
interface SpendCompositionResponse {
|
|
7346
7351
|
input?: Side;
|
|
7347
7352
|
harness?: HarnessEntry[];
|
|
@@ -7944,6 +7949,10 @@ interface Usage {
|
|
|
7944
7949
|
completionTokensDetails?: CompletionTokensDetails;
|
|
7945
7950
|
}
|
|
7946
7951
|
|
|
7952
|
+
interface UsageByWorkspaceProjectUserResponse {
|
|
7953
|
+
breakdown?: WorkspaceProjectUserCount[];
|
|
7954
|
+
}
|
|
7955
|
+
|
|
7947
7956
|
interface UserDefinedMetricPythonCode {
|
|
7948
7957
|
metric: string;
|
|
7949
7958
|
arguments: Record<string, string>;
|
|
@@ -8121,6 +8130,13 @@ interface WorkspaceNameHolder {
|
|
|
8121
8130
|
workspaceName?: string;
|
|
8122
8131
|
}
|
|
8123
8132
|
|
|
8133
|
+
interface WorkspaceProjectUserCount {
|
|
8134
|
+
workspaceId?: string;
|
|
8135
|
+
projectId?: string;
|
|
8136
|
+
user?: string;
|
|
8137
|
+
count?: number;
|
|
8138
|
+
}
|
|
8139
|
+
|
|
8124
8140
|
interface WorkspaceSpansCount {
|
|
8125
8141
|
workspace?: string;
|
|
8126
8142
|
spanCount?: number;
|
|
@@ -8615,6 +8631,22 @@ declare namespace AiSpendClient {
|
|
|
8615
8631
|
declare class AiSpendClient {
|
|
8616
8632
|
protected readonly _options: NormalizedClientOptions<AiSpendClient.Options>;
|
|
8617
8633
|
constructor(options?: AiSpendClient.Options);
|
|
8634
|
+
/**
|
|
8635
|
+
* Get the per-item breakdown for every composition lane in one request
|
|
8636
|
+
*
|
|
8637
|
+
* @param {OpikApi.SpendMetricRequest} request
|
|
8638
|
+
* @param {AiSpendClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
8639
|
+
*
|
|
8640
|
+
* @throws {@link OpikApi.BadRequestError}
|
|
8641
|
+
*
|
|
8642
|
+
* @example
|
|
8643
|
+
* await client.aiSpend.getSpendAllBreakdowns({
|
|
8644
|
+
* intervalStart: new Date("2024-01-15T09:30:00.000Z"),
|
|
8645
|
+
* intervalEnd: new Date("2024-01-15T09:30:00.000Z")
|
|
8646
|
+
* })
|
|
8647
|
+
*/
|
|
8648
|
+
getSpendAllBreakdowns(request: SpendMetricRequest, requestOptions?: AiSpendClient.RequestOptions): HttpResponsePromise<SpendBreakdownsResponse>;
|
|
8649
|
+
private __getSpendAllBreakdowns;
|
|
8618
8650
|
/**
|
|
8619
8651
|
* Get coding-agent token-flow composition (Sankey)
|
|
8620
8652
|
*
|
|
@@ -12522,6 +12554,16 @@ declare class SystemUsageClient {
|
|
|
12522
12554
|
*/
|
|
12523
12555
|
getSpansBiInfo(requestOptions?: SystemUsageClient.RequestOptions): HttpResponsePromise<BiInformationResponse>;
|
|
12524
12556
|
private __getSpansBiInfo;
|
|
12557
|
+
/**
|
|
12558
|
+
* Get spans count on previous day grouped by workspace, project and user
|
|
12559
|
+
*
|
|
12560
|
+
* @param {SystemUsageClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
12561
|
+
*
|
|
12562
|
+
* @example
|
|
12563
|
+
* await client.systemUsage.getSpansCountBreakdownForWorkspaces()
|
|
12564
|
+
*/
|
|
12565
|
+
getSpansCountBreakdownForWorkspaces(requestOptions?: SystemUsageClient.RequestOptions): HttpResponsePromise<UsageByWorkspaceProjectUserResponse>;
|
|
12566
|
+
private __getSpansCountBreakdownForWorkspaces;
|
|
12525
12567
|
/**
|
|
12526
12568
|
* Get spans count on previous day for all available workspaces
|
|
12527
12569
|
*
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import {Ia}from'./chunk-
|
|
1
|
+
import {Ia}from'./chunk-EM6ZX2PJ.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-EM6ZX2PJ.js';Ia();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {Ca}from'./chunk-
|
|
1
|
+
import {Ca}from'./chunk-EM6ZX2PJ.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-EM6ZX2PJ.js';Ca();
|