Skip to content

Chrome 148 added Prompt API#29474

Merged
caugner merged 16 commits into
mdn:mainfrom
jmedley:prompt-api
Apr 23, 2026
Merged

Chrome 148 added Prompt API#29474
caugner merged 16 commits into
mdn:mainfrom
jmedley:prompt-api

Conversation

@jmedley

@jmedley jmedley commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Chrome is shipping the Prompt API in 148. See https://chromestatus.com/feature/5134603979063296

Test results and supporting details

I generated a schema from existing BCD and tested the JSON against the schema.

Related issues

Fixes #29473 and mdn/content#43755

@github-actions github-actions Bot added data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API size:xl [PR only] >1000 LoC changed labels Apr 13, 2026
@github-actions

github-actions Bot commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

Tip: Review these changes grouped by change (recommended for most PRs), or grouped by feature (for large PRs).

@jmedley

jmedley commented Apr 16, 2026

Copy link
Copy Markdown
Contributor Author

@hamishwillee I've had three checks pending ever since I submitted this. How do I move this forward?

@chrisdavidmills

Copy link
Copy Markdown
Contributor

Hi @jmedley! I've approved the checks to run. I think this is always the case with a new account, for the first few PRs. Now we need to find someone to do a review.

@chrisdavidmills chrisdavidmills requested a review from caugner April 16, 2026 18:56
@jmedley

jmedley commented Apr 16, 2026

Copy link
Copy Markdown
Contributor Author

@chrisdavidmills Thanks! I've lost access to me old account.

@hamishwillee

Copy link
Copy Markdown
Contributor

@jpmedley FYI I work on Mozilla stuff on Mon, Tues, Friday in Melbourne, Australia timezone. Which is to say that I only just got into work and saw this. You shouldn't have this problem going forward, but it can take time for the (very busy) BCD team to review.

…ebview_ios to LanguageModel* files

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@jmedley

jmedley commented Apr 17, 2026

Copy link
Copy Markdown
Contributor Author

@hamishwillee, @chrisdavidmills I'm working on the other lint failures, but the location of this spec fails the regex for "spec_url": https://webmachinelearning.github.io/prompt-api/

npm lint is also complaining that "spec_url" needs to be an array.

@hamishwillee

Copy link
Copy Markdown
Contributor

A spec url must contain a # fragment identifier. It may also need to be registered. Sometimes you may need to add the spec to https://github.com/w3c/browser-specs. It is also possibly you may need to create an exception.
I don't do this often enough to remember the steps sorry - @caugner will probably post something more useful.

@jmedley jmedley requested review from a team and mdn-bot as code owners April 17, 2026 02:40
@github-actions github-actions Bot added infra Infrastructure issues (npm, GitHub Actions, releases) of this project dependencies Pull requests that update a dependency package or file. labels Apr 17, 2026
@jmedley

jmedley commented Apr 17, 2026

Copy link
Copy Markdown
Contributor Author

@hamishwillee @caugner I forgot to mention that this spec doesn't have fragment identifiers.

@chrisdavidmills

Copy link
Copy Markdown
Contributor

@hamishwillee @caugner I forgot to mention that this spec doesn't have fragment identifiers.

It looks like it does to me. https://webmachinelearning.github.io/prompt-api/, right?

As an FYI, text fragments are also acceptable in spec URLs, in cases where there isn't a clear URL fragment to point to a definition.

@caugner caugner left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First review round, without looking at the values.

Comment thread api/LanguageModel.json Outdated
Comment thread api/LanguageModel.json Outdated
Comment thread api/LanguageModel.json Outdated
Comment thread api/LanguageModel.json Outdated
Comment thread api/LanguageModel.json Outdated
Comment thread api/LanguageModelMessageContent.json Outdated
Comment thread api/LanguageModelPromptOptions.json Outdated
Comment thread api/LanguageModelTool.json Outdated
Comment thread api/LanguageModelToolFunction.json Outdated
Comment thread package-lock.json
Co-authored-by: Claas Augner <495429+caugner@users.noreply.github.com>
@github-actions github-actions Bot added size:l [PR only] 101-1000 LoC changed and removed size:xl [PR only] >1000 LoC changed labels Apr 19, 2026
Co-authored-by: Claas Augner <495429+caugner@users.noreply.github.com>
@jmedley

jmedley commented Apr 19, 2026

Copy link
Copy Markdown
Contributor Author

@caugner PTAL

Sorry about the mess-ups. I'm a few years rusty.

@jmedley jmedley requested a review from caugner April 19, 2026 15:46
@github-actions github-actions Bot removed infra Infrastructure issues (npm, GitHub Actions, releases) of this project dependencies Pull requests that update a dependency package or file. labels Apr 20, 2026
Comment thread api/LanguageModel.json Outdated
jmedley and others added 2 commits April 23, 2026 09:52
Co-authored-by: Claas Augner <495429+caugner@users.noreply.github.com>
@jmedley

jmedley commented Apr 23, 2026

Copy link
Copy Markdown
Contributor Author

@caugner PTAL

@caugner caugner changed the title Chrome added Prompt API in 148 #29473 Chrome 148 added Prompt API Apr 23, 2026
@caugner caugner enabled auto-merge (squash) April 23, 2026 17:03
@caugner caugner merged commit ac9a139 into mdn:main Apr 23, 2026
9 checks passed
@mdn-bot mdn-bot mentioned this pull request Apr 23, 2026
Comment thread api/LanguageModel.json
Comment on lines +70 to +72
"availability_static": {
"__compat": {
"spec_url": "https://webmachinelearning.github.io/prompt-api/#dom-languagemodel-availability",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should have had a description. I filed #29537 to have a lint for it in the future.

@jmedley jmedley deleted the prompt-api branch April 26, 2026 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

data:api Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API size:l [PR only] 101-1000 LoC changed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Prompt API - Missing compat data for Chrome and Edge

6 participants