Оптимизируйте свои подборки Сохраняйте и классифицируйте контент в соответствии со своими настройками.
Служба Google Assistant дает вам полный контроль над интеграцией с Assistant, предоставляя конечную точку потоковой передачи. Передавайте аудиозапрос пользователя на эту конечную точку, чтобы получить аудиоответ Google Assistant.
Вы можете создавать привязки для этого API на различных языках (например, Go, Node.js, C++ и Java) на всех платформах, поддерживаемых gRPC .
Основные требования к оборудованию
Прежде чем начать, вам потребуются следующие компоненты:
Устройство, работающее на одной из поддерживаемых платформ и имеющее подключение к Интернету.
Микрофон
Спикер
Шаги
Следующие разделы применимы к Python и Raspberry Pi.
Если вы не хотите использовать Python, воспользуйтесь руководством по интеграции , чтобы интегрировать службу Google Assistant на других языках и на разных платформах.
Встроить Google Ассистента
В этом разделе представлен пример службы Google Assistant, работающий на вашем устройстве:
[[["Прост для понимания","easyToUnderstand","thumb-up"],["Помог мне решить мою проблему","solvedMyProblem","thumb-up"],["Другое","otherUp","thumb-up"]],[["Отсутствует нужная мне информация","missingTheInformationINeed","thumb-down"],["Слишком сложен/слишком много шагов","tooComplicatedTooManySteps","thumb-down"],["Устарел","outOfDate","thumb-down"],["Проблема с переводом текста","translationIssue","thumb-down"],["Проблемы образцов/кода","samplesCodeIssue","thumb-down"],["Другое","otherDown","thumb-down"]],["Последнее обновление: 2024-09-24 UTC."],[[["\u003cp\u003eThe Google Assistant Service provides a streaming endpoint for integrating the Assistant into your devices for experimental and non-commercial use.\u003c/p\u003e\n"],["\u003cp\u003eYou need a device with internet, microphone, and speaker to get started with the Google Assistant Service integration.\u003c/p\u003e\n"],["\u003cp\u003eThe guide provides step-by-step instructions for embedding and extending the Google Assistant using Python on a Raspberry Pi.\u003c/p\u003e\n"],["\u003cp\u003eYou can find resources for integrating with other languages and platforms using the provided integration guide.\u003c/p\u003e\n"],["\u003cp\u003eThe Google Assistant SDK cannot be used for commercial devices.\u003c/p\u003e\n"]]],["The Google Assistant Service provides a streaming endpoint for integrating with the Assistant, accepting user audio queries and returning audio responses. It supports multiple languages and platforms. Core actions include setting up hardware (device, microphone, speaker), configuring audio and developer accounts, registering a device model, installing the SDK and sample code, and running the sample. The service can also be extended to handle device actions by installing hardware, registering traits, and handling commands. Commercial use is prohibited.\n"],null,["# Introduction to the Google Assistant Service\n\n| **Warning:** You can't launch commercial devices that integrate with the Google Assistant SDK. It's available for experimental and non-commercial uses only.\n\n\u003cbr /\u003e\n\nThe Google Assistant Service gives you full control over the integration with\nthe Assistant by providing a streaming endpoint. Stream a user audio query to\nthis endpoint to receive a Google Assistant audio response.\n\nYou can generate bindings for this API from a variety of languages (for example,\nGo, Node.js, C++, and Java) on all platforms supported by [gRPC](http://www.grpc.io/about/#osp).\n\nBasic hardware requirements\n---------------------------\n\nBefore you begin, you'll need the following components:\n\n- A device running on one of the supported platforms, with internet connectivity\n- A microphone\n- A speaker\n\nSteps\n-----\n\nThe following sections are applicable to Python and the Raspberry Pi.\n\nIf you do not want to use Python, use the [integration guide](/assistant/sdk/guides/service/integrate#other-languages)\nto integrate the Google Assistant Service in other languages and on different\nplatforms.\n\n### Embed the Google Assistant\n\nThis section gets the Google Assistant Service sample working on your device:\n\n1. [Set Up Hardware and Network Access](/assistant/sdk/guides/service/python/embed/setup)\n2. [Configure and Test the Audio](/assistant/sdk/guides/service/python/embed/audio)\n3. [Configure a Developer Project and Account Settings](/assistant/sdk/guides/service/python/embed/config-dev-project-and-account)\n4. [Register the Device Model](/assistant/sdk/guides/service/python/embed/register-device)\n5. [Install the SDK and Sample Code](/assistant/sdk/guides/service/python/embed/install-sample)\n6. [Run the Sample Code](/assistant/sdk/guides/service/python/embed/run-sample)\n7. [Next Steps](/assistant/sdk/guides/service/python/embed/next-steps)\n\n### Extend the Google Assistant\n\nThis section extends the Google Assistant Service sample to include\n[Device Actions](/assistant/sdk/device-actions-overview):\n\n1. [Install Hardware](/assistant/sdk/guides/service/python/extend/install-hardware)\n2. [Register Traits](/assistant/sdk/guides/service/python/extend/register-device-traits)\n3. [Handle Commands](/assistant/sdk/guides/service/python/extend/handle-device-commands)\n4. [Add More Traits and Handlers](/assistant/sdk/guides/service/python/extend/add-trait-and-handler)\n5. [Register Custom Device Actions](/assistant/sdk/guides/service/python/extend/custom-actions)"]]