@bitfab/sdk 0.61.6 → 0.62.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/{chunk-QMRM4QEG.js → chunk-5EWDDBPF.js} +2 -2
- package/dist/{chunk-QMRM4QEG.js.map → chunk-5EWDDBPF.js.map} +1 -1
- package/dist/{chunk-2FX6Q72M.js → chunk-A5ACPLO3.js} +6 -6
- package/dist/{chunk-2FX6Q72M.js.map → chunk-A5ACPLO3.js.map} +1 -1
- package/dist/{chunk-IV6RXUSF.js → chunk-GGXDYIY4.js} +19 -7
- package/dist/chunk-GGXDYIY4.js.map +1 -0
- package/dist/{chunk-6SGSL4DI.js → chunk-IPV4QUWI.js} +2 -2
- package/dist/{chunk-6SGSL4DI.js.map → chunk-IPV4QUWI.js.map} +1 -1
- package/dist/{chunk-WMVXFHWY.js → chunk-XMTPGVK2.js} +15 -20
- package/dist/chunk-XMTPGVK2.js.map +1 -0
- package/dist/{http-GGBDE3LK.js → http-E7KJFDES.js} +2 -2
- package/dist/{http-3HBLZCPN.js → http-ECIHVF6V.js} +2 -2
- package/dist/index.cjs +15 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -34
- package/dist/index.d.ts +2 -34
- package/dist/index.js +3 -3
- package/dist/node.cjs +15 -20
- package/dist/node.cjs.map +1 -1
- package/dist/node.d.cts +1 -1
- package/dist/node.d.ts +1 -1
- package/dist/node.js +3 -3
- package/dist/{replay-W6KOZULR.js → replay-QJC3FX6H.js} +3 -3
- package/dist/replayCli.js +2 -2
- package/dist/seedCli.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-IV6RXUSF.js.map +0 -1
- package/dist/chunk-WMVXFHWY.js.map +0 -1
- /package/dist/{http-3HBLZCPN.js.map → http-E7KJFDES.js.map} +0 -0
- /package/dist/{http-GGBDE3LK.js.map → http-ECIHVF6V.js.map} +0 -0
- /package/dist/{replay-W6KOZULR.js.map → replay-QJC3FX6H.js.map} +0 -0
package/dist/index.d.cts
CHANGED
|
@@ -761,32 +761,6 @@ interface TokenUsage {
|
|
|
761
761
|
cached: number | null;
|
|
762
762
|
total: number | null;
|
|
763
763
|
}
|
|
764
|
-
interface TraceOutlineSpanError {
|
|
765
|
-
source: string;
|
|
766
|
-
error: string;
|
|
767
|
-
step?: string;
|
|
768
|
-
}
|
|
769
|
-
interface TraceOutlineSpan {
|
|
770
|
-
spanId: string;
|
|
771
|
-
name: string | null;
|
|
772
|
-
type: string;
|
|
773
|
-
traceFunctionKey: string | null;
|
|
774
|
-
durationMs: number | null;
|
|
775
|
-
tokens: TokenUsage | null;
|
|
776
|
-
model: string | null;
|
|
777
|
-
errors: TraceOutlineSpanError[] | null;
|
|
778
|
-
mocked: boolean;
|
|
779
|
-
children: TraceOutlineSpan[];
|
|
780
|
-
}
|
|
781
|
-
interface TraceOutline {
|
|
782
|
-
traceId: string;
|
|
783
|
-
name: string | null;
|
|
784
|
-
status: string;
|
|
785
|
-
traceFunctionKey: string | null;
|
|
786
|
-
durationMs: number | null;
|
|
787
|
-
spanCount: number;
|
|
788
|
-
spans: TraceOutlineSpan[];
|
|
789
|
-
}
|
|
790
764
|
/**
|
|
791
765
|
* Describes a single file edited as part of a code change.
|
|
792
766
|
*
|
|
@@ -909,8 +883,6 @@ interface CompleteReplayResponse {
|
|
|
909
883
|
* `ReplayItem.tokens`. Absent on servers that predate this field.
|
|
910
884
|
*/
|
|
911
885
|
tokens?: Record<string, TokenUsage | null>;
|
|
912
|
-
traceOutlines?: Record<string, TraceOutline>;
|
|
913
|
-
originalTraceOutlines?: Record<string, TraceOutline>;
|
|
914
886
|
/**
|
|
915
887
|
* Number of traces the server has persisted for this experiment at
|
|
916
888
|
* completion time. Lets the SDK distinguish "uploads failed" from
|
|
@@ -2298,8 +2270,6 @@ interface ReplayProgressItem {
|
|
|
2298
2270
|
model?: string | null;
|
|
2299
2271
|
dbSnapshotRef?: DbSnapshotRef | null;
|
|
2300
2272
|
dbBranchTimings?: DbBranchTimings | null;
|
|
2301
|
-
traceOutline?: TraceOutline | null;
|
|
2302
|
-
originalTraceOutline?: TraceOutline | null;
|
|
2303
2273
|
}
|
|
2304
2274
|
/**
|
|
2305
2275
|
* @deprecated Use {@link ReplayItemFinishProgress}. This legacy shape also
|
|
@@ -2455,8 +2425,6 @@ interface ReplayItem<T> {
|
|
|
2455
2425
|
* no snapshot ref, or against a server that predates timings.
|
|
2456
2426
|
*/
|
|
2457
2427
|
dbBranchTimings: DbBranchTimings | null;
|
|
2458
|
-
traceOutline: TraceOutline | null;
|
|
2459
|
-
originalTraceOutline: TraceOutline | null;
|
|
2460
2428
|
carriedOver?: boolean;
|
|
2461
2429
|
}
|
|
2462
2430
|
|
|
@@ -3882,7 +3850,7 @@ interface CommitRef {
|
|
|
3882
3850
|
/**
|
|
3883
3851
|
* SDK version from package.json (injected at build time)
|
|
3884
3852
|
*/
|
|
3885
|
-
declare const __version__ = "0.
|
|
3853
|
+
declare const __version__ = "0.62.1";
|
|
3886
3854
|
|
|
3887
3855
|
/**
|
|
3888
3856
|
* Constants for the Bitfab SDK.
|
|
@@ -4021,4 +3989,4 @@ declare function seedFromRegistry(registry: ReplayRegistry, pipeline: string, ca
|
|
|
4021
3989
|
run?: boolean;
|
|
4022
3990
|
}): Promise<SeedResult>;
|
|
4023
3991
|
|
|
4024
|
-
export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionLabelEvidence, type AssertionVerdict, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, 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 GenerateAssertionsOptions, type GetGraderLabelsParams, type GraderLabel, type GraderLabelSource, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, 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 ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, 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 SaveDatasetParams, type SaveDatasetResult, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, type TokenUsage, type TraceAssertion, type TraceAssertionSource, type TraceAssertionsResult, type TraceAssertionsUpdate, type TraceIngestionType, type TraceLabels, type
|
|
3992
|
+
export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionLabelEvidence, type AssertionVerdict, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, 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 GenerateAssertionsOptions, type GetGraderLabelsParams, type GraderLabel, type GraderLabelSource, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, 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 ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, 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 SaveDatasetParams, type SaveDatasetResult, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, 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, TracesClient, type TracingProcessor, type VercelCallParams, type VercelGenerateResult, type VercelStreamResult, type WrapBAMLOptions, type WrappedBamlFn, __version__, defineReplayRegistry, finalizers, flushTraces, getCurrentReplayBranch, getCurrentSpan, getCurrentTrace, reportReplayProgress, reseedFromRegistry, seedFromRegistry, serializeReplayResult };
|
package/dist/index.d.ts
CHANGED
|
@@ -761,32 +761,6 @@ interface TokenUsage {
|
|
|
761
761
|
cached: number | null;
|
|
762
762
|
total: number | null;
|
|
763
763
|
}
|
|
764
|
-
interface TraceOutlineSpanError {
|
|
765
|
-
source: string;
|
|
766
|
-
error: string;
|
|
767
|
-
step?: string;
|
|
768
|
-
}
|
|
769
|
-
interface TraceOutlineSpan {
|
|
770
|
-
spanId: string;
|
|
771
|
-
name: string | null;
|
|
772
|
-
type: string;
|
|
773
|
-
traceFunctionKey: string | null;
|
|
774
|
-
durationMs: number | null;
|
|
775
|
-
tokens: TokenUsage | null;
|
|
776
|
-
model: string | null;
|
|
777
|
-
errors: TraceOutlineSpanError[] | null;
|
|
778
|
-
mocked: boolean;
|
|
779
|
-
children: TraceOutlineSpan[];
|
|
780
|
-
}
|
|
781
|
-
interface TraceOutline {
|
|
782
|
-
traceId: string;
|
|
783
|
-
name: string | null;
|
|
784
|
-
status: string;
|
|
785
|
-
traceFunctionKey: string | null;
|
|
786
|
-
durationMs: number | null;
|
|
787
|
-
spanCount: number;
|
|
788
|
-
spans: TraceOutlineSpan[];
|
|
789
|
-
}
|
|
790
764
|
/**
|
|
791
765
|
* Describes a single file edited as part of a code change.
|
|
792
766
|
*
|
|
@@ -909,8 +883,6 @@ interface CompleteReplayResponse {
|
|
|
909
883
|
* `ReplayItem.tokens`. Absent on servers that predate this field.
|
|
910
884
|
*/
|
|
911
885
|
tokens?: Record<string, TokenUsage | null>;
|
|
912
|
-
traceOutlines?: Record<string, TraceOutline>;
|
|
913
|
-
originalTraceOutlines?: Record<string, TraceOutline>;
|
|
914
886
|
/**
|
|
915
887
|
* Number of traces the server has persisted for this experiment at
|
|
916
888
|
* completion time. Lets the SDK distinguish "uploads failed" from
|
|
@@ -2298,8 +2270,6 @@ interface ReplayProgressItem {
|
|
|
2298
2270
|
model?: string | null;
|
|
2299
2271
|
dbSnapshotRef?: DbSnapshotRef | null;
|
|
2300
2272
|
dbBranchTimings?: DbBranchTimings | null;
|
|
2301
|
-
traceOutline?: TraceOutline | null;
|
|
2302
|
-
originalTraceOutline?: TraceOutline | null;
|
|
2303
2273
|
}
|
|
2304
2274
|
/**
|
|
2305
2275
|
* @deprecated Use {@link ReplayItemFinishProgress}. This legacy shape also
|
|
@@ -2455,8 +2425,6 @@ interface ReplayItem<T> {
|
|
|
2455
2425
|
* no snapshot ref, or against a server that predates timings.
|
|
2456
2426
|
*/
|
|
2457
2427
|
dbBranchTimings: DbBranchTimings | null;
|
|
2458
|
-
traceOutline: TraceOutline | null;
|
|
2459
|
-
originalTraceOutline: TraceOutline | null;
|
|
2460
2428
|
carriedOver?: boolean;
|
|
2461
2429
|
}
|
|
2462
2430
|
|
|
@@ -3882,7 +3850,7 @@ interface CommitRef {
|
|
|
3882
3850
|
/**
|
|
3883
3851
|
* SDK version from package.json (injected at build time)
|
|
3884
3852
|
*/
|
|
3885
|
-
declare const __version__ = "0.
|
|
3853
|
+
declare const __version__ = "0.62.1";
|
|
3886
3854
|
|
|
3887
3855
|
/**
|
|
3888
3856
|
* Constants for the Bitfab SDK.
|
|
@@ -4021,4 +3989,4 @@ declare function seedFromRegistry(registry: ReplayRegistry, pipeline: string, ca
|
|
|
4021
3989
|
run?: boolean;
|
|
4022
3990
|
}): Promise<SeedResult>;
|
|
4023
3991
|
|
|
4024
|
-
export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionLabelEvidence, type AssertionVerdict, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, 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 GenerateAssertionsOptions, type GetGraderLabelsParams, type GraderLabel, type GraderLabelSource, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, 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 ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, 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 SaveDatasetParams, type SaveDatasetResult, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, type TokenUsage, type TraceAssertion, type TraceAssertionSource, type TraceAssertionsResult, type TraceAssertionsUpdate, type TraceIngestionType, type TraceLabels, type
|
|
3992
|
+
export { type ActiveSpanContext, type AdaptContext, type AdaptInputsFn, type AddDatasetGradersResult, type AddDatasetTracesResult, type AllowedEnvVars, type ApprovalFields, type ApprovalState, type Approver, type ArchiveAssertionsParams, AssertionCategoriesClient, type AssertionCategory, type AssertionCategorySummary, type AssertionEvidenceParameter, type AssertionGeneration, AssertionGenerationError, type AssertionGenerationStatus, AssertionGenerationTimeoutError, type AssertionLabelEvidence, type AssertionVerdict, type Assignee, BITFAB_PROGRESS_PREFIX, type BamlExecutionResult, Bitfab, BitfabClaudeAgentHandler, type BitfabConfig, BitfabError, BitfabFunction, BitfabLangGraphCallbackHandler as BitfabLangChainCallbackHandler, BitfabLangGraphCallbackHandler, BitfabLangGraphIntegration, type BitfabLanguageModelMiddleware, BitfabOpenAIAgentHandler, BitfabOpenAITracingProcessor, BitfabRivetIntegration, BitfabVercelAiHandler, type CaptureSurface, type CaptureWhen, type CapturedSpan, 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 GenerateAssertionsOptions, type GetGraderLabelsParams, type GraderLabel, type GraderLabelSource, type GraderRerun, GraderRerunError, type GraderRerunProgress, type GraderRerunResult, type GraderRerunStatus, GraderRerunTimeoutError, GradersClient, HttpClient, type HumanLabelOutcome, type HumanLabelUpdate, type Justification, type JustificationSpan, type LabelAction, type LabelConfidence, type LabelOutcome, type LabelSource, type LabelStatus, type LabelTarget, type LabelUpdate, LabelsClient, type LangGraphIntegrationOptions, type ListDatasetsParams, 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 ProviderDefinition, type RemoveDatasetGradersResult, type RemoveDatasetTracesResult, 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 SaveDatasetParams, type SaveDatasetResult, type SeedCase, type SeedCaseOptions, type SeedResult, type SeedRunOptions, type SelectiveReplayDecision, type SelectiveReplayOptions, type SelectiveReplayReport, type SpanLookup, type SpanMethodDecorator, type SpanMethodDecoratorContext, type SpanNodeMeta, type SpanOccurrence, type SpanOptions, type SpanType, 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, TracesClient, type TracingProcessor, type VercelCallParams, type VercelGenerateResult, type VercelStreamResult, type WrapBAMLOptions, type WrappedBamlFn, __version__, defineReplayRegistry, finalizers, flushTraces, getCurrentReplayBranch, getCurrentSpan, getCurrentTrace, reportReplayProgress, reseedFromRegistry, seedFromRegistry, serializeReplayResult };
|
package/dist/index.js
CHANGED
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
getCurrentTrace,
|
|
27
27
|
reseedFromRegistry,
|
|
28
28
|
seedFromRegistry
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-A5ACPLO3.js";
|
|
30
30
|
import "./chunk-K4XCWQBC.js";
|
|
31
31
|
import {
|
|
32
32
|
BITFAB_PROGRESS_PREFIX,
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
ReplayError,
|
|
36
36
|
reportReplayProgress,
|
|
37
37
|
serializeReplayResult
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-XMTPGVK2.js";
|
|
39
39
|
import {
|
|
40
40
|
BitfabError,
|
|
41
41
|
DEFAULT_SERVICE_URL,
|
|
@@ -43,7 +43,7 @@ import {
|
|
|
43
43
|
MixedTracingError,
|
|
44
44
|
__version__,
|
|
45
45
|
flushTraces
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-IPV4QUWI.js";
|
|
47
47
|
import "./chunk-BAOIRE5T.js";
|
|
48
48
|
export {
|
|
49
49
|
AssertionCategoriesClient,
|
package/dist/node.cjs
CHANGED
|
@@ -88,7 +88,7 @@ var __version__, __packageName__;
|
|
|
88
88
|
var init_version_generated = __esm({
|
|
89
89
|
"src/version.generated.ts"() {
|
|
90
90
|
"use strict";
|
|
91
|
-
__version__ = "0.
|
|
91
|
+
__version__ = "0.62.1";
|
|
92
92
|
__packageName__ = "@bitfab/sdk";
|
|
93
93
|
}
|
|
94
94
|
});
|
|
@@ -3704,12 +3704,13 @@ function installReplayInterruptHandlers(target) {
|
|
|
3704
3704
|
const removeHandlers = () => {
|
|
3705
3705
|
for (const [signal, handler] of handlers) {
|
|
3706
3706
|
host.removeListener(signal, handler);
|
|
3707
|
+
replayListeners.delete(handler);
|
|
3707
3708
|
}
|
|
3708
3709
|
handlers.clear();
|
|
3709
3710
|
};
|
|
3710
3711
|
let interrupting = false;
|
|
3711
3712
|
const handleSignal = async (signal) => {
|
|
3712
|
-
const hostHandlesSignal = host.
|
|
3713
|
+
const hostHandlesSignal = host.listeners(signal).some((listener) => !replayListeners.has(listener));
|
|
3713
3714
|
const markedInterrupted = await target.interrupt();
|
|
3714
3715
|
removeHandlers();
|
|
3715
3716
|
if (target.onInterrupt !== void 0) {
|
|
@@ -3738,11 +3739,12 @@ function installReplayInterruptHandlers(target) {
|
|
|
3738
3739
|
void handleSignal(signal);
|
|
3739
3740
|
};
|
|
3740
3741
|
handlers.set(signal, handler);
|
|
3742
|
+
replayListeners.add(handler);
|
|
3741
3743
|
host.on(signal, handler);
|
|
3742
3744
|
}
|
|
3743
3745
|
return { remove: removeHandlers, interrupted: () => interrupting };
|
|
3744
3746
|
}
|
|
3745
|
-
var REPLAY_INTERRUPT_SIGNALS;
|
|
3747
|
+
var REPLAY_INTERRUPT_SIGNALS, replayListeners;
|
|
3746
3748
|
var init_replayInterrupt = __esm({
|
|
3747
3749
|
"src/replayInterrupt.ts"() {
|
|
3748
3750
|
"use strict";
|
|
@@ -3750,6 +3752,7 @@ var init_replayInterrupt = __esm({
|
|
|
3750
3752
|
"SIGINT",
|
|
3751
3753
|
"SIGTERM"
|
|
3752
3754
|
];
|
|
3755
|
+
replayListeners = /* @__PURE__ */ new Set();
|
|
3753
3756
|
}
|
|
3754
3757
|
});
|
|
3755
3758
|
|
|
@@ -4134,8 +4137,6 @@ function carriedOverReplayItem(finished) {
|
|
|
4134
4137
|
model: null,
|
|
4135
4138
|
dbSnapshotRef: null,
|
|
4136
4139
|
dbBranchTimings: null,
|
|
4137
|
-
traceOutline: null,
|
|
4138
|
-
originalTraceOutline: null,
|
|
4139
4140
|
carriedOver: true
|
|
4140
4141
|
};
|
|
4141
4142
|
}
|
|
@@ -4428,9 +4429,7 @@ async function processItem(httpClient, serverItem, fn, experimentId, mockStrateg
|
|
|
4428
4429
|
tokens: null,
|
|
4429
4430
|
model: serverItem.originalModel ?? serverItem.model ?? null,
|
|
4430
4431
|
dbSnapshotRef: dbSnapshotRef ?? null,
|
|
4431
|
-
dbBranchTimings: dbBranchTimings ?? null
|
|
4432
|
-
traceOutline: null,
|
|
4433
|
-
originalTraceOutline: null
|
|
4432
|
+
dbBranchTimings: dbBranchTimings ?? null
|
|
4434
4433
|
};
|
|
4435
4434
|
}
|
|
4436
4435
|
try {
|
|
@@ -4518,9 +4517,7 @@ async function processItem(httpClient, serverItem, fn, experimentId, mockStrateg
|
|
|
4518
4517
|
tokens: null,
|
|
4519
4518
|
model: originalModel,
|
|
4520
4519
|
dbSnapshotRef: dbSnapshotRef ?? null,
|
|
4521
|
-
dbBranchTimings: dbBranchTimings ?? null
|
|
4522
|
-
traceOutline: null,
|
|
4523
|
-
originalTraceOutline: null
|
|
4520
|
+
dbBranchTimings: dbBranchTimings ?? null
|
|
4524
4521
|
};
|
|
4525
4522
|
}
|
|
4526
4523
|
async function waitForReplayPersistence(httpClient, experimentId, replayedTraceIds) {
|
|
@@ -4587,11 +4584,11 @@ function sleepForReplayPersistence(ms) {
|
|
|
4587
4584
|
setTimeout(resolve, ms);
|
|
4588
4585
|
});
|
|
4589
4586
|
}
|
|
4590
|
-
async function mapWithConcurrency2(tasks, maxConcurrency, onSettled, onStarted) {
|
|
4587
|
+
async function mapWithConcurrency2(tasks, maxConcurrency, onSettled, onStarted, shouldStop) {
|
|
4591
4588
|
const results = new Array(tasks.length);
|
|
4592
4589
|
let nextIndex = 0;
|
|
4593
4590
|
async function worker() {
|
|
4594
|
-
while (nextIndex < tasks.length) {
|
|
4591
|
+
while (nextIndex < tasks.length && shouldStop?.() !== true) {
|
|
4595
4592
|
const index = nextIndex++;
|
|
4596
4593
|
onStarted?.(index);
|
|
4597
4594
|
const result = await tasks[index]();
|
|
@@ -4604,7 +4601,7 @@ async function mapWithConcurrency2(tasks, maxConcurrency, onSettled, onStarted)
|
|
|
4604
4601
|
() => worker()
|
|
4605
4602
|
);
|
|
4606
4603
|
await Promise.all(workers);
|
|
4607
|
-
return results;
|
|
4604
|
+
return results.slice(0, nextIndex);
|
|
4608
4605
|
}
|
|
4609
4606
|
async function replay(httpClient, serviceUrl, traceFunctionKey, fn, options, registeredOverrides = []) {
|
|
4610
4607
|
if (options?.resume !== void 0) {
|
|
@@ -4888,9 +4885,7 @@ async function runReplaySession(httpClient, fn, session, fullExperimentUrl, maxC
|
|
|
4888
4885
|
tokens: item.tokens,
|
|
4889
4886
|
model: item.model,
|
|
4890
4887
|
dbSnapshotRef: item.dbSnapshotRef,
|
|
4891
|
-
dbBranchTimings: item.dbBranchTimings
|
|
4892
|
-
traceOutline: item.traceOutline,
|
|
4893
|
-
originalTraceOutline: item.originalTraceOutline
|
|
4888
|
+
dbBranchTimings: item.dbBranchTimings
|
|
4894
4889
|
}
|
|
4895
4890
|
});
|
|
4896
4891
|
} catch {
|
|
@@ -4921,9 +4916,11 @@ async function runReplaySession(httpClient, fn, session, fullExperimentUrl, maxC
|
|
|
4921
4916
|
});
|
|
4922
4917
|
} catch {
|
|
4923
4918
|
}
|
|
4924
|
-
} : void 0
|
|
4919
|
+
} : void 0,
|
|
4920
|
+
interrupted
|
|
4925
4921
|
);
|
|
4926
4922
|
const resultItems = [...carriedOverItems, ...ranItems];
|
|
4923
|
+
throwIfInterrupted(interrupted, resultItems, experimentId, fullExperimentUrl);
|
|
4927
4924
|
if (options?.dryRun === true) {
|
|
4928
4925
|
throwIfInterrupted(
|
|
4929
4926
|
interrupted,
|
|
@@ -4985,9 +4982,7 @@ async function runReplaySession(httpClient, fn, session, fullExperimentUrl, maxC
|
|
|
4985
4982
|
}
|
|
4986
4983
|
if (mapped !== void 0) {
|
|
4987
4984
|
item.tokens = replayTokens?.[mapped] ?? null;
|
|
4988
|
-
item.traceOutline = completeResult.traceOutlines?.[mapped] ?? null;
|
|
4989
4985
|
}
|
|
4990
|
-
item.originalTraceOutline = completeResult.originalTraceOutlines?.[item.originalTraceId] ?? null;
|
|
4991
4986
|
}
|
|
4992
4987
|
if (completedCount > 0 && missing.length === completedCount) {
|
|
4993
4988
|
const serverCount = completeResult.traceCount !== void 0 ? ` The server persisted ${completeResult.traceCount} trace(s) for this run.` : "";
|