#133 · Primary category: Speech & Audio

CTCDecoder

beam-search best-path ctc ctc-loss handwriting-recognition language-model loss opencl prefix-search python recurrent-neural-networks speech-recognition token-passing

Connectionist Temporal Classification (CTC) decoding algorithms: best path, beam search, lexicon search, prefix search, and token passing. Implemented in Python.

Project last updated:01/31/26

GitHub Stars

837

Forks

179

Contributors

7

License

MIT

Why we included this project

The decoder is the part of a CTC pipeline that often gets glossed over until the output comes out wrong. This small Python package implements the standard options, best path and beam search for the common cases, plus lexicon search, prefix search, and token passing for when you need more than a greedy guess. The beam search decoder can optionally use a bigram language model built from your own text, and the lexicon search relies on a BK-tree to return dictionary words within a chosen edit distance. It is a focused, dependency-light library rather than a full training framework, so it is easy to drop into an existing pipeline or to read through if you want to understand how each algorithm works. If you build speech-to-text or handwriting recognition on a CTC-trained network, this is a handy reference and a solid baseline to measure your own decoder against.

Articles for this project

No articles for this project yet.

To suggest a topic or contribute an article, contact us.

Related projects in this category