The all-in-one voice SDK
Project description
vocode Python SDK
pip install vocode
import asyncio
import signal
from vocode.conversation import Conversation
from vocode.helpers import create_microphone_input_and_speaker_output
from vocode.models.transcriber import DeepgramTranscriberConfig
from vocode.models.agent import LLMAgentConfig
from vocode.models.synthesizer import AzureSynthesizerConfig
if __name__ == "__main__":
microphone_input, speaker_output = create_microphone_input_and_speaker_output(use_first_available_device=True)
conversation = Conversation(
input_device=microphone_input,
output_device=speaker_output,
transcriber_config=DeepgramTranscriberConfig.from_input_device(microphone_input),
agent_config=LLMAgentConfig(prompt_preamble="The AI is having a pleasant conversation about life."),
synthesizer_config=AzureSynthesizerConfig.from_output_device(speaker_output)
)
signal.signal(signal.SIGINT, lambda _0, _1: conversation.deactivate())
asyncio.run(conversation.start())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
vocode-0.1.19.tar.gz
(8.7 kB
view details)
Built Distribution
vocode-0.1.19-py3-none-any.whl
(13.1 kB
view details)
File details
Details for the file vocode-0.1.19.tar.gz
.
File metadata
- Download URL: vocode-0.1.19.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.10.9 Darwin/21.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7be0d637dd6a97c312a05d237a1d9bad949717b096304414350f07d82152b8a |
|
MD5 | 24640734a0cea41147d439564c078acc |
|
BLAKE2b-256 | 2a819cd65075446c387305e648e436cada254c010228ef27316182c436191cd5 |
File details
Details for the file vocode-0.1.19-py3-none-any.whl
.
File metadata
- Download URL: vocode-0.1.19-py3-none-any.whl
- Upload date:
- Size: 13.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.10.9 Darwin/21.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c66c07a33dca708c84e5315a91246274e6a8c260cbb7f61abd1309dd73e57e2a |
|
MD5 | 38a1474f1f28246df1112422b921812b |
|
BLAKE2b-256 | fa2fe6be303a46bc0c8924fc6b4033e79e1512b057273ec1b27ce50006cb1636 |