Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

LuisActionBindingAttribute.cs 891 B

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
  1. namespace Microsoft.Cognitive.LUIS.ActionBinding
  2. {
  3. using System;
  4. [AttributeUsage(AttributeTargets.Class, AllowMultiple = true)]
  5. public class LuisActionBindingAttribute : Attribute
  6. {
  7. public LuisActionBindingAttribute(string intentName)
  8. {
  9. if (string.IsNullOrWhiteSpace(intentName))
  10. {
  11. throw new ArgumentException(nameof(intentName));
  12. }
  13. this.IntentName = intentName;
  14. // setting defaults
  15. this.CanExecuteWithNoContext = true;
  16. this.ConfirmOnSwitchingContext = true;
  17. this.FriendlyName = this.IntentName;
  18. }
  19. public bool CanExecuteWithNoContext { get; set; }
  20. public bool ConfirmOnSwitchingContext { get; set; }
  21. public string FriendlyName { get; set; }
  22. public string IntentName { get; private set; }
  23. }
  24. }
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...