triangle-types 1.0.33 → 1.0.35
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/dist/src/types/fragments/Fragment.js +1 -1
- package/dist/src/types/scout/UserScoutConversationMessage.d.ts +1 -0
- package/dist/src/types/scout/UserScoutConversationMessage.js +3 -0
- package/package.json +1 -1
- package/src/types/fragments/Fragment.ts +1 -1
- package/src/types/scout/UserScoutConversationMessage.ts +3 -0
|
@@ -22,7 +22,7 @@ export class Fragment {
|
|
|
22
22
|
typeof fragment.max_size === "number" &&
|
|
23
23
|
typeof fragment.min_index === "number" &&
|
|
24
24
|
typeof fragment.max_index === "number" &&
|
|
25
|
-
typeof fragment.title === "
|
|
25
|
+
typeof fragment.title === "string" &&
|
|
26
26
|
typeof fragment.text === "string");
|
|
27
27
|
}
|
|
28
28
|
}
|
|
@@ -11,6 +11,7 @@ export declare class UserScoutConversationMessage {
|
|
|
11
11
|
readonly user_scout_conversation_id: string;
|
|
12
12
|
readonly role_id: UserScoutConversationRoleID;
|
|
13
13
|
readonly system_prompt?: string;
|
|
14
|
+
readonly fragment_ids?: string[];
|
|
14
15
|
readonly text: string;
|
|
15
16
|
constructor(user_scout_conversation_message: any);
|
|
16
17
|
static is(user_scout_conversation_message: any): user_scout_conversation_message is UserScoutConversationMessage;
|
|
@@ -12,6 +12,7 @@ export class UserScoutConversationMessage {
|
|
|
12
12
|
user_scout_conversation_id;
|
|
13
13
|
role_id;
|
|
14
14
|
system_prompt;
|
|
15
|
+
fragment_ids;
|
|
15
16
|
text;
|
|
16
17
|
constructor(user_scout_conversation_message) {
|
|
17
18
|
if (!UserScoutConversationMessage.is(user_scout_conversation_message)) {
|
|
@@ -26,6 +27,7 @@ export class UserScoutConversationMessage {
|
|
|
26
27
|
this.user_scout_conversation_id = user_scout_conversation_message.user_scout_conversation_id;
|
|
27
28
|
this.role_id = user_scout_conversation_message.role_id;
|
|
28
29
|
this.system_prompt = user_scout_conversation_message.system_prompt;
|
|
30
|
+
this.fragment_ids = user_scout_conversation_message.fragment_ids;
|
|
29
31
|
this.text = user_scout_conversation_message.text;
|
|
30
32
|
}
|
|
31
33
|
static is(user_scout_conversation_message) {
|
|
@@ -39,6 +41,7 @@ export class UserScoutConversationMessage {
|
|
|
39
41
|
typeof user_scout_conversation_message.user_scout_conversation_id === "string" &&
|
|
40
42
|
is_user_scout_conversation_role_id(user_scout_conversation_message.role_id) &&
|
|
41
43
|
(user_scout_conversation_message.system_prompt === undefined || typeof user_scout_conversation_message.system_prompt === "string") &&
|
|
44
|
+
(user_scout_conversation_message.fragment_ids === undefined || Array.isArray(user_scout_conversation_message.fragment_ids) && user_scout_conversation_message.fragment_ids.every((fragment_id) => typeof fragment_id === "string")) &&
|
|
42
45
|
typeof user_scout_conversation_message.text === "string");
|
|
43
46
|
}
|
|
44
47
|
}
|
package/package.json
CHANGED
|
@@ -26,7 +26,7 @@ export class Fragment {
|
|
|
26
26
|
typeof fragment.max_size === "number" &&
|
|
27
27
|
typeof fragment.min_index === "number" &&
|
|
28
28
|
typeof fragment.max_index === "number" &&
|
|
29
|
-
typeof fragment.title === "
|
|
29
|
+
typeof fragment.title === "string" &&
|
|
30
30
|
typeof fragment.text === "string"
|
|
31
31
|
)
|
|
32
32
|
}
|
|
@@ -16,6 +16,7 @@ export class UserScoutConversationMessage {
|
|
|
16
16
|
readonly user_scout_conversation_id : string
|
|
17
17
|
readonly role_id : UserScoutConversationRoleID
|
|
18
18
|
readonly system_prompt? : string
|
|
19
|
+
readonly fragment_ids? : string[]
|
|
19
20
|
readonly text : string
|
|
20
21
|
|
|
21
22
|
constructor(user_scout_conversation_message : any) {
|
|
@@ -31,6 +32,7 @@ export class UserScoutConversationMessage {
|
|
|
31
32
|
this.user_scout_conversation_id = user_scout_conversation_message.user_scout_conversation_id
|
|
32
33
|
this.role_id = user_scout_conversation_message.role_id
|
|
33
34
|
this.system_prompt = user_scout_conversation_message.system_prompt
|
|
35
|
+
this.fragment_ids = user_scout_conversation_message.fragment_ids
|
|
34
36
|
this.text = user_scout_conversation_message.text
|
|
35
37
|
}
|
|
36
38
|
|
|
@@ -46,6 +48,7 @@ export class UserScoutConversationMessage {
|
|
|
46
48
|
typeof user_scout_conversation_message.user_scout_conversation_id === "string" &&
|
|
47
49
|
is_user_scout_conversation_role_id(user_scout_conversation_message.role_id) &&
|
|
48
50
|
(user_scout_conversation_message.system_prompt === undefined || typeof user_scout_conversation_message.system_prompt === "string") &&
|
|
51
|
+
(user_scout_conversation_message.fragment_ids === undefined || Array.isArray(user_scout_conversation_message.fragment_ids) && user_scout_conversation_message.fragment_ids.every((fragment_id : any) => typeof fragment_id === "string")) &&
|
|
49
52
|
typeof user_scout_conversation_message.text === "string"
|
|
50
53
|
)
|
|
51
54
|
}
|