azure_cognitiveservices_qnamakerruntime 0.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (32) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +21 -0
  3. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime.rb +47 -0
  4. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/context_dto.rb +73 -0
  5. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/error.rb +108 -0
  6. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/error_code_type.rb +28 -0
  7. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/error_response.rb +48 -0
  8. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/error_response_error.rb +85 -0
  9. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/feedback_record_dto.rb +72 -0
  10. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/feedback_records_dto.rb +55 -0
  11. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/inner_error_model.rb +62 -0
  12. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/metadata_dto.rb +65 -0
  13. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/prompt_dto.rb +86 -0
  14. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/prompt_dtoqna.rb +108 -0
  15. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/qn_adto.rb +128 -0
  16. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/qn_adtocontext.rb +63 -0
  17. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/qn_asearch_result.rb +130 -0
  18. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/qn_asearch_result_context.rb +63 -0
  19. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/qn_asearch_result_list.rb +55 -0
  20. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/query_context_dto.rb +57 -0
  21. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/query_dto.rb +137 -0
  22. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/models/query_dtocontext.rb +51 -0
  23. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/module_definition.rb +9 -0
  24. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/qnamaker_runtime_client.rb +127 -0
  25. data/lib/4.0/generated/azure_cognitiveservices_qnamakerruntime/runtime.rb +214 -0
  26. data/lib/azure_cognitiveservices_qnamakerruntime.rb +6 -0
  27. data/lib/module_definition.rb +7 -0
  28. data/lib/profiles/latest/modules/qnamakerruntime_profile_module.rb +135 -0
  29. data/lib/profiles/latest/qnamakerruntime_latest_profile_client.rb +38 -0
  30. data/lib/profiles/latest/qnamakerruntime_module_definition.rb +8 -0
  31. data/lib/version.rb +7 -0
  32. metadata +147 -0
