Unverified Commit dc9bfeaa authored by Aurora Scharff's avatar Aurora Scharff Committed by GitHub

Update evals for stabilized navigation APIs (#100145)

## Summary

- require the stable `navigation()` API in the Partial Prefetching
optimizer eval instead of accepting `unstable_navigation()`
- keep the skill-only static-shell optimizer eval out of published
results
- run the empty-static-params fixture as a normal baseline/docs eval
instead of attaching an unrelated skill

The other published `prefetch()` and `navigation()` graders were already
updated when those APIs stabilized in #99241.

## Verification

- `pnpm prettier --with-node-modules --ignore-path .prettierignore
--write evals/eval.config.json
evals/evals/agent-051-optimize-partial-prefetching/EVAL.ts`
- `npx eslint --config eslint.config.mjs --fix
evals/evals/agent-051-optimize-partial-prefetching/EVAL.ts`
- Not run: full eval execution (metadata and static grader-only changes)

<!-- NEXT_JS_LLM -->
parent ec59230d
...@@ -16,10 +16,10 @@ ...@@ -16,10 +16,10 @@
}, },
"agent-050-optimize-static-shell": { "agent-050-optimize-static-shell": {
"skills": ["next-cache-components-optimizer"], "skills": ["next-cache-components-optimizer"],
"publish": false,
"timeout": 7200 "timeout": 7200
}, },
"agent-054-cache-components-empty-static-params": { "agent-054-cache-components-empty-static-params": {
"skills": ["next-cache-components-adoption"],
"timeout": 1800 "timeout": 1800
}, },
"agent-055-stale-build-error": { "agent-055-stale-build-error": {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* Optimize one Partial Prefetching navigation * Optimize one Partial Prefetching navigation
* *
* The fixture starts after Cache Components and Partial Prefetching adoption. * The fixture starts after Cache Components and Partial Prefetching adoption.
* The agent must turn one accepted, URL-specific product goal into an * The agent must turn one accepted, URL-specific session goal into an
* instant() RED-to-GREEN loop without expanding the cost to every card. * instant() RED-to-GREEN loop without expanding the cost to every card.
*/ */
...@@ -52,7 +52,13 @@ test('adds reusable cached work', () => { ...@@ -52,7 +52,13 @@ test('adds reusable cached work', () => {
}) })
test('uses the navigation stage', () => { test('uses the navigation stage', () => {
expect(source).toMatch(/\b(?:unstable_)?navigation\s*\(/) const navigationImport = source.match(
/import\s*\{[^}]*\bnavigation\b(?:\s+as\s+([A-Za-z_$][\w$]*))?[^}]*\}\s*from\s*['"]next\/cache['"]/
)
expect(navigationImport).not.toBeNull()
const localName = navigationImport?.[1] ?? 'navigation'
expect(source).toMatch(new RegExp(`await\\s+${localName}\\s*\\(`))
}) })
test('optimizes only the selected featured navigation', async () => { test('optimizes only the selected featured navigation', async () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment