대화형 작업이 2023년 6월 13일에 지원 중단되었습니다. 자세한 내용은
대화 작업 지원 중단을 참고하세요.
Method: projects.matchIntents
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
HTTP 요청
POST https://actions.googleapis.com/v2/{project=projects/*}:matchIntents
URL은 gRPC 트랜스코딩 문법을 사용합니다.
경로 매개변수
매개변수 |
project |
string
필수 항목입니다. 테스트 중인 프로젝트로, 프로젝트 ID로 표시됩니다. 형식: projects/{project}
|
요청 본문
요청 본문에는 다음과 같은 구조의 데이터가 포함됩니다.
JSON 표현 |
{
"query": string,
"locale": string
} |
필드 |
query |
string
필수 항목입니다. 일반 텍스트로 된 사용자 쿼리.
|
locale |
string
필수 항목입니다. 쿼리를 평가하는 데 사용할 언어입니다(예: 'en'). 형식은 BCP 47(https://tools.ietf.org/html/bcp47)을 따라야 합니다. https://developers.google.com/assistant/console/languages-locales에서 지원되는 언어 목록을 참고하세요.
|
응답 본문
성공할 경우 응답 본문에 다음 구조의 데이터가 포함됩니다.
JSON 표현 |
{
"matchedIntents": [
{
object (Intent )
}
]
} |
필드 |
matchedIntents[] |
object (Intent )
일치하는 인텐트로, 관련성이 가장 높은 것부터 순서대로 정렬됩니다. 처음 50개의 일치하는 항목만 반환됩니다.
|
인텐트
JSON 표현 |
{
"name": string,
"params": {
string: {
object (IntentParameterValue )
},
...
},
"query": string
} |
필드 |
name |
string
필수 항목입니다. 마지막으로 일치된 인텐트의 이름입니다.
|
params |
map (key: string, value: object (IntentParameterValue ))
필수 항목입니다. 인텐트 일치의 일부로 식별된 매개변수를 나타냅니다. 식별된 매개변수의 이름을 사용자 입력에서 식별된 매개변수의 값에 매핑한 것입니다. 식별된 일치하는 인텐트에서 정의된 모든 매개변수가 여기에 나타납니다. "key": value 쌍 목록을 포함하는 객체입니다. 예: { "name": "wrench", "mass": "1.3kg", "count": "3" }
|
query |
string
선택사항입니다. 이 인텐트와 일치하는 최종 사용자의 입력 또는 음성 입력입니다. 이 필드는 사용자 입력에 따라 인텐트가 일치될 때 채워집니다.
|
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2024-08-22(UTC)
[[["이해하기 쉬움","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-08-22(UTC)"],[[["Finds the intents that match a given user query, returning the top 50 matches ranked by relevance."],["Requires a `POST` request to the specified endpoint, including the project ID and user query."],["The request body must contain the user query as plain text and the locale for evaluation."],["The response includes a list of matched intents, each with its name, parameters, and the original query."],["Each intent object provides details like the intent name, identified parameters, and the portion of the user input that triggered the match."]]],["This document details the process of matching user queries to intents via a `POST` request to `https://actions.googleapis.com/v2/{project=projects/*}:matchIntents`. The request requires a `project` path parameter, a JSON body with `query` and `locale` strings. The response returns a JSON object with `matchedIntents`, an array of matched intents, each with `name`, `params` (parameter name-value pairs), and `query` fields. Only the first 50 matching intents are returned, ordered from most to least relevant.\n"]]