@@ -0,0 +1,63 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # Context of a QnA
10
+ #
11
+ class QnADTOContext < ContextDTO
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ #
17
+ # Mapper for QnADTOContext class as Ruby Hash.
18
+ # This will be used for serialization/deserialization.
19
+ #
20
+ def self.mapper()
21
+ {
22
+ client_side_validation: true,
23
+ required: false,
24
+ serialized_name: 'QnADTO_context',
25
+ type: {
26
+ name: 'Composite',
27
+ class_name: 'QnADTOContext',
28
+ model_properties: {
29
+ is_context_only: {
30
+ client_side_validation: true,
31
+ required: false,
32
+ serialized_name: 'isContextOnly',
33
+ type: {
34
+ name: 'Boolean'
35
+ }
36
+ },
37
+ prompts: {
38
+ client_side_validation: true,
39
+ required: false,
40
+ serialized_name: 'prompts',
41
+ constraints: {
42
+ MaxItems: 20
43
+ },
44
+ type: {
45
+ name: 'Sequence',
46
+ element: {
47
+ client_side_validation: true,
48
+ required: false,
49
+ serialized_name: 'PromptDTOElementType',
50
+ type: {
51
+ name: 'Composite',
52
+ class_name: 'PromptDTO'
53
+ }
54
+ }
55
+ }
56
+ }
57
+ }
58
+ }
59
+ }
60
+ end
61
+ end
62
+ end
63
+ end
@@ -0,0 +1,130 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # Represents Search Result.
10
+ #
11
+ class QnASearchResult
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [Array<String>] List of questions.
16
+ attr_accessor :questions
17
+
18
+ # @return [String] Answer.
19
+ attr_accessor :answer
20
+
21
+ # @return [Float] Search result score.
22
+ attr_accessor :score
23
+
24
+ # @return [Integer] Id of the QnA result.
25
+ attr_accessor :id
26
+
27
+ # @return [String] Source of QnA result.
28
+ attr_accessor :source
29
+
30
+ # @return [Array<MetadataDTO>] List of metadata.
31
+ attr_accessor :metadata
32
+
33
+ # @return [QnASearchResultContext] Context object of the QnA
34
+ attr_accessor :context
35
+
36
+
37
+ #
38
+ # Mapper for QnASearchResult class as Ruby Hash.
39
+ # This will be used for serialization/deserialization.
40
+ #
41
+ def self.mapper()
42
+ {
43
+ client_side_validation: true,
44
+ required: false,
45
+ serialized_name: 'QnASearchResult',
46
+ type: {
47
+ name: 'Composite',
48
+ class_name: 'QnASearchResult',
49
+ model_properties: {
50
+ questions: {
51
+ client_side_validation: true,
52
+ required: false,
53
+ serialized_name: 'questions',
54
+ type: {
55
+ name: 'Sequence',
56
+ element: {
57
+ client_side_validation: true,
58
+ required: false,
59
+ serialized_name: 'StringElementType',
60
+ type: {
61
+ name: 'String'
62
+ }
63
+ }
64
+ }
65
+ },
66
+ answer: {
67
+ client_side_validation: true,
68
+ required: false,
69
+ serialized_name: 'answer',
70
+ type: {
71
+ name: 'String'
72
+ }
73
+ },
74
+ score: {
75
+ client_side_validation: true,
76
+ required: false,
77
+ serialized_name: 'score',
78
+ type: {
79
+ name: 'Double'
80
+ }
81
+ },
82
+ id: {
83
+ client_side_validation: true,
84
+ required: false,
85
+ serialized_name: 'id',
86
+ type: {
87
+ name: 'Number'
88
+ }
89
+ },
90
+ source: {
91
+ client_side_validation: true,
92
+ required: false,
93
+ serialized_name: 'source',
94
+ type: {
95
+ name: 'String'
96
+ }
97
+ },
98
+ metadata: {
99
+ client_side_validation: true,
100
+ required: false,
101
+ serialized_name: 'metadata',
102
+ type: {
103
+ name: 'Sequence',
104
+ element: {
105
+ client_side_validation: true,
106
+ required: false,
107
+ serialized_name: 'MetadataDTOElementType',
108
+ type: {
109
+ name: 'Composite',
110
+ class_name: 'MetadataDTO'
111
+ }
112
+ }
113
+ }
114
+ },
115
+ context: {
116
+ client_side_validation: true,
117
+ required: false,
118
+ serialized_name: 'context',
119
+ type: {
120
+ name: 'Composite',
121
+ class_name: 'QnASearchResultContext'
122
+ }
123
+ }
124
+ }
125
+ }
126
+ }
127
+ end
128
+ end
129
+ end
130
+ end
@@ -0,0 +1,63 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # Context object of the QnA
10
+ #
11
+ class QnASearchResultContext < ContextDTO
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ #
17
+ # Mapper for QnASearchResultContext class as Ruby Hash.
18
+ # This will be used for serialization/deserialization.
19
+ #
20
+ def self.mapper()
21
+ {
22
+ client_side_validation: true,
23
+ required: false,
24
+ serialized_name: 'QnASearchResult_context',
25
+ type: {
26
+ name: 'Composite',
27
+ class_name: 'QnASearchResultContext',
28
+ model_properties: {
29
+ is_context_only: {
30
+ client_side_validation: true,
31
+ required: false,
32
+ serialized_name: 'isContextOnly',
33
+ type: {
34
+ name: 'Boolean'
35
+ }
36
+ },
37
+ prompts: {
38
+ client_side_validation: true,
39
+ required: false,
40
+ serialized_name: 'prompts',
41
+ constraints: {
42
+ MaxItems: 20
43
+ },
44
+ type: {
45
+ name: 'Sequence',
46
+ element: {
47
+ client_side_validation: true,
48
+ required: false,
49
+ serialized_name: 'PromptDTOElementType',
50
+ type: {
51
+ name: 'Composite',
52
+ class_name: 'PromptDTO'
53
+ }
54
+ }
55
+ }
56
+ }
57
+ }
58
+ }
59
+ }
60
+ end
61
+ end
62
+ end
63
+ end
@@ -0,0 +1,55 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # Represents List of Question Answers.
10
+ #
11
+ class QnASearchResultList
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [Array<QnASearchResult>] Represents Search Result list.
16
+ attr_accessor :answers
17
+
18
+
19
+ #
20
+ # Mapper for QnASearchResultList class as Ruby Hash.
21
+ # This will be used for serialization/deserialization.
22
+ #
23
+ def self.mapper()
24
+ {
25
+ client_side_validation: true,
26
+ required: false,
27
+ serialized_name: 'QnASearchResultList',
28
+ type: {
29
+ name: 'Composite',
30
+ class_name: 'QnASearchResultList',
31
+ model_properties: {
32
+ answers: {
33
+ client_side_validation: true,
34
+ required: false,
35
+ serialized_name: 'answers',
36
+ type: {
37
+ name: 'Sequence',
38
+ element: {
39
+ client_side_validation: true,
40
+ required: false,
41
+ serialized_name: 'QnASearchResultElementType',
42
+ type: {
43
+ name: 'Composite',
44
+ class_name: 'QnASearchResult'
45
+ }
46
+ }
47
+ }
48
+ }
49
+ }
50
+ }
51
+ }
52
+ end
53
+ end
54
+ end
55
+ end
@@ -0,0 +1,57 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # Context object with previous QnA's information.
10
+ #
11
+ class QueryContextDTO
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [String] Previous QnA Id - qnaId of the top result.
16
+ attr_accessor :previous_qna_id
17
+
18
+ # @return [String] Previous user query.
19
+ attr_accessor :previous_user_query
20
+
21
+
22
+ #
23
+ # Mapper for QueryContextDTO class as Ruby Hash.
24
+ # This will be used for serialization/deserialization.
25
+ #
26
+ def self.mapper()
27
+ {
28
+ client_side_validation: true,
29
+ required: false,
30
+ serialized_name: 'QueryContextDTO',
31
+ type: {
32
+ name: 'Composite',
33
+ class_name: 'QueryContextDTO',
34
+ model_properties: {
35
+ previous_qna_id: {
36
+ client_side_validation: true,
37
+ required: false,
38
+ serialized_name: 'previousQnaId',
39
+ type: {
40
+ name: 'String'
41
+ }
42
+ },
43
+ previous_user_query: {
44
+ client_side_validation: true,
45
+ required: false,
46
+ serialized_name: 'previousUserQuery',
47
+ type: {
48
+ name: 'String'
49
+ }
50
+ }
51
+ }
52
+ }
53
+ }
54
+ end
55
+ end
56
+ end
57
+ end
@@ -0,0 +1,137 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::QnamakerRuntime::V4_0
7
+ module Models
8
+ #
9
+ # POST body schema to query the knowledgebase.
10
+ #
11
+ class QueryDTO
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [String] Exact qnaId to fetch from the knowledgebase, this
16
+ # field takes priority over question.
17
+ attr_accessor :qna_id
18
+
19
+ # @return [String] User question to query against the knowledge base.
20
+ attr_accessor :question
21
+
22
+ # @return [Integer] Max number of answers to be returned for the
23
+ # question.
24
+ attr_accessor :top
25
+
26
+ # @return [String] Unique identifier for the user.
27
+ attr_accessor :user_id
28
+
29
+ # @return [Boolean] Query against the test index.
30
+ attr_accessor :is_test
31
+
32
+ # @return [Float] Threshold for answers returned based on score.
33
+ attr_accessor :score_threshold
34
+
35
+ # @return [QueryDTOContext] Context object with previous QnA's
36
+ # information.
37
+ attr_accessor :context
38
+
39
+ # @return [Array<MetadataDTO>] Find only answers that contain these
40
+ # metadata.
41
+ attr_accessor :strict_filters
42
+
43
+
44
+ #
45
+ # Mapper for QueryDTO class as Ruby Hash.
46
+ # This will be used for serialization/deserialization.
47
+ #
48
+ def self.mapper()
49
+ {
50
+ client_side_validation: true,
51
+ required: false,
52
+ serialized_name: 'QueryDTO',
53
+ type: {
54
+ name: 'Composite',
55
+ class_name: 'QueryDTO',
56
+ model_properties: {
57
+ qna_id: {
58
+ client_side_validation: true,
59
+ required: false,
60
+ serialized_name: 'qnaId',
61
+ type: {
62
+ name: 'String'
63
+ }
64
+ },
65
+ question: {
66
+ client_side_validation: true,
67
+ required: false,
68
+ serialized_name: 'question',
69
+ type: {
70
+ name: 'String'
71
+ }
72
+ },
73
+ top: {
74
+ client_side_validation: true,
75
+ required: false,
76
+ serialized_name: 'top',
77
+ type: {
78
+ name: 'Number'
79
+ }
80
+ },
81
+ user_id: {
82
+ client_side_validation: true,
83
+ required: false,
84
+ serialized_name: 'userId',
85
+ type: {
86
+ name: 'String'
87
+ }
88
+ },
89
+ is_test: {
90
+ client_side_validation: true,
91
+ required: false,
92
+ serialized_name: 'isTest',
93
+ type: {
94
+ name: 'Boolean'
95
+ }
96
+ },
97
+ score_threshold: {
98
+ client_side_validation: true,
99
+ required: false,
100
+ serialized_name: 'scoreThreshold',
101
+ type: {
102
+ name: 'Double'
103
+ }
104
+ },
105
+ context: {
106
+ client_side_validation: true,
107
+ required: false,
108
+ serialized_name: 'context',
109
+ type: {
110
+ name: 'Composite',
111
+ class_name: 'QueryDTOContext'
112
+ }
113
+ },
114
+ strict_filters: {
115
+ client_side_validation: true,
116
+ required: false,
117
+ serialized_name: 'strictFilters',
118
+ type: {
119
+ name: 'Sequence',
120
+ element: {
121
+ client_side_validation: true,
122
+ required: false,
123
+ serialized_name: 'MetadataDTOElementType',
124
+ type: {
125
+ name: 'Composite',
126
+ class_name: 'MetadataDTO'
127
+ }
128
+ }
129
+ }
130
+ }
131
+ }
132
+ }
133
+ }
134
+ end
135
+ end
136
+ end
137
+ end