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.20.tar.gz
(8.9 kB
view details)
Built Distribution
vocode-0.1.20-py3-none-any.whl
(13.6 kB
view details)
File details
Details for the file vocode-0.1.20.tar.gz
.
File metadata
- Download URL: vocode-0.1.20.tar.gz
- Upload date:
- Size: 8.9 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 | ca550766e4c8daf713cc5caf49d72101a7a9c60c625e34dd44806ea6b2d1e3f5 |
|
MD5 | 2c255cfa6cf2d7f7aebab661d59cf339 |
|
BLAKE2b-256 | 4382ab3b4b169125f4deab85e1ae3bbb4a295ddaa9eb8c2cfa5f9dc01ddc8506 |
File details
Details for the file vocode-0.1.20-py3-none-any.whl
.
File metadata
- Download URL: vocode-0.1.20-py3-none-any.whl
- Upload date:
- Size: 13.6 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 | e66a986d5f7618f2aeeac5834ef94052317be8ac141ef3f23e8f419fa14ed1ab |
|
MD5 | 98260366ae7d48ea060e599e09686fce |
|
BLAKE2b-256 | 1fb9199becface5578e85adbc578048f8abc2029090dbe420fbb434e573548b3 |