OpenViSTAI · Agents · Blockchain · Crypto
Menu
Audio & Voice AI

Pocketsphinx

PocketSphinx is a compact C speech-recognition engine for large-vocabulary, speaker-independent continuous speech. Its command-line tool transcribes audio and can align a recording to a supplied word sequence.

Independent OpenViST project profile, based on linked sources.

Pocketsphinx — OpenViST project profile in Audio & Voice AI.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use PocketSphinx when a development project needs compact, speaker-independent speech recognition, or when audio must be aligned to text already known.

Who it is for

  • Developers embedding speech recognition in compact applications
  • People building continuous speech transcription workflows
  • Users who need word, phone, or state alignment for audio with a known transcript

Documented uses

  • Recognize speech in a single-channel audio file or standard-input stream.
  • Detect speech segments and return recognized text with timing and probability fields.
  • Align a recording to supplied words, with optional phone- or state-level alignment.
Before you choose

Requirements & limits

  • The command-line tool expects single-channel, 16-bit PCM input; the README suggests SoX for converting other formats.
  • The former bundled audio library has been removed, so audio capture workflows use external tools such as SoX.
  • The README describes CMake builds for Linux and Windows but expresses uncertainty about macOS.
  • The README identifies the project as open source and directs users to the LICENSE file for terms of use.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Install the Python module in a virtual environment

Create a virtual environment and install the PocketSphinx Python module from the repository’s top-level directory.

Before you start

  • A Python 3 installation
  • A local checkout of the PocketSphinx repository

Steps

  1. Create a virtual environment with the command below.

    Documented command
    python3 -m venv ~/ve_pocketsphinx
  2. Activate it with . ~/ve_pocketsphinx/bin/activate.

  3. From the repository’s top-level directory, run the command below.

    Documented command
    pip install .

Expected outcome

The Python module is installed in the activated virtual environment.

Guide limitations

  • This recipe covers installation, not running a recognition task.
  • The README says the listed audio dependencies are useful for example code but are not strictly necessary to build and install.
Source-based practical guide

Build and install the C library and bindings

Use CMake to build and install PocketSphinx.

Before you start

  • A local checkout of the PocketSphinx repository
  • CMake and a build environment
  • Access to /usr/local, or a different install prefix

Steps

  1. From the repository’s top-level directory, configure with cmake -S . -B build.

  2. Build with cmake --build build.

  3. Install with cmake --build build --target install.

Expected outcome

The C library and bindings are built and installed to the configured prefix.

Guide limitations

  • The README says CMake should give reasonable results on Linux and Windows but notes uncertainty about macOS.
  • The README directs users without access to /usr/local to set a different prefix with -DCMAKE_INSTALL_PREFIX in the first CMake command.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
15 October 2026
Original website title
cmusphinx/pocketsphinx · Official homepage title · retained in its source language