> ## Documentation Index
> Fetch the complete documentation index at: https://docs.elbic.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Pronunciation & IPA

> Fix how specific words are spoken with inline IPA in the request text, or replacement/IPA entries in pronunciation dictionaries.

When the model mispronounces a brand name, product, or domain term, you have
two tools: write **IPA directly in the request text**, or set up a
**pronunciation dictionary** that fixes the word in every request that
selects it.

## Inline IPA in the request text

Write the IPA transcription between slashes, directly where the word would
be:

```text
"Willkommen bei /ˈkuːɡl̩/ Audio."
```

Use the slash form shown here and test it with the target voice and language.
Text normalization leaves an IPA span between the slashes unchanged; numbers
and dates around it are still expanded.

<Tabs>
  <Tab title="Python">
    ```python
    audio = client.tts.generate(
        text="Willkommen bei /ˈkuːɡl̩/ Audio.",
        voice_id=1071,
        language="de",
    )
    ```
  </Tab>
  <Tab title="JavaScript">
    ```typescript
    const audio = await client.tts.generate({
      text: 'Willkommen bei /ˈkuːɡl̩/ Audio.',
      voiceId: 1071,
      language: 'de',
    });
    ```
  </Tab>
  <Tab title="cURL">
    ```bash
    curl -X POST https://api.elbic.com/v1/tts/generate \
      -H "Authorization: Bearer $KUGELAUDIO_API_KEY" \
      -H "Content-Type: application/json; charset=utf-8" \
      -d '{
        "text": "Willkommen bei /ˈkuːɡl̩/ Audio.",
        "voice_id": 1071,
        "language": "de"
      }' --output output.pcm
    ```
  </Tab>
</Tabs>

<Note>
  Use real IPA characters (the non-ASCII phonetic alphabet, e.g. `ˈ`, `ː`,
  `ɡ`), not ASCII respellings, inside the slashes. A plain English word
  between slashes is just read as text. SSML `<phoneme>` tags are **not**
  supported; write the IPA inline instead.

  Leave out syllable dots: write `/ɡastʁoskoˈpiː/`, not `/ɡas.tʁo.sko.ˈpiː/`.
  A dot inside the slashes can be read aloud as "Punkt" or break the word apart.
</Note>

Inline IPA is per-request. If the same word needs fixing everywhere, put it
in a dictionary instead:

## Pronunciation dictionaries

A dictionary is a per-project word list. It applies to a synthesis request
only when that request sends the dictionary's `project_id`. Each entry maps a
word to either:

- a **replacement** spelling (write it how it *sounds*), or
- an **IPA transcription** (exact phonetic control).

`replacement` is required on every entry; when `ipa` is also set,
**IPA wins**.

```json
{
  "word": "Kugel",
  "replacement": "Koogel",
  "ipa": "ˈkuːɡl̩"
}
```

Dictionaries are managed via the API or SDKs and applied server-side, so your
request text stays clean. Send `project_id` on synthesis from the raw API, from
every generation and session method in Python (`project_id`), Java and
JavaScript (`projectId`), or from the LiveKit and Pipecat plugins. Full
management guide: [Dictionaries](/features/dictionaries) ·
[API reference](/api-reference/endpoints/dictionaries) · SDK reference:
[Dictionaries](/sdks/dictionaries) (Python, TypeScript, Java).

## Choosing the right tool

| Problem | Tool |
|---------|------|
| Word pronounced wrong everywhere ("Kugel" read as English) | Dictionary entry with `replacement` or `ipa` |
| Exact phonetics required (clinical terms, names) | Dictionary entry with `ipa`, or inline `/aɪ piː eɪ/` |
| One-off pronunciation fix in a single request | [Inline IPA](#inline-ipa-in-the-request-text), or just write the spoken form ("Koogel Audio") |
| Text should be spelled character-by-character (codes, emails) | [`<spell>` tags](/prompting/spell) |
| Numbers/dates/currency read wrong | Set `language` + [normalization](/features/text-processing) |
| Migrating from SSML `<phoneme alphabet="ipa">` | Remove the unsupported tag and replace it with [inline `/…/` IPA](#inline-ipa-in-the-request-text) |

## Quick example

Send the dictionary's project ID on synthesis. With `projectId` set, the
project's active dictionaries for the request language apply; use
`dictionaryIds` when you need an exact selection:

```typescript
const d = await client.dictionaries.create({ name: 'brand-terms', language: 'de' });
await client.dictionaries.entries.add(d.id, {
  word: 'Kugel',
  replacement: 'Koogel',
  ipa: 'ˈkuːɡl̩',
});

const audio = await client.tts.generate({
  text: 'Willkommen bei Kugel Audio.',
  voiceId: 1071,
  language: 'de',
  projectId: d.projectId,
});
```

See [Dictionaries](/features/dictionaries) for the language filter,
per-request selection, and bulk sync.

## Next steps

<CardGroup cols={2}>
  <Card title="Dictionaries" icon="book" href="/features/dictionaries">
    Project word lists and per-request selection
  </Card>
  <Card title="Spell tags" icon="font" href="/prompting/spell">
    Read codes and emails character by character
  </Card>
  <Card title="Text normalization" icon="spell-check" href="/features/text-processing">
    How numbers, dates and currencies are read
  </Card>
  <Card title="Dictionaries API" icon="code" href="/api-reference/endpoints/dictionaries">
    Raw HTTP contract for dictionaries and entries
  </Card>
</CardGroup>
