neuralseek 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (236) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +206 -0
  3. package/docs/AnalyticsApi.md +59 -0
  4. package/docs/AnalyticsBody.md +6 -0
  5. package/docs/AnswerRatingsBody.md +7 -0
  6. package/docs/CategorizeApi.md +58 -0
  7. package/docs/CategorizeBody.md +6 -0
  8. package/docs/ChatCompletionsBody.md +9 -0
  9. package/docs/ChatcompletionsMessages.md +16 -0
  10. package/docs/ChatcompletionsTools.md +13 -0
  11. package/docs/ExtractBody.md +11 -0
  12. package/docs/ExtractEntitiesApi.md +58 -0
  13. package/docs/GuardrailsApi.md +109 -0
  14. package/docs/IdentifysingleBody.md +6 -0
  15. package/docs/InlineResponse200.md +6 -0
  16. package/docs/InlineResponse2001.md +8 -0
  17. package/docs/InlineResponse20010.md +6 -0
  18. package/docs/InlineResponse20011.md +9 -0
  19. package/docs/InlineResponse20012.md +7 -0
  20. package/docs/InlineResponse20013.md +6 -0
  21. package/docs/InlineResponse2002.md +10 -0
  22. package/docs/InlineResponse2002Render.md +9 -0
  23. package/docs/InlineResponse2003.md +6 -0
  24. package/docs/InlineResponse2003Data.md +10 -0
  25. package/docs/InlineResponse2004.md +10 -0
  26. package/docs/InlineResponse2004Choices.md +8 -0
  27. package/docs/InlineResponse2004Message.md +14 -0
  28. package/docs/InlineResponse2005.md +9 -0
  29. package/docs/InlineResponse2005TopIntents.md +7 -0
  30. package/docs/InlineResponse2006.md +9 -0
  31. package/docs/InlineResponse2006ExtractedEntities.md +6 -0
  32. package/docs/InlineResponse2007.md +12 -0
  33. package/docs/InlineResponse2007Translations.md +6 -0
  34. package/docs/InlineResponse2008.md +7 -0
  35. package/docs/InlineResponse2009.md +7 -0
  36. package/docs/KeysApi.md +99 -0
  37. package/docs/LogExternalAgentBody.md +11 -0
  38. package/docs/LogExternalAgentEntries.md +34 -0
  39. package/docs/LogsApi.md +110 -0
  40. package/docs/LogsBody.md +8 -0
  41. package/docs/MAIstroAgentRatingsApi.md +109 -0
  42. package/docs/MAIstroApi.md +367 -0
  43. package/docs/MaistroBatchBody.md +9 -0
  44. package/docs/MaistroBody.md +9 -0
  45. package/docs/MaistroOptions.md +20 -0
  46. package/docs/MaistroRateBody.md +9 -0
  47. package/docs/MaistroRatingsBody.md +7 -0
  48. package/docs/MaistroStreamBody.md +9 -0
  49. package/docs/MaistroStreamOptions.md +19 -0
  50. package/docs/PiiBody.md +6 -0
  51. package/docs/RateBody.md +8 -0
  52. package/docs/ScoreBody.md +7 -0
  53. package/docs/Seek.md +9 -0
  54. package/docs/SeekAnswerRatingsApi.md +109 -0
  55. package/docs/SeekApi.md +109 -0
  56. package/docs/SeekOptions.md +24 -0
  57. package/docs/SeekResponse.md +32 -0
  58. package/docs/SeekResponsePassages.md +11 -0
  59. package/docs/SeekResponseVariablesExpanded.md +7 -0
  60. package/docs/SeekStreamBody.md +9 -0
  61. package/docs/SeekStreamOptions.md +23 -0
  62. package/docs/SeekStreamOptionsLastTurn.md +7 -0
  63. package/docs/SeekStreamOptionsPersonalize.md +10 -0
  64. package/docs/SeekStreamParams.md +7 -0
  65. package/docs/SeekStreamUserSession.md +7 -0
  66. package/docs/SeekStreamUserSessionMetadata.md +6 -0
  67. package/docs/SeekStreamUserSessionSystem.md +6 -0
  68. package/docs/ServiceTestApi.md +46 -0
  69. package/docs/TestBody.md +6 -0
  70. package/docs/TestBody1.md +6 -0
  71. package/docs/TestQuestionsApi.md +107 -0
  72. package/docs/TrainBody.md +7 -0
  73. package/docs/TrainKBApi.md +58 -0
  74. package/docs/TranslateApi.md +259 -0
  75. package/docs/TranslateBody.md +11 -0
  76. package/docs/TranslateGlossaryBody.md +6 -0
  77. package/docs/TranslateGlossaryBody1.md +6 -0
  78. package/docs/UserDataApi.md +59 -0
  79. package/git_push.sh +52 -0
  80. package/mocha.opts +1 -0
  81. package/package.json +55 -0
  82. package/src/AnalyticsApi.js +82 -0
  83. package/src/ApiClient.js +585 -0
  84. package/src/CategorizeApi.js +87 -0
  85. package/src/ExtractEntitiesApi.js +87 -0
  86. package/src/GuardrailsApi.js +134 -0
  87. package/src/KeysApi.js +122 -0
  88. package/src/LogsApi.js +133 -0
  89. package/src/MAIstroAgentRatingsApi.js +134 -0
  90. package/src/MAIstroApi.js +366 -0
  91. package/src/SeekAnswerRatingsApi.js +134 -0
  92. package/src/SeekApi.js +136 -0
  93. package/src/ServiceTestApi.js +79 -0
  94. package/src/TestQuestionsApi.js +124 -0
  95. package/src/TrainKBApi.js +85 -0
  96. package/src/TranslateApi.js +277 -0
  97. package/src/UserDataApi.js +81 -0
  98. package/src/index.js +587 -0
  99. package/src/model/AnalyticsBody.js +54 -0
  100. package/src/model/AnswerRatingsBody.js +62 -0
  101. package/src/model/CategorizeBody.js +55 -0
  102. package/src/model/ChatCompletionsBody.js +80 -0
  103. package/src/model/ChatcompletionsMessages.js +92 -0
  104. package/src/model/ChatcompletionsTools.js +75 -0
  105. package/src/model/ExtractBody.js +94 -0
  106. package/src/model/IdentifysingleBody.js +55 -0
  107. package/src/model/InlineResponse200.js +56 -0
  108. package/src/model/InlineResponse2001.js +70 -0
  109. package/src/model/InlineResponse20010.js +54 -0
  110. package/src/model/InlineResponse20011.js +81 -0
  111. package/src/model/InlineResponse20012.js +60 -0
  112. package/src/model/InlineResponse20013.js +55 -0
  113. package/src/model/InlineResponse2002.js +88 -0
  114. package/src/model/InlineResponse2002Render.js +80 -0
  115. package/src/model/InlineResponse2003.js +56 -0
  116. package/src/model/InlineResponse2003Data.js +88 -0
  117. package/src/model/InlineResponse2004.js +86 -0
  118. package/src/model/InlineResponse2004Choices.js +70 -0
  119. package/src/model/InlineResponse2004Message.js +80 -0
  120. package/src/model/InlineResponse2005.js +80 -0
  121. package/src/model/InlineResponse2005TopIntents.js +64 -0
  122. package/src/model/InlineResponse2006.js +79 -0
  123. package/src/model/InlineResponse2006ExtractedEntities.js +55 -0
  124. package/src/model/InlineResponse2007.js +103 -0
  125. package/src/model/InlineResponse2007Translations.js +55 -0
  126. package/src/model/InlineResponse2008.js +63 -0
  127. package/src/model/InlineResponse2009.js +63 -0
  128. package/src/model/LogExternalAgentBody.js +104 -0
  129. package/src/model/LogExternalAgentEntries.js +195 -0
  130. package/src/model/LogsBody.js +73 -0
  131. package/src/model/MaistroBatchBody.js +81 -0
  132. package/src/model/MaistroBody.js +81 -0
  133. package/src/model/MaistroOptions.js +176 -0
  134. package/src/model/MaistroRateBody.js +78 -0
  135. package/src/model/MaistroRatingsBody.js +62 -0
  136. package/src/model/MaistroStreamBody.js +81 -0
  137. package/src/model/MaistroStreamOptions.js +167 -0
  138. package/src/model/PiiBody.js +55 -0
  139. package/src/model/RateBody.js +70 -0
  140. package/src/model/ScoreBody.js +63 -0
  141. package/src/model/Seek.js +82 -0
  142. package/src/model/SeekOptions.js +216 -0
  143. package/src/model/SeekResponse.js +281 -0
  144. package/src/model/SeekResponsePassages.js +99 -0
  145. package/src/model/SeekResponseVariablesExpanded.js +64 -0
  146. package/src/model/SeekStreamBody.js +82 -0
  147. package/src/model/SeekStreamOptions.js +207 -0
  148. package/src/model/SeekStreamOptionsLastTurn.js +64 -0
  149. package/src/model/SeekStreamOptionsPersonalize.js +91 -0
  150. package/src/model/SeekStreamParams.js +64 -0
  151. package/src/model/SeekStreamUserSession.js +63 -0
  152. package/src/model/SeekStreamUserSessionMetadata.js +55 -0
  153. package/src/model/SeekStreamUserSessionSystem.js +55 -0
  154. package/src/model/TestBody.js +53 -0
  155. package/src/model/TestBody1.js +55 -0
  156. package/src/model/TrainBody.js +63 -0
  157. package/src/model/TranslateBody.js +99 -0
  158. package/src/model/TranslateGlossaryBody.js +53 -0
  159. package/src/model/TranslateGlossaryBody1.js +54 -0
  160. package/test/api/AnalyticsApi.spec.js +60 -0
  161. package/test/api/CategorizeApi.spec.js +61 -0
  162. package/test/api/ExtractEntitiesApi.spec.js +61 -0
  163. package/test/api/GuardrailsApi.spec.js +85 -0
  164. package/test/api/KeysApi.spec.js +79 -0
  165. package/test/api/LogsApi.spec.js +88 -0
  166. package/test/api/MAIstroAgentRatingsApi.spec.js +79 -0
  167. package/test/api/MAIstroApi.spec.js +180 -0
  168. package/test/api/SeekAnswerRatingsApi.spec.js +79 -0
  169. package/test/api/SeekApi.spec.js +81 -0
  170. package/test/api/ServiceTestApi.spec.js +59 -0
  171. package/test/api/TestQuestionsApi.spec.js +78 -0
  172. package/test/api/TrainKBApi.spec.js +59 -0
  173. package/test/api/TranslateApi.spec.js +143 -0
  174. package/test/api/UserDataApi.spec.js +60 -0
  175. package/test/assert-equals.js +81 -0
  176. package/test/model/AnalyticsBody.spec.js +52 -0
  177. package/test/model/AnswerRatingsBody.spec.js +58 -0
  178. package/test/model/CategorizeBody.spec.js +52 -0
  179. package/test/model/ChatCompletionsBody.spec.js +70 -0
  180. package/test/model/ChatcompletionsMessages.spec.js +58 -0
  181. package/test/model/ChatcompletionsTools.spec.js +58 -0
  182. package/test/model/ExtractBody.spec.js +82 -0
  183. package/test/model/IdentifysingleBody.spec.js +52 -0
  184. package/test/model/InlineResponse200.spec.js +52 -0
  185. package/test/model/InlineResponse2001.spec.js +64 -0
  186. package/test/model/InlineResponse20010.spec.js +52 -0
  187. package/test/model/InlineResponse20011.spec.js +70 -0
  188. package/test/model/InlineResponse20012.spec.js +58 -0
  189. package/test/model/InlineResponse20013.spec.js +52 -0
  190. package/test/model/InlineResponse2002.spec.js +76 -0
  191. package/test/model/InlineResponse2002Render.spec.js +70 -0
  192. package/test/model/InlineResponse2003.spec.js +52 -0
  193. package/test/model/InlineResponse2003Data.spec.js +76 -0
  194. package/test/model/InlineResponse2004.spec.js +76 -0
  195. package/test/model/InlineResponse2004Choices.spec.js +64 -0
  196. package/test/model/InlineResponse2004Message.spec.js +58 -0
  197. package/test/model/InlineResponse2005.spec.js +70 -0
  198. package/test/model/InlineResponse2005TopIntents.spec.js +58 -0
  199. package/test/model/InlineResponse2006.spec.js +70 -0
  200. package/test/model/InlineResponse2006ExtractedEntities.spec.js +52 -0
  201. package/test/model/InlineResponse2007.spec.js +88 -0
  202. package/test/model/InlineResponse2007Translations.spec.js +52 -0
  203. package/test/model/InlineResponse2008.spec.js +58 -0
  204. package/test/model/InlineResponse2009.spec.js +58 -0
  205. package/test/model/LogExternalAgentBody.spec.js +82 -0
  206. package/test/model/LogExternalAgentEntries.spec.js +118 -0
  207. package/test/model/LogsBody.spec.js +64 -0
  208. package/test/model/MaistroBatchBody.spec.js +70 -0
  209. package/test/model/MaistroBody.spec.js +70 -0
  210. package/test/model/MaistroOptions.spec.js +136 -0
  211. package/test/model/MaistroRateBody.spec.js +70 -0
  212. package/test/model/MaistroRatingsBody.spec.js +58 -0
  213. package/test/model/MaistroStreamBody.spec.js +70 -0
  214. package/test/model/MaistroStreamOptions.spec.js +130 -0
  215. package/test/model/PiiBody.spec.js +52 -0
  216. package/test/model/RateBody.spec.js +64 -0
  217. package/test/model/ScoreBody.spec.js +58 -0
  218. package/test/model/Seek.spec.js +70 -0
  219. package/test/model/SeekOptions.spec.js +160 -0
  220. package/test/model/SeekResponse.spec.js +208 -0
  221. package/test/model/SeekResponsePassages.spec.js +82 -0
  222. package/test/model/SeekResponseVariablesExpanded.spec.js +58 -0
  223. package/test/model/SeekStreamBody.spec.js +70 -0
  224. package/test/model/SeekStreamOptions.spec.js +154 -0
  225. package/test/model/SeekStreamOptionsLastTurn.spec.js +58 -0
  226. package/test/model/SeekStreamOptionsPersonalize.spec.js +76 -0
  227. package/test/model/SeekStreamParams.spec.js +58 -0
  228. package/test/model/SeekStreamUserSession.spec.js +58 -0
  229. package/test/model/SeekStreamUserSessionMetadata.spec.js +52 -0
  230. package/test/model/SeekStreamUserSessionSystem.spec.js +52 -0
  231. package/test/model/TestBody.spec.js +52 -0
  232. package/test/model/TestBody1.spec.js +52 -0
  233. package/test/model/TrainBody.spec.js +58 -0
  234. package/test/model/TranslateBody.spec.js +82 -0
  235. package/test/model/TranslateGlossaryBody.spec.js +52 -0
  236. package/test/model/TranslateGlossaryBody1.spec.js +52 -0
