대화형 에이전트(Dialogflow CX) 대화(세션)를 상태 머신으로 설명하고 시각화할 수 있습니다.
세션의 상태는 페이지로 표시됩니다.
각 흐름에 대해 여러 페이지를 정의하면 조합된 페이지에서 흐름이 설계된 주제에 대한 완전한 대화를 처리할 수 있습니다.
특정 시점에 정확히 하나의 페이지는 현재 페이지이고, 현재 페이지는 활성 페이지로 간주되며, 해당 페이지와 연결된 흐름은 활성으로 간주됩니다.
모든 흐름에는 특수한 시작 페이지가 있습니다.
처음에 흐름이 활성화되면 시작 페이지가 현재 페이지가 됩니다.
각 대화 차례에서 현재 페이지는 동일하게 유지되거나 다른 페이지로 전환됩니다.
페이지가 나타내는 대화 상태와 관련된 정보를 최종 사용자로부터 수집하도록 각 페이지를 구성합니다.
예를 들어 아래의 다이어그램에서 피자 배달 에이전트의 음식 주문 흐름을 위한 파란색 페이지를 만들 수 있습니다.
다이어그램의 시작 노드는 음식 주문 흐름의 시작 페이지를 나타냅니다.
흐름이 완료되면 확인 흐름으로 전환됩니다.
페이지의 수명 주기
페이지가 활성화되면 에이전트는 입력 fulfillment, 양식 사전 작성, 상태 핸들러 평가, 양식 매개변수 프롬프트, 최종 사용자에게 응답 메시지 전송, 페이지 변경 또는 반복 루프를 포함하는 여러 단계를 따릅니다.
이 프로세스의 세부정보는 다음과 같습니다.
페이지에 항목 fulfillment가 있으면 호출됩니다.
fulfillment가 제공하는 모든 정적 응답은 응답 큐에 추가됩니다.
부분 응답이 사용 설정된 경우 대화형 에이전트(Dialogflow CX)는 응답 큐를 삭제하고 대기 중인 모든 메시지를 스트리밍 API 호출자의 부분 응답으로 전송합니다.
fulfillment에 웹훅이 있으면 웹훅이 호출되어 큐에 응답을 추가할 수 있습니다. 이러한 추가 응답은 응답 큐의 즉각적인 플러시를 트리거하지 않습니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-09-04(UTC)"],[[["\u003cp\u003eDialogflow CX conversations are structured as state machines, where each state is represented by a page.\u003c/p\u003e\n"],["\u003cp\u003eEach flow in Dialogflow CX can contain multiple pages, and at any given moment, only one page is the active or current page within its flow.\u003c/p\u003e\n"],["\u003cp\u003eThe lifecycle of a page involves entry fulfillment, form pre-filling, state handler evaluation, parameter prompting, sending responses, and potential transitions to other pages.\u003c/p\u003e\n"],["\u003cp\u003ePages collect information from end-users relevant to the current conversational state, using form parameters to capture structured input.\u003c/p\u003e\n"],["\u003cp\u003ePage data includes a display name, entry fulfillment, parameters, routes, route groups, and event handlers, and settings can be accessed and modified through the console or API, allowing for detailed customization.\u003c/p\u003e\n"]]],[],null,["# Pages\n\nA Conversational Agents (Dialogflow CX) conversation (session) can be described and visualized as a\n[state machine](https://en.wikipedia.org/wiki/Finite-state_machine).\nThe states of a session are represented by\n\n*pages*.\n\n\nFor each\n[flow](/dialogflow/cx/docs/concept/flow),\nyou define many pages,\nwhere your combined pages can handle a complete conversation\non the topics the flow is designed for.\nAt any given moment,\nexactly one page is the *current page* ,\nthe current page is considered *active* ,\nand the flow associated with that page is considered *active* .\nEvery flow has a special\n[start page](/dialogflow/cx/docs/concept/flow#start-page).\nWhen a flow initially becomes active,\nthe start page becomes the current page.\nFor each conversational turn,\nthe current page will either stay the same or transition to another page.\n\nYou configure each page to collect information\nfrom the end-user that is relevant\nfor the conversational state represented by the page.\nFor example, you might create the pages (in blue) in the diagram below\nfor a *Food Order* flow of a pizza delivery agent.\nThe *Start* node of the diagram\nrepresents the start page of the *Food Order* flow.\nWhen the flow is complete, it transitions to the *Confirmation* flow.\n\nLifecycle of a page\n-------------------\n\nOnce a page becomes active,\nthe agent follows several steps which may involve\nentry fulfillment, prefilling forms, state handler evaluation,\nform parameter prompting, sending response messages to the end-user,\nand either a page change or a repeat loop:\n\nThe details of this process are as follows:\n\n1. If entry\n [fulfillment](/dialogflow/cx/docs/concept/fulfillment)\n exists for the page, it is called.\n Any static responses provided by fulfillment are added to the\n [response queue](/dialogflow/cx/docs/concept/fulfillment#queue).\n\n If [partial response](/dialogflow/cx/docs/concept/fulfillment#partial-response)\n is enabled, Conversational Agents (Dialogflow CX) flushes the *response queue* and sends all queued\n messages as a partial response to the streaming API caller.\n\n If the fulfillment has a webhook, the webhook is called, which may append\n additional responses to the queue. These additional responses do not\n trigger an immediate flush of the *response queue*.\n2. If the page has form parameters, they may be pre-filled:\n\n - Any set [session parameter](/dialogflow/cx/docs/concept/parameter#session) with the same name as a [form parameter](/dialogflow/cx/docs/concept/parameter#form) is copied to the form parameter.\n - If a [route](/dialogflow/cx/docs/concept/handler#route) triggered a transition to this page, and the route contains a matched [intent](/dialogflow/cx/docs/concept/intent), any intent parameter with the same name as a [form parameter](/dialogflow/cx/docs/concept/parameter#form) is copied to the form parameter.\n3. If any state handlers are\n [in scope](/dialogflow/cx/docs/concept/handler#scope),\n they are evaluated according to the\n [handler evaluation order rules](/dialogflow/cx/docs/concept/handler#eval).\n This can involve routes, event handlers,\n or reprompt handlers invoked from the prior loop iteration.\n If any state handler is called,\n one or both of the following may happen:\n\n - If fulfillment exists for the handler, it is called. Any static responses provided by fulfillment are added to the [response queue](/dialogflow/cx/docs/concept/fulfillment#queue). Partial response and webhook are also executed if they are enabled.\n - If a target flow or page exists for the handler, the session transitions to the target and the page becomes inactive.\n4. If all of the following are true,\n a form parameter prompt is added to the response queue:\n\n - The page has a form.\n - There are required form parameters left to fill.\n - A [reprompt handler](/dialogflow/cx/docs/concept/parameter#reprompt) was not followed in step 3.\n - Partial response and webhook are executed if they are enabled.\n5. The remaining response queue messages are sent to the end-user,\n and the agent waits for end-user input.\n\n6. If end-user input provides a prompted form parameter,\n fill the parameter.\n Continue to step 3.\n\nPage lifecycle navigation\n-------------------------\n\nThe [simulator](/dialogflow/cx/docs/concept/console#simulator) execution steps\nviewer allows you to switch between the steps for a specific conversation turn\nand brings the related agent builder elements into focus for each step. In the\nfollowing example, end-user input \"I would like to rent a car\" triggers five\nexecution and transition steps:\n\n1. The executions steps viewer brings you to conversation starting page\n for the first step. In this case it's the default start page.\n\n2. Transition route for the intent `car_rental.reservation_create` is triggered.\n The executions steps viewer brings this route to focus, where you can see\n that the transition target is the `Pickup Location` page.\n\n3. Agent enters page `Pickup Location`.\n\n4. Agent evaluates the entry fulfillment of `Pickup Location` page. The\n fulfillment is empty, so nothing happens.\n\n5. Agent tries to collect the required form parameter `pickup_location` and\n the initial prompt fulfillment message for this parameter is shown to the\n end-user.\n\nYou can also undo the last utterance and try something else to test different\npage transitions.\n\nCreate a page\n-------------\n\n| **Note:** A page will not appear on the console graph until transitions have been created with a target set to the page.\n\nTo create a page: \n\n### Console\n\n1. Open the [Dialogflow CX console](https://dialogflow.cloud.google.com/cx/projects).\n2. Choose your Google Cloud project.\n3. Select your agent.\n4. Select a flow for the page in the **Flows** section.\n5. Click the add *add* button in the **Pages** section.\n6. Enter a display name for your page.\n7. Click the settings *more_vert* button next to the page display name.\n8. Select **Edit**.\n9. Enter the fields in the page edit panel that appears.\n10. Click **Save**.\n\n### API\n\nSee the `create` method for the `Page` type.\n\n\nGo to the Page API reference \n**Select a protocol and version for the Page reference:**\n\nClose\n\n\u003cbr /\u003e\n\nPage data\n---------\n\nTo access a page's data: \n\n### Console\n\n1. Open the [Dialogflow CX console](https://dialogflow.cloud.google.com/cx/projects).\n2. Choose the Google Cloud project for the agent.\n3. Select your agent.\n4. Click the flow in the **Flows** section.\n5. The flow's pages are populated in the **Pages** section.\n6. Click the settings *more_vert* button next to the page display name.\n7. Select **Edit**.\n8. Enter the fields in the page edit panel that appears.\n9. Click **Save** to save any changes.\n\n### API\n\nSee the `get` and `patch/update` methods for the `Page` type.\n\n\nGo to the Page API reference \n**Select a protocol and version for the Page reference:**\n\nClose\n\n\u003cbr /\u003e\n\nThe following data is associated with pages:\n\n- **Display name**: A human-readable name for your page.\n- **Entry fulfillment** (also known as **Entry dialogue** ): This is the [fulfillment](/dialogflow/cx/docs/concept/fulfillment) to call when the page initially becomes active.\n- **Parameters** : These are the parameter values in a page [form](/dialogflow/cx/docs/concept/parameter#form) that capture structured input from the end-user.\n- **Routes** : These state handlers may be called when the page is active. For details, see [Page-level handler routes](/dialogflow/cx/docs/concept/handler#route-page)\n- **Route groups** : The routes within these groups may be called when the page is active. For details, see [Route groups](/dialogflow/cx/docs/concept/handler#route-group)\n- **Event handlers** : These event handlers may be called when the page is active. For details, see [Page-level event handlers](/dialogflow/cx/docs/concept/handler#event-page)\n\nPage settings\n-------------\n\nThe following settings are available for pages:\n\n- **Advanced speech settings** :\n These [advanced speech settings](/dialogflow/cx/docs/concept/advanced-speech)\n can optionally override the same\n [flow speech settings](/dialogflow/cx/docs/concept/flow#settings)\n and\n [agent speech settings](/dialogflow/cx/docs/concept/agent-settings#settings-speech).\n\n- **Speech adaptation settings** :\n Page level speech adaptation settings can optionally override the same\n [flow speech adaptation settings](/dialogflow/cx/docs/concept/flow#settings).\n More detailed instructions in\n [manual speech adaptation](/dialogflow/cx/docs/concept/speech-adaptation#manual-adaptation).\n\nTo access page settings: \n\n### Console\n\n1. Open the [Dialogflow CX console](https://dialogflow.cloud.google.com/cx/projects).\n2. Choose your Google Cloud project.\n3. Select your agent.\n4. Hover your mouse over the page in the **Pages** section.\n5. Click the options *more_vert* button.\n6. Select **Page settings**.\n7. Browse or edit settings.\n8. Click **Save** to save any changes.\n\n### API\n\nSee the `get` and `patch/update` methods for the `Page` type.\n\n\nGo to the Page API reference \n**Select a protocol and version for the Page reference:**\n\nClose\n\n\u003cbr /\u003e\n\nDelete a page\n-------------\n\nTo delete a page: \n\n### Console\n\n1. Open the [Dialogflow CX console](https://dialogflow.cloud.google.com/cx/projects).\n2. Choose your Google Cloud project.\n3. Select your agent.\n4. Select the flow for the page in the **Flows** section.\n5. Click the settings *more_vert* button next to the page display name in the **Pages** section.\n6. Select **Delete**.\n\n### API\n\nSee the `delete` method for the `Page` type.\n\n\nGo to the Page API reference \n**Select a protocol and version for the Page reference:**\n\nClose\n\n\u003cbr /\u003e"]]