Pipecat video avatar service for Protoface.
Project description
Protoface Pipecat Plugin
Add Protoface video avatars to Pipecat pipelines.
Maintained by Protoface.
Installation
pip install pipecat-protoface
Or with uv:
uv add pipecat-protoface
Install the Pipecat extras required by your application separately, such as the transport, LLM, STT, or TTS services in your pipeline.
For this repo's WebRTC example:
uv sync --extra dev --extra example
If you prefer pip:
pip install -e ".[dev,example]"
Prerequisites
- Protoface API key (
PROTOFACE_API_KEY) - Protoface avatar ID (
PROTOFACE_AVATAR_ID) - API keys for the Pipecat services used by your pipeline
Usage
ProtofaceVideoService starts a hosted Protoface avatar session. It consumes
TTSAudioRawFrame audio from a Pipecat pipeline and emits synchronized
SpeechOutputAudioRawFrame and OutputImageRawFrame frames downstream.
Your application still chooses the Pipecat transport for the end user.
import os
from pipecat_protoface import ProtofaceVideoService
protoface = ProtofaceVideoService(
api_key=os.environ["PROTOFACE_API_KEY"],
avatar_id=os.environ["PROTOFACE_AVATAR_ID"],
)
pipeline = Pipeline([
transport.input(),
stt,
context_aggregator.user(),
llm,
tts,
protoface, # Video avatar (returns synchronized audio/video)
transport.output(),
context_aggregator.assistant(),
])
For realtime speech-to-speech services, place ProtofaceVideoService after your
realtime LLM service and before the output transport:
pipeline = Pipeline([
transport.input(),
gemini_live,
protoface,
transport.output(),
])
See examples/video_service.py for a complete WebRTC example using Gemini Live.
Session Startup
ProtofaceVideoService starts a hosted Protoface avatar session when the
pipeline starts. Audio produced before the avatar session is ready is buffered,
then streamed once the connection is available.
Running the Example
- Install dependencies:
uv sync --extra dev --extra example
- Set up your environment:
cp env.example .env
# Edit .env with your keys:
# PROTOFACE_API_KEY
# PROTOFACE_AVATAR_ID
# GOOGLE_API_KEY or GEMINI_API_KEY
#
# GEMINI_LIVE_MODEL and GEMINI_VOICE are optional.
- Run the
ProtofaceVideoServiceexample with the built-in WebRTC transport:
uv run python examples/video_service.py -t webrtc
The example reads either GOOGLE_API_KEY or GEMINI_API_KEY.
By default, the plugin connects to https://api.protoface.com; set
PROTOFACE_API_URL only when testing against another Protoface environment.
Set PROTOFACE_DEBUG_MEDIA=1 to log avatar audio/video frame counts during
local testing.
Compatibility
- Pipecat v1.4.0+
- Python 3.11+
- Built-in WebRTC transport for the included example
License
Apache-2.0 - see LICENSE
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pipecat_protoface-0.1.0.tar.gz.
File metadata
- Download URL: pipecat_protoface-0.1.0.tar.gz
- Upload date:
- Size: 22.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
aefd015a3b3f0e7cbbd63e1cb98b39cf3888f47ea5f9e8884ebe0b28f0bc490a
|
|
| MD5 |
90b73a1b4c12af5d0456fc35ad262823
|
|
| BLAKE2b-256 |
a21fdb6a512a29c7453c5d55f23118a50d9efd53cbdc6a30afe782c553a91b3f
|
Provenance
The following attestation bundles were made for pipecat_protoface-0.1.0.tar.gz:
Publisher:
release.yml on protoface-ai/protoface-plugin-pipecat
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pipecat_protoface-0.1.0.tar.gz -
Subject digest:
aefd015a3b3f0e7cbbd63e1cb98b39cf3888f47ea5f9e8884ebe0b28f0bc490a - Sigstore transparency entry: 1973408553
- Sigstore integration time:
-
Permalink:
protoface-ai/protoface-plugin-pipecat@106cc0643d534b16ad09a1ed0305ca84e537be9d -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/protoface-ai
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@106cc0643d534b16ad09a1ed0305ca84e537be9d -
Trigger Event:
release
-
Statement type:
File details
Details for the file pipecat_protoface-0.1.0-py3-none-any.whl.
File metadata
- Download URL: pipecat_protoface-0.1.0-py3-none-any.whl
- Upload date:
- Size: 17.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2cc5ea8a0f43f4fd0cd3eb37b8dc85aff5b4cf9c92c0364d783e9bd68c2acd2c
|
|
| MD5 |
d93299674db7f9c83adb530618556401
|
|
| BLAKE2b-256 |
efe6915501c37579bb340c009a4717cfe469fcec59e7fea745b5ba333622f962
|
Provenance
The following attestation bundles were made for pipecat_protoface-0.1.0-py3-none-any.whl:
Publisher:
release.yml on protoface-ai/protoface-plugin-pipecat
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pipecat_protoface-0.1.0-py3-none-any.whl -
Subject digest:
2cc5ea8a0f43f4fd0cd3eb37b8dc85aff5b4cf9c92c0364d783e9bd68c2acd2c - Sigstore transparency entry: 1973408633
- Sigstore integration time:
-
Permalink:
protoface-ai/protoface-plugin-pipecat@106cc0643d534b16ad09a1ed0305ca84e537be9d -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/protoface-ai
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@106cc0643d534b16ad09a1ed0305ca84e537be9d -
Trigger Event:
release
-
Statement type: