@bitfab/sdk 0.74.3 → 0.74.5

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/node.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as RivetEffectType, $n as TraceAssertionSource, $r as AssertionCategory, $t as LabelSource, A as SpanMethodDecoratorContext, Ai as SelectiveReplayDecision, An as SaveAssertion, Ar as DatasetTraceIds, At as LangGraphIntegrationOptions, B as getCurrentTrace, Bi as Justification, Bn as ScenarioActualOutcome, Br as RemoveDatasetTracesResult, Bt as GraderVerdictSource, C as NodeMethodDecorator, Ci as BitfabError, Cn as AssertionKind, Cr as ExperimentTotals, Ct as PiIntegrationOptions, D as SeedCaseOptions, Di as DbSnapshotRef, Dn as AssertionVerdictEvidence, Dr as AddDatasetTracesResult, Dt as BitfabAgentMiddleware, E as ReseedResult, Ei as DbSnapshotProvider, En as AssertionRewriteStatus, Er as AddDatasetGradersResult, Et as BitfabOpenAIAgentHandler, F as WrapOpenAIResponsesOptions, Fi as ProviderDefinition, Fn as SaveScenarioHistoryEntry, Fr as GraderRerunResult, Ft as GraderLabelOutcome, G as TracingProcessor, Gn as ScenarioDataSources, Gr as UpdateDatasetParams, Gt as AssertionVerdict, H as ActiveSpanContext, Hn as ScenarioData, Hr as RerunGradersResult, Ht as GradersClient, I as WrapOpenRouterOptions, Ii as ApprovalFields, In as SaveScenarioParams, Ir as GraderRerunStatus, It as GraderLabelSource, J as SpanListParams, Jn as ScenarioRecord, Jr as VercelCallParams, Jt as HumanVerdictOutcome, K as ListedSpan, Kn as ScenarioGeneration, Kr as BitfabLanguageModelMiddleware, Kt as HumanLabelOutcome, L as WrappedBamlFn, Li as ApprovalState, Ln as SavedTraceAssertion, Lr as GraderRerunTimeoutError, Lt as GraderLabelUpdate, M as WrapAnthropicOptions, Mi as SelectiveReplayReport, Mn as SaveAssertionsParams, Mr as GraderRerun, Mt as GetGraderLabelsParams, N as WrapBAMLOptions, Ni as AllowedEnvVars, Nn as SaveScenarioActualOutcome, Nr as GraderRerunError, Nt as GetGraderVerdictsParams, O as SeedRunOptions, Oi as SUPPORTED_PROVIDERS, On as GenerateAssertionsOptions, Or as Dataset, Ot as BitfabLangGraphAgent, P as WrapJevOptions, Pi as BamlExecutionResult, Pn as SaveScenarioData, Pr as GraderRerunProgress, Pt as GraderLabel, Q as RivetContextLike, Qn as TraceAssertion, Qr as AssertionCategoriesClient, Qt as LabelOutcome, R as getCurrentReplayBranch, Ri as Approver, Rn as Scenario, Rr as ListDatasetsParams, Rt as GraderVerdict, S as DetachedTrace, Si as SpanNodeMeta, Sn as AssertionGenerationTimeoutError, Sr as ExperimentTally, St as BitfabPiIntegration, T as ReseedOptions, Ti as DbSnapshotConfig, Tn as AssertionRewrite, Tr as ListExperimentsParams, Tt as OrganizationMembersClient, U as BitfabOpenAITracingProcessor, Un as ScenarioDataAppend, Ur as SaveDatasetParams, Ut as ArchiveLabelTarget, V as CaptureSurface, Vi as JustificationSpan, Vn as ScenarioCreationStatus, Vr as RerunGradersOptions, Vt as GraderVerdictUpdate, W as TraceResponse, Wn as ScenarioDataOrigin, Wr as SaveDatasetResult, Wt as ArchiveVerdictTarget, X as SpansClient, Xn as ScenarioSource, Xr as VercelStreamResult, Xt as LabelAction, Y as SpanListResult, Yn as ScenarioRecordInput, Yr as VercelGenerateResult, Yt as HumanVerdictUpdate, Z as BitfabRivetIntegration, Zn as ScenarioTrigger, Zr as BitfabClaudeAgentHandler, Zt as LabelConfidence, _ as BitfabConfig, _i as MockOverrideInput, _n as AssertionCode, _r as ExperimentSummary, _t as TraceIngestionType, a as ReplayRegistryOptions, ai as SaveCategoryParams, an as TraceLabels, ar as TraceTarget, at as DbBranchOptions, b as CurrentSpan, bi as NO_MOCK_OVERRIDE, bn as AssertionGenerationError, br as ExperimentSummaryFacts, bt as ReplayInterrupt, c as SeedResult, ci as HttpClient, cn as VerdictAction, cr as Experiment, ct as ReplayError, d as seedFromRegistry, di as SpanType, dn as VerdictSource, dr as ExperimentJitter, dt as ReplayItemFinishProgress, ei as AssertionCategorySummary, en as LabelStatus, er as TraceAssertionsResult, et as RivetIntegrationOptions, f as finalizers, fi as TokenUsage, fn as VerdictStatus, fr as ExperimentPage, ft as ReplayItemStartProgress, g as Bitfab, gi as MockOverrideCtx, gn as ArchiveAssertionsParams, gr as ExperimentStatus, gt as ReplayResult, h as CommitRef, hi as MockOverride, hn as VerdictsClient, hr as ExperimentRunBy, ht as ReplayProgressItem, i as ReplayRegistryContext, ii as SaveAssertionCategoryParams, in as PassFailVerdict, ir as TraceSearchResult, it as BITFAB_PROGRESS_PREFIX, j as SpanOptions, ji as SelectiveReplayOptions, jn as SaveAssertionsAllParams, jr as DatasetsClient, jt as BitfabLangGraphCallbackHandler, k as SpanMethodDecorator, ki as ReplayNodeIdentity, kn as GenerateScenarioOptions, kr as DatasetGraderRef, kt as BitfabLangGraphIntegration, l as defineReplayRegistry, li as SpanLookup, ln as VerdictConfidence, lr as ExperimentCategoryTally, lt as ReplayExperiment, m as __version__, mi as DbBranchTimings, mn as VerdictUpdate, mr as ExperimentRollupResult, mt as ReplayProgress, n as ReplayRegistration, ni as Category, nn as LabelUpdate, nr as TraceSearchFilters, nt as AdaptContext, o as ReseedRegistryResult, oi as CapturedSpan, on as TraceVerdicts, or as TraceTargetOccurrence, ot as DbBranchReplayError, p as DEFAULT_SERVICE_URL, pi as flushTraces, pn as VerdictTarget, pr as ExperimentRollup, pt as ReplayOptions, q as SpanListField, qn as ScenarioHistoryEntry, qr as BitfabVercelAiHandler, qt as HumanLabelUpdate, r as ReplayRegistry, ri as CategorySummary, rn as LabelsClient, rr as TraceSearchParams, rt as AdaptInputsFn, s as SeedCase, si as CodeChangeFile, sn as Verdict, sr as TracesClient, st as MockStrategy, t as ReplayOptionsFactory, ti as CategoriesClient, tn as LabelTarget, tr as TraceAssertionsUpdate, tt as ReplayBranch, u as reseedFromRegistry, ui as SpanOccurrence, un as VerdictOutcome, ur as ExperimentCodeChangeTotals, ut as ReplayItem, v as BitfabFunction, vi as MockOverrideResolver, vn as AssertionEvidenceParameter, vr as ExperimentSummaryBeforeAfter, vt as reportReplayProgress, w as NodeOptions, wi as MixedTracingError, wn as AssertionLabelEvidence, wr as ExperimentsClient, wt as OrganizationMember, x as CurrentTrace, xi as NodeMatcher, xn as AssertionGenerationStatus, xr as ExperimentSummaryResult, xt as ReplayInterruptSignal, y as CaptureWhen, yi as MockValue, yn as AssertionGeneration, yr as ExperimentSummaryExampleTrace, yt as serializeReplayResult, z as getCurrentSpan, zi as Assignee, zn as ScenarioAction, zr as RemoveDatasetGradersResult, zt as GraderVerdictOutcome } from "./index-eZPhpygX.js";
2
- export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, type ArchiveLabelTarget, type ArchiveVerdictTarget, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionCode, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionKind, type AssertionLabelEvidence, type AssertionRewrite, type AssertionRewriteStatus, type AssertionVerdict, type AssertionVerdictEvidence, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, type BitfabAgentMiddleware, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, type BitfabLangGraphAgent, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabPiIntegration, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, CategoriesClient, type Category, type CategorySummary, type CodeChangeFile, type CommitRef, type CurrentSpan, type CurrentTrace, DEFAULT_SERVICE_URL, type Dataset, type DatasetGraderRef, type DatasetTraceIds, DatasetsClient, type DbBranchOptions, DbBranchReplayError, type DbBranchTimings, type DbSnapshotConfig, type DbSnapshotProvider, type DbSnapshotRef, type DetachedTrace, type Experiment, type ExperimentCategoryTally, type ExperimentCodeChangeTotals, type ExperimentJitter, type ExperimentPage, type ExperimentRollup, type ExperimentRollupResult, type ExperimentRunBy, type ExperimentStatus, type ExperimentSummary, type ExperimentSummaryBeforeAfter, type ExperimentSummaryExampleTrace, type ExperimentSummaryFacts, type ExperimentSummaryResult, type ExperimentTally, type ExperimentTotals, ExperimentsClient, type GenerateAssertionsOptions, type GenerateScenarioOptions, type GetGraderLabelsParams, type GetGraderVerdictsParams, type GraderLabel, type GraderLabelOutcome, type GraderLabelSource, type GraderLabelUpdate, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, type GraderVerdict, type GraderVerdictOutcome, type GraderVerdictSource, type GraderVerdictUpdate, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type HumanVerdictOutcome, type HumanVerdictUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, type ListExperimentsParams, type ListedSpan, MixedTracingError, type MockOverride, type MockOverrideCtx, type MockOverrideInput, type MockOverrideResolver, type MockStrategy, type MockValue, NO_MOCK_OVERRIDE, type NodeMatcher, type NodeMethodDecorator, type NodeOptions, type OrganizationMember, OrganizationMembersClient, type PassFailVerdict, type PiIntegrationOptions, type ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, type ReplayBranch, ReplayError, type ReplayExperiment, type ReplayInterrupt, type ReplayInterruptSignal, type ReplayItem, type ReplayItemFinishProgress, type ReplayItemStartProgress, type ReplayNodeIdentity, type ReplayOptions, type ReplayOptionsFactory, type ReplayProgress, type ReplayProgressItem, type ReplayRegistration, type ReplayRegistry, type ReplayRegistryContext, type ReplayRegistryOptions, type ReplayResult, type RerunGradersOptions, type RerunGradersResult, type ReseedOptions, type ReseedRegistryResult, type ReseedResult, type RivetContextLike, type RivetEffectType, type RivetIntegrationOptions, SUPPORTED_PROVIDERS, type SaveAssertion, type SaveAssertionCategoryParams, type SaveAssertionsAllParams, type SaveAssertionsParams, type SaveCategoryParams, type SaveDatasetParams, type SaveDatasetResult, type SaveScenarioActualOutcome, type SaveScenarioData, type SaveScenarioHistoryEntry, type SaveScenarioParams, type SavedTraceAssertion, type Scenario, type ScenarioAction, type ScenarioActualOutcome, type ScenarioCreationStatus, type ScenarioData, type ScenarioDataAppend, type ScenarioDataOrigin, type ScenarioDataSources, type ScenarioGeneration, type ScenarioHistoryEntry, type ScenarioRecord, type ScenarioRecordInput, type ScenarioSource, type ScenarioTrigger, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanListField, type SpanListParams, type SpanListResult, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, SpansClient, type TokenUsage, type TraceAssertion, type TraceAssertionSource, type TraceAssertionsResult, type TraceAssertionsUpdate, type TraceIngestionType, type TraceLabels, type TraceResponse, type TraceSearchFilters, type TraceSearchParams, type TraceSearchResult, type TraceTarget, type TraceTargetOccurrence, type TraceVerdicts, TracesClient, type TracingProcessor, type UpdateDatasetParams, type VercelCallParams, type VercelGenerateResult, type VercelStreamResult, type Verdict, type VerdictAction, type VerdictConfidence, type VerdictOutcome, type VerdictSource, type VerdictStatus, type VerdictTarget, type VerdictUpdate, VerdictsClient, type WrapAnthropicOptions, type WrapBAMLOptions, type WrapJevOptions, type WrapOpenAIResponsesOptions, type WrapOpenRouterOptions, type WrappedBamlFn, __version__, defineReplayRegistry, finalizers, flushTraces, getCurrentReplayBranch, getCurrentSpan, getCurrentTrace, reportReplayProgress, reseedFromRegistry, seedFromRegistry, serializeReplayResult };
1
+ import { $ as RivetEffectType, $n as TraceAssertion, $r as AssertionCategoriesClient, $t as LabelSource, A as SpanMethodDecoratorContext, Ai as ReplayNodeIdentity, An as GenerateScenarioOptions, Ar as DatasetGraderRef, At as LangGraphIntegrationOptions, B as getCurrentTrace, Bi as Assignee, Bn as ScenarioAction, Br as RemoveDatasetGradersResult, Bt as GraderVerdictSource, C as NodeMethodDecorator, Ci as SpanNodeMeta, Cn as AssertionGenerationTimeoutError, Cr as ExperimentTally, Ct as PiIntegrationOptions, D as SeedCaseOptions, Di as DbSnapshotProvider, Dn as AssertionRewriteStatus, Dr as AddDatasetGradersResult, Dt as BitfabAgentMiddleware, E as ReseedResult, Ei as DbSnapshotConfig, En as AssertionRewrite, Er as ListExperimentsParams, Et as BitfabOpenAIAgentHandler, F as WrapOpenAIResponsesOptions, Fi as BamlExecutionResult, Fn as SaveScenarioData, Fr as GraderRerunProgress, Ft as GraderLabelOutcome, G as TracingProcessor, Gn as ScenarioDataOrigin, Gr as SaveDatasetResult, Gt as AssertionVerdict, H as ActiveSpanContext, Hi as JustificationSpan, Hn as ScenarioCreationStatus, Hr as RerunGradersOptions, Ht as GradersClient, I as WrapOpenRouterOptions, Ii as ProviderDefinition, In as SaveScenarioHistoryEntry, Ir as GraderRerunResult, It as GraderLabelSource, J as SpanListParams, Jn as ScenarioHistoryEntry, Jr as BitfabVercelAiHandler, Jt as HumanVerdictOutcome, K as ListedSpan, Kn as ScenarioDataSources, Kr as UpdateDatasetParams, Kt as HumanLabelOutcome, L as WrappedBamlFn, Li as ApprovalFields, Ln as SaveScenarioParams, Lr as GraderRerunStatus, Lt as GraderLabelUpdate, M as WrapAnthropicOptions, Mi as SelectiveReplayOptions, Mn as SaveAssertionsAllParams, Mr as DatasetsClient, Mt as GetGraderLabelsParams, N as WrapBAMLOptions, Ni as SelectiveReplayReport, Nn as SaveAssertionsParams, Nr as GraderRerun, Nt as GetGraderVerdictsParams, O as SeedRunOptions, Oi as DbSnapshotRef, On as AssertionVerdictEvidence, Or as AddDatasetTracesResult, Ot as BitfabLangGraphAgent, P as WrapJevOptions, Pi as AllowedEnvVars, Pn as SaveScenarioActualOutcome, Pr as GraderRerunError, Pt as GraderLabel, Q as RivetContextLike, Qn as ScenarioTrigger, Qr as BitfabClaudeAgentHandler, Qt as LabelOutcome, R as getCurrentReplayBranch, Ri as ApprovalState, Rn as SavedTraceAssertion, Rr as GraderRerunTimeoutError, Rt as GraderVerdict, S as DetachedTrace, Si as NodeMatcher, Sn as AssertionGenerationStatus, Sr as ExperimentSummaryResult, St as BitfabPiIntegration, T as ReseedOptions, Ti as MixedTracingError, Tn as AssertionLabelEvidence, Tr as ExperimentsClient, Tt as OrganizationMembersClient, U as BitfabOpenAITracingProcessor, Un as ScenarioData, Ur as RerunGradersResult, Ut as ArchiveLabelTarget, V as CaptureSurface, Vi as Justification, Vn as ScenarioActualOutcome, Vr as RemoveDatasetTracesResult, Vt as GraderVerdictUpdate, W as TraceResponse, Wn as ScenarioDataAppend, Wr as SaveDatasetParams, Wt as ArchiveVerdictTarget, X as SpansClient, Xn as ScenarioRecordInput, Xr as VercelGenerateResult, Xt as LabelAction, Y as SpanListResult, Yn as ScenarioRecord, Yr as VercelCallParams, Yt as HumanVerdictUpdate, Z as BitfabRivetIntegration, Zn as ScenarioSource, Zr as VercelStreamResult, Zt as LabelConfidence, _ as BitfabConfig, _i as MockOverrideCtx, _n as AssertionCode, _r as ExperimentStatus, _t as TraceIngestionType, a as ReplayRegistryOptions, ai as SaveAssertionCategoryParams, an as TraceLabels, ar as TraceSearchResult, at as DbBranchOptions, b as CurrentSpan, bi as MockValue, bn as AssertionGeneration, br as ExperimentSummaryExampleTrace, bt as ReplayInterrupt, c as SeedResult, ci as CodeChangeFile, cn as VerdictAction, cr as TracesClient, ct as ReplayError, d as seedFromRegistry, di as SpanOccurrence, dn as VerdictSource, dr as ExperimentCodeChangeTotals, dt as ReplayItemFinishProgress, ei as AssertionCategory, en as LabelStatus, er as TraceAssertionSource, et as RivetIntegrationOptions, f as finalizers, fi as SpanType, fn as VerdictStatus, fr as ExperimentJitter, ft as ReplayItemStartProgress, g as Bitfab, gi as MockOverride, gn as ArchiveAssertionsParams, gr as ExperimentRunBy, gt as ReplayResult, h as CommitRef, hi as DbBranchTimings, hn as VerdictsClient, hr as ExperimentRollupResult, ht as ReplayProgressItem, i as ReplayRegistryContext, ii as CategorySummary, in as PassFailVerdict, ir as TraceSearchParams, it as BITFAB_PROGRESS_PREFIX, j as SpanOptions, ji as SelectiveReplayDecision, jn as SaveAssertion, jr as DatasetTraceIds, jt as BitfabLangGraphCallbackHandler, k as SpanMethodDecorator, ki as SUPPORTED_PROVIDERS, kn as GenerateAssertionsOptions, kr as Dataset, kt as BitfabLangGraphIntegration, l as defineReplayRegistry, li as HttpClient, ln as VerdictConfidence, lr as Experiment, lt as ReplayExperiment, m as __version__, mi as flushTraces, mn as VerdictUpdate, mr as ExperimentRollup, mt as ReplayProgress, n as ReplayRegistration, ni as CategoriesClient, nn as LabelUpdate, nr as TraceAssertionsUpdate, nt as AdaptContext, o as ReseedRegistryResult, oi as SaveCategoryParams, on as TraceVerdicts, or as TraceTarget, ot as DbBranchReplayError, p as DEFAULT_SERVICE_URL, pi as TokenUsage, pn as VerdictTarget, pr as ExperimentPage, pt as ReplayOptions, q as SpanListField, qn as ScenarioGeneration, qr as BitfabLanguageModelMiddleware, qt as HumanLabelUpdate, r as ReplayRegistry, ri as Category, rn as LabelsClient, rr as TraceSearchFilters, rt as AdaptInputsFn, s as SeedCase, si as CapturedSpan, sn as Verdict, sr as TraceTargetOccurrence, st as MockStrategy, t as ReplayOptionsFactory, ti as AssertionCategorySummary, tn as LabelTarget, tr as TraceAssertionsResult, tt as ReplayBranch, u as reseedFromRegistry, ui as SpanLookup, un as VerdictOutcome, ur as ExperimentCategoryTally, ut as ReplayItem, v as BitfabFunction, vi as MockOverrideInput, vn as AssertionCodeDraft, vr as ExperimentSummary, vt as reportReplayProgress, w as NodeOptions, wi as BitfabError, wn as AssertionKind, wr as ExperimentTotals, wt as OrganizationMember, x as CurrentTrace, xi as NO_MOCK_OVERRIDE, xn as AssertionGenerationError, xr as ExperimentSummaryFacts, xt as ReplayInterruptSignal, y as CaptureWhen, yi as MockOverrideResolver, yn as AssertionEvidenceParameter, yr as ExperimentSummaryBeforeAfter, yt as serializeReplayResult, z as getCurrentSpan, zi as Approver, zn as Scenario, zr as ListDatasetsParams, zt as GraderVerdictOutcome } from "./index-PwbvfBty.js";
2
+ export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, type ArchiveLabelTarget, type ArchiveVerdictTarget, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionCode, type AssertionCodeDraft, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionKind, type AssertionLabelEvidence, type AssertionRewrite, type AssertionRewriteStatus, type AssertionVerdict, type AssertionVerdictEvidence, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, type BitfabAgentMiddleware, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, type BitfabLangGraphAgent, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabPiIntegration, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, CategoriesClient, type Category, type CategorySummary, type CodeChangeFile, type CommitRef, type CurrentSpan, type CurrentTrace, DEFAULT_SERVICE_URL, type Dataset, type DatasetGraderRef, type DatasetTraceIds, DatasetsClient, type DbBranchOptions, DbBranchReplayError, type DbBranchTimings, type DbSnapshotConfig, type DbSnapshotProvider, type DbSnapshotRef, type DetachedTrace, type Experiment, type ExperimentCategoryTally, type ExperimentCodeChangeTotals, type ExperimentJitter, type ExperimentPage, type ExperimentRollup, type ExperimentRollupResult, type ExperimentRunBy, type ExperimentStatus, type ExperimentSummary, type ExperimentSummaryBeforeAfter, type ExperimentSummaryExampleTrace, type ExperimentSummaryFacts, type ExperimentSummaryResult, type ExperimentTally, type ExperimentTotals, ExperimentsClient, type GenerateAssertionsOptions, type GenerateScenarioOptions, type GetGraderLabelsParams, type GetGraderVerdictsParams, type GraderLabel, type GraderLabelOutcome, type GraderLabelSource, type GraderLabelUpdate, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, type GraderVerdict, type GraderVerdictOutcome, type GraderVerdictSource, type GraderVerdictUpdate, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type HumanVerdictOutcome, type HumanVerdictUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, type ListExperimentsParams, type ListedSpan, MixedTracingError, type MockOverride, type MockOverrideCtx, type MockOverrideInput, type MockOverrideResolver, type MockStrategy, type MockValue, NO_MOCK_OVERRIDE, type NodeMatcher, type NodeMethodDecorator, type NodeOptions, type OrganizationMember, OrganizationMembersClient, type PassFailVerdict, type PiIntegrationOptions, type ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, type ReplayBranch, ReplayError, type ReplayExperiment, type ReplayInterrupt, type ReplayInterruptSignal, type ReplayItem, type ReplayItemFinishProgress, type ReplayItemStartProgress, type ReplayNodeIdentity, type ReplayOptions, type ReplayOptionsFactory, type ReplayProgress, type ReplayProgressItem, type ReplayRegistration, type ReplayRegistry, type ReplayRegistryContext, type ReplayRegistryOptions, type ReplayResult, type RerunGradersOptions, type RerunGradersResult, type ReseedOptions, type ReseedRegistryResult, type ReseedResult, type RivetContextLike, type RivetEffectType, type RivetIntegrationOptions, SUPPORTED_PROVIDERS, type SaveAssertion, type SaveAssertionCategoryParams, type SaveAssertionsAllParams, type SaveAssertionsParams, type SaveCategoryParams, type SaveDatasetParams, type SaveDatasetResult, type SaveScenarioActualOutcome, type SaveScenarioData, type SaveScenarioHistoryEntry, type SaveScenarioParams, type SavedTraceAssertion, type Scenario, type ScenarioAction, type ScenarioActualOutcome, type ScenarioCreationStatus, type ScenarioData, type ScenarioDataAppend, type ScenarioDataOrigin, type ScenarioDataSources, type ScenarioGeneration, type ScenarioHistoryEntry, type ScenarioRecord, type ScenarioRecordInput, type ScenarioSource, type ScenarioTrigger, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanListField, type SpanListParams, type SpanListResult, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, SpansClient, type TokenUsage, type TraceAssertion, type TraceAssertionSource, type TraceAssertionsResult, type TraceAssertionsUpdate, type TraceIngestionType, type TraceLabels, type TraceResponse, type TraceSearchFilters, type TraceSearchParams, type TraceSearchResult, type TraceTarget, type TraceTargetOccurrence, type TraceVerdicts, TracesClient, type TracingProcessor, type UpdateDatasetParams, type VercelCallParams, type VercelGenerateResult, type VercelStreamResult, type Verdict, type VerdictAction, type VerdictConfidence, type VerdictOutcome, type VerdictSource, type VerdictStatus, type VerdictTarget, type VerdictUpdate, VerdictsClient, type WrapAnthropicOptions, type WrapBAMLOptions, type WrapJevOptions, type WrapOpenAIResponsesOptions, type WrapOpenRouterOptions, type WrappedBamlFn, __version__, defineReplayRegistry, finalizers, flushTraces, getCurrentReplayBranch, getCurrentSpan, getCurrentTrace, reportReplayProgress, reseedFromRegistry, seedFromRegistry, serializeReplayResult };
package/dist/node.js CHANGED
@@ -1,5 +1,5 @@
1
- import { A as VerdictsClient, C as OrganizationMembersClient, D as BitfabLangGraphCallbackHandler, E as BitfabLangGraphIntegration, F as GraderRerunTimeoutError, I as BitfabClaudeAgentHandler, L as DEFAULT_SERVICE_URL, M as SUPPORTED_PROVIDERS, N as DatasetsClient, O as GradersClient, P as GraderRerunError, R as AssertionCategoriesClient, S as BitfabPiIntegration, T as NO_MOCK_OVERRIDE, _ as BITFAB_PROGRESS_PREFIX, a as Bitfab, b as reportReplayProgress, c as getCurrentSpan, d as BitfabOpenAITracingProcessor, f as AssertionGenerationError, g as BitfabRivetIntegration, h as SpansClient, i as finalizers, j as ExperimentsClient, k as LabelsClient, l as getCurrentTrace, m as TracesClient, n as reseedFromRegistry, o as BitfabFunction, p as AssertionGenerationTimeoutError, r as seedFromRegistry, s as getCurrentReplayBranch, t as defineReplayRegistry, u as BitfabVercelAiHandler, v as DbBranchReplayError, w as BitfabOpenAIAgentHandler, x as serializeReplayResult, y as ReplayError, z as CategoriesClient } from "./src-v9Cp4amm.js";
2
- import { C as BitfabError, E as __version__, i as flushTraces, t as HttpClient, w as MixedTracingError } from "./http-Dd0XLEqA.js";
1
+ import { A as VerdictsClient, C as OrganizationMembersClient, D as BitfabLangGraphCallbackHandler, E as BitfabLangGraphIntegration, F as GraderRerunTimeoutError, I as BitfabClaudeAgentHandler, L as DEFAULT_SERVICE_URL, M as SUPPORTED_PROVIDERS, N as DatasetsClient, O as GradersClient, P as GraderRerunError, R as AssertionCategoriesClient, S as BitfabPiIntegration, T as NO_MOCK_OVERRIDE, _ as BITFAB_PROGRESS_PREFIX, a as Bitfab, b as reportReplayProgress, c as getCurrentSpan, d as BitfabOpenAITracingProcessor, f as AssertionGenerationError, g as BitfabRivetIntegration, h as SpansClient, i as finalizers, j as ExperimentsClient, k as LabelsClient, l as getCurrentTrace, m as TracesClient, n as reseedFromRegistry, o as BitfabFunction, p as AssertionGenerationTimeoutError, r as seedFromRegistry, s as getCurrentReplayBranch, t as defineReplayRegistry, u as BitfabVercelAiHandler, v as DbBranchReplayError, w as BitfabOpenAIAgentHandler, x as serializeReplayResult, y as ReplayError, z as CategoriesClient } from "./src-Ch86hs9i.js";
2
+ import { C as BitfabError, E as __version__, i as flushTraces, t as HttpClient, w as MixedTracingError } from "./http-C_t7m9b_.js";
3
3
  import { U as registerAsyncLocalStorageClass, z as assertAsyncStorageRegistered } from "./autoTrace-kHOBg49M.js";
