Add prompt improvement button in drawer
This commit is contained in:
@@ -126,6 +126,22 @@ export type BatchRunSnapshot = {
|
||||
stopReason: "manual" | "assertion_failure" | "execution_error" | null;
|
||||
};
|
||||
|
||||
export type PromptImprovementResult = {
|
||||
diagnosis: string;
|
||||
promptChange: {
|
||||
before: string;
|
||||
after: string;
|
||||
reason: string;
|
||||
evidence: string[];
|
||||
} | null;
|
||||
manualRecommendations: Array<{
|
||||
category: "tool" | "test_case" | "other";
|
||||
title: string;
|
||||
detail: string;
|
||||
}>;
|
||||
evaluatorName: string;
|
||||
};
|
||||
|
||||
export function firstEvaluationFailureReason(item: BatchRunCase): string {
|
||||
const evaluations = [
|
||||
...item.turns.flatMap((turn) => turn.evaluations),
|
||||
|
||||
Reference in New Issue
Block a user