Skip to content

Commit 1638fa2

Browse files
Capabilities 2025 queries (#4243)
* Generative AI 2025 queries Fugu queries from 2022, that now include the Built-in AI APIs and WebGPU. * Update sql/2025/generative-ai/fugu.sql * Move Fugu SQL to Capabilities --------- Co-authored-by: Barry Pollard <barrypollard@google.com>
1 parent 9b53be8 commit 1638fa2

4 files changed

Lines changed: 77 additions & 1 deletion

File tree

sql/2025/capabilities/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# 2025 Capabilities queries
2+
3+
<!--
4+
This directory contains all of the 2025 Capabilities chapter queries.
5+
6+
Each query should have a corresponding `metric_name.sql` file.
7+
Note that readers are linked to this directory, so try to make the SQL file names descriptive for easy browsing.
8+
9+
Analysts: if helpful, you can use this README to give additional info about the queries.
10+
-->
11+
12+
## Resources
13+
14+
- [📄 Planning doc][~google-doc]
15+
- [📊 Results sheet][~google-sheets]
16+
- [📝 Markdown file][~chapter-markdown]
17+
18+
[~google-doc]: https://docs.google.com/document/d/1JFSXGg3KJeDNcWyGdfM8qcEBYZq0b4p3GXR_J7iJqWY/edit?tab=t.0#heading=h.8r1dmmbwunyr
19+
[~google-sheets]: https://docs.google.com/spreadsheets/d/1tBTCtkEw0QEOyebuHIettqGEKw1gtO2EB1jkwpRKb18/edit
20+
[~chapter-markdown]: https://github.com/HTTPArchive/almanac.httparchive.org/tree/main/src/content/en/2025/capabilities.md

sql/2025/capabilities/fugu.sql

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
#standardSQL
2+
SELECT
3+
client,
4+
fuguAPI,
5+
COUNT(DISTINCT root_page) AS sites,
6+
total,
7+
COUNT(DISTINCT root_page) / total AS pct,
8+
ARRAY_TO_STRING(ARRAY_AGG(DISTINCT page LIMIT 50), ' ') AS sample_urls
9+
FROM
10+
`httparchive.crawl.pages`
11+
JOIN
12+
(
13+
SELECT
14+
client,
15+
COUNT(root_page) AS total
16+
FROM
17+
`httparchive.crawl.pages`
18+
WHERE
19+
date = '2025-07-01'
20+
GROUP BY
21+
client
22+
) USING (client),
23+
UNNEST(JSON_KEYS(custom_metrics.other.`fugu-apis`)) AS fuguAPI
24+
WHERE
25+
date = '2025-07-01' AND
26+
custom_metrics.other.`fugu-apis` IS NOT NULL
27+
GROUP BY
28+
fuguAPI,
29+
client,
30+
total
31+
HAVING
32+
COUNT(DISTINCT root_page) >= 10
33+
ORDER BY
34+
pct DESC,
35+
client;

sql/2025/capabilities/top.sql

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#standardSQL
2+
SELECT
3+
client,
4+
page,
5+
COUNT(DISTINCT fuguAPI) AS fuguAPIs
6+
FROM
7+
`httparchive.crawl.pages`,
8+
UNNEST(JSON_KEYS(custom_metrics.other.`fugu-apis`)) AS fuguAPI
9+
WHERE
10+
date = '2025-07-01' AND
11+
custom_metrics.other.`fugu-apis` IS NOT NULL
12+
GROUP BY
13+
client,
14+
page
15+
HAVING
16+
COUNT(DISTINCT fuguAPI) >= 1
17+
ORDER BY
18+
fuguAPIs DESC,
19+
page,
20+
client
21+
LIMIT 100;

sql/2025/generative-ai/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@
1717

1818
[~google-doc]: https://docs.google.com/document/d/1HpI_E35FU_vqsJlMEONnCyR5lAvzDwVkWBg3lIlwlvw
1919
[~google-sheets]: https://docs.google.com/spreadsheets/d/1q_hFsWlt6DZMmwnxrTmU3nCRjT2w38AomAlw8b_lthE/edit
20-
[~chapter-markdown]: https://github.com/HTTPArchive/almanac.httparchive.org/tree/main/src/content/en/2025/ecommerce.md
20+
[~chapter-markdown]: https://github.com/HTTPArchive/almanac.httparchive.org/tree/main/src/content/en/2025/generative-ai.md

0 commit comments

Comments
 (0)