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

# Uplift AI Speech-to-Text

> UpliftAISTTService transcribes Urdu-optimized speech using Uplift AI's Scribe STT API with VAD-segmented audio.

> [!NOTE]
>
> **Community-maintained integration.** This service is built and
> maintained by
> [havkerboi123](https://github.com/havkerboi123)
> . Pipecat does not test or officially support it. Please report issues and
> request changes on the
> [source repository](https://github.com/havkerboi123/pipecat-upliftai-stt)
> . Learn more about
> [community integrations](https://docs.pipecat.ai/api-reference/server/services/community-integrations.md)
> .

## Overview

`UpliftAISTTService` transcribes audio into text using [Uplift AI](https://upliftai.org)'s
Scribe speech-to-text API, optimized for the Urdu language with optional
domain-specific optimization. It is a `SegmentedSTTService` built on Uplift AI's
HTTP transcription endpoint.

> [card] [Source Repository](https://github.com/havkerboi123/pipecat-upliftai-stt)
>
> Source code, examples, and issues for the Uplift AI STT integration

> [card] [Uplift AI](https://upliftai.org)
>
> Learn more about Uplift AI's speech services

> [card] [API Keys](https://platform.upliftai.org/studio/api-keys)
>
> Create and manage your Uplift AI API keys

## Installation

This is a community-maintained package distributed separately from `pipecat-ai`.
It is not yet published to PyPI, so install it directly from GitHub:

```bash theme={null}
uv pip install git+https://github.com/havkerboi123/pipecat-upliftai-stt.git
```

## Prerequisites

### Uplift AI Account Setup

Before using the Uplift AI STT service, you need:

1. **Uplift AI Account**: Sign up at [Uplift AI](https://upliftai.org)
2. **API Key**: Generate a key (format: `sk_api_...`) from the
   [API Keys page](https://platform.upliftai.org/studio/api-keys)

### Required Environment Variables

* `UPLIFT_API_KEY`: Your Uplift AI API key. Falls back to this environment
  variable if `api_key` is not passed to the constructor.

## Configuration

**api\_key** `str` (default: None)

Uplift AI API key. Falls back to the `UPLIFT_API_KEY` environment variable if
not provided.

**base\_url** `str` (default: [https://api.upliftai.org/v1](https://api.upliftai.org/v1))

Base URL for the Uplift AI API.

**sample\_rate** `int` (default: None)

Audio sample rate in Hz. If not provided, the pipeline's sample rate is used.

**model** `str` (default: scribe)

Model to use for transcription. Options: `"scribe"` (full accuracy, 40
credits/min) or `"scribe-mini"` (cost-effective, 20 credits/min).

**domain** `str` (default: None)

Optional domain-specific optimization. Options: `"phone-commerce"` or
`"farming"`.

**params** `UpliftAISTTService.InputParams` (default: None)

Alternative parameter configuration. See [InputParams](#inputparams) below.

### InputParams

Advanced configuration passed via the `params` constructor argument using
`UpliftAISTTService.InputParams(...)`.

| Parameter | Type | Default | Description |
| - | - | - | - |
| `model` | `str` | `"scribe"` | Model to use. Options: `"scribe"` or `"scribe-mini"`. |
| `language` | `str` | `"ur"` | Transcription language. Currently only Urdu (`"ur"`) is supported. |
| `domain` | `str` | `None` | Optional domain optimization: `"phone-commerce"` or `"farming"`. |

> [!NOTE]
>
> See the [source
> repository](https://github.com/havkerboi123/pipecat-upliftai-stt) for the
> authoritative, up-to-date configuration options.

## Usage

```python theme={null}
import os
from pipecat.pipeline.pipeline import Pipeline
from pipecat_upliftai import UpliftAISTTService

stt = UpliftAISTTService(
    api_key=os.getenv("UPLIFT_API_KEY"),
    model="scribe",
    domain="phone-commerce",  # optional
)

pipeline = Pipeline([
    transport.input(),               # audio/user input
    stt,                             # Uplift STT transcription
    context_aggregator.user(),       # add user text to context
    llm,                             # LLM generates response
    tts,                             # text to speech synthesis
    transport.output(),              # stream audio back to user
    context_aggregator.assistant(),  # store assistant response
])
```

You can also switch the model or domain at runtime:

```python theme={null}
await stt.set_model("scribe-mini")
await stt.set_domain("farming")
await stt.set_domain(None)  # disable domain optimization
```

## Compatibility

Tested with Pipecat v0.0.86 and later. Check the [source
repository](https://github.com/havkerboi123/pipecat-upliftai-stt) for the latest
tested version and changelog.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.