Reference documentation and code samples for the Google Cloud Dialogflow V2 Client class QueryGenerationDebugInfo.
Token usage metadata for query generation.
Generated from protobuf message google.cloud.dialogflow.v2.KnowledgeAssistDebugInfo.QueryGenerationDebugInfo
Namespace
Google \ Cloud \ Dialogflow \ V2 \ KnowledgeAssistDebugInfoMethods
__construct
Constructor.
| Parameters | |
|---|---|
| Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ prompt_token_count |
int
The total number of tokens in the prompt. |
↳ candidates_token_count |
int
The total number of tokens in the generated candidates. |
↳ total_token_count |
int
The total number of tokens for the entire request. |
getPromptTokenCount
The total number of tokens in the prompt.
| Returns | |
|---|---|
| Type | Description |
int |
|
setPromptTokenCount
The total number of tokens in the prompt.
| Parameter | |
|---|---|
| Name | Description |
var |
int
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getCandidatesTokenCount
The total number of tokens in the generated candidates.
| Returns | |
|---|---|
| Type | Description |
int |
|
setCandidatesTokenCount
The total number of tokens in the generated candidates.
| Parameter | |
|---|---|
| Name | Description |
var |
int
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getTotalTokenCount
The total number of tokens for the entire request.
| Returns | |
|---|---|
| Type | Description |
int |
|
setTotalTokenCount
The total number of tokens for the entire request.
| Parameter | |
|---|---|
| Name | Description |
var |
int
|
| Returns | |
|---|---|
| Type | Description |
$this |
|