From b9a342794f2594033c5a48b8323610f30eedd527 Mon Sep 17 00:00:00 2001 From: Kevin Kowalski Date: Thu, 9 Sep 2021 01:28:31 -0500 Subject: [PATCH] feat(assistant-v2): add SEARCH as a type of the message to MessageInput & MessageInputStateless --- .../assistant/v2/model/MessageInput.java | 22 ++++++++++++++++--- .../v2/model/MessageInputStateless.java | 22 ++++++++++++++++--- 2 files changed, 38 insertions(+), 6 deletions(-) diff --git a/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInput.java b/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInput.java index 28733a06e32..0172938a5b7 100644 --- a/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInput.java +++ b/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInput.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2018, 2020. + * (C) Copyright IBM Corp. 2021. * * 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 @@ -20,10 +20,20 @@ /** An input object that includes the input text. */ public class MessageInput extends GenericModel { - /** The type of user input. Currently, only text input is supported. */ + /** + * The type of the message: + * + *

- `text`: The user input is processed normally by the assistant. - `search`: Only search + * results are returned. (Any dialog or actions skill is bypassed.) + * + *

**Note:** A `search` message results in an error if no search skill is configured for the + * assistant. + */ public interface MessageType { /** text. */ String TEXT = "text"; + /** search. */ + String SEARCH = "search"; } @SerializedName("message_type") @@ -186,7 +196,13 @@ public Builder newBuilder() { /** * Gets the messageType. * - *

The type of user input. Currently, only text input is supported. + *

The type of the message: + * + *

- `text`: The user input is processed normally by the assistant. - `search`: Only search + * results are returned. (Any dialog or actions skill is bypassed.) + * + *

**Note:** A `search` message results in an error if no search skill is configured for the + * assistant. * * @return the messageType */ diff --git a/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInputStateless.java b/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInputStateless.java index 5789a7629d2..f287e35a245 100644 --- a/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInputStateless.java +++ b/assistant/src/main/java/com/ibm/watson/assistant/v2/model/MessageInputStateless.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2020. + * (C) Copyright IBM Corp. 2021. * * 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 @@ -20,10 +20,20 @@ /** An input object that includes the input text. */ public class MessageInputStateless extends GenericModel { - /** The type of user input. Currently, only text input is supported. */ + /** + * The type of the message: + * + *

- `text`: The user input is processed normally by the assistant. - `search`: Only search + * results are returned. (Any dialog or actions skill is bypassed.) + * + *

**Note:** A `search` message results in an error if no search skill is configured for the + * assistant. + */ public interface MessageType { /** text. */ String TEXT = "text"; + /** search. */ + String SEARCH = "search"; } @SerializedName("message_type") @@ -186,7 +196,13 @@ public Builder newBuilder() { /** * Gets the messageType. * - *

The type of user input. Currently, only text input is supported. + *

The type of the message: + * + *

- `text`: The user input is processed normally by the assistant. - `search`: Only search + * results are returned. (Any dialog or actions skill is bypassed.) + * + *

**Note:** A `search` message results in an error if no search skill is configured for the + * assistant. * * @return the messageType */