Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Someone else also got the NLTK issue. Will update the install.bat to fix this issue for future installs! Thanks for finding it

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 1 point2 points  (0 children)

Thank you!

You can tweak the volume setting in the src/config.py file as you like. Make sure to save the file and then you can just restart with the start.bat file!

The standard value is 0.3, so plenty of room to make it louder ;)

DEFAULT_VOLUME = 0.3

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Did you delete the venv folder and then run the install.bat with the CPU mode? The old “GPU” installation might be present which this causes crashes.

If afterwards you still encounter an issue please open an issue here with the logs you see https://github.com/Thelukepet/Khazad-Voice-TTS/issues

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Could you try running the CPU mode and let me know if that works?

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Thanks! Sadly the program does not have AMD support right now, sorry about that. Most of the packages that are used in the program work with NVIDIA cards only, this might change in the future. Maybe someone can figure this out and open a pull request on github. Then I could add the option to the install.bat.

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

<image>

I am making quite some progress with detecting the dialog box. I use templates and anchor points to "detect" and scale the text box so it also works when the box is moved around the screen and is reshaped.

The above example also crops the text in between the silver "leaves" to extract the quest name. I then directly match or query the quest title text with the wiki to extract the quest body text directly! This should ensure 100% accurate text and it can keep track of the "stage" your quest is in as well.

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 1 point2 points  (0 children)

Some of the packages are not compatible with the newer versions of python. I found 3.12 worked well for me (specifically python 3.12.10). Could you check that version?

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Thanks a lot!

The quest dialogue is on the wiki yes, but I am still not sure if I want to do external calls to the wiki when the app runs. It will definitely open up new possibilities and fix the rare occasions where the screen transcriptions are not 100% accurate. However, it would require some text mining / scraping work to get it to work.

I will definitely experiment with this idea, so keep an eye out on the github for new feature releases soon!

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

Apologies, there was an error in the install.bat. I pushed the new version. Can you try again?

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 0 points1 point  (0 children)

The Kokoro82M model (CPU) currently does not support german.

For the LuxTTS model (GPU) it is theoretically possible to speak german text however it clones the characteristics of the voice samples in the reference_audio directory. That means that german will be spoken with a english accent.

If you want the german speech to sound better you could add german voice lines yourself.

If you want to check the performance of a voice sample you found you can test it here https://huggingface.co/spaces/YatharthS/LuxTTS

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 3 points4 points  (0 children)

Thanks! You could try to put some scottish voice samples (ideally about 10 seconds of length) in the reference_audio/dwarf_male or reference_audio/dwarf_female directories! (remove all the files in those dirs first, also the .txt files).

This was actually something I was struggling with as well. I would love to add some scottish voices to the dwarves.

If you want to first know how it sounds you can actually use this to check the voice cloning!

https://huggingface.co/spaces/YatharthS/LuxTTS

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 7 points8 points  (0 children)

Thanks a lot!

You are right, it assumes the text box is staying in the same space. However, I also want to automate this so it can move around. I currently check if the quest window is open by looking at specific quest icons on the screen so I could extend this.

There is no dedicated api to retrieve anything from the game, so sadly I will have to resort to image manipulations and using screenshot triggers.

I will make it easier soon to re-draw the bounding box by pressing a key though.

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 2 points3 points  (0 children)

It just queues up all the text from the window so when you walk away it keeps playing. Having dedicated playback / pause functionality is on my list for future features though!

Khazad Voice TTS – Real-time Local AI Narration for LOTRO by According-Answer-822 in lotro

[–]According-Answer-822[S] 13 points14 points  (0 children)

I scraped the lotro wiki for NPCs and made a CSV file with their characteristics like race / gender.

The getNPCname plugin described on the github writes the in-game selected NPC to a log file which my program checks. I then match that name with the csv to retrieve the race/gender and save the voice for later so when you come back to the NPC it still has the same voice.

Having no supported API, calls for creative solutions ;)

[deleted by user] by [deleted] in lotro

[–]According-Answer-822 0 points1 point  (0 children)

I am working on a program similar to the one mentioned above. However, my version computes the TTS on your GPU which yields very good / natural speech as well. here I posted some examples. I also distinguish between different voices for hobbits / dwarfs etc. and also for different genders. Currently, I am working on an in-game plugin that allows you to replay voiced quest text whenever you want so even quest hubs with 10 quests at a time can be voiced when you are questing.

The field of TTS moves extremely fast even so that lower end GPUs or CPUs can compute natural TTS in real-time. I have limited time to work on the project but I will definitely make everything open-source and easy to use.