-
Notifications
You must be signed in to change notification settings - Fork 598
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add Agent Assist Summarization API (https://cloud.google.com/ag…
…ent-assist/docs/summarization) (#1002) * fix: revert removal of LRO mixin PiperOrigin-RevId: 476177109 Source-Link: googleapis/googleapis@652c4c1 Source-Link: googleapis/googleapis-gen@92d0bfe Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiOTJkMGJmZTI0MDZlODI4NWNkNDE2MjU0ZGY0NWQ4MmZlYWM2ODc5ZiJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore: override API mixins when needed PiperOrigin-RevId: 477248447 Source-Link: googleapis/googleapis@4689c73 Source-Link: googleapis/googleapis-gen@c405978 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYzQwNTk3ODZhNWNkODA1YTAxNTFkOTViNDc3ZmJjNDg2YmNiY2VkYyJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * feat: Add Agent Assist Summarization API (https://cloud.google.com/agent-assist/docs/summarization) docs: clarify SuggestionFeature enums which are specific to chat agents PiperOrigin-RevId: 477479918 Source-Link: googleapis/googleapis@6deca98 Source-Link: googleapis/googleapis-gen@b23d242 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYjIzZDI0MmM1YzVkZWI3Y2U2ZjRhN2Y3MTg2MmEzMTE1NTUwNjliZCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix: applied owl-bot transformations manually * fix: lint * fix: revert some changes * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Alexander Fenster <[email protected]>
- Loading branch information
1 parent
89d1fd4
commit eb5830e
Showing
49 changed files
with
12,482 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
77 changes: 77 additions & 0 deletions
77
...-cloud-dialogflow/samples/generated/v2beta1/conversations.suggest_conversation_summary.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
// Copyright 2022 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
// | ||
// ** This file is automatically generated by gapic-generator-typescript. ** | ||
// ** https://github.com/googleapis/gapic-generator-typescript ** | ||
// ** All changes to this file may be overwritten. ** | ||
|
||
|
||
|
||
'use strict'; | ||
|
||
function main(conversation) { | ||
// [START dialogflow_v2beta1_generated_Conversations_SuggestConversationSummary_async] | ||
/** | ||
* This snippet has been automatically generated and should be regarded as a code template only. | ||
* It will require modifications to work. | ||
* It may require correct/in-range values for request initialization. | ||
* TODO(developer): Uncomment these variables before running the sample. | ||
*/ | ||
/** | ||
* Required. The conversation to fetch suggestion for. | ||
* Format: `projects/<Project ID>/locations/<Location | ||
* ID>/conversations/<Conversation ID>`. | ||
*/ | ||
// const conversation = 'abc123' | ||
/** | ||
* The name of the latest conversation message used as context for | ||
* compiling suggestion. If empty, the latest message of the conversation will | ||
* be used. | ||
* Format: `projects/<Project ID>/locations/<Location | ||
* ID>/conversations/<Conversation ID>/messages/<Message ID>`. | ||
*/ | ||
// const latestMessage = 'abc123' | ||
/** | ||
* Max number of messages prior to and including | ||
* latest_message to use as context when compiling the | ||
* suggestion. By default 500 and at most 1000. | ||
*/ | ||
// const contextSize = 1234 | ||
|
||
// Imports the Dialogflow library | ||
const {ConversationsClient} = require('@google-cloud/dialogflow').v2beta1; | ||
|
||
// Instantiates a client | ||
const dialogflowClient = new ConversationsClient(); | ||
|
||
async function callSuggestConversationSummary() { | ||
// Construct request | ||
const request = { | ||
conversation, | ||
}; | ||
|
||
// Run request | ||
const response = await dialogflowClient.suggestConversationSummary(request); | ||
console.log(response); | ||
} | ||
|
||
callSuggestConversationSummary(); | ||
// [END dialogflow_v2beta1_generated_Conversations_SuggestConversationSummary_async] | ||
} | ||
|
||
process.on('unhandledRejection', err => { | ||
console.error(err.message); | ||
process.exitCode = 1; | ||
}); | ||
main(...process.argv.slice(2)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.