Chrome Prompt API Test - Gemini Nano Local AI

1 min read Original article ↗

1. Check Availability

Check if the Prompt API and Gemini Nano model are available on this device.

Click button to check

2. Model Parameters

Get the model's default and maximum parameter values.

3. Load Model

Load the model and create a session with optional custom parameters.

No model loaded

4. Prompt (Non-Streaming)

Send a prompt and get the complete response at once.

5. Prompt (Streaming)

Send a prompt and see the response stream in real-time.

6. Structured Output (JSON Schema)

Constrain the model's response using a JSON Schema.

7. Reset Session

Reset the conversation context (preserves system prompt, clears chat history).

Load model first