Skip to content

Commit bb058b7

Browse files
Lusa Zhandevtools-frontend-scoped@luci-project-accounts.iam.gserviceaccount.com
authored andcommitted
[Lighthouse] Add agentic browsing category
The category checkbox is disabled by default. The custom agentic browsing config is included in front_end/panels/lighthouse/LighthouseProtocolService.ts for now, but will be removed once the agentic browsing category is in the default config. Bug: 501056067 Change-Id: I199a87fd59cf6cdaaacd5205259aa29d4b6ff99b Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/7806870 Reviewed-by: Paul Irish <paulirish@chromium.org> Commit-Queue: Lusa Zhan <lusazhan@chromium.org>
1 parent e3bc3c3 commit bb058b7

5 files changed

Lines changed: 22 additions & 2 deletions

File tree

front_end/core/host/UserMetrics.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1146,7 +1146,8 @@ export const enum LighthouseCategoryUsed {
11461146
SEO = 3,
11471147
PWA = 4,
11481148
PUB_ADS = 5,
1149-
MAX_VALUE = 6,
1149+
AGENTIC_BROWSING = 6,
1150+
MAX_VALUE = 7,
11501151
}
11511152

11521153
export const enum SwatchType {

front_end/models/lighthouse/RunTypes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type * as Common from '../../core/common/common.js';
55
import type * as Host from '../../core/host/host.js';
66
import type * as Platform from '../../core/platform/platform.js';
77

8-
export type CategoryId = 'performance'|'accessibility'|'best-practices'|'seo';
8+
export type CategoryId = 'performance'|'accessibility'|'best-practices'|'seo'|'agentic-browsing';
99
export type RunMode = 'navigation'|'timespan'|'snapshot';
1010

1111
export interface Preset {

front_end/panels/lighthouse/LighthouseController.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,15 @@ const UIStrings = {
8484
* @description Tooltip text of checkbox to include running the Search Engine Optimization audits in Lighthouse
8585
*/
8686
isThisPageOptimizedForSearch: 'Is this page optimized for search engine results ranking',
87+
/**
88+
* @description Text of checkbox to include running the Agentic Browsing audits in Lighthouse
89+
*/
90+
agenticBrowsing: 'Agentic browsing',
91+
/**
92+
* @description Tooltip text of checkbox to include running the Agentic Browsing audits in Lighthouse
93+
*/
94+
agenticBrowsingDescription:
95+
'These checks ensure high-quality, browsable websites for AI agents and validate the correctness of WebMCP integrations. This category is still under development and subject to change.',
8796
/**
8897
* @description ARIA label for a radio button input to emulate mobile device behavior when running audits in Lighthouse.
8998
*/
@@ -749,6 +758,15 @@ export function getPresets(): LighthouseModel.RunTypes.Preset[] {
749758
supportedModes: ['navigation', 'snapshot'],
750759
userMetric: Host.UserMetrics.LighthouseCategoryUsed.SEO,
751760
},
761+
{
762+
setting: Common.Settings.Settings.instance().createSetting(
763+
'lighthouse.cat-agentic-browsing', false, Common.Settings.SettingStorageType.SYNCED),
764+
configID: 'agentic-browsing',
765+
title: i18nLazyString(UIStrings.agenticBrowsing),
766+
description: i18nLazyString(UIStrings.agenticBrowsingDescription),
767+
supportedModes: ['navigation', 'snapshot'],
768+
userMetric: Host.UserMetrics.LighthouseCategoryUsed.AGENTIC_BROWSING,
769+
},
752770
];
753771
}
754772
return presets;

front_end/ui/visual_logging/KnownContextValues.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2504,6 +2504,7 @@ export const knownContextValues = new Set([
25042504
'lighthouse.audit.work-during-interaction',
25052505
'lighthouse.cancel',
25062506
'lighthouse.cat-a11y',
2507+
'lighthouse.cat-agentic-browsing',
25072508
'lighthouse.cat-best-practices',
25082509
'lighthouse.cat-perf',
25092510
'lighthouse.cat-seo',
2.15 KB
Loading

0 commit comments

Comments
 (0)