@bitfab/sdk 0.57.3 → 0.57.4

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/index.d.cts CHANGED
@@ -1322,6 +1322,7 @@ type LabelVerdict = {
1322
1322
  label: boolean;
1323
1323
  annotation: string;
1324
1324
  confidence?: LabelConfidence;
1325
+ evidence?: Justification | null;
1325
1326
  } | {
1326
1327
  skip: true;
1327
1328
  } | {
@@ -1339,6 +1340,7 @@ type HumanLabelUpdate = {
1339
1340
  label: boolean;
1340
1341
  annotation: string;
1341
1342
  confidence?: LabelConfidence;
1343
+ evidence?: Justification | null;
1342
1344
  };
1343
1345
  type HumanLabelOutcome = {
1344
1346
  traceId: string;
@@ -1352,6 +1354,7 @@ type AssertionVerdict = {
1352
1354
  labelStatus: LabelStatus;
1353
1355
  label: boolean | null;
1354
1356
  annotation: string | null;
1357
+ evidence: Justification | null;
1355
1358
  confidence: LabelConfidence | null;
1356
1359
  labelSource: LabelSource;
1357
1360
  approved: boolean;
@@ -1361,6 +1364,7 @@ type TraceLabels = {
1361
1364
  labelStatus: LabelStatus;
1362
1365
  label: boolean | null;
1363
1366
  annotation: string | null;
1367
+ evidence: Justification | null;
1364
1368
  approved: boolean;
1365
1369
  passed: number;
1366
1370
  failed: number;
@@ -1379,6 +1383,8 @@ declare class LabelsClient {
1379
1383
  saveHumanAll(updates: HumanLabelUpdate[]): Promise<HumanLabelOutcome[]>;
1380
1384
  get(traceId: string): Promise<TraceLabels | null>;
1381
1385
  getAll(traceIds: string[]): Promise<TraceLabels[]>;
1386
+ /** Suggest evidence for a whole-trace or assertion label. Currently returns an empty list. */
1387
+ getLabelEvidence(traceId: string, assertionId?: string): Promise<Justification>;
1382
1388
  }
1383
1389
 
1384
1390
  type GraderLabelSource = "human" | "live_grader";
@@ -3604,7 +3610,7 @@ interface CommitRef {
3604
3610
  /**
3605
3611
  * SDK version from package.json (injected at build time)
3606
3612
  */
3607
- declare const __version__ = "0.57.3";
3613
+ declare const __version__ = "0.57.4";
3608
3614
 
3609
3615
  /**
3610
3616
  * Constants for the Bitfab SDK.
package/dist/index.d.ts CHANGED
@@ -1322,6 +1322,7 @@ type LabelVerdict = {
1322
1322
  label: boolean;
1323
1323
  annotation: string;
1324
1324
  confidence?: LabelConfidence;
1325
+ evidence?: Justification | null;
1325
1326
  } | {
1326
1327
  skip: true;
1327
1328
  } | {
@@ -1339,6 +1340,7 @@ type HumanLabelUpdate = {
1339
1340
  label: boolean;
1340
1341
  annotation: string;
1341
1342
  confidence?: LabelConfidence;
1343
+ evidence?: Justification | null;
1342
1344
  };
1343
1345
  type HumanLabelOutcome = {
1344
1346
  traceId: string;
@@ -1352,6 +1354,7 @@ type AssertionVerdict = {
1352
1354
  labelStatus: LabelStatus;
1353
1355
  label: boolean | null;
1354
1356
  annotation: string | null;
1357
+ evidence: Justification | null;
1355
1358
  confidence: LabelConfidence | null;
1356
1359
  labelSource: LabelSource;
1357
1360
  approved: boolean;
@@ -1361,6 +1364,7 @@ type TraceLabels = {
1361
1364
  labelStatus: LabelStatus;
1362
1365
  label: boolean | null;
1363
1366
  annotation: string | null;
1367
+ evidence: Justification | null;
1364
1368
  approved: boolean;
1365
1369
  passed: number;
1366
1370
  failed: number;
@@ -1379,6 +1383,8 @@ declare class LabelsClient {
1379
1383
  saveHumanAll(updates: HumanLabelUpdate[]): Promise<HumanLabelOutcome[]>;
1380
1384
  get(traceId: string): Promise<TraceLabels | null>;
1381
1385
  getAll(traceIds: string[]): Promise<TraceLabels[]>;
1386
+ /** Suggest evidence for a whole-trace or assertion label. Currently returns an empty list. */
1387
+ getLabelEvidence(traceId: string, assertionId?: string): Promise<Justification>;
1382
1388
  }
1383
1389
 
1384
1390
  type GraderLabelSource = "human" | "live_grader";
@@ -3604,7 +3610,7 @@ interface CommitRef {
3604
3610
  /**
3605
3611
  * SDK version from package.json (injected at build time)
3606
3612
  */
3607
- declare const __version__ = "0.57.3";
3613
+ declare const __version__ = "0.57.4";
3608
3614
 
3609
3615
  /**
3610
3616
  * Constants for the Bitfab SDK.
package/dist/index.js CHANGED
@@ -21,7 +21,7 @@ import {
21
21
  getCurrentTrace,
22
22
  reseedFromRegistry,
23
23
  seedFromRegistry
24
- } from "./chunk-BJUKVV7A.js";
24
+ } from "./chunk-4Z3VI3KK.js";
25
25
  import "./chunk-RCHSYWKI.js";
26
26
  import {
27
27
  BITFAB_PROGRESS_PREFIX,
@@ -30,7 +30,7 @@ import {
30
30
  ReplayError,
31
31
  reportReplayProgress,
32
32
  serializeReplayResult
33
- } from "./chunk-CP3KI734.js";
33
+ } from "./chunk-TN4YJM7E.js";
34
34
  import {
35
35
  BitfabError,
36
36
  DEFAULT_SERVICE_URL,
@@ -38,7 +38,7 @@ import {
38
38
  MixedTracingError,
39
39
  __version__,
40
40
  flushTraces
41
- } from "./chunk-S2EBISN2.js";
41
+ } from "./chunk-7V4LTGW3.js";
42
42
  import "./chunk-VCRFFCLY.js";
43
43
  export {
44
44
  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.57.3";
91
+ __version__ = "0.57.4";
92
92
  __packageName__ = "@bitfab/sdk";
93
93
  }
94
94
  });
@@ -5992,6 +5992,7 @@ init_http();
5992
5992
  // src/labels.ts
5993
5993
  var LABELS_PATH = "/api/sdk/traces/labels";
5994
5994
  var HUMAN_LABELS_PATH = "/api/sdk/traces/labels/human";
5995
+ var LABEL_EVIDENCE_PATH = "/api/sdk/traces/labels/label-evidence";
5995
5996
  var LabelsClient = class {
5996
5997
  constructor(httpClient) {
5997
5998
  this.httpClient = httpClient;
@@ -6040,6 +6041,17 @@ var LabelsClient = class {
6040
6041
  );
6041
6042
  return response.labels;
6042
6043
  }
6044
+ /** Suggest evidence for a whole-trace or assertion label. Currently returns an empty list. */
6045
+ async getLabelEvidence(traceId, assertionId) {
6046
+ const query = new URLSearchParams({ traceId });
6047
+ if (assertionId !== void 0) {
6048
+ query.set("assertionId", assertionId);
6049
+ }
6050
+ const response = await this.httpClient.get(
6051
+ `${LABEL_EVIDENCE_PATH}?${query.toString()}`
6052
+ );
6053
+ return response.evidence;
6054
+ }
6043
6055
  };
6044
6056
 
6045
6057
  // src/langgraph.ts