AI · 14 — Voice chat on a web page

Everything at once: an embeddable web chat where you can TYPE or TALK (mic button). Voice is transcribed by local Whisper, answered by local Ollama, and spoken back by local Kokoro — a full voice assistant with zero cloud. Deploy it, then open the chat page.

What’s inside

8 nodes — every type links to its full reference page.

StepNodeType
Web Chat Web Chat input.webchat
Transcribe (voice turns) AI Transcribe ai.transcribe
Whisper STT (local) AI Model ai.model
Think AI Prompt ai.prompt
Ollama (local) AI Model ai.model
Speak AI Speak ai.speak
Kokoro TTS (local) AI Model ai.model
Play (editor tests) Play Audio output.audio

Import it

  1. Studio → Import — paste the JSON below (or the URL /docs/templates/ai-14-voice-chat-on-a-web-page.json).
  2. Or ask the AI Copilot with the JSON pasted after the phrase:
    import this workflow json into a new workflow named "AI · 14 — Voice chat on a web page"
  3. Any credentials the nodes need are ${credential.…} references — add them once in Admin → Credentials and the template picks them up. Nothing secret ships in a template.
The workflow document (flowdrome.workflow.v1, 6 node types)
{
  "schemaVersion": "flowdrome.workflow.v1",
  "id": "",
  "name": "AI · 14 — Voice chat on a web page",
  "version": "0",
  "status": "draft",
  "nodes": [
    {
      "id": "chat",
      "type": "input.webchat",
      "label": "Web Chat",
      "category": "trigger",
      "config": {
        "path": "/chat/ai-demo",
        "title": "Voice assistant",
        "greeting": "Hi! Type, or press the mic and talk — I answer out loud.",
        "placeholder": "Say something…",
        "accent": "#635bff",
        "position": "right",
        "replyField": "",
        "allowedOrigins": "*"
      },
      "position": {
        "x": 0,
        "y": 0
      }
    },
    {
      "id": "hear",
      "type": "ai.transcribe",
      "label": "Transcribe (voice turns)",
      "category": "ai",
      "config": {
        "baseUrl": "http://localhost:8970/v1",
        "apiKey": "",
        "model": "Systran/faster-whisper-tiny.en",
        "audioField": "audio",
        "language": "",
        "outputField": "message",
        "timeoutMs": 120000
      },
      "position": {
        "x": 530,
        "y": 0
      },
      "attachments": {
        "model": "stt"
      }
    },
    {
      "id": "stt",
      "type": "ai.model",
      "label": "Whisper STT (local)",
      "category": "ai",
      "config": {
        "provider": "generic-url",
        "baseUrl": "http://localhost:8970/v1",
        "apiKey": "",
        "model": "Systran/faster-whisper-tiny.en",
        "models": [],
        "temperature": 0.2,
        "maxTokens": 512
      },
      "position": {
        "x": 530,
        "y": 222
      }
    },
    {
      "id": "brain",
      "type": "ai.prompt",
      "label": "Think",
      "category": "ai",
      "config": {
        "provider": "ollama",
        "baseUrl": "",
        "apiKey": "",
        "model": "qwen2.5:1.5b",
        "systemPrompt": "You are a friendly voice assistant. Answer in ONE short sentence — it will be read aloud.",
        "promptMode": "field",
        "promptField": "message",
        "temperature": "0.4",
        "maxTokens": 120,
        "jsonMode": false,
        "timeoutMs": 120000
      },
      "position": {
        "x": 1060,
        "y": 0
      },
      "attachments": {
        "model": "llm"
      }
    },
    {
      "id": "llm",
      "type": "ai.model",
      "label": "Ollama (local)",
      "category": "ai",
      "config": {
        "provider": "ollama",
        "baseUrl": "",
        "apiKey": "",
        "model": "qwen2.5:1.5b",
        "models": [],
        "temperature": 0.2,
        "maxTokens": 512
      },
      "position": {
        "x": 1060,
        "y": 222
      }
    },
    {
      "id": "speak",
      "type": "ai.speak",
      "label": "Speak",
      "category": "ai",
      "config": {
        "baseUrl": "http://localhost:8880/v1",
        "apiKey": "",
        "model": "kokoro",
        "voice": "af_heart",
        "textField": "reply",
        "format": "mp3",
        "timeoutMs": 120000
      },
      "position": {
        "x": 1590,
        "y": 0
      },
      "attachments": {
        "model": "tts"
      }
    },
    {
      "id": "tts",
      "type": "ai.model",
      "label": "Kokoro TTS (local)",
      "category": "ai",
      "config": {
        "provider": "generic-url",
        "baseUrl": "http://localhost:8880/v1",
        "apiKey": "",
        "model": "kokoro",
        "models": [],
        "temperature": 0.2,
        "maxTokens": 512
      },
      "position": {
        "x": 1590,
        "y": 222
      }
    },
    {
      "id": "play",
      "type": "output.audio",
      "label": "Play (editor tests)",
      "category": "output",
      "config": {
        "audioField": "",
        "label": ""
      },
      "position": {
        "x": 2120,
        "y": 0
      }
    }
  ],
  "edges": [
    {
      "id": "e0",
      "sourceNodeId": "chat",
      "sourcePort": "output",
      "targetNodeId": "hear",
      "targetPort": "input"
    },
    {
      "id": "e1",
      "sourceNodeId": "hear",
      "sourcePort": "output",
      "targetNodeId": "brain",
      "targetPort": "input"
    },
    {
      "id": "e2",
      "sourceNodeId": "brain",
      "sourcePort": "output",
      "targetNodeId": "speak",
      "targetPort": "input"
    },
    {
      "id": "e3",
      "sourceNodeId": "speak",
      "sourcePort": "output",
      "targetNodeId": "play",
      "targetPort": "input"
    }
  ],
  "triggers": [
    {
      "id": "t0",
      "nodeId": "chat"
    }
  ],
  "meta": {
    "snippets": [],
    "source": "template-gallery",
    "description": "Everything at once: an embeddable web chat where you can TYPE or TALK (mic button). Voice is transcribed by local Whisper, answered by local Ollama, and spoken back by local Kokoro — a full voice assistant with zero cloud. Deploy it, then open the chat page."
  }
}

Generated from the verified demo corpus — this exact document seeds and runs on a fresh Flowdrome. Raw JSON: ai-14-voice-chat-on-a-web-page.json.