4
4
  import { AsyncLocalStorage } from "async_hooks";
5
5
  //#region src/asyncStorageNode.ts
@@ -644,6 +644,7 @@ const VALUE_FLAGS = /* @__PURE__ */ new Set([
644
644
  "--dataset-id",
645
645
  "--dataset-ids",
646
646
  "--grader-ids",
647
+ "--category-ids",
647
648
  "--mock",
648
649
  "--param",
649
650
  "--params",
@@ -688,6 +689,7 @@ const RESUME_CONFLICTING_FLAGS = [
688
689
  ["attempts", "--attempts"],
689
690
  ["graderIds", "--grader-ids"],
690
691
  ["onlyWithAssertions", "--only-with-assertions"],
692
+ ["categoryIds", "--category-ids"],
691
693
  ["dryRun", "--dry-run"]
692
694
  ];
693
695
  const RESUME_CLEARED_OPTIONS = {
@@ -698,26 +700,30 @@ const RESUME_CLEARED_OPTIONS = {
698
700
  attempts: void 0,
699
701
  graderIds: void 0,
700
702
  onlyWithAssertions: void 0,
703
+ categoryIds: void 0,
701
704
  dryRun: void 0
702
705
  };
703
- function hasApprovedAssertion(assertions) {
704
- return assertions.some((assertion) => assertion.approvalState === "approved");
706
+ function narrowsToAssertions(narrowing) {
707
+ return narrowing.onlyWithAssertions || narrowing.categoryIds !== void 0;
705
708
  }
706
- async function boundTraceIds(client, traceIds, limit, onlyWithAssertions) {
709
+ function hasApprovedAssertion(assertions, categoryIds) {
710
+ return assertions.some((assertion) => assertion.approvalState === "approved" && (categoryIds === void 0 || assertion.category_id !== null && categoryIds.includes(assertion.category_id)));
711
+ }
712
+ async function boundTraceIds(client, traceIds, limit, narrowing) {
707
713
  if (!Number.isInteger(limit) || limit < 1) throw new BitfabError("Replay limit must be a positive integer.");
708
- if (!onlyWithAssertions || limit >= traceIds.length) return traceIds.slice(0, limit);
714
+ if (!narrowsToAssertions(narrowing) || limit >= traceIds.length) return traceIds.slice(0, limit);
709
715
  const selected = [];
710
716
  for (const traceId of traceIds) {
711
717
  const { assertions, inheritedFrom } = await client.traces.getAssertions(traceId);
712
- if (inheritedFrom === null && hasApprovedAssertion(assertions)) {
718
+ if (inheritedFrom === null && hasApprovedAssertion(assertions, narrowing.categoryIds)) {
713
719
  selected.push(traceId);
714
720
  if (selected.length === limit) break;
715
721
  }
716
722
  }
717
- if (selected.length === 0) throw new BitfabError("No traces with approved assertions matched this replay selection.");
723
+ if (selected.length === 0) throw new BitfabError(narrowing.categoryIds === void 0 ? "No traces with approved assertions matched this replay selection." : "No traces with an approved assertion in the given categories matched this replay selection.");
718
724
  return selected;
719
725
  }
720
- async function pinnedDatasetMembers(client, datasetIds, limit, onlyWithAssertions = false) {
726
+ async function pinnedDatasetMembers(client, datasetIds, limit, narrowing = { onlyWithAssertions: false }) {
721
727
  const members = /* @__PURE__ */ new Set();
722
728
  for (const datasetId of datasetIds) {
723
729
  const { traceIds } = await client.datasets.listTraces(datasetId);
@@ -726,10 +732,10 @@ async function pinnedDatasetMembers(client, datasetIds, limit, onlyWithAssertion
726
732
  const ordered = [...members].sort();
727
733
  if (limit >= ordered.length) return;
728
734
  if (limit > MAX_PINNED_TRACE_IDS) throw new BitfabError(`Bounding a dataset replay to ${limit} names one trace ID per replayed item, and a replay accepts at most ${MAX_PINNED_TRACE_IDS}. Drop the limit to replay every selected dataset in full.`);
729
- return boundTraceIds(client, ordered, limit, onlyWithAssertions);
735
+ return boundTraceIds(client, ordered, limit, narrowing);
730
736
  }
731
737
  function usage(registry) {
732
- return `Usage: bitfab-replay --registry <path> <${registry === void 0 ? "pipeline" : Object.keys(registry).join("|")}> [options]\n\nOptions:\n --limit N (bounds a trace ID or dataset selection instead of replacing it)\n --attempts N (replay each trace N times in this run, max ${MAX_ATTEMPTS})\n --trace-ids id1,id2\n --name NAME (what this run is testing, such as "baseline"; Bitfab already records the commit, branch, and datasets)\n --notes TEXT (run conditions Bitfab cannot see, such as a forced feature flag)\n --metadata key=value (repeatable; tags kept on the experiment, such as which schedule launched it, and filterable through client.experiments.list)\n --concurrency N, --max-concurrency N\n --code-change working-tree|last-branch|default-branch|ref|skip|manual (required: the code change this run tests; working-tree is the uncommitted changes vs HEAD, last-branch the diff against the branch this one was cut from, default-branch the diff against the default branch, ref the diff against --code-change-base, skip none, manual the edits in --code-change-file)\n --code-change-base BRANCH|COMMIT (with --code-change ref: the branch or commit to diff against)\n --code-change-file PATH (with --code-change manual: a JSON file of { description, files })\n --experiment-group-id UUID (join this experiment group; a new UUID creates the group)\n --experiment-group-name NAME (name the group when this run creates it or it has no name yet; requires --experiment-group-id)\n --dataset-ids uuid1,uuid2 (--dataset-id is the same flag)\n --grader-ids id1,id2\n --only-with-assertions (replay only traces carrying an approved assertion)\n --skip-assertion-judging (don't judge approved assertions on each replay; judging is on by default and costs model calls)\n --judge-assertions (deprecated: judging is on by default)\n --mock none|all|marked\n --db-branch, --no-db-branch\n --dry-run (resolve inputs, run nothing)\n --fail-on-error (exit 1 after printing the result when any replayed item errored; under --dry-run, items whose inputs failed to resolve count)\n --resume EXPERIMENT_ID (finish an experiment that stopped partway, running only the items it did not finish, with the traces, attempts, and graders it started with)\n --force (with --resume, resume even when the experiment may still be running or the code changed since it started)\n --params PATH\n --param name=value (repeatable)\n -h, --help`;
738
+ return `Usage: bitfab-replay --registry <path> <${registry === void 0 ? "pipeline" : Object.keys(registry).join("|")}> [options]\n\nOptions:\n --limit N (bounds a trace ID or dataset selection instead of replacing it)\n --attempts N (replay each trace N times in this run, max ${MAX_ATTEMPTS})\n --trace-ids id1,id2\n --name NAME (what this run is testing, such as "baseline"; Bitfab already records the commit, branch, and datasets)\n --notes TEXT (run conditions Bitfab cannot see, such as a forced feature flag)\n --metadata key=value (repeatable; tags kept on the experiment, such as which schedule launched it, and filterable through client.experiments.list)\n --concurrency N, --max-concurrency N\n --code-change working-tree|last-branch|default-branch|ref|skip|manual (required: the code change this run tests; working-tree is the uncommitted changes vs HEAD, last-branch the diff against the branch this one was cut from, default-branch the diff against the default branch, ref the diff against --code-change-base, skip none, manual the edits in --code-change-file)\n --code-change-base BRANCH|COMMIT (with --code-change ref: the branch or commit to diff against)\n --code-change-file PATH (with --code-change manual: a JSON file of { description, files })\n --experiment-group-id UUID (join this experiment group; a new UUID creates the group)\n --experiment-group-name NAME (name the group when this run creates it or it has no name yet; requires --experiment-group-id)\n --dataset-ids uuid1,uuid2 (--dataset-id is the same flag)\n --grader-ids id1,id2\n --only-with-assertions (replay only traces carrying an approved assertion)\n --category-ids id1,id2 (with --trace-ids or --dataset-ids: replay only the traces carrying an approved assertion in one of these categories; which assertions are judged stays the same)\n --skip-assertion-judging (don't judge approved assertions on each replay; judging is on by default and costs model calls)\n --judge-assertions (deprecated: judging is on by default)\n --mock none|all|marked\n --db-branch, --no-db-branch\n --dry-run (resolve inputs, run nothing)\n --fail-on-error (exit 1 after printing the result when any replayed item errored; under --dry-run, items whose inputs failed to resolve count)\n --resume EXPERIMENT_ID (finish an experiment that stopped partway, running only the items it did not finish, with the traces, attempts, and graders it started with)\n --force (with --resume, resume even when the experiment may still be running or the code changed since it started)\n --params PATH\n --param name=value (repeatable)\n -h, --help`;
733
739
  }
734
740
  var ReplayCliHelp = class extends Error {};
735
741
  async function reseedFromRegistry(registry, pipeline, traceIds) {
@@ -939,6 +945,9 @@ function parseReplayCliArgs(registry, argv) {
939
945
  case "--grader-ids":
940
946
  parsed.graderIds = commaSeparated(flag, raw);
941
947
  break;
948
+ case "--category-ids":
949
+ parsed.categoryIds = commaSeparated(flag, raw);
950
+ break;
942
951
  case "--mock":
943
952
  if (raw !== "none" && raw !== "all" && raw !== "marked") throw new BitfabError(`--mock must be one of: none, all, marked (received '${raw}').`);
944
953
  parsed.mock = raw;
@@ -1164,6 +1173,7 @@ async function runReplayCli(registry, argv = typeof process === "undefined" ? []
1164
1173
  datasetIds: selectedDatasetIds,
1165
1174
  ...args.graderIds === void 0 ? {} : { graderIds: args.graderIds },
1166
1175
  ...args.onlyWithAssertions === void 0 ? {} : { onlyWithAssertions: args.onlyWithAssertions },
1176
+ ...args.categoryIds === void 0 ? {} : { categoryIds: args.categoryIds },
1167
1177
  ...args.skipAssertionJudging === void 0 ? {} : { skipAssertionJudging: args.skipAssertionJudging },
1168
1178
  ...args.mock === void 0 ? {} : { mock: args.mock },
1169
1179
  ...args.dbBranch === void 0 ? {} : { dbBranch: args.dbBranch && registrationOptions.dbBranch !== void 0 && registrationOptions.dbBranch !== false ? registrationOptions.dbBranch : args.dbBranch },
@@ -1197,13 +1207,18 @@ async function runReplayCli(registry, argv = typeof process === "undefined" ? []
1197
1207
  options.traceIds = args.traceIds;
1198
1208
  options.datasetIds = void 0;
1199
1209
  } else if (args.datasetIds !== void 0) options.traceIds = void 0;
1210
+ if (options.categoryIds !== void 0 && options.traceIds === void 0 && options.datasetIds === void 0) throw new BitfabError("--category-ids narrows a trace ID or dataset selection. Pass it with --trace-ids or --dataset-ids.");
1200
1211
  const bound = args.limit ?? registrationOptions.limit;
1201
1212
  options.limit = void 0;
1213
+ const narrowing = {
1214
+ onlyWithAssertions: options.onlyWithAssertions === true,
1215
+ categoryIds: options.categoryIds
1216
+ };
1202
1217
  if (options.traceIds !== void 0) {
1203
- if (bound !== void 0) options.traceIds = await boundTraceIds(registration.client, options.traceIds, bound, options.onlyWithAssertions === true);
1218
+ if (bound !== void 0) options.traceIds = await boundTraceIds(registration.client, options.traceIds, bound, narrowing);
1204
1219
  } else if (options.datasetIds !== void 0) {
1205
1220
  if (bound !== void 0) {
1206
- const pinned = await pinnedDatasetMembers(registration.client, options.datasetIds, bound, options.onlyWithAssertions === true);
1221
+ const pinned = await pinnedDatasetMembers(registration.client, options.datasetIds, bound, narrowing);
1207
1222
  if (pinned !== void 0) options.traceIds = pinned;
1208
1223
  }
1209
1224
  } else options.limit = bound ?? 10;
@@ -1323,4 +1338,4 @@ function runIfEntrypoint(moduleUrl, main) {
1323
1338
  //#endregion
1324
1339
  export { runRegistryMain as a, runSeedCli as c, runIfEntrypoint as i, parseRegistryCommandArgs as n, checkReplayCliArgs as o, resolveRegistry as r, runReplayCli as s, importRegistry as t };
1325
1340
 
1326
- //# sourceMappingURL=registryCommand-BQcyBmhN.js.map
1341
+ //# sourceMappingURL=registryCommand-Bm2-Peq8.js.map