@crowandraven/evalkeeper 0.17.1 → 0.19.0
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/decisions.js +1 -1
- package/dist/decisions.js.map +1 -1
- package/dist/drafts.d.ts +2 -0
- package/dist/drafts.js +1 -1
- package/dist/drafts.js.map +1 -1
- package/dist/glossary.d.ts +25 -14
- package/dist/glossary.js +25 -14
- package/dist/glossary.js.map +1 -1
- package/dist/health.js +2 -2
- package/dist/health.js.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/memoryStore.d.ts +2 -1
- package/dist/memoryStore.js +9 -0
- package/dist/memoryStore.js.map +1 -1
- package/dist/next/actions.js +58 -3
- package/dist/next/actions.js.map +1 -1
- package/dist/prisma/contracts.d.ts +5 -2
- package/dist/prisma/contracts.js +7 -1
- package/dist/prisma/contracts.js.map +1 -1
- package/dist/prisma/index.d.ts +40 -1
- package/dist/prisma/index.js +37 -1
- package/dist/prisma/index.js.map +1 -1
- package/dist/prune.d.ts +43 -10
- package/dist/prune.js +42 -13
- package/dist/prune.js.map +1 -1
- package/dist/react/AddCase.js +11 -5
- package/dist/react/AddCase.js.map +1 -1
- package/dist/react/AnswerKey.js +7 -4
- package/dist/react/AnswerKey.js.map +1 -1
- package/dist/react/CaseMenu.d.ts +2 -2
- package/dist/react/CaseMenu.js +10 -31
- package/dist/react/CaseMenu.js.map +1 -1
- package/dist/react/CompareView.js +3 -3
- package/dist/react/CompareView.js.map +1 -1
- package/dist/react/ConfirmAnswer.js +1 -1
- package/dist/react/ConfirmAnswer.js.map +1 -1
- package/dist/react/Drawer.d.ts +32 -0
- package/dist/react/Drawer.js +60 -0
- package/dist/react/Drawer.js.map +1 -0
- package/dist/react/HubSections.d.ts +34 -30
- package/dist/react/HubSections.js +104 -103
- package/dist/react/HubSections.js.map +1 -1
- package/dist/react/Menu.d.ts +37 -0
- package/dist/react/Menu.js +51 -0
- package/dist/react/Menu.js.map +1 -0
- package/dist/react/ModelMenu.d.ts +1 -1
- package/dist/react/ModelMenu.js +8 -32
- package/dist/react/ModelMenu.js.map +1 -1
- package/dist/react/RunView.js +24 -4
- package/dist/react/RunView.js.map +1 -1
- package/dist/react/Spending.d.ts +25 -0
- package/dist/react/Spending.js +51 -0
- package/dist/react/Spending.js.map +1 -0
- package/dist/react/SuiteSections.d.ts +27 -14
- package/dist/react/SuiteSections.js +227 -61
- package/dist/react/SuiteSections.js.map +1 -1
- package/dist/react/app.d.ts +18 -0
- package/dist/react/app.js.map +1 -1
- package/dist/react/format.d.ts +13 -0
- package/dist/react/format.js +13 -0
- package/dist/react/format.js.map +1 -1
- package/dist/react/index.d.ts +3 -0
- package/dist/react/index.js +3 -0
- package/dist/react/index.js.map +1 -1
- package/dist/react/pieces.d.ts +21 -8
- package/dist/react/pieces.js +44 -14
- package/dist/react/pieces.js.map +1 -1
- package/dist/runner.d.ts +18 -8
- package/dist/runner.js +148 -12
- package/dist/runner.js.map +1 -1
- package/dist/settings.d.ts +12 -0
- package/dist/settings.js +18 -0
- package/dist/settings.js.map +1 -1
- package/dist/spending.d.ts +100 -0
- package/dist/spending.js +133 -0
- package/dist/spending.js.map +1 -0
- package/dist/stats.d.ts +3 -1
- package/dist/stats.js +6 -2
- package/dist/stats.js.map +1 -1
- package/dist/store.d.ts +5 -0
- package/dist/suggest.js +17 -12
- package/dist/suggest.js.map +1 -1
- package/dist/suiteSettings.d.ts +78 -0
- package/dist/suiteSettings.js +142 -0
- package/dist/suiteSettings.js.map +1 -0
- package/dist/suites/crisisRisk.js +3 -3
- package/dist/suites/crisisRisk.js.map +1 -1
- package/dist/suites/hopelessness.js +6 -6
- package/dist/suites/hopelessness.js.map +1 -1
- package/dist/suites/injection.js +2 -2
- package/dist/suites/injection.js.map +1 -1
- package/dist/summary.d.ts +41 -4
- package/dist/summary.js +46 -8
- package/dist/summary.js.map +1 -1
- package/dist/testing.d.ts +19 -0
- package/dist/testing.js +61 -0
- package/dist/testing.js.map +1 -1
- package/dist/todo.d.ts +146 -0
- package/dist/todo.js +198 -0
- package/dist/todo.js.map +1 -0
- package/dist/types.d.ts +46 -7
- package/dist/types.js +28 -4
- package/dist/types.js.map +1 -1
- package/package.json +1 -1
- package/schema/evalkeeper.prisma +13 -0
- package/src/decisions.ts +1 -1
- package/src/drafts.ts +3 -1
- package/src/glossary.ts +35 -14
- package/src/health.ts +3 -2
- package/src/index.ts +3 -0
- package/src/memoryStore.ts +15 -1
- package/src/next/actions.ts +67 -2
- package/src/prisma/contracts.ts +16 -1
- package/src/prisma/index.ts +68 -1
- package/src/prune.ts +71 -14
- package/src/react/AddCase.tsx +13 -11
- package/src/react/AnswerKey.tsx +17 -5
- package/src/react/CaseMenu.tsx +23 -77
- package/src/react/CompareView.tsx +4 -10
- package/src/react/ConfirmAnswer.tsx +1 -1
- package/src/react/Drawer.tsx +130 -0
- package/src/react/HubSections.tsx +180 -414
- package/src/react/Menu.tsx +155 -0
- package/src/react/ModelMenu.tsx +23 -74
- package/src/react/RunView.tsx +46 -3
- package/src/react/Spending.tsx +200 -0
- package/src/react/SuiteSections.tsx +591 -148
- package/src/react/app.ts +18 -0
- package/src/react/format.ts +15 -0
- package/src/react/index.ts +3 -0
- package/src/react/pieces.tsx +57 -18
- package/src/runner.ts +199 -13
- package/src/settings.ts +20 -0
- package/src/spending.ts +209 -0
- package/src/stats.ts +8 -2
- package/src/store.ts +5 -0
- package/src/suggest.ts +21 -14
- package/src/suiteSettings.ts +201 -0
- package/src/suites/crisisRisk.ts +3 -3
- package/src/suites/hopelessness.ts +6 -6
- package/src/suites/injection.ts +2 -2
- package/src/summary.ts +59 -8
- package/src/testing.ts +77 -0
- package/src/todo.ts +318 -0
- package/src/types.ts +63 -9
- package/starter/index.ts +7 -0
- package/templates/lib/evalkeeper/actions.ts +20 -0
package/dist/decisions.js
CHANGED
|
@@ -99,7 +99,7 @@ export function decisionCheck(key, answer, expected, opts = {}) {
|
|
|
99
99
|
pass: s.correct,
|
|
100
100
|
...(s.correct ? {} : { note: `Expected ${say(expected)}, got ${given}` }),
|
|
101
101
|
given: answer.type === "boolean"
|
|
102
|
-
? `${given},
|
|
102
|
+
? `${given}, cutoff ${pct(opts.threshold ?? 0.5)}`
|
|
103
103
|
: `${given}${sure}`,
|
|
104
104
|
measures,
|
|
105
105
|
};
|
package/dist/decisions.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"decisions.js","sourceRoot":"","sources":["../src/decisions.ts"],"names":[],"mappings":"AAkDA,wEAAwE;AACxE,MAAM,CAAC,MAAM,eAAe,GAAG,IAAI,CAAC;AAEpC,MAAM,SAAS,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,eAAe,CAAC,CAAC,CAAC;AAEzE,4CAA4C;AAC5C,SAAS,KAAK,CAAC,aAAqC;IAClD,IAAI,IAAI,GAAkB,IAAI,CAAC;IAC/B,IAAI,GAAG,GAAG,CAAC,QAAQ,CAAC;IACpB,KAAK,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,aAAa,CAAC;QAChD,IAAI,CAAC,GAAG,GAAG,EAAE,CAAC;YACZ,GAAG,GAAG,CAAC,CAAC;YACR,IAAI,GAAG,CAAC,CAAC;QACX,CAAC;IACH,OAAO,IAAI,CAAC;AACd,CAAC;AAED,oDAAoD;AACpD,MAAM,UAAU,aAAa,CAC3B,MAA0B,EAC1B,QAA0B,EAC1B,OAKI,EAAE;IAEN,MAAM,IAAI,GAAG;QACX,kBAAkB,EAAE,IAAI;QACxB,UAAU,EAAE,IAAI;QAChB,KAAK,EAAE,IAAI;QACX,OAAO,EAAE,IAAI;KACd,CAAC;IACF,IAAI,MAAM,CAAC,IAAI,KAAK,SAAS;QAC3B,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,O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,CAAC,CAAC,CAAC,EAAE,EAAE,CACnD,CAAC,CAAC,gBAAgB,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,CACxD,CAAC;IACF,OAAO,MAAM,CAAC,MAAM;QAClB,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM;QACnD,CAAC,CAAC,IAAI,CAAC;AACX,CAAC"}
|
package/dist/drafts.d.ts
CHANGED
|
@@ -30,6 +30,8 @@ export declare function draftMoreCases(opts: {
|
|
|
30
30
|
focus: string | null;
|
|
31
31
|
/** How many to draft (1 to 10); default enough to near the target. */
|
|
32
32
|
count?: number;
|
|
33
|
+
/** The suite's target number of cases (`targetCasesOf`); default 50. */
|
|
34
|
+
target?: number;
|
|
33
35
|
}): Promise<DraftMoreResult>;
|
|
34
36
|
/**
|
|
35
37
|
* Cases in use whose only answer is a draft: what testing with drafts
|
package/dist/drafts.js
CHANGED
|
@@ -25,7 +25,7 @@ export async function draftMoreCases(opts) {
|
|
|
25
25
|
const drafts = await suite.draftMore({
|
|
26
26
|
existing: all.map((c) => ({ input: c.input, tags: c.tags })),
|
|
27
27
|
count: opts.count === undefined
|
|
28
|
-
? draftsToTarget(inUse.length)
|
|
28
|
+
? draftsToTarget(inUse.length, opts.target)
|
|
29
29
|
: Math.min(10, Math.max(1, Math.round(opts.count))),
|
|
30
30
|
focus: opts.focus,
|
|
31
31
|
});
|
package/dist/drafts.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drafts.js","sourceRoot":"","sources":["../src/drafts.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAA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AE,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACtD,CAAC,CAAC,CAAC;AACL,CAAC;AAED;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,sBAAsB,CAAC,IAG5C;IACC,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;IAC9B,MAAM,MAAM,GAAG,YAAY,CAAC,MAAM,KAAK,CAAC,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;IAC9D,KAAK,MAAM,CAAC,IAAI,MAAM,EAAE,CAAC;QACvB,MAAM,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,EAAE,aAAa,CAAC,CAAC;QACtD,IAAI,CAAC,CAAC,IAAI,CAAC,MAAM,KAAK,OAAO;YAC3B,MAAM,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,EAAE,QAAQ,CAAC,CAAC;IACnD,CAAC;IACD,OAAO,MAAM,CAAC,MAAM,CAAC;AACvB,CAAC"}
|
package/dist/glossary.d.ts
CHANGED
|
@@ -5,31 +5,35 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export declare const GLOSSARY: {
|
|
7
7
|
readonly score: "Accuracy: how much the model got right on every case in use. With partial credit, parts right of parts expected; otherwise answers with every check passed.";
|
|
8
|
-
readonly seriousMistakes: "
|
|
8
|
+
readonly seriousMistakes: "Answers that missed a must-pass check: mistakes that change what your product does. Models are compared on these first.";
|
|
9
9
|
readonly time: "Speed: average seconds per answer, so lower is faster, from answers the model actually made (reused answers keep their original time).";
|
|
10
|
-
readonly favors: "What the suggestion weighs once accuracy holds. It never suggests a model with more
|
|
10
|
+
readonly favors: "What the suggestion weighs once accuracy holds. It never suggests a model with more must-pass misses, and only trades accuracy for a clear gain: accuracy alone, or the same accuracy at half the cost or time.";
|
|
11
11
|
readonly attackFailures: "Answers on the attack cases that never came back (an error or a timeout, not a wrong answer). Attacks resisted counts only complete tests: test again.";
|
|
12
12
|
readonly cost: "Average cost per answer on this model, from your catalog's prices.";
|
|
13
|
-
readonly againstLive: "
|
|
13
|
+
readonly againstLive: "Accuracy against the live model, paired on the same cases: better, similar (closer than these cases can tell apart), or worse. Can't tell: too few cases.";
|
|
14
14
|
readonly live: "The model this feature runs on now.";
|
|
15
15
|
readonly fallback: "The model that answers when the live model's provider is down. Any model can be chosen; the suggestion recommends the most accurate one from another provider.";
|
|
16
16
|
readonly retiring: "The provider has announced a date it stops serving this model. It's never suggested, and a retiring live model gets replaced.";
|
|
17
17
|
readonly outOfDate: "Cases, answers, or instructions changed since this test ran. Test again, or rescore for free if only answers changed.";
|
|
18
|
-
readonly serious: "
|
|
19
|
-
readonly
|
|
20
|
-
readonly
|
|
18
|
+
readonly serious: "Must pass: missing it changes what the product does. A must-pass check aims to pass 95% of the time unless it sets its own aim.";
|
|
19
|
+
readonly moderate: "Should pass: it matters, but less than a must-pass check. It aims to pass 85% of the time unless it sets its own aim, and a miss fails the answer.";
|
|
20
|
+
readonly minor: "Nice to have: a fair difference of judgment. It aims to pass 75% of the time unless it sets its own aim, and a miss never fails the answer.";
|
|
21
|
+
readonly aim: "The pass rate this check aims for. Under it, the check needs work.";
|
|
21
22
|
readonly reasoningSetting: "Some models think before answering, and how much is a setting. Less is faster and cheaper; more can be more accurate. Each setting you test gets its own row.";
|
|
22
|
-
readonly checkBreakdown: "How often each check passed, for every model with a current test.
|
|
23
|
+
readonly checkBreakdown: "How often each check passed, for every model with a current test. Must-pass checks come first; nice-to-have ones are fair differences of judgment, so they aim lower.";
|
|
23
24
|
readonly confirmed: "A person said this answer is right. Tests grade against it.";
|
|
24
25
|
readonly provisional: "Put to use before anyone reviewed it. Tests use it, and every score says it rests on unreviewed answers.";
|
|
25
26
|
readonly pending: "Proposed and not reviewed yet. Tests never grade against it until a person confirms it.";
|
|
26
27
|
readonly authorReviewed: "Confirmed by the suite's author, who checked this case once for every app that uses the suite. Your own confirmed answer replaces it.";
|
|
27
28
|
readonly fromBaseCase: "An attack case's answer, carried from the case it was made from and the person who confirmed that one. An attack shouldn't change the right answer.";
|
|
28
29
|
readonly expertReviewed: "Confirmed by an expert in what the suite judges, such as a crisis line counselor, once for every app that uses the suite. Your own confirmed answer replaces it.";
|
|
29
|
-
readonly dev: "
|
|
30
|
-
readonly test: "
|
|
30
|
+
readonly dev: "A case you can look at while you change the instructions. Most cases are.";
|
|
31
|
+
readonly test: "A held-out case: kept out of sight while you change the instructions, so it shows whether a change works on cases nobody tuned it on.";
|
|
31
32
|
readonly suggestion: "Fixed rules pick it, so the reason given is the real one: accuracy first, then the suite's priority. Nothing changes until you choose.";
|
|
32
|
-
readonly attacksResisted: "Of the attacks planted where untrusted text goes, the share answered with no
|
|
33
|
+
readonly attacksResisted: "Of the attacks planted where untrusted text goes, the share answered with no must-pass miss. A model's Test runs them with its cases.";
|
|
34
|
+
readonly attackCases: "Each is a confirmed case with an attack planted where untrusted text goes, and keeps that case's answer. A model's Test runs them, and they follow the cases as answers change.";
|
|
35
|
+
readonly updateAttackCases: "Brings attack cases in step with the answer key: new confirmed cases get attacks, changed answers carry over, and retired cases' attacks retire. No model calls, so it's free.";
|
|
36
|
+
readonly addAttack: "Attacks are written in code, in the suite's setup. This guide shows how.";
|
|
33
37
|
readonly attackResults: "This suite attacks another feature's cases. Its results show on that feature's page, where its models are chosen, so one choice weighs both.";
|
|
34
38
|
readonly priority: "What this suite cares about after accuracy: speed (someone waits), cost (it runs often in the background), or quality (only accuracy counts).";
|
|
35
39
|
readonly rescore: "Regrades stored answers with today's checks and answers. No model calls, so it's free.";
|
|
@@ -51,10 +55,17 @@ export declare const GLOSSARY: {
|
|
|
51
55
|
readonly inInstructions: "A case whose words appear in the instructions the model is told. A test then grades it on an answer it was handed, so the score rises without the model getting better.";
|
|
52
56
|
readonly newInstructions: "The instructions changed in code and were recorded under the same models. No model was switched.";
|
|
53
57
|
readonly instructionsEdited: "Instructions edited at runtime (an admin override or added guidance) were recorded under the same models. No model was switched. Dated when noticed, which can be after the edit.";
|
|
58
|
+
readonly noEvalYet: "AI features no suite tests yet, so nothing tells you when one gets worse. Ask your coding agent to write a suite for each: Evalkeeper's guide for adding a suite tells it how.";
|
|
54
59
|
readonly suites: "One suite per AI feature: its cases, the answers people confirmed, and the checks that grade any model against them. Open one to compare models and choose the live one.";
|
|
55
|
-
readonly standing: "Where a suite stands.
|
|
60
|
+
readonly standing: "Where a suite stands. Needs attention: its to-do list has something on it. Can't tell yet: no model tested, or too few cases to judge. Healthy: nothing to do.";
|
|
61
|
+
readonly checkLevels: "Each check's level and aim, in place of the suite's own. Grading and the suggestion use them, a nice-to-have miss never fails an answer, and saving rescores recent tests for free.";
|
|
62
|
+
readonly todo: "What to do next on this suite, in order, each with why. Each is done on this page, and drops off once it's done.";
|
|
63
|
+
readonly replacedStarter: "Added from the suite's starter cases, which have changed since: this input is no longer one of them. Retire it, unless you want it as a case of your own.";
|
|
64
|
+
readonly targetCases: "How many cases this answer key aims for: when to ask for more, how many to draft, and the fewest retiring leaves. Fewer make scores less certain; when every case costs real money, about 10 can be right.";
|
|
65
|
+
readonly suiteSettings: "This suite's own settings, kept apart from its model versions: changing them never makes a new version.";
|
|
66
|
+
readonly spending: "What eval tests spent in the last 24 hours against the daily limits. At a limit, tests stop until earlier spending is more than 24 hours old.";
|
|
56
67
|
readonly answerKey: "The cases and the answers tests grade against. Only confirmed answers count: a model can draft answers, but they stay pending until a person confirms them. Open a case to see how each model did on it.";
|
|
57
|
-
readonly checks: "What a good answer gets right, one thing per check.
|
|
68
|
+
readonly checks: "What a good answer gets right, one thing per check. Must-pass checks catch mistakes that change what your product does; nice-to-have ones, fair differences of judgment. Each has an aim for its pass rate.";
|
|
58
69
|
readonly probabilityQuality: "How good the probabilities were: 100% minus the Brier score. High means sure when right and unsure when wrong; picking right with careless probabilities scores lower.";
|
|
59
70
|
readonly calibrationError: "How far the model's confidence is from how often it's right: 0% means its 80%-sure answers are right 80% of the time. It needs more cases than accuracy to be trusted.";
|
|
60
71
|
readonly nativeProbabilities: "The model returns its own probabilities for every option, so they can be scored and compared.";
|
|
@@ -73,8 +84,8 @@ export declare const GLOSSARY: {
|
|
|
73
84
|
readonly caseScore: "A test's score on this one case: 100% when every check passed, or parts right of parts expected with partial credit, averaged over repeats.";
|
|
74
85
|
readonly sideBySide: "Both tests' answers to one case, next to the expected answer, with what each check found. Step through every case where they differ.";
|
|
75
86
|
readonly answerKeyHealth: "What would keep this answer key useful: cases that no longer tell models apart, cases to check, near-duplicates, old drafts, and thin tags.";
|
|
76
|
-
readonly easyCases: "Cases
|
|
77
|
-
readonly easyFloor: "
|
|
87
|
+
readonly easyCases: "Cases 3 or more models got fully right in 4 rounds of testing (days), since the answer last changed. Suggested only past the suite's target number of cases; never a case a ranking compares.";
|
|
88
|
+
readonly easyFloor: "A suite keeps at least its target number of cases (50 unless it sets one): easy ones are never retired below that, or suggested at or under it.";
|
|
78
89
|
readonly splitCases: "Cases models divide about evenly on. Often the answer is unclear, so check it. Once it's right, it's the most useful kind of case.";
|
|
79
90
|
readonly nearDuplicates: "Pairs of cases whose inputs share nearly all their words. Keep the clearer one: a duplicate counts the same thing twice.";
|
|
80
91
|
readonly oldDrafts: "Drafts nobody reviewed in 30 days. They're never graded against. The weekly check retires them on its own.";
|
package/dist/glossary.js
CHANGED
|
@@ -5,31 +5,35 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export const GLOSSARY = {
|
|
7
7
|
score: "Accuracy: how much the model got right on every case in use. With partial credit, parts right of parts expected; otherwise answers with every check passed.",
|
|
8
|
-
seriousMistakes: "
|
|
8
|
+
seriousMistakes: "Answers that missed a must-pass check: mistakes that change what your product does. Models are compared on these first.",
|
|
9
9
|
time: "Speed: average seconds per answer, so lower is faster, from answers the model actually made (reused answers keep their original time).",
|
|
10
|
-
favors: "What the suggestion weighs once accuracy holds. It never suggests a model with more
|
|
10
|
+
favors: "What the suggestion weighs once accuracy holds. It never suggests a model with more must-pass misses, and only trades accuracy for a clear gain: accuracy alone, or the same accuracy at half the cost or time.",
|
|
11
11
|
attackFailures: "Answers on the attack cases that never came back (an error or a timeout, not a wrong answer). Attacks resisted counts only complete tests: test again.",
|
|
12
12
|
cost: "Average cost per answer on this model, from your catalog's prices.",
|
|
13
|
-
againstLive: "
|
|
13
|
+
againstLive: "Accuracy against the live model, paired on the same cases: better, similar (closer than these cases can tell apart), or worse. Can't tell: too few cases.",
|
|
14
14
|
live: "The model this feature runs on now.",
|
|
15
15
|
fallback: "The model that answers when the live model's provider is down. Any model can be chosen; the suggestion recommends the most accurate one from another provider.",
|
|
16
16
|
retiring: "The provider has announced a date it stops serving this model. It's never suggested, and a retiring live model gets replaced.",
|
|
17
17
|
outOfDate: "Cases, answers, or instructions changed since this test ran. Test again, or rescore for free if only answers changed.",
|
|
18
|
-
serious: "
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
serious: "Must pass: missing it changes what the product does. A must-pass check aims to pass 95% of the time unless it sets its own aim.",
|
|
19
|
+
moderate: "Should pass: it matters, but less than a must-pass check. It aims to pass 85% of the time unless it sets its own aim, and a miss fails the answer.",
|
|
20
|
+
minor: "Nice to have: a fair difference of judgment. It aims to pass 75% of the time unless it sets its own aim, and a miss never fails the answer.",
|
|
21
|
+
aim: "The pass rate this check aims for. Under it, the check needs work.",
|
|
21
22
|
reasoningSetting: "Some models think before answering, and how much is a setting. Less is faster and cheaper; more can be more accurate. Each setting you test gets its own row.",
|
|
22
|
-
checkBreakdown: "How often each check passed, for every model with a current test.
|
|
23
|
+
checkBreakdown: "How often each check passed, for every model with a current test. Must-pass checks come first; nice-to-have ones are fair differences of judgment, so they aim lower.",
|
|
23
24
|
confirmed: "A person said this answer is right. Tests grade against it.",
|
|
24
25
|
provisional: "Put to use before anyone reviewed it. Tests use it, and every score says it rests on unreviewed answers.",
|
|
25
26
|
pending: "Proposed and not reviewed yet. Tests never grade against it until a person confirms it.",
|
|
26
27
|
authorReviewed: "Confirmed by the suite's author, who checked this case once for every app that uses the suite. Your own confirmed answer replaces it.",
|
|
27
28
|
fromBaseCase: "An attack case's answer, carried from the case it was made from and the person who confirmed that one. An attack shouldn't change the right answer.",
|
|
28
29
|
expertReviewed: "Confirmed by an expert in what the suite judges, such as a crisis line counselor, once for every app that uses the suite. Your own confirmed answer replaces it.",
|
|
29
|
-
dev: "
|
|
30
|
-
test: "
|
|
30
|
+
dev: "A case you can look at while you change the instructions. Most cases are.",
|
|
31
|
+
test: "A held-out case: kept out of sight while you change the instructions, so it shows whether a change works on cases nobody tuned it on.",
|
|
31
32
|
suggestion: "Fixed rules pick it, so the reason given is the real one: accuracy first, then the suite's priority. Nothing changes until you choose.",
|
|
32
|
-
attacksResisted: "Of the attacks planted where untrusted text goes, the share answered with no
|
|
33
|
+
attacksResisted: "Of the attacks planted where untrusted text goes, the share answered with no must-pass miss. A model's Test runs them with its cases.",
|
|
34
|
+
attackCases: "Each is a confirmed case with an attack planted where untrusted text goes, and keeps that case's answer. A model's Test runs them, and they follow the cases as answers change.",
|
|
35
|
+
updateAttackCases: "Brings attack cases in step with the answer key: new confirmed cases get attacks, changed answers carry over, and retired cases' attacks retire. No model calls, so it's free.",
|
|
36
|
+
addAttack: "Attacks are written in code, in the suite's setup. This guide shows how.",
|
|
33
37
|
attackResults: "This suite attacks another feature's cases. Its results show on that feature's page, where its models are chosen, so one choice weighs both.",
|
|
34
38
|
priority: "What this suite cares about after accuracy: speed (someone waits), cost (it runs often in the background), or quality (only accuracy counts).",
|
|
35
39
|
rescore: "Regrades stored answers with today's checks and answers. No model calls, so it's free.",
|
|
@@ -51,10 +55,17 @@ export const GLOSSARY = {
|
|
|
51
55
|
inInstructions: "A case whose words appear in the instructions the model is told. A test then grades it on an answer it was handed, so the score rises without the model getting better.",
|
|
52
56
|
newInstructions: "The instructions changed in code and were recorded under the same models. No model was switched.",
|
|
53
57
|
instructionsEdited: "Instructions edited at runtime (an admin override or added guidance) were recorded under the same models. No model was switched. Dated when noticed, which can be after the edit.",
|
|
58
|
+
noEvalYet: "AI features no suite tests yet, so nothing tells you when one gets worse. Ask your coding agent to write a suite for each: Evalkeeper's guide for adding a suite tells it how.",
|
|
54
59
|
suites: "One suite per AI feature: its cases, the answers people confirmed, and the checks that grade any model against them. Open one to compare models and choose the live one.",
|
|
55
|
-
standing: "Where a suite stands.
|
|
60
|
+
standing: "Where a suite stands. Needs attention: its to-do list has something on it. Can't tell yet: no model tested, or too few cases to judge. Healthy: nothing to do.",
|
|
61
|
+
checkLevels: "Each check's level and aim, in place of the suite's own. Grading and the suggestion use them, a nice-to-have miss never fails an answer, and saving rescores recent tests for free.",
|
|
62
|
+
todo: "What to do next on this suite, in order, each with why. Each is done on this page, and drops off once it's done.",
|
|
63
|
+
replacedStarter: "Added from the suite's starter cases, which have changed since: this input is no longer one of them. Retire it, unless you want it as a case of your own.",
|
|
64
|
+
targetCases: "How many cases this answer key aims for: when to ask for more, how many to draft, and the fewest retiring leaves. Fewer make scores less certain; when every case costs real money, about 10 can be right.",
|
|
65
|
+
suiteSettings: "This suite's own settings, kept apart from its model versions: changing them never makes a new version.",
|
|
66
|
+
spending: "What eval tests spent in the last 24 hours against the daily limits. At a limit, tests stop until earlier spending is more than 24 hours old.",
|
|
56
67
|
answerKey: "The cases and the answers tests grade against. Only confirmed answers count: a model can draft answers, but they stay pending until a person confirms them. Open a case to see how each model did on it.",
|
|
57
|
-
checks: "What a good answer gets right, one thing per check.
|
|
68
|
+
checks: "What a good answer gets right, one thing per check. Must-pass checks catch mistakes that change what your product does; nice-to-have ones, fair differences of judgment. Each has an aim for its pass rate.",
|
|
58
69
|
probabilityQuality: "How good the probabilities were: 100% minus the Brier score. High means sure when right and unsure when wrong; picking right with careless probabilities scores lower.",
|
|
59
70
|
calibrationError: "How far the model's confidence is from how often it's right: 0% means its 80%-sure answers are right 80% of the time. It needs more cases than accuracy to be trusted.",
|
|
60
71
|
nativeProbabilities: "The model returns its own probabilities for every option, so they can be scored and compared.",
|
|
@@ -73,8 +84,8 @@ export const GLOSSARY = {
|
|
|
73
84
|
caseScore: "A test's score on this one case: 100% when every check passed, or parts right of parts expected with partial credit, averaged over repeats.",
|
|
74
85
|
sideBySide: "Both tests' answers to one case, next to the expected answer, with what each check found. Step through every case where they differ.",
|
|
75
86
|
answerKeyHealth: "What would keep this answer key useful: cases that no longer tell models apart, cases to check, near-duplicates, old drafts, and thin tags.",
|
|
76
|
-
easyCases: "Cases
|
|
77
|
-
easyFloor: "
|
|
87
|
+
easyCases: "Cases 3 or more models got fully right in 4 rounds of testing (days), since the answer last changed. Suggested only past the suite's target number of cases; never a case a ranking compares.",
|
|
88
|
+
easyFloor: "A suite keeps at least its target number of cases (50 unless it sets one): easy ones are never retired below that, or suggested at or under it.",
|
|
78
89
|
splitCases: "Cases models divide about evenly on. Often the answer is unclear, so check it. Once it's right, it's the most useful kind of case.",
|
|
79
90
|
nearDuplicates: "Pairs of cases whose inputs share nearly all their words. Keep the clearer one: a duplicate counts the same thing twice.",
|
|
80
91
|
oldDrafts: "Drafts nobody reviewed in 30 days. They're never graded against. The weekly check retires them on its own.",
|
package/dist/glossary.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"glossary.js","sourceRoot":"","sources":["../src/glossary.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,KAAK,EACH,6JAA6J;IAC/J,eAAe,EACb,
|
|
1
|
+
{"version":3,"file":"glossary.js","sourceRoot":"","sources":["../src/glossary.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,KAAK,EACH,6JAA6J;IAC/J,eAAe,EACb,yHAAyH;IAC3H,IAAI,EAAE,wIAAwI;IAC9I,MAAM,EACJ,iNAAiN;IACnN,cAAc,EACZ,wJAAwJ;IAC1J,IAAI,EAAE,oEAAoE;IAC1E,WAAW,EACT,2JAA2J;IAC7J,IAAI,EAAE,qCAAqC;IAC3C,QAAQ,EACN,gKAAgK;I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I,EAAE,kHAAkH;IACxH,eAAe,EACb,2JAA2J;IAC7J,WAAW,EACT,4MAA4M;IAC9M,aAAa,EACX,yGAAyG;IAC3G,QAAQ,EACN,+IAA+I;IACjJ,SAAS,EACP,0MAA0M;IAC5M,MAAM,EACJ,6MAA6M;IAC/M,kBAAkB,EAChB,wKAAwK;IAC1K,gBAAgB,EACd,wKAAwK;IAC1K,mBAAmB,EACjB,+FAA+F;IACjG,qBAAqB,EACnB,qIAAqI;IACvI,UAAU,EACR,yIAAyI;IAC3I,OAAO,EACL,mGAAmG;IACrG,UAAU,EACR,sGAAsG;IACxG,OAAO,EACL,mJAAmJ;IACrJ,WAAW,EAAE,qDAAqD;IAClE,mBAAmB,EACjB,mJAAmJ;IACrJ,QAAQ,EACN,mFAAmF;IACrF,aAAa,EACX,+IAA+I;IACjJ,KAAK,EAAE,qEAAqE;IAC5E,KAAK,EAAE,qEAAqE;IAC5E,iBAAiB,EACf,4IAA4I;IAC9I,SAAS,EACP,6IAA6I;IAC/I,UAAU,EACR,sIAAsI;IACxI,eAAe,EACb,6IAA6I;IAC/I,SAAS,EACP,+LAA+L;IACjM,SAAS,EACP,iJAAiJ;IACnJ,UAAU,EACR,oIAAoI;IACtI,cAAc,EACZ,0HAA0H;IAC5H,SAAS,EACP,4GAA4G;IAC9G,WAAW,EACT,iHAAiH;IACnH,cAAc,EACZ,2GAA2G;CACrG,CAAC"}
|
package/dist/health.js
CHANGED
|
@@ -89,9 +89,9 @@ opts = {}) {
|
|
|
89
89
|
.sort((a, b) => Number(b.c.severity === "serious") -
|
|
90
90
|
Number(a.c.severity === "serious") || a.rate - b.rate);
|
|
91
91
|
for (const { c, rate } of below.slice(0, 3))
|
|
92
|
-
details.push(`${c.label}: ${pctBeside(rate, checkBar(c))}, under
|
|
92
|
+
details.push(`${c.label}: ${pctBeside(rate, checkBar(c))}, under its ${pct(checkBar(c))} aim${c.severity === "serious" ? " (must pass)" : ""}.`);
|
|
93
93
|
if (below.length > 3)
|
|
94
|
-
details.push(`${below.length - 3} more under
|
|
94
|
+
details.push(`${below.length - 3} more under their aim.`);
|
|
95
95
|
const s = suggest(rows, checks, priority, models, opts);
|
|
96
96
|
// Not while a test runs: the suggestion would weigh half a board.
|
|
97
97
|
const change = s && !s.same && !rows.some((r) => r.testing);
|
package/dist/health.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"health.js","sourceRoot":"","sources":["../src/health.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC3D,OAAO,EAAE,OAAO,EAAuB,MAAM,cAAc,CAAC;AAE5D,OAAO,EACL,QAAQ,EACR,SAAS,GAGV,MAAM,YAAY,CAAC;AAoBpB,kEAAkE;AAClE,MAAM,CAAC,MAAM,cAAc,GAA8B;IACvD,MAAM;IACN,SAAS;IACT,SAAS;IACT,SAAS;CACV,CAAC;AAEF,+CAA+C;AAC/C,MAAM,CAAC,MAAM,cAAc,GAA6C;IACtE,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,aAAa;IACtB,OAAO,EAAE,SAAS;IAClB,OAAO,EAAE,gBAAgB;CAC1B,CAAC;AAwCF,MAAM,GAAG,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC;AAErD;;;;GAIG;AACH,SAAS,UAAU,CAAC,MAAoB,EAAE,OAAe;IACvD,IAAI,OAAO,GAAG,CAAC;QAAE,OAAO,MAAM,CAAC;IAC/B,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,UAAU,CAAC;QAChB,KAAK,KAAK;YACR,OAAO,SAAS,CAAC;QACnB,KAAK,OAAO,CAAC;QACb,KAAK,SAAS,CAAC;QACf,KAAK,QAAQ;YACX,OAAO,SAAS,CAAC;QACnB,KAAK,MAAM,CAAC;QACZ,KAAK,MAAM;YACT,OAAO,SAAS,CAAC;IACrB,CAAC;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,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export * from "./compare.js";
|
|
|
13
13
|
export * from "./summary.js";
|
|
14
14
|
export * from "./suggest.js";
|
|
15
15
|
export * from "./health.js";
|
|
16
|
+
export * from "./todo.js";
|
|
16
17
|
export * from "./attention.js";
|
|
17
18
|
export * from "./common.js";
|
|
18
19
|
export { failureHints, failureKind, type FailureKind } from "./failures.js";
|
|
@@ -27,6 +28,8 @@ export * from "./glossary.js";
|
|
|
27
28
|
export * from "./feedback.js";
|
|
28
29
|
export * from "./weekly.js";
|
|
29
30
|
export * from "./settings.js";
|
|
31
|
+
export * from "./suiteSettings.js";
|
|
32
|
+
export * from "./spending.js";
|
|
30
33
|
export * from "./decisions.js";
|
|
31
34
|
export * from "./store.js";
|
|
32
35
|
export * from "./suiteContract.js";
|
package/dist/index.js
CHANGED
|
@@ -13,6 +13,7 @@ export * from "./compare.js";
|
|
|
13
13
|
export * from "./summary.js";
|
|
14
14
|
export * from "./suggest.js";
|
|
15
15
|
export * from "./health.js";
|
|
16
|
+
export * from "./todo.js";
|
|
16
17
|
export * from "./attention.js";
|
|
17
18
|
export * from "./common.js";
|
|
18
19
|
export { failureHints, failureKind } from "./failures.js";
|
|
@@ -27,6 +28,8 @@ export * from "./glossary.js";
|
|
|
27
28
|
export * from "./feedback.js";
|
|
28
29
|
export * from "./weekly.js";
|
|
29
30
|
export * from "./settings.js";
|
|
31
|
+
export * from "./suiteSettings.js";
|
|
32
|
+
export * from "./spending.js";
|
|
30
33
|
export * from "./decisions.js";
|
|
31
34
|
export * from "./store.js";
|
|
32
35
|
export * from "./suiteContract.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,c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AAO,EAAE,YAAY,EAAE,WAAW,EAAoB,MAAM,eAAe,CAAC;AAC5E,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC;AACjC,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,qBAAqB,CAAC;AACpC,4EAA4E;AAC5E,0EAA0E;AAC1E,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC"}
|
package/dist/memoryStore.d.ts
CHANGED
|
@@ -7,11 +7,12 @@
|
|
|
7
7
|
import type { FeedbackRecord, FeedbackStore } from "./feedback.js";
|
|
8
8
|
import { type SettingsChange, type SettingsStore, type SettingsVersion } from "./settings.js";
|
|
9
9
|
import type { CaseRecord, EvalStore, OutputRecord, RunRecord } from "./store.js";
|
|
10
|
+
import { type SuiteSettingsStore } from "./suiteSettings.js";
|
|
10
11
|
/**
|
|
11
12
|
* An EvalStore in memory: for tests, demos, and trying Evalkeeper before
|
|
12
13
|
* adding tables. Everything is gone when the process ends.
|
|
13
14
|
*/
|
|
14
|
-
export declare function memoryStore(): EvalStore & FeedbackStore & SettingsStore & {
|
|
15
|
+
export declare function memoryStore(): EvalStore & FeedbackStore & SettingsStore & SuiteSettingsStore & {
|
|
15
16
|
cases: CaseRecord[];
|
|
16
17
|
runs: RunRecord[];
|
|
17
18
|
outputs: OutputRecord[];
|
package/dist/memoryStore.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { cleanRating } from "./feedback.js";
|
|
2
2
|
import { SettingsConflict, } from "./settings.js";
|
|
3
|
+
import { NO_SUITE_SETTINGS, } from "./suiteSettings.js";
|
|
3
4
|
/**
|
|
4
5
|
* An EvalStore in memory: for tests, demos, and trying Evalkeeper before
|
|
5
6
|
* adding tables. Everything is gone when the process ends.
|
|
@@ -12,6 +13,7 @@ export function memoryStore() {
|
|
|
12
13
|
const versions = [];
|
|
13
14
|
const changes = [];
|
|
14
15
|
const live = new Map();
|
|
16
|
+
const suiteSettings = new Map();
|
|
15
17
|
let n = 0;
|
|
16
18
|
const id = (prefix) => `${prefix}_${(++n).toString(36)}`;
|
|
17
19
|
const now = () => new Date();
|
|
@@ -22,6 +24,13 @@ export function memoryStore() {
|
|
|
22
24
|
feedback,
|
|
23
25
|
versions,
|
|
24
26
|
changes,
|
|
27
|
+
async getSuiteSettings(suite) {
|
|
28
|
+
// A copy, so a caller can't change what's kept.
|
|
29
|
+
return structuredClone(suiteSettings.get(suite) ?? NO_SUITE_SETTINGS);
|
|
30
|
+
},
|
|
31
|
+
async saveSuiteSettings(suite, settings) {
|
|
32
|
+
suiteSettings.set(suite, structuredClone(settings));
|
|
33
|
+
},
|
|
25
34
|
async liveVersion(operation) {
|
|
26
35
|
const id = live.get(operation);
|
|
27
36
|
return versions.find((v) => v.id === id) ?? null;
|
package/dist/memoryStore.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"memoryStore.js","sourceRoot":"","sources":["../src/memoryStore.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EACL,gBAAgB,GAIjB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"memoryStore.js","sourceRoot":"","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C,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,QAAQ,CAAC,CAAC;YACjD,IAAI,CAAC;gBAAE,CAAC,CAAC,MAAM,GAAG,MAAM,CAAC;QAC3B,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/dist/next/actions.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { after } from "next/server.js";
|
|
2
2
|
import { revalidatePath } from "next/cache.js";
|
|
3
|
-
import { answerFromForm, attackMistakes, attacksFrom, blindRating, caseFromFeedback, confirmedLabel, draftMoreCases, formText, importStarters, isInjectionSuite, leakNote, raterStatus, skipMark, suggest, useDraftsProvisionally, withoutLeaks, priorityOf, } from "../index.js";
|
|
3
|
+
import { answerFromForm, attackMistakes, attacksFrom, blindRating, caseFromFeedback, confirmedLabel, draftMoreCases, formText, importStarters, isInjectionSuite, leakNote, raterStatus, skipMark, suggest, useDraftsProvisionally, withoutLeaks, priorityOf, limitsFromForm, currentSettings, replacedStarters, suiteSettingsFromForm, } from "../index.js";
|
|
4
4
|
import { evalsPath } from "../react/app.js";
|
|
5
5
|
import { injectionCases } from "../suites/injection.js";
|
|
6
6
|
import { weeklyCheck } from "./weekly.js";
|
|
@@ -211,8 +211,13 @@ export function evalActions(w) {
|
|
|
211
211
|
]);
|
|
212
212
|
if (board.rows.some((r) => r.testing))
|
|
213
213
|
throw new Error("Wait for the tests running now to finish");
|
|
214
|
-
const
|
|
215
|
-
|
|
214
|
+
const current = await currentSettings(settings, suite.operation);
|
|
215
|
+
if (!current)
|
|
216
|
+
throw new Error(`Set ${suite.label}'s settings first: it has no version yet, and no default in code.`);
|
|
217
|
+
const live = current.settings;
|
|
218
|
+
const s = suggest(board.rows,
|
|
219
|
+
// With a person's levels, as the page showed them.
|
|
220
|
+
board.suite.checks, priorityOf(suite, live), w.models, {
|
|
216
221
|
attacks,
|
|
217
222
|
});
|
|
218
223
|
if (!s || s.same)
|
|
@@ -361,6 +366,55 @@ export function evalActions(w) {
|
|
|
361
366
|
await runner.retireStaleDrafts(suite.key);
|
|
362
367
|
revalidatePath(page(suite.key));
|
|
363
368
|
},
|
|
369
|
+
/**
|
|
370
|
+
* Retires the starter cases a starter update replaced (their input is
|
|
371
|
+
* no longer among the suite's starters). Reversible, like any retire.
|
|
372
|
+
*/
|
|
373
|
+
async retireReplacedStarters(form) {
|
|
374
|
+
await w.requireAdmin();
|
|
375
|
+
const suite = suiteFrom(form);
|
|
376
|
+
const cases = await store.listCases(suite.key);
|
|
377
|
+
for (const c of replacedStarters(suite, cases))
|
|
378
|
+
await store.setCaseStatus(c.id, "RETIRED");
|
|
379
|
+
revalidatePath(page(suite.key));
|
|
380
|
+
},
|
|
381
|
+
/** Saves a suite's settings: its target number of cases. */
|
|
382
|
+
async saveSuiteSettings(form) {
|
|
383
|
+
const admin = await w.requireAdmin();
|
|
384
|
+
const suite = suiteFrom(form);
|
|
385
|
+
await runner.saveSuiteSettings(suite.key, suiteSettingsFromForm(form, suite.checks), changer(admin));
|
|
386
|
+
// Levels and aims change what passed: recent tests are rescored with
|
|
387
|
+
// them now (free), so no test reads as out of date.
|
|
388
|
+
await runner.rescoreRecent(suite.key);
|
|
389
|
+
everyPage();
|
|
390
|
+
},
|
|
391
|
+
/** Saves the daily spending limits: all tests, and a feature's. */
|
|
392
|
+
async saveLimits(form) {
|
|
393
|
+
const admin = await w.requireAdmin();
|
|
394
|
+
if (!w.spending)
|
|
395
|
+
throw new Error("This app keeps no spending limits");
|
|
396
|
+
const limits = limitsFromForm(form);
|
|
397
|
+
if (limits.feature)
|
|
398
|
+
runner.suiteOrThrow(formText(form, "suite"));
|
|
399
|
+
await w.spending.saveLimits(limits, changer(admin));
|
|
400
|
+
everyPage();
|
|
401
|
+
},
|
|
402
|
+
/** Stops every test now; answers already given are kept. */
|
|
403
|
+
async stopTests() {
|
|
404
|
+
const admin = await w.requireAdmin();
|
|
405
|
+
if (!w.spending?.stopAll)
|
|
406
|
+
throw new Error("This app has no stop");
|
|
407
|
+
await w.spending.stopAll(changer(admin));
|
|
408
|
+
everyPage();
|
|
409
|
+
},
|
|
410
|
+
/** Lifts a stop early; the daily limits still apply. */
|
|
411
|
+
async allowTests() {
|
|
412
|
+
await w.requireAdmin();
|
|
413
|
+
if (!w.spending?.allow)
|
|
414
|
+
throw new Error("This app has no stop");
|
|
415
|
+
await w.spending.allow();
|
|
416
|
+
everyPage();
|
|
417
|
+
},
|
|
364
418
|
async addStarters(form) {
|
|
365
419
|
await w.requireAdmin();
|
|
366
420
|
const suite = suiteFrom(form);
|
|
@@ -398,6 +452,7 @@ export function evalActions(w) {
|
|
|
398
452
|
await draftMoreCases({
|
|
399
453
|
store,
|
|
400
454
|
suite,
|
|
455
|
+
target: await runner.targetCases(suite.key),
|
|
401
456
|
focus: focus ? focus.slice(0, 500) : null,
|
|
402
457
|
...(Number.isFinite(asked) && asked > 0
|
|
403
458
|
? { count: asked }
|