@absolutejs/absolute 0.19.0-beta.536 → 0.19.0-beta.537

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/ai/index.js CHANGED
@@ -6000,6 +6000,64 @@ var buildRAGEvaluationHistoryRows = (history) => {
6000
6000
  }
6001
6001
  return rows;
6002
6002
  };
6003
+ var buildRAGEvaluationCaseTracePresentations = (history) => {
6004
+ if (!history?.caseTraceSnapshots.length) {
6005
+ return [];
6006
+ }
6007
+ return history.caseTraceSnapshots.map((entry) => {
6008
+ const label = entry.label ?? entry.caseId;
6009
+ const currentMode = entry.traceMode ?? "no-trace";
6010
+ const previousMode = entry.previousTraceMode ?? "n/a";
6011
+ const currentVariants = entry.variantQueries.length > 0 ? entry.variantQueries.join(", ") : "none";
6012
+ const previousVariants = entry.previousVariantQueries.length > 0 ? entry.previousVariantQueries.join(", ") : "none";
6013
+ const currentStages = Object.keys(entry.stageCounts).length > 0 ? Object.entries(entry.stageCounts).map(([stage, count]) => `${stage} ${count}`).join(", ") : "none";
6014
+ const previousStages = Object.keys(entry.previousStageCounts).length > 0 ? Object.entries(entry.previousStageCounts).map(([stage, count]) => `${stage} ${count}`).join(", ") : "none";
6015
+ return {
6016
+ caseId: entry.caseId,
6017
+ label,
6018
+ summary: `${entry.traceChange} \xB7 ${previousMode}\u2192${currentMode} \xB7 final ${entry.previousFinalCount ?? 0}\u2192${entry.finalCount}`,
6019
+ traceChange: entry.traceChange,
6020
+ rows: [
6021
+ { label: "Query", value: entry.query },
6022
+ { label: "Trace change", value: entry.traceChange },
6023
+ { label: "Mode", value: `${previousMode}\u2192${currentMode}` },
6024
+ {
6025
+ label: "Transformed query",
6026
+ value: `${entry.previousTransformedQuery?.trim() || "n/a"}\u2192${entry.transformedQuery?.trim() || "n/a"}`
6027
+ },
6028
+ {
6029
+ label: "Final",
6030
+ value: `${entry.previousFinalCount ?? 0}\u2192${entry.finalCount}`
6031
+ },
6032
+ {
6033
+ label: "Vector",
6034
+ value: `${entry.previousVectorCount ?? 0}\u2192${entry.vectorCount}`
6035
+ },
6036
+ {
6037
+ label: "Lexical",
6038
+ value: `${entry.previousLexicalCount ?? 0}\u2192${entry.lexicalCount}`
6039
+ },
6040
+ {
6041
+ label: "Candidate topK",
6042
+ value: `${entry.previousCandidateTopK ?? 0}\u2192${entry.candidateTopK}`
6043
+ },
6044
+ {
6045
+ label: "Lexical topK",
6046
+ value: `${entry.previousLexicalTopK ?? 0}\u2192${entry.lexicalTopK}`
6047
+ },
6048
+ {
6049
+ label: "Variants",
6050
+ value: `${previousVariants}\u2192${currentVariants}`
6051
+ },
6052
+ {
6053
+ label: "Stages",
6054
+ value: `${previousStages}\u2192${currentStages}`
6055
+ },
6056
+ { label: "Status", value: entry.status }
6057
+ ]
6058
+ };
6059
+ });
6060
+ };
6003
6061
  var buildRAGEvaluationRunDiff = ({
6004
6062
  current,
6005
6063
  previous
@@ -11756,6 +11814,7 @@ export {
11756
11814
  buildRAGEvaluationResponse,
11757
11815
  buildRAGEvaluationLeaderboard,
11758
11816
  buildRAGEvaluationHistoryRows,
11817
+ buildRAGEvaluationCaseTracePresentations,
11759
11818
  buildRAGContext,
11760
11819
  buildRAGComparisonTraceSummaryRows,
11761
11820
  buildRAGComparisonTraceDiffRows,
@@ -11774,5 +11833,5 @@ export {
11774
11833
  aiChat
11775
11834
  };
11776
11835
 
11777
- //# debugId=2E0B1A7677E438F664756E2164756E21
11836
+ //# debugId=BBC0B1F804D3DF1E64756E2164756E21
11778
11837
  //# sourceMappingURL=index.js.map