@otto-code/protocol 0.8.9 → 0.8.12
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/agent-queue.d.ts +87 -0
- package/dist/agent-queue.js +106 -0
- package/dist/brain.d.ts +2321 -0
- package/dist/brain.js +1082 -0
- package/dist/client-capabilities.d.ts +2 -0
- package/dist/client-capabilities.js +10 -0
- package/dist/code-intelligence.d.ts +917 -0
- package/dist/code-intelligence.js +699 -0
- package/dist/communications.d.ts +1106 -0
- package/dist/communications.js +384 -0
- package/dist/context.d.ts +787 -0
- package/dist/context.js +295 -0
- package/dist/daemon-config.d.ts +377 -0
- package/dist/daemon-config.js +395 -0
- package/dist/file-operations.d.ts +380 -0
- package/dist/file-operations.js +282 -0
- package/dist/generated/validation/ws-outbound.aot.js +54927 -48878
- package/dist/git-hosting.d.ts +117 -0
- package/dist/git-hosting.js +109 -0
- package/dist/git-operations.d.ts +255 -0
- package/dist/git-operations.js +221 -0
- package/dist/integration-authorization.d.ts +195 -0
- package/dist/integration-authorization.js +125 -0
- package/dist/kanban.d.ts +341 -0
- package/dist/kanban.js +273 -0
- package/dist/loop/rpc-schemas.d.ts +6 -6
- package/dist/meetings.d.ts +95 -0
- package/dist/meetings.js +57 -0
- package/dist/messages.d.ts +21054 -24042
- package/dist/messages.js +4355 -8731
- package/dist/orchestration.d.ts +726 -0
- package/dist/orchestration.js +232 -0
- package/dist/personality-schemas.d.ts +221 -0
- package/dist/personality-schemas.js +340 -0
- package/dist/preview.d.ts +140 -0
- package/dist/preview.js +98 -0
- package/dist/project-knowledge.d.ts +740 -0
- package/dist/project-knowledge.js +229 -0
- package/dist/project-links.d.ts +102 -0
- package/dist/project-links.js +62 -0
- package/dist/provider-config.d.ts +87 -2
- package/dist/provider-config.js +110 -0
- package/dist/refine.d.ts +93 -0
- package/dist/refine.js +78 -0
- package/dist/schedule/rpc-schemas.d.ts +47 -47
- package/dist/schedule/types.d.ts +13 -13
- package/dist/speech.d.ts +180 -0
- package/dist/speech.js +177 -0
- package/dist/storage.d.ts +79 -0
- package/dist/storage.js +107 -0
- package/dist/suggested-tasks.d.ts +106 -0
- package/dist/suggested-tasks.js +81 -0
- package/dist/terminal-compatibility.d.ts +55 -0
- package/dist/terminal-compatibility.js +35 -0
- package/dist/usage-stats.d.ts +255 -0
- package/dist/usage-stats.js +162 -0
- package/dist/validation/ws-outbound-schema-metadata.d.ts +1404 -274
- package/dist/worktree-ops.d.ts +81 -0
- package/dist/worktree-ops.js +88 -0
- package/package.json +1 -1
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* Otto steer-queue wire schemas: the agent.queue.* remove, reorder and clear RPCs and the queued-message payload. Fork-only capability, so it owns its schemas; messages.ts re-exports them.
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* One message parked for delivery as an agent's NEXT turn (`delivery: "queue"`).
|
|
7
|
+
* The daemon owns the queue; this is the read-only projection the Queue track
|
|
8
|
+
* renders. Declared above AgentSnapshotPayloadSchema - zod-aot emits schemas in
|
|
9
|
+
* source order, so a forward reference is a build-time ReferenceError.
|
|
10
|
+
*/
|
|
11
|
+
export declare const QueuedAgentMessagePayloadSchema: z.ZodObject<{
|
|
12
|
+
id: z.ZodString;
|
|
13
|
+
preview: z.ZodString;
|
|
14
|
+
enqueuedAt: z.ZodString;
|
|
15
|
+
attachmentCount: z.ZodOptional<z.ZodNumber>;
|
|
16
|
+
source: z.ZodOptional<z.ZodEnum<{
|
|
17
|
+
user: "user";
|
|
18
|
+
system: "system";
|
|
19
|
+
}>>;
|
|
20
|
+
}, z.core.$strip>;
|
|
21
|
+
/** Pull one message back out of an agent's queue (Queue-track edit / send now). */
|
|
22
|
+
export declare const AgentQueueRemoveRequestMessageSchema: z.ZodObject<{
|
|
23
|
+
type: z.ZodLiteral<"agent.queue.remove.request">;
|
|
24
|
+
requestId: z.ZodString;
|
|
25
|
+
agentId: z.ZodString;
|
|
26
|
+
messageId: z.ZodString;
|
|
27
|
+
}, z.core.$strip>;
|
|
28
|
+
/**
|
|
29
|
+
* Move one queued message to a different position in an agent's queue.
|
|
30
|
+
*
|
|
31
|
+
* Order is what the queue means, so this is the edit that changes the next
|
|
32
|
+
* turn's content without changing the queue's membership. The daemon resolves
|
|
33
|
+
* `messageId` fresh and clamps `toIndex`, so a client acting on a snapshot that
|
|
34
|
+
* is one drain stale reorders what is actually there or reports `moved: false`.
|
|
35
|
+
* COMPAT(steerQueueReorder): added in v0.6.9, drop the gate when floor >= v0.6.9.
|
|
36
|
+
*/
|
|
37
|
+
export declare const AgentQueueReorderRequestMessageSchema: z.ZodObject<{
|
|
38
|
+
type: z.ZodLiteral<"agent.queue.reorder.request">;
|
|
39
|
+
requestId: z.ZodString;
|
|
40
|
+
agentId: z.ZodString;
|
|
41
|
+
messageId: z.ZodString;
|
|
42
|
+
toIndex: z.ZodNumber;
|
|
43
|
+
}, z.core.$strip>;
|
|
44
|
+
/** Drop every message queued behind an agent's current turn. */
|
|
45
|
+
export declare const AgentQueueClearRequestMessageSchema: z.ZodObject<{
|
|
46
|
+
type: z.ZodLiteral<"agent.queue.clear.request">;
|
|
47
|
+
requestId: z.ZodString;
|
|
48
|
+
agentId: z.ZodString;
|
|
49
|
+
}, z.core.$strip>;
|
|
50
|
+
export declare const AgentQueueRemoveResponseMessageSchema: z.ZodObject<{
|
|
51
|
+
type: z.ZodLiteral<"agent.queue.remove.response">;
|
|
52
|
+
payload: z.ZodObject<{
|
|
53
|
+
requestId: z.ZodString;
|
|
54
|
+
agentId: z.ZodString;
|
|
55
|
+
removed: z.ZodNullable<z.ZodObject<{
|
|
56
|
+
id: z.ZodString;
|
|
57
|
+
text: z.ZodString;
|
|
58
|
+
}, z.core.$strip>>;
|
|
59
|
+
error: z.ZodNullable<z.ZodString>;
|
|
60
|
+
}, z.core.$strip>;
|
|
61
|
+
}, z.core.$strip>;
|
|
62
|
+
export declare const AgentQueueReorderResponseMessageSchema: z.ZodObject<{
|
|
63
|
+
type: z.ZodLiteral<"agent.queue.reorder.response">;
|
|
64
|
+
payload: z.ZodObject<{
|
|
65
|
+
requestId: z.ZodString;
|
|
66
|
+
agentId: z.ZodString;
|
|
67
|
+
moved: z.ZodBoolean;
|
|
68
|
+
error: z.ZodNullable<z.ZodString>;
|
|
69
|
+
}, z.core.$strip>;
|
|
70
|
+
}, z.core.$strip>;
|
|
71
|
+
export declare const AgentQueueClearResponseMessageSchema: z.ZodObject<{
|
|
72
|
+
type: z.ZodLiteral<"agent.queue.clear.response">;
|
|
73
|
+
payload: z.ZodObject<{
|
|
74
|
+
requestId: z.ZodString;
|
|
75
|
+
agentId: z.ZodString;
|
|
76
|
+
clearedCount: z.ZodNumber;
|
|
77
|
+
error: z.ZodNullable<z.ZodString>;
|
|
78
|
+
}, z.core.$strip>;
|
|
79
|
+
}, z.core.$strip>;
|
|
80
|
+
export type QueuedAgentMessagePayload = z.infer<typeof QueuedAgentMessagePayloadSchema>;
|
|
81
|
+
export type AgentQueueRemoveRequestMessage = z.infer<typeof AgentQueueRemoveRequestMessageSchema>;
|
|
82
|
+
export type AgentQueueRemoveResponseMessage = z.infer<typeof AgentQueueRemoveResponseMessageSchema>;
|
|
83
|
+
export type AgentQueueReorderRequestMessage = z.infer<typeof AgentQueueReorderRequestMessageSchema>;
|
|
84
|
+
export type AgentQueueReorderResponseMessage = z.infer<typeof AgentQueueReorderResponseMessageSchema>;
|
|
85
|
+
export type AgentQueueClearRequestMessage = z.infer<typeof AgentQueueClearRequestMessageSchema>;
|
|
86
|
+
export type AgentQueueClearResponseMessage = z.infer<typeof AgentQueueClearResponseMessageSchema>;
|
|
87
|
+
//# sourceMappingURL=agent-queue.d.ts.map
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* Otto steer-queue wire schemas: the agent.queue.* remove, reorder and clear RPCs and the queued-message payload. Fork-only capability, so it owns its schemas; messages.ts re-exports them.
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* One message parked for delivery as an agent's NEXT turn (`delivery: "queue"`).
|
|
7
|
+
* The daemon owns the queue; this is the read-only projection the Queue track
|
|
8
|
+
* renders. Declared above AgentSnapshotPayloadSchema - zod-aot emits schemas in
|
|
9
|
+
* source order, so a forward reference is a build-time ReferenceError.
|
|
10
|
+
*/
|
|
11
|
+
export const QueuedAgentMessagePayloadSchema = z.object({
|
|
12
|
+
id: z.string(),
|
|
13
|
+
/** Leading text of the message, truncated for display. */
|
|
14
|
+
preview: z.string(),
|
|
15
|
+
enqueuedAt: z.string(),
|
|
16
|
+
attachmentCount: z.number().int().nonnegative().optional(),
|
|
17
|
+
/**
|
|
18
|
+
* Who parked the message. Absent (from an older daemon) or "user" is a normal
|
|
19
|
+
* user turn; "system" marks a system-injected entry (a chat mention, a
|
|
20
|
+
* scheduled fire) that the daemon's drain never merges into a user turn - the
|
|
21
|
+
* client must likewise exclude it from "Send all".
|
|
22
|
+
*/
|
|
23
|
+
source: z.enum(["user", "system"]).optional(),
|
|
24
|
+
});
|
|
25
|
+
/** Pull one message back out of an agent's queue (Queue-track edit / send now). */
|
|
26
|
+
export const AgentQueueRemoveRequestMessageSchema = z.object({
|
|
27
|
+
type: z.literal("agent.queue.remove.request"),
|
|
28
|
+
requestId: z.string(),
|
|
29
|
+
/** Accepts full ID, unique prefix, or exact full title (server resolves). */
|
|
30
|
+
agentId: z.string(),
|
|
31
|
+
/** The queued message's `id` from `AgentSnapshotPayload.queuedMessages`. */
|
|
32
|
+
messageId: z.string(),
|
|
33
|
+
});
|
|
34
|
+
/**
|
|
35
|
+
* Move one queued message to a different position in an agent's queue.
|
|
36
|
+
*
|
|
37
|
+
* Order is what the queue means, so this is the edit that changes the next
|
|
38
|
+
* turn's content without changing the queue's membership. The daemon resolves
|
|
39
|
+
* `messageId` fresh and clamps `toIndex`, so a client acting on a snapshot that
|
|
40
|
+
* is one drain stale reorders what is actually there or reports `moved: false`.
|
|
41
|
+
* COMPAT(steerQueueReorder): added in v0.6.9, drop the gate when floor >= v0.6.9.
|
|
42
|
+
*/
|
|
43
|
+
export const AgentQueueReorderRequestMessageSchema = z.object({
|
|
44
|
+
type: z.literal("agent.queue.reorder.request"),
|
|
45
|
+
requestId: z.string(),
|
|
46
|
+
/** Accepts full ID, unique prefix, or exact full title (server resolves). */
|
|
47
|
+
agentId: z.string(),
|
|
48
|
+
/** The queued message's `id` from `AgentSnapshotPayload.queuedMessages`. */
|
|
49
|
+
messageId: z.string(),
|
|
50
|
+
/** Zero-based destination, clamped to the queue's current length. */
|
|
51
|
+
toIndex: z.number().int().nonnegative(),
|
|
52
|
+
});
|
|
53
|
+
/** Drop every message queued behind an agent's current turn. */
|
|
54
|
+
export const AgentQueueClearRequestMessageSchema = z.object({
|
|
55
|
+
type: z.literal("agent.queue.clear.request"),
|
|
56
|
+
requestId: z.string(),
|
|
57
|
+
/** Accepts full ID, unique prefix, or exact full title (server resolves). */
|
|
58
|
+
agentId: z.string(),
|
|
59
|
+
});
|
|
60
|
+
export const AgentQueueRemoveResponseMessageSchema = z.object({
|
|
61
|
+
type: z.literal("agent.queue.remove.response"),
|
|
62
|
+
payload: z.object({
|
|
63
|
+
requestId: z.string(),
|
|
64
|
+
agentId: z.string(),
|
|
65
|
+
/**
|
|
66
|
+
* The removed message's text, handed back so the composer can put it back
|
|
67
|
+
* in the box for editing or re-send it right away. Null when the id was
|
|
68
|
+
* already gone - the turn drained it while the tap was in flight.
|
|
69
|
+
* Attachments are not echoed: the client that queued the message keeps its
|
|
70
|
+
* own local copy keyed by `id` (see the composer's queued-attachment
|
|
71
|
+
* sidecar), and a client that never queued it has nothing to restore.
|
|
72
|
+
*/
|
|
73
|
+
removed: z
|
|
74
|
+
.object({
|
|
75
|
+
id: z.string(),
|
|
76
|
+
text: z.string(),
|
|
77
|
+
})
|
|
78
|
+
.nullable(),
|
|
79
|
+
error: z.string().nullable(),
|
|
80
|
+
}),
|
|
81
|
+
});
|
|
82
|
+
export const AgentQueueReorderResponseMessageSchema = z.object({
|
|
83
|
+
type: z.literal("agent.queue.reorder.response"),
|
|
84
|
+
payload: z.object({
|
|
85
|
+
requestId: z.string(),
|
|
86
|
+
agentId: z.string(),
|
|
87
|
+
/**
|
|
88
|
+
* False when the id was already gone (the turn drained it while the tap was
|
|
89
|
+
* in flight) or the entry was already at that position. The authoritative
|
|
90
|
+
* order arrives on the agent snapshot either way, so a client only needs
|
|
91
|
+
* this to decide whether to surface an error.
|
|
92
|
+
*/
|
|
93
|
+
moved: z.boolean(),
|
|
94
|
+
error: z.string().nullable(),
|
|
95
|
+
}),
|
|
96
|
+
});
|
|
97
|
+
export const AgentQueueClearResponseMessageSchema = z.object({
|
|
98
|
+
type: z.literal("agent.queue.clear.response"),
|
|
99
|
+
payload: z.object({
|
|
100
|
+
requestId: z.string(),
|
|
101
|
+
agentId: z.string(),
|
|
102
|
+
clearedCount: z.number().int().nonnegative(),
|
|
103
|
+
error: z.string().nullable(),
|
|
104
|
+
}),
|
|
105
|
+
});
|
|
106
|
+
//# sourceMappingURL=agent-queue.js.map
|