@peopl-health/nexus 1.7.4 → 1.7.5
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/lib/assistants/BaseAssistant.js +2 -15
- package/lib/index.d.ts +0 -1
- package/package.json +1 -1
|
@@ -7,9 +7,8 @@ const { getLastNMessages } = require('../helpers/assistantHelper');
|
|
|
7
7
|
* and supports dynamic tool registration.
|
|
8
8
|
*/
|
|
9
9
|
class BaseAssistant {
|
|
10
|
-
constructor(
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
constructor(options = {}) {
|
|
11
|
+
console.log('options', options);
|
|
13
12
|
this.assistantId = options.assistantId || null;
|
|
14
13
|
this.thread = options.thread || null;
|
|
15
14
|
this.status = options.status || 'idle';
|
|
@@ -53,18 +52,6 @@ class BaseAssistant {
|
|
|
53
52
|
}
|
|
54
53
|
}
|
|
55
54
|
|
|
56
|
-
_normalizeOptions(input) {
|
|
57
|
-
if (!input || typeof input !== 'object') {
|
|
58
|
-
return { thread: input };
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
if (input && input._id && !input.assistantId && !input.client && !input.tools) {
|
|
62
|
-
return { thread: input };
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
return input;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
55
|
_ensureClient() {
|
|
69
56
|
if (!this.client) {
|
|
70
57
|
throw new Error('LLM client not configured. Ensure openaiClient is initialized.');
|
package/lib/index.d.ts
CHANGED