forked from ggerganov/whisper.cpp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request ggerganov#4 from ggerganov/master
Update from upstream
- Loading branch information
Showing
15 changed files
with
5,138 additions
and
594 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
eleven-labs.py | ||
audio.mp3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
if (WHISPER_SUPPORT_SDL2) | ||
# talk-llama | ||
set(TARGET talk-llama) | ||
#add_executable(${TARGET} talk-llama.cpp llama.cpp) | ||
#target_include_directories(${TARGET} PRIVATE ${SDL2_INCLUDE_DIRS}) | ||
#target_link_libraries(${TARGET} PRIVATE common common-sdl whisper ${SDL2_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}) | ||
|
||
# TODO: this is temporary | ||
# need to export ggml symbols for MSVC, but too lazy .. | ||
add_executable(${TARGET} talk-llama.cpp llama.cpp ../common.cpp ../common-sdl.cpp ../../ggml.c ../../whisper.cpp) | ||
|
||
target_include_directories(${TARGET} PRIVATE ${SDL2_INCLUDE_DIRS} ../../) | ||
target_link_libraries(${TARGET} PRIVATE ${SDL2_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}) | ||
|
||
include(DefaultTargetOptions) | ||
endif () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# talk-llama | ||
|
||
Talk with an LLaMA AI in your terminal | ||
|
||
[Demo Talk](https://user-images.githubusercontent.com/1991296/228024237-848f998c-c334-46a6-bef8-3271590da83b.mp4) | ||
|
||
## Building | ||
|
||
The `talk-llama` tool depends on SDL2 library to capture audio from the microphone. You can build it like this: | ||
|
||
```bash | ||
# Install SDL2 on Linux | ||
sudo apt-get install libsdl2-dev | ||
|
||
# Install SDL2 on Mac OS | ||
brew install sdl2 | ||
|
||
# Build the "talk-llama" executable | ||
make talk-llama | ||
|
||
# Run it | ||
./talk-llama -mw ./models/ggml-small.en.bin -ml ../llama.cpp/models/13B/ggml-model-q4_0.bin -p "Georgi" -t 8 | ||
``` | ||
|
||
- The `-mw` argument specifies the Whisper model that you would like to use. Recommended `base` or `small` for real-time experience | ||
- The `-ml` argument specifies the LLaMA model that you would like to use. Read the instructions in https://github.com/ggerganov/llama.cpp for information about how to obtain a `ggml` compatible LLaMA model | ||
|
||
## TTS | ||
|
||
For best experience, this example needs a TTS tool to convert the generated text responses to voice. | ||
You can use any TTS engine that you would like - simply edit the [speak.sh](speak.sh) script to your needs. | ||
By default, it is configured to use MacOS's `say`, but you can use whatever you wish. | ||
|
||
## Discussion | ||
|
||
If you have any feedback, please let "us" know in the following discussion: https://github.com/ggerganov/whisper.cpp/discussions/672?converting=1 |
Oops, something went wrong.