NanoLLM icon indicating copy to clipboard operation
NanoLLM copied to clipboard

Reorganizing of plugin directories seems to break speech tools such as riva_asr and riva_tts

Open ChadSwenson opened this issue 8 months ago • 1 comments

The following commit seems to move several speech related plugins from the audio directory to a new speech directory: Hash: 31ad117619ff12f21f841484fcdf963b1512b159 Message: "updated plugins" Date: 2024/06/12 @ 9:50 PM

Trying to run any example that uses riva asr now give the following error:

Traceback (most recent call last): File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/opt/NanoLLM/nano_llm/agents/web_chat.py", line 327, in agent = WebChat(**vars(args)) File "/opt/NanoLLM/nano_llm/agents/web_chat.py", line 32, in init super().init(**kwargs) File "/opt/NanoLLM/nano_llm/agents/voice_chat.py", line 38, in init self.asr = AutoASR.from_pretrained(asr=asr, **kwargs) File "/opt/NanoLLM/nano_llm/plugins/speech/auto_asr.py", line 34, in from_pretrained from nano_llm.plugins.audio.riva_asr import RivaASR ModuleNotFoundError: No module named 'nano_llm.plugins.audio.riva_asr'

I am able to resolve this issue for Riva by modifying the imports in the following files: /opt/NanoLLM/nano_llm/plugins/speech/auto_asr.py line 34 /opt/NanoLLM/nano_llm/plugins/speech/auto_tts.py lines 44-46

Changing "audio" to "speech" to match the directory changes in the provided git commit allows the riva asr and tts plugins to work.

ChadSwenson avatar Jun 20 '24 13:06 ChadSwenson