{"id":5990,"library":"livekit-plugins-google","title":"LiveKit Google Cloud Plugins","description":"livekit-plugins-google provides Speech-to-Text (STT) and Text-to-Speech (TTS) capabilities using Google Cloud services for the LiveKit Agent Framework. It enables agents to transcribe audio and generate spoken responses using Google's robust AI models. The current version is 1.5.2, aligning with the `livekit-agents` monorepo's release cadence, which typically sees frequent updates.","status":"active","version":"1.5.2","language":"en","source_language":"en","source_url":"https://github.com/livekit/agents","tags":["livekit","google-cloud","stt","tts","speech-to-text","text-to-speech","agent-framework","ai"],"install":[{"cmd":"pip install livekit-plugins-google","lang":"bash","label":"Install latest version"}],"dependencies":[{"reason":"This package is a plugin for the LiveKit Agent Framework and requires `livekit-agents` as its core dependency.","package":"livekit-agents","optional":false},{"reason":"Requires Python 3.10 or newer.","package":"python","optional":false}],"imports":[{"symbol":"STT","correct":"from livekit.plugins.google import STT"},{"symbol":"TTS","correct":"from livekit.plugins.google import TTS"}],"quickstart":{"code":"import asyncio\nfrom livekit.plugins.google import STT, TTS\n\nasync def main():\n    # Google Cloud authentication is typically handled via environment variables\n    # such as GOOGLE_APPLICATION_CREDENTIALS or gcloud CLI configuration.\n    # Ensure your environment is set up for Google Cloud authentication.\n\n    # Instantiate Google Speech-to-Text\n    try:\n        google_stt = STT()\n        print(f\"Google STT initialized: {google_stt.name}\")\n\n        # Instantiate Google Text-to-Speech\n        google_tts = TTS()\n        print(f\"Google TTS initialized: {google_tts.name}\")\n\n        # Example of using TTS (simplified, in a real agent context it handles audio streams)\n        # Note: This quickstart primarily demonstrates initialization.\n        # Actual usage involves passing audio frames to STT and receiving audio frames from TTS.\n        text_to_speak = \"Hello, this is a test from LiveKit Google TTS.\"\n        # In a real scenario, this would generate an audio iterator\n        # audio_iterator = await google_tts.synthesize(text_to_speak)\n        print(f\"Would synthesize: '{text_to_speak}'\")\n\n    except Exception as e:\n        print(f\"Failed to initialize Google plugins. Ensure Google Cloud SDK is configured and credentials are set: {e}\")\n\nif __name__ == \"__main__\":\n    asyncio.run(main())\n","lang":"python","description":"This quickstart demonstrates how to initialize the Google STT and TTS plugins. It assumes your environment is configured for Google Cloud authentication (e.g., via `GOOGLE_APPLICATION_CREDENTIALS` environment variable or `gcloud auth application-default login`). In a real LiveKit agent, these plugins would be integrated into an Agent instance to process live audio streams."},"warnings":[{"fix":"Set the `GOOGLE_APPLICATION_CREDENTIALS` environment variable or authenticate via `gcloud` CLI. Refer to Google Cloud's authentication documentation.","message":"Authentication for Google Cloud services is crucial. This library relies on the standard `google-cloud-sdk` authentication flow. Ensure `GOOGLE_APPLICATION_CREDENTIALS` is set to a service account key file or `gcloud auth application-default login` has been run.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Always check the `livekit-agents` changelog when updating, and ensure `livekit-plugins-google` is updated to a compatible version. Verify agent code against new API signatures.","message":"This plugin's version is tightly coupled with `livekit-agents`. Major `livekit-agents` updates (e.g., from 0.x to 1.x) may introduce breaking API changes that require corresponding updates to `livekit-plugins-google` and your agent code.","severity":"breaking","affected_versions":"<1.5.0 when upgrading to 1.5.0+"},{"fix":"Regularly review the `livekit-agents` GitHub releases and changelog for any updates relevant to the Google plugins.","message":"The `livekit-agents` ecosystem, including plugins, is under active development. While API stability is a goal, expect rapid iteration and potential for minor API adjustments in patch or minor releases, especially for new features.","severity":"gotcha","affected_versions":"All versions"}],"env_vars":null,"last_verified":"2026-04-14T00:00:00.000Z","next_check":"2026-07-13T00:00:00.000Z"}