flashlight / text

Text utilities, including beam search decoding, tokenizing, and more, built for use in Flashlight.
MIT License
64 stars 15 forks source link

Update flashlight text decoder extension for TorchAudio adoptation #8

Closed mthrok closed 2 years ago

mthrok commented 2 years ago

Summary: Make changes to fill some gaps for adopting FL Text decoder in TorchAudio.

  1. Make the extension module flashlight_lib_text_decoder expose KenLM and ZeroLM.
  2. Add ZeroLMPtr alias in ZeroLM.h.

Differential Revision: D37983766

facebook-github-bot commented 2 years ago

This pull request was exported from Phabricator. Differential Revision: D37983766

carolineechen commented 2 years ago

@mthrok @jacobkahn is this functionality working on OSS as well? I'm building bindings from source after pulling in the changes but for some reason am getting ImportError: cannot import name 'ZeroLM' from 'flashlight.lib.text.decoder', all other ones load in fine