@neta-art/cohub-protocol 1.4.0 → 1.5.0
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/core/content.d.ts
CHANGED
package/dist/model/session.d.ts
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
import type { ContentBlock } from "../core/content.js";
|
|
2
2
|
import type { Usage } from "../core/usage.js";
|
|
3
|
+
export type SessionForkRecord = {
|
|
4
|
+
id: string;
|
|
5
|
+
spaceId: string;
|
|
6
|
+
parentSessionId: string;
|
|
7
|
+
childSessionId: string;
|
|
8
|
+
rootSessionId: string;
|
|
9
|
+
depth: number;
|
|
10
|
+
anchorSourceSessionId: string;
|
|
11
|
+
anchorTurnId: string;
|
|
12
|
+
anchorSequence: number;
|
|
13
|
+
ancestorSessionIds: string[];
|
|
14
|
+
sessionPath: string[];
|
|
15
|
+
createdBy: string | null;
|
|
16
|
+
createdAt: string;
|
|
17
|
+
};
|
|
18
|
+
export type SessionTurnSegmentRecord = {
|
|
19
|
+
id: string;
|
|
20
|
+
sessionId: string;
|
|
21
|
+
ordinal: number;
|
|
22
|
+
sourceSessionId: string;
|
|
23
|
+
fromSequence: number;
|
|
24
|
+
toSequence: number | null;
|
|
25
|
+
createdAt: string;
|
|
26
|
+
};
|
|
3
27
|
export type { MessageToolCallsFile, SessionTurnIntent, SessionTurnIntermediateIndex, SessionTurnIntermediateSummary, SessionTurnIndexItem, SessionTurnRecord, SessionTurnStatus, SessionTurnSummary, StoredIntermediateMessage, StoredToolCall, TurnIntermediateMessagesFile, } from "./turn.js";
|
|
4
28
|
export type SessionPromptInput = {
|
|
5
29
|
spaceId: string;
|
|
@@ -74,10 +98,6 @@ export type SessionRecord = {
|
|
|
74
98
|
status: string | null;
|
|
75
99
|
externalSessionId: string | null;
|
|
76
100
|
meta: Record<string, unknown> | null;
|
|
77
|
-
parentSessionId: string | null;
|
|
78
|
-
forkedFromMessageId: string | null;
|
|
79
|
-
lineageRootSessionId: string | null;
|
|
80
|
-
forkDepth: number;
|
|
81
101
|
latestMessageText: string | null;
|
|
82
102
|
lastMessageAt: string | null;
|
|
83
103
|
lastMessageId: string | null;
|
package/dist/model/turn.d.ts
CHANGED
|
@@ -67,6 +67,8 @@ export type TurnIntermediateMessagesFile = {
|
|
|
67
67
|
export type SessionTurnIndexItem = {
|
|
68
68
|
id: string;
|
|
69
69
|
sessionId: string;
|
|
70
|
+
sourceSessionId?: string;
|
|
71
|
+
sourceTurnId?: string;
|
|
70
72
|
sequence: number;
|
|
71
73
|
status: SessionTurnStatus;
|
|
72
74
|
startedAt: string | null;
|
|
@@ -89,6 +91,8 @@ export type SessionTurnAuthorProfile = {
|
|
|
89
91
|
export type SessionTurnRecord = {
|
|
90
92
|
id: string;
|
|
91
93
|
sessionId: string;
|
|
94
|
+
sourceSessionId?: string;
|
|
95
|
+
sourceTurnId?: string;
|
|
92
96
|
userUuid: string | null;
|
|
93
97
|
sequence: number;
|
|
94
98
|
status: SessionTurnStatus;
|
|
@@ -24,6 +24,11 @@ export declare const contentBlockSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
24
24
|
data: z.ZodString;
|
|
25
25
|
}, z.core.$strip>]>;
|
|
26
26
|
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
27
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
28
|
+
type: z.ZodLiteral<"shell_command">;
|
|
29
|
+
command: z.ZodString;
|
|
30
|
+
rawText: z.ZodString;
|
|
31
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
27
32
|
}, z.core.$strip>, z.ZodObject<{
|
|
28
33
|
type: z.ZodLiteral<"tool_use">;
|
|
29
34
|
id: z.ZodString;
|
|
@@ -81,6 +86,11 @@ export declare const wsClientEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
81
86
|
data: z.ZodString;
|
|
82
87
|
}, z.core.$strip>]>;
|
|
83
88
|
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
89
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
90
|
+
type: z.ZodLiteral<"shell_command">;
|
|
91
|
+
command: z.ZodString;
|
|
92
|
+
rawText: z.ZodString;
|
|
93
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
84
94
|
}, z.core.$strip>, z.ZodObject<{
|
|
85
95
|
type: z.ZodLiteral<"tool_use">;
|
|
86
96
|
id: z.ZodString;
|
|
@@ -21,6 +21,12 @@ export const contentBlockSchema = z.discriminatedUnion("type", [
|
|
|
21
21
|
]),
|
|
22
22
|
_meta: contentBlockMetaSchema.optional(),
|
|
23
23
|
}),
|
|
24
|
+
z.object({
|
|
25
|
+
type: z.literal("shell_command"),
|
|
26
|
+
command: z.string(),
|
|
27
|
+
rawText: z.string(),
|
|
28
|
+
_meta: contentBlockMetaSchema.optional(),
|
|
29
|
+
}),
|
|
24
30
|
z.object({
|
|
25
31
|
type: z.literal("tool_use"),
|
|
26
32
|
id: z.string(),
|