Improve onboarding verification and routing controls
This commit is contained in:
1 parent
bc0f8e0773
commit
d05de52cd9
30 files changed
+3024
-162
No files matched your search
@@ -93,6 +93,29 @@ describe("judgeOnboardingWithLlm", () => {
|
||||
}
|
||||
});
|
||||
|
||||
it("keeps scores when rationale is longer than the prompt asks for", async () => {
|
||||
const result = await judgeOnboardingWithLlm(
|
||||
new FakeLlmClient(
|
||||
JSON.stringify({
|
||||
friendliness: 3,
|
||||
accuracy: 4,
|
||||
concision: 5,
|
||||
scope: 4,
|
||||
rationale: "가".repeat(800),
|
||||
}),
|
||||
),
|
||||
evalCase,
|
||||
"이제 방 하트 인증만 남았어요.",
|
||||
derived,
|
||||
);
|
||||
|
||||
expect(result.skipped).toBe(false);
|
||||
if (!result.skipped) {
|
||||
expect(result.scores.overall).toBe(4);
|
||||
expect(result.rationale).toHaveLength(500);
|
||||
}
|
||||
});
|
||||
|
||||
it("skips when the judge returns invalid JSON", async () => {
|
||||
const result = await judgeOnboardingWithLlm(
|
||||
new FakeLlmClient('{"friendliness":"bad"}'),
|
||||
|
||||
Reference in new issue
Block a user