Use when asked to write or create an ai_eval test under test/ai_evals/ for an evaluation use case in test/ai_evals/eval_data/evals/. Works across all DevTools domains (performance, network, elements, sources, console, accessibility, storage). To minimize latency, in your FIRST turn call view_file in parallel on SKILL.md, task.textproto + agent_prompt.md for <eval-id>, and test/ai_evals/BUILD.gn (plus test/ai_evals/<domain>/BUILD.gn if <domain> is known).
86%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Passed
No findings from the security scan
test/ai_evals/)[!CAUTION]
- CRITICAL RULE — SINGLE V2 TEST ONLY: Always write only one V2 evaluation test per eval (
enabledFeatures: ['DevToolsAiV2Architecture']) using the canonical template below. NEVER create V1 tests or V1+V2 pairs.- CRITICAL RULE — NEVER SET OR PASS CONTEXT: NEVER call
findAndSetContext(or any panel/UI context-selection helper) and NEVER passcontexttoevalTask.executePrompt(...), even wheninitial_contextis present intask.textproto.- CRITICAL RULE — MINIMAL FILE READS & NO UNREQUESTED COMMANDS:
- Only read
task.textproto,agent_prompt.md, andBUILD.gnfiles. Do NOT readai_eval-helpers.ts,ai-eval-state-provider.ts,base-apps/,front_end/, or legacy tests that usefindAndSetContext.- Do NOT run
git,autoninja,./dt lint, or./dt testunless the user explicitly asks to build or run the test.
BUILD.gn in One Parallel TurnCall view_file in parallel on:
task.textproto and agent_prompt.md for <eval-id>:
test/ai_evals/eval_data/evals/<eval-id>/ (evalFolder = '') or nested path test/ai_evals/eval_data/evals/<eval-folder>/<eval-id>/ (evalFolder = '<eval-folder>', e.g. 'network').agent_prompt.md: extract the trimmed prompt string <agent_prompt>.task.textproto: infer <domain> in priority order:
<eval-folder> subfolder name.tags: "performance", "network", "elements", "sources", "console", "accessibility", "storage" (ignore generic tags like "cd4h" or "bugfix", and prefer panel domain tags over sub-topic tags like "cls").initial_context.panel fallback (for folder naming only — never set context in code):
NETWORK_REQUEST $\rightarrow$ networkPERFORMANCE $\rightarrow$ performanceDOM_NODE / ELEMENTS $\rightarrow$ elementsSOURCE_FILE / SOURCES $\rightarrow$ sourcesCONSOLE $\rightarrow$ consoleACCESSIBILITY $\rightarrow$ accessibilitySTORAGE / APPLICATION $\rightarrow$ storagesetupAndRunEvalApp parses base_app and initial_url from task.textproto automatically at runtime—do not hardcode them.test/ai_evals/BUILD.gn (and test/ai_evals/<domain>/BUILD.gn if <domain> is already known).BUILD.gn in One Parallel TurnIn a single parallel tool-call turn:
test/ai_evals/<domain>/<eval-id>.test.ts (write_to_file) using this exact domain-agnostic V2 template (<Domain> is capitalized <domain>, e.g. Performance, Network, Elements, Sources, Console, Accessibility, Storage):// Copyright 2026 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import {assert} from 'chai';
import {
setupAndRunEvalApp,
stopEvalApp,
} from '../helpers/ai_eval-helpers.js';
import {describe, it, setup} from '../mocha-interface.js';
describe('<Domain> AI Eval: <eval-id>', function() {
this.timeout(180_000);
setup({
dockingMode: 'undocked',
enabledFeatures: ['DevToolsAiV2Architecture'],
devToolsSettings: {
'ai-assistance-enabled': true,
'ai-assistance-v2-opt-in-change-dialog-seen': true,
},
evalConfig: {
type: '<domain>',
label: '<eval-id>',
taskId: '<eval-id>',
},
});
it('launches app, navigates to initial URL, and executes prompt', async ({inspectedPage, evalTask}) => {
const app = await setupAndRunEvalApp('<evalFolder>', '<eval-id>');
try {
assert.isDefined(app.config.initialUrl, 'Expected initial_url to be defined in task.textproto');
await inspectedPage.page.goto(app.config.initialUrl, {waitUntil: 'networkidle0'});
await evalTask.executePrompt({
prompts: ['<agent_prompt>'],
});
} finally {
await stopEvalApp(app);
}
});
});BUILD.gn:
test/ai_evals/<domain>/BUILD.gn exists: Add "<eval-id>.test.ts" in alphabetical order to sources (replace_file_content).<domain> is a new domain folder: Create test/ai_evals/<domain>/BUILD.gn (write_to_file) and add "<domain>" to deps in both group("ai_evals") and generated_file("test_inputs") in test/ai_evals/BUILD.gn (replace_file_content):
# Copyright 2026 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("../../../scripts/build/typescript/typescript.gni")
node_ts_library("<domain>") {
sources = [ "<eval-id>.test.ts" ]
ts_deps = [
"..:harness_library",
"../../e2e/helpers",
"../helpers",
]
}ChromeDevTools/devtools-frontend
82e99f9
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.