프로젝트가 어시스턴트와 상호작용하는 방식을 맞춤설정합니다. 예를 들어 오디오를 재생할 때 버튼을 눌러 어시스턴트를 트리거하거나 LED를 깜박입니다. 어시스턴트의 음성 인식 스크립트를 디스플레이에 표시할 수도 있습니다.
기기 작업으로 프로젝트를 제어합니다.
예를 들어 어시스턴트가 내장된 램프에 밝기를 켜고 변경해 달라고 요청할 수 있습니다.
프로젝트가 어시스턴트와 상호작용하는 방식 맞춤설정
어시스턴트 트리거
Google 어시스턴트 라이브러리를 사용하면 Ok Google과 같은 핫워드를 말하여 어시스턴트 요청을 트리거합니다. 마이크를 음소거하여 어시스턴트가 핫워드를 듣지 않도록 할 수 있습니다. set_mic_mute()를 사용하여 이를 제어합니다. 자체 맞춤 이벤트를 기반으로 start_conversation() 메서드를 트리거합니다.
사용자 요청의 스크립트 가져오기
Google 어시스턴트 SDK는 사용자 요청의 텍스트 스크립트를 제공합니다. 이 기능을 사용하면 텍스트를 디스플레이에 렌더링하거나 기기에서 로컬 작업을 실행하는 등 좀 더 창의적인 작업을 통해 사용자에게 피드백을 제공할 수 있습니다.
[null,null,["최종 업데이트: 2025-07-26(UTC)"],[[["\u003cp\u003eThe Google Assistant Library for Python is deprecated and developers should utilize the Google Assistant Service instead.\u003c/p\u003e\n"],["\u003cp\u003eCustomize Assistant interaction by triggering requests with custom events (e.g., button press) and displaying speech transcripts.\u003c/p\u003e\n"],["\u003cp\u003eControl your project using Device Actions, enabling voice control for functionalities like adjusting brightness.\u003c/p\u003e\n"],["\u003cp\u003eThe library provides methods for microphone control (\u003ccode\u003eset_mic_mute\u003c/code\u003e) and initiating conversations (\u003ccode\u003estart_conversation\u003c/code\u003e).\u003c/p\u003e\n"],["\u003cp\u003eAccess user request transcripts via the \u003ccode\u003eON_RECOGNIZING_SPEECH_FINISHED\u003c/code\u003e event for feedback or custom actions.\u003c/p\u003e\n"]]],[],null,["# Next Steps\n\n| **Warning:** The Google Assistant Library for Python is deprecated as of June 28th, 2019. Use the [Google Assistant Service](/assistant/sdk/guides/service/python) instead.\n\n\u003cbr /\u003e\n\nOnce you have the Google Assistant running on your project, give these a try:\n\n1. [Customize](#custom-interaction) how your project interacts with the\n Assistant. For example, trigger the Assistant with the push of a button or\n blink an LED when playing back audio. You can even show a speech recognition\n transcript from the Assistant on a display.\n\n2. [Control](#device-control) your project with Device Actions.\n For example, ask your lamp, with the Assistant built-in, to turn on and\n change its brightness.\n\nCustomize how your project interacts with the Assistant\n-------------------------------------------------------\n\n### Trigger the Assistant\n\nWith the Google Assistant Library, you trigger an Assistant request by speaking\na hotword like *Ok Google* . You can mute the microphone to stop the Assistant\nfrom listening for the hotword. Use the [`set_mic_mute()`](/assistant/sdk/reference/library/python#google.assistant.library.Assistant.set_mic_mute)\nto control this. Trigger the [`start_conversation()`](/assistant/sdk/reference/library/python#google.assistant.library.Assistant.start_conversation)\nmethod based on your own custom event.\n\n### Get the transcript of the user request\n\nThe Google Assistant SDK gives you a text transcript of the user request. Use\nthis to provide feedback to the user by rendering the text to a display, or even\nfor something more creative such as performing some local actions on the device.\n\nThe transcript is located in a Python string object in the [`ON_RECOGNIZING_SPEECH_FINISHED`](/assistant/sdk/reference/library/python#google.assistant.library.event.EventType.ON_RECOGNIZING_SPEECH_FINISHED)\nevent.\n\nControl your project with Device Actions\n----------------------------------------\n\nYou can add Device Actions to the Assistant that allow you to control your\ndevice via voice. [Extend](/assistant/sdk/guides/library/python/extend/install-hardware)\nthe Google Assistant Library sample to include [Device Actions](/assistant/sdk/device-actions-overview)."]]