@tiledesk/tiledesk-tybot-connector 0.2.74 → 0.2.75-rc1

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tiledesk/tiledesk-tybot-connector",
3
- "version": "0.2.74",
3
+ "version": "0.2.75-rc1",
4
4
  "description": "Tiledesk Tybot connector",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -57,11 +57,13 @@ class DirAskGPTV2 {
57
57
 
58
58
  // default values
59
59
  let answer = "No answers";
60
- let source = null;
60
+ let namespace = this.context.projectId;
61
61
  let model = "gpt-3.5-turbo";
62
62
  let temperature;
63
63
  let max_tokens;
64
64
  let top_k;
65
+
66
+ let source = null;
65
67
 
66
68
  if (!action.question || action.question === '') {
67
69
  console.error("Error: DirAskGPT question attribute is mandatory. Executing condition false...");
@@ -73,6 +75,9 @@ class DirAskGPTV2 {
73
75
  return;
74
76
  }
75
77
 
78
+ if (action.namespace) {
79
+ namespace = action.namespace;
80
+ }
76
81
  if (action.model) {
77
82
  model = action.model;
78
83
  }
@@ -143,7 +148,7 @@ class DirAskGPTV2 {
143
148
  let json = {
144
149
  question: filled_question,
145
150
  gptkey: key,
146
- namespace: this.context.projectId,
151
+ namespace: namespace,
147
152
  model: model
148
153
  };
149
154
  if (top_k) {