@@ -0,0 +1,63 @@
1
+ /*
2
+ * NeuralSeek
3
+ * NeuralSeek - The business LLM accelerator
4
+ *
5
+ * OpenAPI spec version: 1.0.1
6
+ * Contact: support@NeuralSeek.com
7
+ *
8
+ * NOTE: This class is auto generated by the swagger code generator program.
9
+ * https://github.com/swagger-api/swagger-codegen.git
10
+ *
11
+ * Swagger Codegen version: 3.0.78
12
+ *
13
+ * Do not edit the class manually.
14
+ *
15
+ */
16
+ import ApiClient from '../ApiClient';
17
+
18
+ /**
19
+ * The ScoreBody model module.
20
+ * @module model/ScoreBody
21
+ * @version 1.0.1
22
+ */
23
+ export default class ScoreBody {
24
+ /**
25
+ * Constructs a new <code>ScoreBody</code>.
26
+ * @alias module:model/ScoreBody
27
+ * @class
28
+ */
29
+ constructor() {
30
+ }
31
+
32
+ /**
33
+ * Constructs a <code>ScoreBody</code> from a plain JavaScript object, optionally creating a new instance.
34
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
35
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
36
+ * @param {module:model/ScoreBody} obj Optional instance to populate.
37
+ * @return {module:model/ScoreBody} The populated <code>ScoreBody</code> instance.
38
+ */
39
+ static constructFromObject(data, obj) {
40
+ if (data) {
41
+ obj = obj || new ScoreBody();
42
+ if (data.hasOwnProperty('text'))
43
+ obj.text = ApiClient.convertToType(data['text'], 'String');
44
+ if (data.hasOwnProperty('passages'))
45
+ obj.passages = ApiClient.convertToType(data['passages'], ['String']);
46
+ }
47
+ return obj;
48
+ }
49
+ }
50
+
51
+ /**
52
+ * The text to score
53
+ * @member {String} text
54
+ * @default ''
55
+ */
56
+ ScoreBody.prototype.text = '';
57
+
58
+ /**
59
+ * The rating score. An integer, 0-5. 0 is worst, 5 is best. For Thumbs up / Thumbs down send 0 or 5
60
+ * @member {Array.<String>} passages
61
+ */
62
+ ScoreBody.prototype.passages = undefined;
63
+
@@ -0,0 +1,82 @@
1
+ /*
2
+ * NeuralSeek
3
+ * NeuralSeek - The business LLM accelerator
4
+ *
5
+ * OpenAPI spec version: 1.0.1
6
+ * Contact: support@NeuralSeek.com
7
+ *
8
+ * NOTE: This class is auto generated by the swagger code generator program.
9
+ * https://github.com/swagger-api/swagger-codegen.git
10
+ *
11
+ * Swagger Codegen version: 3.0.78
12
+ *
13
+ * Do not edit the class manually.
14
+ *
15
+ */
16
+ import ApiClient from '../ApiClient';
17
+ import SeekOptions from './SeekOptions';
18
+ import SeekStreamParams from './SeekStreamParams';
19
+ import SeekStreamUserSession from './SeekStreamUserSession';
20
+
21
+ /**
22
+ * The Seek model module.
23
+ * @module model/Seek
24
+ * @version 1.0.1
25
+ */
26
+ export default class Seek {
27
+ /**
28
+ * Constructs a new <code>Seek</code>.
29
+ * @alias module:model/Seek
30
+ * @class
31
+ * @param question {String} The user's question for NeuralSeek
32
+ */
33
+ constructor(question) {
34
+ this.question = question;
35
+ }
36
+
37
+ /**
38
+ * Constructs a <code>Seek</code> from a plain JavaScript object, optionally creating a new instance.
39
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
40
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
41
+ * @param {module:model/Seek} obj Optional instance to populate.
42
+ * @return {module:model/Seek} The populated <code>Seek</code> instance.
43
+ */
44
+ static constructFromObject(data, obj) {
45
+ if (data) {
46
+ obj = obj || new Seek();
47
+ if (data.hasOwnProperty('question'))
48
+ obj.question = ApiClient.convertToType(data['question'], 'String');
49
+ if (data.hasOwnProperty('user_session'))
50
+ obj.userSession = SeekStreamUserSession.constructFromObject(data['user_session']);
51
+ if (data.hasOwnProperty('params'))
52
+ obj.params = ApiClient.convertToType(data['params'], [SeekStreamParams]);
53
+ if (data.hasOwnProperty('options'))
54
+ obj.options = SeekOptions.constructFromObject(data['options']);
55
+ }
56
+ return obj;
57
+ }
58
+ }
59
+
60
+ /**
61
+ * The user's question for NeuralSeek
62
+ * @member {String} question
63
+ * @default ''
64
+ */
65
+ Seek.prototype.question = '';
66
+
67
+ /**
68
+ * @member {module:model/SeekStreamUserSession} userSession
69
+ */
70
+ Seek.prototype.userSession = undefined;
71
+
72
+ /**
73
+ * An array of parameters to use in evaluation of the seek when calling mAIstro during a seek.
74
+ * @member {Array.<module:model/SeekStreamParams>} params
75
+ */
76
+ Seek.prototype.params = undefined;
77
+
78
+ /**
79
+ * @member {module:model/SeekOptions} options
80
+ */
81
+ Seek.prototype.options = undefined;
82
+
@@ -0,0 +1,216 @@
1
+ /*
2
+ * NeuralSeek
3
+ * NeuralSeek - The business LLM accelerator
4
+ *
5
+ * OpenAPI spec version: 1.0.1
6
+ * Contact: support@NeuralSeek.com
7
+ *
8
+ * NOTE: This class is auto generated by the swagger code generator program.
9
+ * https://github.com/swagger-api/swagger-codegen.git
10
+ *
11
+ * Swagger Codegen version: 3.0.78
12
+ *
13
+ * Do not edit the class manually.
14
+ *
15
+ */
16
+ import ApiClient from '../ApiClient';
17
+ import SeekStreamOptionsLastTurn from './SeekStreamOptionsLastTurn';
18
+ import SeekStreamOptionsPersonalize from './SeekStreamOptionsPersonalize';
19
+
20
+ /**
21
+ * The SeekOptions model module.
22
+ * @module model/SeekOptions
23
+ * @version 1.0.1
24
+ */
25
+ export default class SeekOptions {
26
+ /**
27
+ * Constructs a new <code>SeekOptions</code>.
28
+ * Optional object for runtime override of Seek options.
29
+ * @alias module:model/SeekOptions
30
+ * @class
31
+ */
32
+ constructor() {
33
+ }
34
+
35
+ /**
36
+ * Constructs a <code>SeekOptions</code> from a plain JavaScript object, optionally creating a new instance.
37
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
38
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
39
+ * @param {module:model/SeekOptions} obj Optional instance to populate.
40
+ * @return {module:model/SeekOptions} The populated <code>SeekOptions</code> instance.
41
+ */
42
+ static constructFromObject(data, obj) {
43
+ if (data) {
44
+ obj = obj || new SeekOptions();
45
+ if (data.hasOwnProperty('personalize'))
46
+ obj.personalize = SeekStreamOptionsPersonalize.constructFromObject(data['personalize']);
47
+ if (data.hasOwnProperty('proposalID'))
48
+ obj.proposalID = ApiClient.convertToType(data['proposalID'], 'String');
49
+ if (data.hasOwnProperty('streaming'))
50
+ obj.streaming = ApiClient.convertToType(data['streaming'], 'Boolean');
51
+ if (data.hasOwnProperty('seekLLM'))
52
+ obj.seekLLM = ApiClient.convertToType(data['seekLLM'], 'String');
53
+ if (data.hasOwnProperty('language'))
54
+ obj.language = ApiClient.convertToType(data['language'], 'String');
55
+ if (data.hasOwnProperty('filter'))
56
+ obj.filter = ApiClient.convertToType(data['filter'], 'String');
57
+ if (data.hasOwnProperty('lastTurn'))
58
+ obj.lastTurn = ApiClient.convertToType(data['lastTurn'], [SeekStreamOptionsLastTurn]);
59
+ if (data.hasOwnProperty('promptEngineering'))
60
+ obj.promptEngineering = ApiClient.convertToType(data['promptEngineering'], 'String');
61
+ if (data.hasOwnProperty('promptEngineeringPhrase'))
62
+ obj.promptEngineeringPhrase = ApiClient.convertToType(data['promptEngineeringPhrase'], 'String');
63
+ if (data.hasOwnProperty('answerLength'))
64
+ obj.answerLength = ApiClient.convertToType(data['answerLength'], 'Number');
65
+ if (data.hasOwnProperty('url'))
66
+ obj.url = ApiClient.convertToType(data['url'], 'String');
67
+ if (data.hasOwnProperty('stump'))
68
+ obj.stump = ApiClient.convertToType(data['stump'], 'String');
69
+ if (data.hasOwnProperty('includeSourceResults'))
70
+ obj.includeSourceResults = ApiClient.convertToType(data['includeSourceResults'], 'Boolean');
71
+ if (data.hasOwnProperty('includeHighlights'))
72
+ obj.includeHighlights = ApiClient.convertToType(data['includeHighlights'], 'Boolean');
73
+ if (data.hasOwnProperty('includeSourceResultsFormatted'))
74
+ obj.includeSourceResultsFormatted = ApiClient.convertToType(data['includeSourceResultsFormatted'], 'Boolean');
75
+ if (data.hasOwnProperty('sourceResultsNumber'))
76
+ obj.sourceResultsNumber = ApiClient.convertToType(data['sourceResultsNumber'], 'Number');
77
+ if (data.hasOwnProperty('sourceResultsSummaryLength'))
78
+ obj.sourceResultsSummaryLength = ApiClient.convertToType(data['sourceResultsSummaryLength'], 'Number');
79
+ if (data.hasOwnProperty('returnVariables'))
80
+ obj.returnVariables = ApiClient.convertToType(data['returnVariables'], 'Boolean');
81
+ if (data.hasOwnProperty('returnVariablesExpanded'))
82
+ obj.returnVariablesExpanded = ApiClient.convertToType(data['returnVariablesExpanded'], 'Boolean');
83
+ }
84
+ return obj;
85
+ }
86
+ }
87
+
88
+ /**
89
+ * @member {module:model/SeekStreamOptionsPersonalize} personalize
90
+ */
91
+ SeekOptions.prototype.personalize = undefined;
92
+
93
+ /**
94
+ * Override all settings by passing a NeuralSeek Proposal ID.
95
+ * @member {String} proposalID
96
+ * @default ''
97
+ */
98
+ SeekOptions.prototype.proposalID = '';
99
+
100
+ /**
101
+ * Return the response via SSE streaming. This is not compatible with most Virtual Agent platforms, and is intentded for direct website use.
102
+ * @member {Boolean} streaming
103
+ * @default false
104
+ */
105
+ SeekOptions.prototype.streaming = false;
106
+
107
+ /**
108
+ * Override the LLM load balancer and force seek to use a specific LLM. Input the LLM code here. You must have a valid model card set up on the configure tab for the code you input.
109
+ * @member {String} seekLLM
110
+ * @default ''
111
+ */
112
+ SeekOptions.prototype.seekLLM = '';
113
+
114
+ /**
115
+ * Valid values are: en, es, de, it, fr, ja, ar
116
+ * @member {String} language
117
+ * @default ''
118
+ */
119
+ SeekOptions.prototype.language = '';
120
+
121
+ /**
122
+ * Text to use as a filter against the filter field set in the KnowledgeBase configuration. Use commas to separate multiple strings for an 'or' filter. You can use the filter to isolate a certain subset of documents in the knowledgebase.
123
+ * @member {String} filter
124
+ * @default ''
125
+ */
126
+ SeekOptions.prototype.filter = '';
127
+
128
+ /**
129
+ * lastTurn is a flexible object. It is backwards compatible with the original single turn object, as well as compatible with the Watson Assistant session history format.
130
+ * @member {Array.<module:model/SeekStreamOptionsLastTurn>} lastTurn
131
+ */
132
+ SeekOptions.prototype.lastTurn = undefined;
133
+
134
+ /**
135
+ * Enable Prompt engineering. Valid values are the strings 'true' and 'false'
136
+ * @member {String} promptEngineering
137
+ * @default ''
138
+ */
139
+ SeekOptions.prototype.promptEngineering = '';
140
+
141
+ /**
142
+ * Prepend a phrase to cleansed user input. Must enable Prompt Engineering inside the NeuralSeek \"Configure\" page
143
+ * @member {String} promptEngineeringPhrase
144
+ * @default ''
145
+ */
146
+ SeekOptions.prototype.promptEngineeringPhrase = '';
147
+
148
+ /**
149
+ * The verbosity of the answer. A whole number 1-4
150
+ * @member {Number} answerLength
151
+ */
152
+ SeekOptions.prototype.answerLength = undefined;
153
+
154
+ /**
155
+ * URL of the current page when using with a web-based Virtual Agent
156
+ * @member {String} url
157
+ * @default ''
158
+ */
159
+ SeekOptions.prototype.url = '';
160
+
161
+ /**
162
+ * Stump Speech text. Fallback for when all else fails.
163
+ * @member {String} stump
164
+ * @default ''
165
+ */
166
+ SeekOptions.prototype.stump = '';
167
+
168
+ /**
169
+ * Include generation source results. Defaults to false.
170
+ * @member {Boolean} includeSourceResults
171
+ * @default false
172
+ */
173
+ SeekOptions.prototype.includeSourceResults = false;
174
+
175
+ /**
176
+ * Include highlights from source results. Defaults to false.
177
+ * @member {Boolean} includeHighlights
178
+ * @default false
179
+ */
180
+ SeekOptions.prototype.includeHighlights = false;
181
+
182
+ /**
183
+ * Include generation source results, and output them into a formatted string. Defaults to false.
184
+ * @member {Boolean} includeSourceResultsFormatted
185
+ * @default false
186
+ */
187
+ SeekOptions.prototype.includeSourceResultsFormatted = false;
188
+
189
+ /**
190
+ * When including source results, how many to include.'
191
+ * @member {Number} sourceResultsNumber
192
+ * @default 3
193
+ */
194
+ SeekOptions.prototype.sourceResultsNumber = 3;
195
+
196
+ /**
197
+ * When including source results, how long of a summary to include.'
198
+ * @member {Number} sourceResultsSummaryLength
199
+ * @default 100
200
+ */
201
+ SeekOptions.prototype.sourceResultsSummaryLength = 100;
202
+
203
+ /**
204
+ * Return the final state of all variables in a dense object
205
+ * @member {Boolean} returnVariables
206
+ * @default false
207
+ */
208
+ SeekOptions.prototype.returnVariables = false;
209
+
210
+ /**
211
+ * Return the final state of all variables in the same format as the input params
212
+ * @member {Boolean} returnVariablesExpanded
213
+ * @default false
214
+ */
215
+ SeekOptions.prototype.returnVariablesExpanded = false;
216
+
@@ -0,0 +1,281 @@
1
+ /*
2
+ * NeuralSeek
3
+ * NeuralSeek - The business LLM accelerator
4
+ *
5
+ * OpenAPI spec version: 1.0.1
6
+ * Contact: support@NeuralSeek.com
7
+ *
8
+ * NOTE: This class is auto generated by the swagger code generator program.
9
+ * https://github.com/swagger-api/swagger-codegen.git
10
+ *
11
+ * Swagger Codegen version: 3.0.78
12
+ *
13
+ * Do not edit the class manually.
14
+ *
15
+ */
16
+ import ApiClient from '../ApiClient';
17
+ import SeekResponsePassages from './SeekResponsePassages';
18
+ import SeekResponseVariablesExpanded from './SeekResponseVariablesExpanded';
19
+
20
+ /**
21
+ * The SeekResponse model module.
22
+ * @module model/SeekResponse
23
+ * @version 1.0.1
24
+ */
25
+ export default class SeekResponse {
26
+ /**
27
+ * Constructs a new <code>SeekResponse</code>.
28
+ * @alias module:model/SeekResponse
29
+ * @class
30
+ * @param answer {String} The generated answer
31
+ * @param score {Number} The final confidence score of the answer (0-100)
32
+ */
33
+ constructor(answer, score) {
34
+ this.answer = answer;
35
+ this.score = score;
36
+ }
37
+
38
+ /**
39
+ * Constructs a <code>SeekResponse</code> from a plain JavaScript object, optionally creating a new instance.
40
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
41
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
42
+ * @param {module:model/SeekResponse} obj Optional instance to populate.
43
+ * @return {module:model/SeekResponse} The populated <code>SeekResponse</code> instance.
44
+ */
45
+ static constructFromObject(data, obj) {
46
+ if (data) {
47
+ obj = obj || new SeekResponse();
48
+ if (data.hasOwnProperty('answer'))
49
+ obj.answer = ApiClient.convertToType(data['answer'], 'String');
50
+ if (data.hasOwnProperty('ufa'))
51
+ obj.ufa = ApiClient.convertToType(data['ufa'], 'String');
52
+ if (data.hasOwnProperty('answerId'))
53
+ obj.answerId = ApiClient.convertToType(data['answerId'], 'String');
54
+ if (data.hasOwnProperty('thumbs'))
55
+ obj.thumbs = ApiClient.convertToType(data['thumbs'], 'String');
56
+ if (data.hasOwnProperty('thumbsSVG'))
57
+ obj.thumbsSVG = ApiClient.convertToType(data['thumbsSVG'], 'String');
58
+ if (data.hasOwnProperty('intent'))
59
+ obj.intent = ApiClient.convertToType(data['intent'], 'String');
60
+ if (data.hasOwnProperty('category'))
61
+ obj.category = ApiClient.convertToType(data['category'], 'Number');
62
+ if (data.hasOwnProperty('categoryName'))
63
+ obj.categoryName = ApiClient.convertToType(data['categoryName'], 'String');
64
+ if (data.hasOwnProperty('score'))
65
+ obj.score = ApiClient.convertToType(data['score'], 'Number');
66
+ if (data.hasOwnProperty('KBscore'))
67
+ obj.kBscore = ApiClient.convertToType(data['KBscore'], 'Number');
68
+ if (data.hasOwnProperty('semanticAnalysis'))
69
+ obj.semanticAnalysis = ApiClient.convertToType(data['semanticAnalysis'], 'String');
70
+ if (data.hasOwnProperty('cachedResult'))
71
+ obj.cachedResult = ApiClient.convertToType(data['cachedResult'], 'String');
72
+ if (data.hasOwnProperty('langCode'))
73
+ obj.langCode = ApiClient.convertToType(data['langCode'], 'String');
74
+ if (data.hasOwnProperty('url'))
75
+ obj.url = ApiClient.convertToType(data['url'], 'String');
76
+ if (data.hasOwnProperty('document'))
77
+ obj.document = ApiClient.convertToType(data['document'], 'String');
78
+ if (data.hasOwnProperty('time'))
79
+ obj.time = ApiClient.convertToType(data['time'], 'Number');
80
+ if (data.hasOwnProperty('kbTime'))
81
+ obj.kbTime = ApiClient.convertToType(data['kbTime'], 'Number');
82
+ if (data.hasOwnProperty('protectTime'))
83
+ obj.protectTime = ApiClient.convertToType(data['protectTime'], 'Number');
84
+ if (data.hasOwnProperty('categorySelectionTime'))
85
+ obj.categorySelectionTime = ApiClient.convertToType(data['categorySelectionTime'], 'Number');
86
+ if (data.hasOwnProperty('promptInjection'))
87
+ obj.promptInjection = ApiClient.convertToType(data['promptInjection'], 'Number');
88
+ if (data.hasOwnProperty('sourceResultsFormatted'))
89
+ obj.sourceResultsFormatted = ApiClient.convertToType(data['sourceResultsFormatted'], 'String');
90
+ if (data.hasOwnProperty('passages'))
91
+ obj.passages = ApiClient.convertToType(data['passages'], [SeekResponsePassages]);
92
+ if (data.hasOwnProperty('kbCoverage'))
93
+ obj.kbCoverage = ApiClient.convertToType(data['kbCoverage'], 'Number');
94
+ if (data.hasOwnProperty('sentiment'))
95
+ obj.sentiment = ApiClient.convertToType(data['sentiment'], 'Number');
96
+ if (data.hasOwnProperty('semanticScore'))
97
+ obj.semanticScore = ApiClient.convertToType(data['semanticScore'], 'Number');
98
+ if (data.hasOwnProperty('variables'))
99
+ obj.variables = ApiClient.convertToType(data['variables'], Object);
100
+ if (data.hasOwnProperty('variablesExpanded'))
101
+ obj.variablesExpanded = ApiClient.convertToType(data['variablesExpanded'], [SeekResponseVariablesExpanded]);
102
+ }
103
+ return obj;
104
+ }
105
+ }
106
+
107
+ /**
108
+ * The generated answer
109
+ * @member {String} answer
110
+ * @default ''
111
+ */
112
+ SeekResponse.prototype.answer = '';
113
+
114
+ /**
115
+ * The raw answer from the LLM before guardrails are applied.
116
+ * @member {String} ufa
117
+ * @default ''
118
+ */
119
+ SeekResponse.prototype.ufa = '';
120
+
121
+ /**
122
+ * The id of the answer. Use this to refer to it from other endpoints, such as the Rating endpoint
123
+ * @member {String} answerId
124
+ * @default ''
125
+ */
126
+ SeekResponse.prototype.answerId = '';
127
+
128
+ /**
129
+ * The URL of a rating HTML page with an SVG to embed with the answer to allow easy rating.
130
+ * @member {String} thumbs
131
+ * @default ''
132
+ */
133
+ SeekResponse.prototype.thumbs = '';
134
+
135
+ /**
136
+ * The URL of a rating SVG to display with the answer to allow easy rating.
137
+ * @member {String} thumbsSVG
138
+ * @default ''
139
+ */
140
+ SeekResponse.prototype.thumbsSVG = '';
141
+
142
+ /**
143
+ * The intent of the answer.
144
+ * @member {String} intent
145
+ * @default ''
146
+ */
147
+ SeekResponse.prototype.intent = '';
148
+
149
+ /**
150
+ * The category id of the answer.
151
+ * @member {Number} category
152
+ */
153
+ SeekResponse.prototype.category = undefined;
154
+
155
+ /**
156
+ * The category name of the answer.
157
+ * @member {String} categoryName
158
+ * @default ''
159
+ */
160
+ SeekResponse.prototype.categoryName = '';
161
+
162
+ /**
163
+ * The final confidence score of the answer (0-100)
164
+ * @member {Number} score
165
+ */
166
+ SeekResponse.prototype.score = undefined;
167
+
168
+ /**
169
+ * The KnowledgeBase confidence of the answer's source documentation (0-100)
170
+ * @member {Number} kBscore
171
+ */
172
+ SeekResponse.prototype.kBscore = undefined;
173
+
174
+ /**
175
+ * Semantic Analysis
176
+ * @member {String} semanticAnalysis
177
+ * @default ''
178
+ */
179
+ SeekResponse.prototype.semanticAnalysis = '';
180
+
181
+ /**
182
+ * If the result came from cache, will be set to the string 'true'
183
+ * @member {String} cachedResult
184
+ * @default ''
185
+ */
186
+ SeekResponse.prototype.cachedResult = '';
187
+
188
+ /**
189
+ * The language code of the answer. If you set the input language code to 'xx' to identify the language, this is useful to condition of the found language and response.
190
+ * @member {String} langCode
191
+ * @default ''
192
+ */
193
+ SeekResponse.prototype.langCode = '';
194
+
195
+ /**
196
+ * The top scoring URL (if available) used to train the answer. Set the field you want returned here in on the Configure tab. The field must contain a URL, or it will be ignored.
197
+ * @member {String} url
198
+ * @default ''
199
+ */
200
+ SeekResponse.prototype.url = '';
201
+
202
+ /**
203
+ * The top document (if available) used to train the answer. Set the field you want returned here in on the Configure tab
204
+ * @member {String} document
205
+ * @default ''
206
+ */
207
+ SeekResponse.prototype.document = '';
208
+
209
+ /**
210
+ * Total processing time in milliseconds
211
+ * @member {Number} time
212
+ */
213
+ SeekResponse.prototype.time = undefined;
214
+
215
+ /**
216
+ * KnowledgeBase response time in milliseconds
217
+ * @member {Number} kbTime
218
+ */
219
+ SeekResponse.prototype.kbTime = undefined;
220
+
221
+ /**
222
+ * PI time in milliseconds
223
+ * @member {Number} protectTime
224
+ */
225
+ SeekResponse.prototype.protectTime = undefined;
226
+
227
+ /**
228
+ * Category Selection time in milliseconds
229
+ * @member {Number} categorySelectionTime
230
+ */
231
+ SeekResponse.prototype.categorySelectionTime = undefined;
232
+
233
+ /**
234
+ * Prompt injection value
235
+ * @member {Number} promptInjection
236
+ */
237
+ SeekResponse.prototype.promptInjection = undefined;
238
+
239
+ /**
240
+ * A listing of the passages used for answer summarization. This will only return if includeSourceResultsFormatted is set to true on the request
241
+ * @member {String} sourceResultsFormatted
242
+ * @default ''
243
+ */
244
+ SeekResponse.prototype.sourceResultsFormatted = '';
245
+
246
+ /**
247
+ * A listing of the passages used for answer summarization. This will only return if includeSourceResults is set to true on the request
248
+ * @member {Array.<module:model/SeekResponsePassages>} passages
249
+ */
250
+ SeekResponse.prototype.passages = undefined;
251
+
252
+ /**
253
+ * KnowledgeBase coverage score. How much content was returned from the KnowledgeBase on the subject asked as compared to benchmarks. Low coverage is not necessarily indicitive of bad content.
254
+ * @member {Number} kbCoverage
255
+ */
256
+ SeekResponse.prototype.kbCoverage = undefined;
257
+
258
+ /**
259
+ * Sentiment score
260
+ * @member {Number} sentiment
261
+ */
262
+ SeekResponse.prototype.sentiment = undefined;
263
+
264
+ /**
265
+ * Semantic score (if enabled)
266
+ * @member {Number} semanticScore
267
+ */
268
+ SeekResponse.prototype.semanticScore = undefined;
269
+
270
+ /**
271
+ * The returned variable.
272
+ * @member {Object} variables
273
+ */
274
+ SeekResponse.prototype.variables = undefined;
275
+
276
+ /**
277
+ * The returned variable, in the format of the input params
278
+ * @member {Array.<module:model/SeekResponseVariablesExpanded>} variablesExpanded
279
+ */
280
+ SeekResponse.prototype.variablesExpanded = undefined;
281
+