Skip to content

Release 3 2020 #633

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Apr 24, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Examples/ExampleTextToSpeechV1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ void Update()
}
textInput.text = placeholderText;
audioStream = null;
StartListening(); // need to connect because service disconnect websocket after transcribing https://cloud.ibm.com/docs/services/text-to-speech?topic=text-to-speech-usingWebSocket#WSsend
StartListening(); // need to connect because service disconnect websocket after transcribing https://cloud.ibm.com/docs/text-to-speech?topic=text-to-speech-usingWebSocket#WSsend
}
}

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Some services use token-based Identity and Access Management (IAM) authenticatio
You supply either an IAM service **API key** or an **access token**:

- Use the API key to have the SDK manage the lifecycle of the access token. The SDK requests an access token, ensures that the access token is valid, and refreshes it if necessary.
- Use the access token if you want to manage the lifecycle yourself. For details, see [Authenticating with IAM tokens](https://cloud.ibm.com/docs/services/watson?topic=watson-iam). If you want to switch to API key, in a coroutine, override your stored IAM credentials with an IAM API key and yield until the credentials object `HasIamTokenData()` returns `true`.
- Use the access token if you want to manage the lifecycle yourself. For details, see [Authenticating with IAM tokens](https://cloud.ibm.com/docs/watson?topic=watson-iam). If you want to switch to API key, in a coroutine, override your stored IAM credentials with an IAM API key and yield until the credentials object `HasIamTokenData()` returns `true`.

#### Supplying the IAM API key
```cs
Expand Down
8 changes: 4 additions & 4 deletions Scripts/Services/Assistant/V1/AssistantService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1268,7 +1268,7 @@ private void OnListExamplesResponse(RESTConnector.Request req, RESTConnector.Res
///
/// Add a new user input example to an intent.
///
/// If you want to add multiple exaples with a single API call, consider using the **[Update
/// If you want to add multiple examples with a single API call, consider using the **[Update
/// intent](#update-intent)** method instead.
///
/// This operation is limited to 1000 requests per 30 minutes. For more information, see **Rate limiting**.
Expand Down Expand Up @@ -3720,7 +3720,7 @@ private void OnListDialogNodesResponse(RESTConnector.Request req, RESTConnector.
/// <param name="userLabel">A label that can be displayed externally to describe the purpose of the node to
/// users. (optional)</param>
/// <param name="disambiguationOptOut">Whether the dialog node should be excluded from disambiguation
/// suggestions. (optional, default to false)</param>
/// suggestions. Valid only when **type**=`standard` or `frame`. (optional, default to false)</param>
/// <param name="includeAudit">Whether to include the audit properties (`created` and `updated` timestamps) in
/// the response. (optional, default to false)</param>
/// <returns><see cref="DialogNode" />DialogNode</returns>
Expand Down Expand Up @@ -3960,7 +3960,7 @@ private void OnGetDialogNodeResponse(RESTConnector.Request req, RESTConnector.Re
/// <param name="newUserLabel">A label that can be displayed externally to describe the purpose of the node to
/// users. (optional)</param>
/// <param name="newDisambiguationOptOut">Whether the dialog node should be excluded from disambiguation
/// suggestions. (optional, default to false)</param>
/// suggestions. Valid only when **type**=`standard` or `frame`. (optional, default to false)</param>
/// <param name="includeAudit">Whether to include the audit properties (`created` and `updated` timestamps) in
/// the response. (optional, default to false)</param>
/// <returns><see cref="DialogNode" />DialogNode</returns>
Expand Down Expand Up @@ -4416,4 +4416,4 @@ private void OnDeleteUserDataResponse(RESTConnector.Request req, RESTConnector.R
((RequestObject<object>)req).Callback(response, resp.Error);
}
}
}
}
3 changes: 2 additions & 1 deletion Scripts/Services/Assistant/V1/Model/DialogNode.cs
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,8 @@ public class DigressOutSlotsValue
[JsonProperty("user_label", NullValueHandling = NullValueHandling.Ignore)]
public string UserLabel { get; set; }
/// <summary>
/// Whether the dialog node should be excluded from disambiguation suggestions.
/// Whether the dialog node should be excluded from disambiguation suggestions. Valid only when
/// **type**=`standard` or `frame`.
/// </summary>
[JsonProperty("disambiguation_opt_out", NullValueHandling = NullValueHandling.Ignore)]
public bool? DisambiguationOptOut { get; set; }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2018, 2019 IBM Corp. All Rights Reserved.
* (C) Copyright IBM Corp. 2018, 2020.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -198,15 +198,15 @@ public class QueryTypeValue
/// The text of the search query. This can be either a natural-language query or a query that uses the Discovery
/// query language syntax, depending on the value of the **query_type** property. For more information, see the
/// [Discovery service
/// documentation](https://cloud.ibm.com/docs/services/discovery/query-operators.html#query-operators). Required
/// when **response_type**=`search_skill`.
/// documentation](https://cloud.ibm.com/docs/discovery/query-operators.html#query-operators). Required when
/// **response_type**=`search_skill`.
/// </summary>
[JsonProperty("query", NullValueHandling = NullValueHandling.Ignore)]
public string Query { get; set; }
/// <summary>
/// An optional filter that narrows the set of documents to be searched. For more information, see the
/// [Discovery service documentation]([Discovery service
/// documentation](https://cloud.ibm.com/docs/services/discovery/query-parameters.html#filter).
/// documentation](https://cloud.ibm.com/docs/discovery/query-parameters.html#filter).
/// </summary>
[JsonProperty("filter", NullValueHandling = NullValueHandling.Ignore)]
public string Filter { get; set; }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2018, 2019 IBM Corp. All Rights Reserved.
* (C) Copyright IBM Corp. 2018, 2020.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -136,14 +136,13 @@ public class PreferenceValue
[JsonProperty("message_to_human_agent", NullValueHandling = NullValueHandling.Ignore)]
public string MessageToHumanAgent { get; set; }
/// <summary>
/// A label identifying the topic of the conversation, derived from the **user_label** property of the relevant
/// node.
/// A label identifying the topic of the conversation, derived from the **title** property of the relevant node.
/// </summary>
[JsonProperty("topic", NullValueHandling = NullValueHandling.Ignore)]
public virtual string Topic { get; private set; }
/// <summary>
/// The ID of the dialog node that the **topic** property is taken from. The **topic** property is populated
/// using the value of the dialog node's **user_label** property.
/// using the value of the dialog node's **title** property.
/// </summary>
[JsonProperty("dialog_node", NullValueHandling = NullValueHandling.Ignore)]
public string DialogNode { get; set; }
Expand Down
9 changes: 9 additions & 0 deletions Scripts/Services/Assistant/V1/Model/RuntimeEntity.cs
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,15 @@ public class RuntimeEntity
[JsonProperty("interpretation", NullValueHandling = NullValueHandling.Ignore)]
public RuntimeEntityInterpretation Interpretation { get; set; }
/// <summary>
/// An array of possible alternative values that the user might have intended instead of the value returned in
/// the **value** property. This property is returned only for `@sys-time` and `@sys-date` entities when the
/// user's input is ambiguous.
///
/// This property is included only if the new system entities are enabled for the workspace.
/// </summary>
[JsonProperty("alternatives", NullValueHandling = NullValueHandling.Ignore)]
public List<RuntimeEntityAlternative> Alternatives { get; set; }
/// <summary>
/// An object describing the role played by a system entity that is specifies the beginning or end of a range
/// recognized in the user input. This property is included only if the new system entities are enabled for the
/// workspace.
Expand Down
38 changes: 38 additions & 0 deletions Scripts/Services/Assistant/V1/Model/RuntimeEntityAlternative.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/**
* (C) Copyright IBM Corp. 2018, 2020.
*
* 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
*
* http://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.
*
*/

using Newtonsoft.Json;

namespace IBM.Watson.Assistant.V1.Model
{
/// <summary>
/// An alternative value for the recognized entity.
/// </summary>
public class RuntimeEntityAlternative
{
/// <summary>
/// The entity value that was recognized in the user input.
/// </summary>
[JsonProperty("value", NullValueHandling = NullValueHandling.Ignore)]
public string Value { get; set; }
/// <summary>
/// A decimal percentage that represents Watson's confidence in the recognized entity.
/// </summary>
[JsonProperty("confidence", NullValueHandling = NullValueHandling.Ignore)]
public float? Confidence { get; set; }
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 3 additions & 4 deletions Scripts/Services/Assistant/V1/Model/RuntimeResponseGeneric.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2018, 2019 IBM Corp. All Rights Reserved.
* (C) Copyright IBM Corp. 2018, 2020.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -134,14 +134,13 @@ public class PreferenceValue
[JsonProperty("message_to_human_agent", NullValueHandling = NullValueHandling.Ignore)]
public string MessageToHumanAgent { get; set; }
/// <summary>
/// A label identifying the topic of the conversation, derived from the **user_label** property of the relevant
/// node.
/// A label identifying the topic of the conversation, derived from the **title** property of the relevant node.
/// </summary>
[JsonProperty("topic", NullValueHandling = NullValueHandling.Ignore)]
public virtual string Topic { get; private set; }
/// <summary>
/// The ID of the dialog node that the **topic** property is taken from. The **topic** property is populated
/// using the value of the dialog node's **user_label** property.
/// using the value of the dialog node's **title** property.
/// </summary>
[JsonProperty("dialog_node", NullValueHandling = NullValueHandling.Ignore)]
public string DialogNode { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion Scripts/Services/Assistant/V2/AssistantService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -333,4 +333,4 @@ private void OnMessageResponse(RESTConnector.Request req, RESTConnector.Response
((RequestObject<MessageResponse>)req).Callback(response, resp.Error);
}
}
}
}
2 changes: 1 addition & 1 deletion Scripts/Services/Assistant/V2/Model/MessageContextSkill.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public class MessageContextSkill
[JsonProperty("user_defined", NullValueHandling = NullValueHandling.Ignore)]
public Dictionary<string, object> UserDefined { get; set; }
/// <summary>
/// For internal use only.
/// System context data used by the skill.
/// </summary>
[JsonProperty("system", NullValueHandling = NullValueHandling.Ignore)]
public Dictionary<string, object> System { get; set; }
Expand Down
20 changes: 15 additions & 5 deletions Scripts/Services/Assistant/V2/Model/MessageInputOptions.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2018, 2019 IBM Corp. All Rights Reserved.
* (C) Copyright IBM Corp. 2018, 2020.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -25,8 +25,9 @@ namespace IBM.Watson.Assistant.V2.Model
public class MessageInputOptions
{
/// <summary>
/// Whether to return additional diagnostic information. Set to `true` to return additional information under
/// the `output.debug` key.
/// Whether to return additional diagnostic information. Set to `true` to return additional information in the
/// `output.debug` property. If you also specify **return_context**=`true`, the returned skill context includes
/// the `system.state` property.
/// </summary>
[JsonProperty("debug", NullValueHandling = NullValueHandling.Ignore)]
public bool? Debug { get; set; }
Expand All @@ -42,10 +43,19 @@ public class MessageInputOptions
[JsonProperty("alternate_intents", NullValueHandling = NullValueHandling.Ignore)]
public bool? AlternateIntents { get; set; }
/// <summary>
/// Whether to return session context with the response. If you specify `true`, the response will include the
/// `context` property.
/// Whether to return session context with the response. If you specify `true`, the response includes the
/// `context` property. If you also specify **debug**=`true`, the returned skill context includes the
/// `system.state` property.
/// </summary>
[JsonProperty("return_context", NullValueHandling = NullValueHandling.Ignore)]
public bool? ReturnContext { get; set; }
/// <summary>
/// Whether to return session context, including full conversation state. If you specify `true`, the response
/// includes the `context` property, and the skill context includes the `system.state` property.
///
/// **Note:** If **export**=`true`, the context is returned regardless of the value of **return_context**.
/// </summary>
[JsonProperty("export", NullValueHandling = NullValueHandling.Ignore)]
public bool? Export { get; set; }
}
}
6 changes: 3 additions & 3 deletions Scripts/Services/Assistant/V2/Model/MessageResponse.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Copyright 2018, 2019 IBM Corp. All Rights Reserved.
* (C) Copyright IBM Corp. 2018, 2020.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -30,8 +30,8 @@ public class MessageResponse
[JsonProperty("output", NullValueHandling = NullValueHandling.Ignore)]
public MessageOutput Output { get; set; }
/// <summary>
/// State information for the conversation. The context is stored by the assistant on a per-session basis. You
/// can use this property to access context variables.
/// Context data for the conversation. The context is stored by the assistant on a per-session basis. You can
/// use this property to access context variables.
///
/// **Note:** The context is included in message responses only if **return_context**=`true` in the message
/// request.
Expand Down
6 changes: 3 additions & 3 deletions Scripts/Services/CompareComply/V1/CompareComplyService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -845,9 +845,9 @@ private void OnDeleteFeedbackResponse(RESTConnector.Request req, RESTConnector.R
/// Run Compare and Comply methods over a collection of input documents.
///
/// **Important:** Batch processing requires the use of the [IBM Cloud Object Storage
/// service](https://cloud.ibm.com/docs/services/cloud-object-storage?topic=cloud-object-storage-about#about-ibm-cloud-object-storage).
/// service](https://cloud.ibm.com/docs/cloud-object-storage?topic=cloud-object-storage-about#about-ibm-cloud-object-storage).
/// The use of IBM Cloud Object Storage with Compare and Comply is discussed at [Using batch
/// processing](https://cloud.ibm.com/docs/services/compare-comply?topic=compare-comply-batching#before-you-batch).
/// processing](https://cloud.ibm.com/docs/compare-comply?topic=compare-comply-batching#before-you-batch).
/// </summary>
/// <param name="callback">The callback function that is invoked when the operation completes.</param>
/// <param name="function">The Compare and Comply method to run across the submitted input documents.</param>
Expand Down Expand Up @@ -1193,4 +1193,4 @@ private void OnUpdateBatchResponse(RESTConnector.Request req, RESTConnector.Resp
((RequestObject<BatchStatus>)req).Callback(response, resp.Error);
}
}
}
}
Loading