
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@pipecat-ai/gemini-live-websocket-transport
Advanced tools
Pipecat Gemini Multimodal Live Transport Package
A real-time websocket transport implementation for interacting with Google's Gemini Multimodal Live API, supporting bidirectional audio and unidirectional text communication.
npm install \
@pipecat-ai/client-js \
@pipecat-ai/real-time-websocket-transport \
@pipecat-ai/gemini-live-websocket-transport
The GeminiLiveWebsocketTransport
class extends the DirectToLLMBaseWebSocketTransport
to implement a fully functional Pipecat Transport
. It provides a framework for implementing real-time communication directly with the Gemini Multimodal Live voice-to-voice service. It handles media device management, audio/video streams, and state management for the connection.
import { GeminiLiveWebsocketTransport, GeminiLLMServiceOptions } from '@pipecat-ai/gemini-live-websocket-transport';
const options: GeminiLLMServiceOptions = {
api_key: 'YOUR_API_KEY',
generation_config: {
temperature: 0.7,
maxOutput_tokens: 1000
}
};
let pcConfig: PipecatClientOptions = {
transport: new GeminiLiveWebsocketTransport(options),
...
};
interface GeminiLLMServiceOptions {
api_key: string; // Required: Your Gemini API key
initial_messages?: Array<{ // Optional: Initial conversation context
content: string;
role: string;
}>;
generation_config?: { // Optional: Generation parameters
candidate_count?: number;
maxOutput_tokens?: number;
temperature?: number;
top_p?: number;
top_k?: number;
presence_penalty?: number;
frequency_penalty?: number;
response_modalities?: string;
speech_config?: {
voice_config?: {
prebuilt_voice_config?: {
voice_name: "Puck" | "Charon" | "Kore" | "Fenrir" | "Aoede";
};
};
};
};
}
// at setup time...
pcClient.appendToContext({ role: "user", content: 'Hello Gemini!' });
The transport implements the various Pipecat event handlers. Check out the docs or samples for more info.
initialize()
: Set up the transport and establish connectionsendMessage(message)
: Send a text messagehandleUserAudioStream(data)
: Stream audio data to the modeldisconnectLLM()
: Close the connectionsendReadyMessage()
: Signal ready stateThe transport can be in one of the following states:
The transport includes comprehensive error handling for:
BSD-2 Clause
FAQs
Pipecat Gemini Multimodal Live Transport Package
We found that @pipecat-ai/gemini-live-websocket-transport demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 7 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.