Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

fix: stop goal-fidelity reviewer treating unpublished model benchmarks as missing work

[._.]/ Adam Eivy854406244806
diff --git a/server/services/codeReview.js b/server/services/codeReview.js
index 343c787624..9d0161f040 100644
--- a/server/services/codeReview.js
+++ b/server/services/codeReview.js
@@ -684,6 +684,8 @@ Judge the production behavior before treating a regression test as the behavior
For an objective that asks to move or reorder an existing UI section, a diff may show the move as a complete added block and a complete deleted block. When the same complete named section, with materially unchanged contents, is added at the requested position and its former placement is removed, judge the pair as one relocation that satisfies the requested order. Do not call the insertion an unrequested addition or the removal a missing section. This rule applies only when the diff establishes that matched move: an added duplicate whose old copy remains, a different section, or independent content changes must still be judged on their own; matching headings alone do not prove a relocation.
+For an objective to add a newly launched AI model to the provider catalog, presets, pricing, or model-comparison seed, judge the sourced facts the diff supplies: the model id in the provider/preset lists, its published prices, and a migration for existing installs when the diff changes shipped provider data. A model-comparison row whose quality, latency, or throughput fields are null (or whose benchmark scores are absent) is NOT missing work when the diff or commit states the vendor has not published those figures; recording an unpublished benchmark would be fabrication. Count a null benchmark as missing only when the objective explicitly asks for benchmarks and the diff offers no statement that none are published. This exempts only unpublished benchmark metrics for a new model; a missing model id, price, preset entry, or required migration remains missing.
+
For an objective about clearing a federated peer's displayed schema-mismatch warning, a diff that makes the unchanged-checksum shortcut conditional on an already saved peer/category schema gap is a production retry, not a check-only change. The saved gap sends that category through the existing snapshot apply path again, where the receiver checks the newly fetched envelope's \`portosMeta.schemaVersions\`; a successful apply clears the saved warning for that peer/category. \`portosMeta.portosVersion\` is only the friendly label captured for display, while \`schemaVersions\` controls compatibility, so an older displayed label does not make this retry ineffective. Count the bypass as requested behavior only when the diff scopes it to an existing peer/category gap and preserves the ordinary unchanged-checksum return otherwise. An unconditional retry, a display-label-only edit, or a generic checksum change does not receive this interpretation and must be judged against the objective as usual.
For an objective to align a default process manifest with production startup and remove a retired process from the UI's expected-process list, judge manifest membership at the registry boundary, even without a literal UI assertion or a changed UI file. Apply this only to paired production removal plus fresh/legacy registry evidence:
diff --git a/server/services/codeReview.test.js b/server/services/codeReview.test.js
index efc055eb13..e6418ae605 100644
--- a/server/services/codeReview.test.js
+++ b/server/services/codeReview.test.js
@@ -1094,6 +1094,41 @@ describe('codeReview helpers', () => {
expect(request.messages[0].content).toContain('test-only change')
})
+ it('ships a new-model addition whose unpublished benchmark fields are null, but not one missing its pricing', async () => {
+ const objective = 'Example Model 1 has just launched; add it to our provider presets, pricing, and model comparison.'
+ const diff = [
+ 'diff --git a/data.reference/model-comparison.json b/data.reference/model-comparison.json',
+ '+ "id": "example-model-1-pricing-standard",',
+ '+ "inputPricePerMTok": 0.1,',
+ '+ "outputPricePerMTok": 0.5,',
+ '+ "quality": null,',
+ '+ "latencyMs": null,',
+ '+ "throughputTps": null,',
+ '+ "notes": "No benchmark scores are published yet, so none are recorded."',
+ ].join('\n')
+ const noPricingDiff = diff.replace(/^\+ "(input|output)PricePerMTok".*\n/gm, '')
+
+ global.fetch = vi.fn(async (_url, init) => {
+ const request = JSON.parse(init.body)
+ const rubric = request.messages[0].content
+ const evidence = request.messages[1].content
+ const recognizes = rubric.includes('is NOT missing work when the diff or commit states the vendor has not published those figures')
+ && rubric.includes('a missing model id, price, preset entry, or required migration remains missing')
+ const hasPricing = evidence.includes('inputPricePerMTok')
+ return mockJsonResponse({
+ choices: [{ message: { content: JSON.stringify(recognizes && hasPricing
+ ? { verdict: 'ship', missing: [], unrequested: [], evidence: 'pricing is sourced and unpublished benchmarks are correctly left null' }
+ : { verdict: 'fix-first', missing: ['published pricing'], unrequested: [], evidence: 'pricing absent' }) } }],
+ })
+ })
+
+ const withPricing = await runLocalGoalFidelityReview({ backend: 'ollama', model: 'example-model', objective, diff })
+ const withoutPricing = await runLocalGoalFidelityReview({ backend: 'ollama', model: 'example-model', objective, diff: noPricingDiff })
+
+ expect(withPricing).toMatchObject({ ok: true, verdict: 'ship', missing: [], unrequested: [] })
+ expect(withoutPricing).toMatchObject({ ok: true, verdict: 'fix-first', missing: ['published pricing'] })
+ })
+
it('ships a same-checksum retry scoped to a saved federated schema gap, not an unconditional retry', async () => {
const objective = 'On our federated instances page, I see a schema version mismatch.'
const scopedRetryDiff = [