Turn an Event Poster into a Reviewable Draft with Chrome's Prompt API A developer built a companion demo that uses Chrome's built-in multimodal Prompt API to extract four fields—title, date, timeZone and location—from a synthetic event poster, keeping model output, application validation and human review as separate steps. The example constrains responses with a strict Zod schema, rejects extra properties, and validates dates and time zones so missing or ambiguous facts surface as review issues rather than invented values. Each extraction attempt gets its own AbortController and generation id, and the result object separates structural acceptance (ok) from readiness (needsReview, submitted). An event poster looks like a convenient shortcut: upload the image and let an AI model fill the form. The difficult part arrives when the poster says “Friday, March 6” without a year, names a city without a time zone, or includes a second date for registration. A well-formed JSON response does not resolve those ambiguities. For an event-planning application, the useful output is a candidate the user can review, with missing information still visible. The companion demo uses Chrome's multimodal Prompt API to extract four fields from a synthetic poster. It keeps model output, application validation, and human review as distinct steps. There is no booking or submission action in the extraction path. Chrome's current Prompt API documentation https://developer.chrome.com/docs/ai/prompt-api describes image input through the browser's built-in model. Availability depends on the browser, device, model state, and requested capabilities. A browser version alone is not a sufficient readiness check. The fixture supplies the same options to availability checking and session creation: js const options = { expectedInputs: { type: "text", languages: "en" }, { type: "image" }, , expectedOutputs: { type: "text", languages: "en" } , }; const state = await LanguageModel.availability options ; if state === "unavailable" { throw new Error "Image extraction is unavailable on this device" ; } The complete TypeScript example adds system instructions and calls creation from the user's extraction action. A model download may be needed. The interface should explain that preparation instead of presenting a frozen button as if inference had already begun. This example uses the built-in browser model and needs no cloud model API key. It still requires an eligible local environment and the relevant browser setup. The output contract contains title , date , timeZone , and location . Each can be null . Missing information is a normal result, not a reason to invent a plausible value. The system instruction asks for visible facts, treats text inside the image as data, and forbids inferring a year or time zone. These instructions help specify the task; they do not prove the model will follow it. A strict Zod object supplies the JSON schema used as a structured-output constraint https://developer.chrome.com/docs/ai/structured-output-for-prompt-api . Extra properties are rejected at the application boundary. The prompt request includes the image as a Blob : js const response = await session.prompt { role: "user", content: { type: "text", value: "Extract the visible event facts." }, { type: "image", value: imageBlob }, } , { responseConstraint: outputSchema, signal }, ; const candidate = inspectCandidate JSON.parse response ; Constraining the response shape makes parsing more dependable. It does not establish that a date belongs to the event, that a venue was read correctly, or that an apparent instruction in the poster should influence application behavior. A date can match YYYY-MM-DD and still be impossible. The validator parses it and compares the normalized ISO date with the original value. That catches cases such as a day that rolls into the following month. Time zones receive a separate check through Intl.DateTimeFormat . A city name is not silently converted into an IANA zone. If the poster does not provide a usable zone, the candidate retains a missing-field issue for the reviewer. The returned object deliberately separates structural acceptance from readiness: return { ok: true, value, issues, needsReview: true, submitted: false, }; Here, ok means the candidate has the required shape. It does not mean every field is complete or that the event can be submitted. Code consuming this result should display issues and keep the review requirement intact. The browser fixture gives each extraction attempt its own AbortController and generation identifier. Starting a new attempt aborts the previous one. The result updates the page only if its identifier still matches the active attempt. Both checks matter. Cancellation requests may race with completion, and a resolved promise can arrive after the user has moved on. The generation check prevents an older poster from replacing the newer draft even if the older work finishes at an awkward moment. The session is destroyed in finally , including parsing failures and aborted requests. The page displays returned text through textContent ; it does not interpret model output as HTML. The package includes six passing validator tests: a complete candidate still requires review, a missing zone remains missing, an impossible date is flagged, an invalid zone is flagged, extra fields are rejected, and non-JSON output fails parsing. Those tests verify application behavior. They do not measure extraction quality. The native model run is still pending, so the package contains no claimed accuracy score or inference latency. For the browser experiment, use the included synthetic poster set. It covers a fully specified event, a missing year, a missing zone, conflicting date information, and text that attempts to redirect the model. The fixtures contain invented event details and no customer data. Record field-level results rather than a single pass percentage. A correct title with an invented year is an important failure even if most fields look right. Also record whether the application preserved uncertainty and whether a reviewer could correct the candidate without starting again. In Trip Workbench, the natural integration point is a draft-import panel beside the existing event form. The model proposes fields; the panel shows the source image, extracted values, and unresolved issues. The user decides which values to apply. Keep final submission in the application's established validation and authorization path. That allows the image feature to improve data entry without making uncertain model output an invisible source of committed state. The useful success criterion is therefore concrete: can a user reach a correct, reviewable event draft faster while seeing what the model could not establish? The companion code provides the boundary conditions for answering that question with real browser runs.