@av-pi-studio/protocol 0.0.99 → 0.0.101

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.
@@ -36,6 +36,7 @@ export declare const SERVER_FEATURES: {
36
36
  readonly extensionPacks: "extensionPacks";
37
37
  readonly providerAuth: "providerAuth";
38
38
  readonly extensionUi: "extensionUi";
39
+ readonly thinkingLevels: "thinkingLevels";
39
40
  };
40
41
  export type ServerFeatureKey = keyof typeof SERVER_FEATURES;
41
42
  export type ServerFeature = (typeof SERVER_FEATURES)[ServerFeatureKey];
@@ -40,6 +40,7 @@ export const SERVER_FEATURES = {
40
40
  extensionPacks: "extensionPacks",
41
41
  providerAuth: "providerAuth",
42
42
  extensionUi: "extensionUi",
43
+ thinkingLevels: "thinkingLevels",
43
44
  };
44
45
  /**
45
46
  * COMPAT annotations for each server feature flag (version added + removal date). The removal dates
@@ -73,6 +74,8 @@ export const SERVER_FEATURE_COMPAT = {
73
74
  providerAuth: COMPAT({ name: "providerAuth", addedIn: "0.0.0", removeBy: "TBD" }),
74
75
  // COMPAT(extensionUi): added 0.0.0, remove by TBD
75
76
  extensionUi: COMPAT({ name: "extensionUi", addedIn: "0.0.0", removeBy: "TBD" }),
77
+ // COMPAT(thinkingLevels): added 0.0.0, remove by TBD
78
+ thinkingLevels: COMPAT({ name: "thinkingLevels", addedIn: "0.0.0", removeBy: "TBD" }),
76
79
  };
77
80
  /**
78
81
  * Returns true only if `flag` is advertised by `caps`. Used at serialization time to gate new wire
@@ -49,12 +49,19 @@ export type Hello = z.infer<typeof helloSchema>;
49
49
  /**
50
50
  * The `server_info` payload carried by the `status` envelope. There is no dedicated welcome
51
51
  * message — the server emits this after accepting the hello, then begins streaming.
52
+ *
53
+ * `homeDir` is the daemon host's home directory (`os.homedir()`), the authoritative value clients
54
+ * expand a `~`-prefixed `cwd`/path against. It is the daemon's home, not the client's: a browser on
55
+ * macOS may drive a Linux daemon (or vice versa), so a client MUST never derive it locally.
56
+ * Optional only for wire compatibility with daemons predating it — a client that gets no value
57
+ * leaves tilde paths unexpanded rather than guessing.
52
58
  */
53
59
  export declare const serverInfoPayloadSchema: z.ZodObject<{
54
60
  status: z.ZodLiteral<"server_info">;
55
61
  serverId: z.ZodString;
56
62
  hostname: z.ZodOptional<z.ZodString>;
57
63
  version: z.ZodOptional<z.ZodString>;
64
+ homeDir: z.ZodOptional<z.ZodString>;
58
65
  capabilities: z.ZodRecord<z.ZodString, z.ZodUnknown>;
59
66
  features: z.ZodRecord<z.ZodString, z.ZodUnknown>;
60
67
  }, "strip", z.ZodTypeAny, {
@@ -62,6 +69,7 @@ export declare const serverInfoPayloadSchema: z.ZodObject<{
62
69
  serverId: string;
63
70
  hostname?: string | undefined;
64
71
  version?: string | undefined;
72
+ homeDir?: string | undefined;
65
73
  capabilities: Record<string, unknown>;
66
74
  features: Record<string, unknown>;
67
75
  }, {
@@ -69,6 +77,7 @@ export declare const serverInfoPayloadSchema: z.ZodObject<{
69
77
  serverId: string;
70
78
  hostname?: string | undefined;
71
79
  version?: string | undefined;
80
+ homeDir?: string | undefined;
72
81
  capabilities: Record<string, unknown>;
73
82
  features: Record<string, unknown>;
74
83
  }>;
@@ -81,6 +90,7 @@ export declare const statusSchema: z.ZodObject<{
81
90
  serverId: z.ZodString;
82
91
  hostname: z.ZodOptional<z.ZodString>;
83
92
  version: z.ZodOptional<z.ZodString>;
93
+ homeDir: z.ZodOptional<z.ZodString>;
84
94
  capabilities: z.ZodRecord<z.ZodString, z.ZodUnknown>;
85
95
  features: z.ZodRecord<z.ZodString, z.ZodUnknown>;
86
96
  }, "strip", z.ZodTypeAny, {
@@ -88,6 +98,7 @@ export declare const statusSchema: z.ZodObject<{
88
98
  serverId: string;
89
99
  hostname?: string | undefined;
90
100
  version?: string | undefined;
101
+ homeDir?: string | undefined;
91
102
  capabilities: Record<string, unknown>;
92
103
  features: Record<string, unknown>;
93
104
  }, {
@@ -95,6 +106,7 @@ export declare const statusSchema: z.ZodObject<{
95
106
  serverId: string;
96
107
  hostname?: string | undefined;
97
108
  version?: string | undefined;
109
+ homeDir?: string | undefined;
98
110
  capabilities: Record<string, unknown>;
99
111
  features: Record<string, unknown>;
100
112
  }>;
@@ -105,6 +117,7 @@ export declare const statusSchema: z.ZodObject<{
105
117
  serverId: string;
106
118
  hostname?: string | undefined;
107
119
  version?: string | undefined;
120
+ homeDir?: string | undefined;
108
121
  capabilities: Record<string, unknown>;
109
122
  features: Record<string, unknown>;
110
123
  };
@@ -115,6 +128,7 @@ export declare const statusSchema: z.ZodObject<{
115
128
  serverId: string;
116
129
  hostname?: string | undefined;
117
130
  version?: string | undefined;
131
+ homeDir?: string | undefined;
118
132
  capabilities: Record<string, unknown>;
119
133
  features: Record<string, unknown>;
120
134
  };
@@ -2828,6 +2842,133 @@ export declare const agentCycleModelResponseSchema: z.ZodObject<{
2828
2842
  }, z.ZodTypeAny, "passthrough">>;
2829
2843
  }, z.ZodTypeAny, "passthrough">>;
2830
2844
  export type AgentCycleModelResponse = z.infer<typeof agentCycleModelResponseSchema>;
2845
+ /** Thinking level (set) — sprint-070. `level` is a dynamic string (per-model discovery), not an
2846
+ * enum, matching `agentSessionConfigSchema.thinkingOptionId`'s convention. The response's
2847
+ * `payload.level` is the EFFECTIVE (possibly Pi-clamped) level, never the requested one. */
2848
+ export declare const agentSetThinkingRequestSchema: z.ZodObject<{
2849
+ type: z.ZodLiteral<"agent_set_thinking_request">;
2850
+ requestId: z.ZodString;
2851
+ agentId: z.ZodString;
2852
+ level: z.ZodString;
2853
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2854
+ type: z.ZodLiteral<"agent_set_thinking_request">;
2855
+ requestId: z.ZodString;
2856
+ agentId: z.ZodString;
2857
+ level: z.ZodString;
2858
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2859
+ type: z.ZodLiteral<"agent_set_thinking_request">;
2860
+ requestId: z.ZodString;
2861
+ agentId: z.ZodString;
2862
+ level: z.ZodString;
2863
+ }, z.ZodTypeAny, "passthrough">>;
2864
+ export type AgentSetThinkingRequest = z.infer<typeof agentSetThinkingRequestSchema>;
2865
+ export declare const agentSetThinkingResponseSchema: z.ZodObject<{
2866
+ type: z.ZodLiteral<"agent_set_thinking_response">;
2867
+ requestId: z.ZodString;
2868
+ payload: z.ZodObject<{
2869
+ agentId: z.ZodString;
2870
+ /** Effective level after provider clamping. */
2871
+ level: z.ZodString;
2872
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2873
+ agentId: z.ZodString;
2874
+ /** Effective level after provider clamping. */
2875
+ level: z.ZodString;
2876
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2877
+ agentId: z.ZodString;
2878
+ /** Effective level after provider clamping. */
2879
+ level: z.ZodString;
2880
+ }, z.ZodTypeAny, "passthrough">>;
2881
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2882
+ type: z.ZodLiteral<"agent_set_thinking_response">;
2883
+ requestId: z.ZodString;
2884
+ payload: z.ZodObject<{
2885
+ agentId: z.ZodString;
2886
+ /** Effective level after provider clamping. */
2887
+ level: z.ZodString;
2888
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2889
+ agentId: z.ZodString;
2890
+ /** Effective level after provider clamping. */
2891
+ level: z.ZodString;
2892
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2893
+ agentId: z.ZodString;
2894
+ /** Effective level after provider clamping. */
2895
+ level: z.ZodString;
2896
+ }, z.ZodTypeAny, "passthrough">>;
2897
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2898
+ type: z.ZodLiteral<"agent_set_thinking_response">;
2899
+ requestId: z.ZodString;
2900
+ payload: z.ZodObject<{
2901
+ agentId: z.ZodString;
2902
+ /** Effective level after provider clamping. */
2903
+ level: z.ZodString;
2904
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2905
+ agentId: z.ZodString;
2906
+ /** Effective level after provider clamping. */
2907
+ level: z.ZodString;
2908
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2909
+ agentId: z.ZodString;
2910
+ /** Effective level after provider clamping. */
2911
+ level: z.ZodString;
2912
+ }, z.ZodTypeAny, "passthrough">>;
2913
+ }, z.ZodTypeAny, "passthrough">>;
2914
+ export type AgentSetThinkingResponse = z.infer<typeof agentSetThinkingResponseSchema>;
2915
+ /** Thinking levels (list) — sprint-070. Live sessions only; drafts answer from the model
2916
+ * catalogue client-side (features/thinking-level-selector.md § Level discovery). */
2917
+ export declare const agentThinkingLevelsRequestSchema: z.ZodObject<{
2918
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
2919
+ requestId: z.ZodString;
2920
+ agentId: z.ZodString;
2921
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2922
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
2923
+ requestId: z.ZodString;
2924
+ agentId: z.ZodString;
2925
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2926
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
2927
+ requestId: z.ZodString;
2928
+ agentId: z.ZodString;
2929
+ }, z.ZodTypeAny, "passthrough">>;
2930
+ export type AgentThinkingLevelsRequest = z.infer<typeof agentThinkingLevelsRequestSchema>;
2931
+ export declare const agentThinkingLevelsResponseSchema: z.ZodObject<{
2932
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
2933
+ requestId: z.ZodString;
2934
+ payload: z.ZodObject<{
2935
+ agentId: z.ZodString;
2936
+ levels: z.ZodArray<z.ZodString, "many">;
2937
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2938
+ agentId: z.ZodString;
2939
+ levels: z.ZodArray<z.ZodString, "many">;
2940
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2941
+ agentId: z.ZodString;
2942
+ levels: z.ZodArray<z.ZodString, "many">;
2943
+ }, z.ZodTypeAny, "passthrough">>;
2944
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2945
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
2946
+ requestId: z.ZodString;
2947
+ payload: z.ZodObject<{
2948
+ agentId: z.ZodString;
2949
+ levels: z.ZodArray<z.ZodString, "many">;
2950
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2951
+ agentId: z.ZodString;
2952
+ levels: z.ZodArray<z.ZodString, "many">;
2953
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2954
+ agentId: z.ZodString;
2955
+ levels: z.ZodArray<z.ZodString, "many">;
2956
+ }, z.ZodTypeAny, "passthrough">>;
2957
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2958
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
2959
+ requestId: z.ZodString;
2960
+ payload: z.ZodObject<{
2961
+ agentId: z.ZodString;
2962
+ levels: z.ZodArray<z.ZodString, "many">;
2963
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
2964
+ agentId: z.ZodString;
2965
+ levels: z.ZodArray<z.ZodString, "many">;
2966
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
2967
+ agentId: z.ZodString;
2968
+ levels: z.ZodArray<z.ZodString, "many">;
2969
+ }, z.ZodTypeAny, "passthrough">>;
2970
+ }, z.ZodTypeAny, "passthrough">>;
2971
+ export type AgentThinkingLevelsResponse = z.infer<typeof agentThinkingLevelsResponseSchema>;
2831
2972
  /** `/copy` — mirrors Pi RPC `get_last_assistant_text`. */
2832
2973
  export declare const agentLastAssistantTextRequestSchema: z.ZodObject<{
2833
2974
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
@@ -9022,6 +9163,120 @@ export declare const sessionMessageSchema: z.ZodDiscriminatedUnion<"type", [z.Zo
9022
9163
  thinkingLevel: z.ZodOptional<z.ZodString>;
9023
9164
  isScoped: z.ZodOptional<z.ZodBoolean>;
9024
9165
  }, z.ZodTypeAny, "passthrough">>;
9166
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
9167
+ type: z.ZodLiteral<"agent_set_thinking_request">;
9168
+ requestId: z.ZodString;
9169
+ agentId: z.ZodString;
9170
+ level: z.ZodString;
9171
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9172
+ type: z.ZodLiteral<"agent_set_thinking_request">;
9173
+ requestId: z.ZodString;
9174
+ agentId: z.ZodString;
9175
+ level: z.ZodString;
9176
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9177
+ type: z.ZodLiteral<"agent_set_thinking_request">;
9178
+ requestId: z.ZodString;
9179
+ agentId: z.ZodString;
9180
+ level: z.ZodString;
9181
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
9182
+ type: z.ZodLiteral<"agent_set_thinking_response">;
9183
+ requestId: z.ZodString;
9184
+ payload: z.ZodObject<{
9185
+ agentId: z.ZodString;
9186
+ /** Effective level after provider clamping. */
9187
+ level: z.ZodString;
9188
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9189
+ agentId: z.ZodString;
9190
+ /** Effective level after provider clamping. */
9191
+ level: z.ZodString;
9192
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9193
+ agentId: z.ZodString;
9194
+ /** Effective level after provider clamping. */
9195
+ level: z.ZodString;
9196
+ }, z.ZodTypeAny, "passthrough">>;
9197
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9198
+ type: z.ZodLiteral<"agent_set_thinking_response">;
9199
+ requestId: z.ZodString;
9200
+ payload: z.ZodObject<{
9201
+ agentId: z.ZodString;
9202
+ /** Effective level after provider clamping. */
9203
+ level: z.ZodString;
9204
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9205
+ agentId: z.ZodString;
9206
+ /** Effective level after provider clamping. */
9207
+ level: z.ZodString;
9208
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9209
+ agentId: z.ZodString;
9210
+ /** Effective level after provider clamping. */
9211
+ level: z.ZodString;
9212
+ }, z.ZodTypeAny, "passthrough">>;
9213
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9214
+ type: z.ZodLiteral<"agent_set_thinking_response">;
9215
+ requestId: z.ZodString;
9216
+ payload: z.ZodObject<{
9217
+ agentId: z.ZodString;
9218
+ /** Effective level after provider clamping. */
9219
+ level: z.ZodString;
9220
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9221
+ agentId: z.ZodString;
9222
+ /** Effective level after provider clamping. */
9223
+ level: z.ZodString;
9224
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9225
+ agentId: z.ZodString;
9226
+ /** Effective level after provider clamping. */
9227
+ level: z.ZodString;
9228
+ }, z.ZodTypeAny, "passthrough">>;
9229
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
9230
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
9231
+ requestId: z.ZodString;
9232
+ agentId: z.ZodString;
9233
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9234
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
9235
+ requestId: z.ZodString;
9236
+ agentId: z.ZodString;
9237
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9238
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
9239
+ requestId: z.ZodString;
9240
+ agentId: z.ZodString;
9241
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
9242
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
9243
+ requestId: z.ZodString;
9244
+ payload: z.ZodObject<{
9245
+ agentId: z.ZodString;
9246
+ levels: z.ZodArray<z.ZodString, "many">;
9247
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9248
+ agentId: z.ZodString;
9249
+ levels: z.ZodArray<z.ZodString, "many">;
9250
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9251
+ agentId: z.ZodString;
9252
+ levels: z.ZodArray<z.ZodString, "many">;
9253
+ }, z.ZodTypeAny, "passthrough">>;
9254
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9255
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
9256
+ requestId: z.ZodString;
9257
+ payload: z.ZodObject<{
9258
+ agentId: z.ZodString;
9259
+ levels: z.ZodArray<z.ZodString, "many">;
9260
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9261
+ agentId: z.ZodString;
9262
+ levels: z.ZodArray<z.ZodString, "many">;
9263
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9264
+ agentId: z.ZodString;
9265
+ levels: z.ZodArray<z.ZodString, "many">;
9266
+ }, z.ZodTypeAny, "passthrough">>;
9267
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9268
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
9269
+ requestId: z.ZodString;
9270
+ payload: z.ZodObject<{
9271
+ agentId: z.ZodString;
9272
+ levels: z.ZodArray<z.ZodString, "many">;
9273
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
9274
+ agentId: z.ZodString;
9275
+ levels: z.ZodArray<z.ZodString, "many">;
9276
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
9277
+ agentId: z.ZodString;
9278
+ levels: z.ZodArray<z.ZodString, "many">;
9279
+ }, z.ZodTypeAny, "passthrough">>;
9025
9280
  }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
9026
9281
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
9027
9282
  requestId: z.ZodString;
@@ -14541,6 +14796,120 @@ export declare const sessionEnvelopeSchema: z.ZodObject<{
14541
14796
  thinkingLevel: z.ZodOptional<z.ZodString>;
14542
14797
  isScoped: z.ZodOptional<z.ZodBoolean>;
14543
14798
  }, z.ZodTypeAny, "passthrough">>;
14799
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
14800
+ type: z.ZodLiteral<"agent_set_thinking_request">;
14801
+ requestId: z.ZodString;
14802
+ agentId: z.ZodString;
14803
+ level: z.ZodString;
14804
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14805
+ type: z.ZodLiteral<"agent_set_thinking_request">;
14806
+ requestId: z.ZodString;
14807
+ agentId: z.ZodString;
14808
+ level: z.ZodString;
14809
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14810
+ type: z.ZodLiteral<"agent_set_thinking_request">;
14811
+ requestId: z.ZodString;
14812
+ agentId: z.ZodString;
14813
+ level: z.ZodString;
14814
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
14815
+ type: z.ZodLiteral<"agent_set_thinking_response">;
14816
+ requestId: z.ZodString;
14817
+ payload: z.ZodObject<{
14818
+ agentId: z.ZodString;
14819
+ /** Effective level after provider clamping. */
14820
+ level: z.ZodString;
14821
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14822
+ agentId: z.ZodString;
14823
+ /** Effective level after provider clamping. */
14824
+ level: z.ZodString;
14825
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14826
+ agentId: z.ZodString;
14827
+ /** Effective level after provider clamping. */
14828
+ level: z.ZodString;
14829
+ }, z.ZodTypeAny, "passthrough">>;
14830
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14831
+ type: z.ZodLiteral<"agent_set_thinking_response">;
14832
+ requestId: z.ZodString;
14833
+ payload: z.ZodObject<{
14834
+ agentId: z.ZodString;
14835
+ /** Effective level after provider clamping. */
14836
+ level: z.ZodString;
14837
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14838
+ agentId: z.ZodString;
14839
+ /** Effective level after provider clamping. */
14840
+ level: z.ZodString;
14841
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14842
+ agentId: z.ZodString;
14843
+ /** Effective level after provider clamping. */
14844
+ level: z.ZodString;
14845
+ }, z.ZodTypeAny, "passthrough">>;
14846
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14847
+ type: z.ZodLiteral<"agent_set_thinking_response">;
14848
+ requestId: z.ZodString;
14849
+ payload: z.ZodObject<{
14850
+ agentId: z.ZodString;
14851
+ /** Effective level after provider clamping. */
14852
+ level: z.ZodString;
14853
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14854
+ agentId: z.ZodString;
14855
+ /** Effective level after provider clamping. */
14856
+ level: z.ZodString;
14857
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14858
+ agentId: z.ZodString;
14859
+ /** Effective level after provider clamping. */
14860
+ level: z.ZodString;
14861
+ }, z.ZodTypeAny, "passthrough">>;
14862
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
14863
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
14864
+ requestId: z.ZodString;
14865
+ agentId: z.ZodString;
14866
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14867
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
14868
+ requestId: z.ZodString;
14869
+ agentId: z.ZodString;
14870
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14871
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
14872
+ requestId: z.ZodString;
14873
+ agentId: z.ZodString;
14874
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
14875
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
14876
+ requestId: z.ZodString;
14877
+ payload: z.ZodObject<{
14878
+ agentId: z.ZodString;
14879
+ levels: z.ZodArray<z.ZodString, "many">;
14880
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14881
+ agentId: z.ZodString;
14882
+ levels: z.ZodArray<z.ZodString, "many">;
14883
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14884
+ agentId: z.ZodString;
14885
+ levels: z.ZodArray<z.ZodString, "many">;
14886
+ }, z.ZodTypeAny, "passthrough">>;
14887
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14888
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
14889
+ requestId: z.ZodString;
14890
+ payload: z.ZodObject<{
14891
+ agentId: z.ZodString;
14892
+ levels: z.ZodArray<z.ZodString, "many">;
14893
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14894
+ agentId: z.ZodString;
14895
+ levels: z.ZodArray<z.ZodString, "many">;
14896
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14897
+ agentId: z.ZodString;
14898
+ levels: z.ZodArray<z.ZodString, "many">;
14899
+ }, z.ZodTypeAny, "passthrough">>;
14900
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14901
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
14902
+ requestId: z.ZodString;
14903
+ payload: z.ZodObject<{
14904
+ agentId: z.ZodString;
14905
+ levels: z.ZodArray<z.ZodString, "many">;
14906
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
14907
+ agentId: z.ZodString;
14908
+ levels: z.ZodArray<z.ZodString, "many">;
14909
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
14910
+ agentId: z.ZodString;
14911
+ levels: z.ZodArray<z.ZodString, "many">;
14912
+ }, z.ZodTypeAny, "passthrough">>;
14544
14913
  }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
14545
14914
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
14546
14915
  requestId: z.ZodString;
@@ -18562,6 +18931,44 @@ export declare const sessionEnvelopeSchema: z.ZodObject<{
18562
18931
  thinkingLevel: z.ZodOptional<z.ZodString>;
18563
18932
  isScoped: z.ZodOptional<z.ZodBoolean>;
18564
18933
  }, z.ZodTypeAny, "passthrough">>;
18934
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
18935
+ type: z.ZodLiteral<"agent_set_thinking_request">;
18936
+ requestId: z.ZodString;
18937
+ agentId: z.ZodString;
18938
+ level: z.ZodString;
18939
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
18940
+ type: z.ZodLiteral<"agent_set_thinking_response">;
18941
+ requestId: z.ZodString;
18942
+ payload: z.ZodObject<{
18943
+ agentId: z.ZodString;
18944
+ /** Effective level after provider clamping. */
18945
+ level: z.ZodString;
18946
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
18947
+ agentId: z.ZodString;
18948
+ /** Effective level after provider clamping. */
18949
+ level: z.ZodString;
18950
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
18951
+ agentId: z.ZodString;
18952
+ /** Effective level after provider clamping. */
18953
+ level: z.ZodString;
18954
+ }, z.ZodTypeAny, "passthrough">>;
18955
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
18956
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
18957
+ requestId: z.ZodString;
18958
+ agentId: z.ZodString;
18959
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
18960
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
18961
+ requestId: z.ZodString;
18962
+ payload: z.ZodObject<{
18963
+ agentId: z.ZodString;
18964
+ levels: z.ZodArray<z.ZodString, "many">;
18965
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
18966
+ agentId: z.ZodString;
18967
+ levels: z.ZodArray<z.ZodString, "many">;
18968
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
18969
+ agentId: z.ZodString;
18970
+ levels: z.ZodArray<z.ZodString, "many">;
18971
+ }, z.ZodTypeAny, "passthrough">>;
18565
18972
  }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
18566
18973
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
18567
18974
  requestId: z.ZodString;
@@ -20285,6 +20692,44 @@ export declare const sessionEnvelopeSchema: z.ZodObject<{
20285
20692
  thinkingLevel: z.ZodOptional<z.ZodString>;
20286
20693
  isScoped: z.ZodOptional<z.ZodBoolean>;
20287
20694
  }, z.ZodTypeAny, "passthrough">>;
20695
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
20696
+ type: z.ZodLiteral<"agent_set_thinking_request">;
20697
+ requestId: z.ZodString;
20698
+ agentId: z.ZodString;
20699
+ level: z.ZodString;
20700
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
20701
+ type: z.ZodLiteral<"agent_set_thinking_response">;
20702
+ requestId: z.ZodString;
20703
+ payload: z.ZodObject<{
20704
+ agentId: z.ZodString;
20705
+ /** Effective level after provider clamping. */
20706
+ level: z.ZodString;
20707
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
20708
+ agentId: z.ZodString;
20709
+ /** Effective level after provider clamping. */
20710
+ level: z.ZodString;
20711
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
20712
+ agentId: z.ZodString;
20713
+ /** Effective level after provider clamping. */
20714
+ level: z.ZodString;
20715
+ }, z.ZodTypeAny, "passthrough">>;
20716
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
20717
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
20718
+ requestId: z.ZodString;
20719
+ agentId: z.ZodString;
20720
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
20721
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
20722
+ requestId: z.ZodString;
20723
+ payload: z.ZodObject<{
20724
+ agentId: z.ZodString;
20725
+ levels: z.ZodArray<z.ZodString, "many">;
20726
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
20727
+ agentId: z.ZodString;
20728
+ levels: z.ZodArray<z.ZodString, "many">;
20729
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
20730
+ agentId: z.ZodString;
20731
+ levels: z.ZodArray<z.ZodString, "many">;
20732
+ }, z.ZodTypeAny, "passthrough">>;
20288
20733
  }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
20289
20734
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
20290
20735
  requestId: z.ZodString;
@@ -21457,6 +21902,7 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
21457
21902
  serverId: z.ZodString;
21458
21903
  hostname: z.ZodOptional<z.ZodString>;
21459
21904
  version: z.ZodOptional<z.ZodString>;
21905
+ homeDir: z.ZodOptional<z.ZodString>;
21460
21906
  capabilities: z.ZodRecord<z.ZodString, z.ZodUnknown>;
21461
21907
  features: z.ZodRecord<z.ZodString, z.ZodUnknown>;
21462
21908
  }, "strip", z.ZodTypeAny, {
@@ -21464,6 +21910,7 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
21464
21910
  serverId: string;
21465
21911
  hostname?: string | undefined;
21466
21912
  version?: string | undefined;
21913
+ homeDir?: string | undefined;
21467
21914
  capabilities: Record<string, unknown>;
21468
21915
  features: Record<string, unknown>;
21469
21916
  }, {
@@ -21471,6 +21918,7 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
21471
21918
  serverId: string;
21472
21919
  hostname?: string | undefined;
21473
21920
  version?: string | undefined;
21921
+ homeDir?: string | undefined;
21474
21922
  capabilities: Record<string, unknown>;
21475
21923
  features: Record<string, unknown>;
21476
21924
  }>;
@@ -21481,6 +21929,7 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
21481
21929
  serverId: string;
21482
21930
  hostname?: string | undefined;
21483
21931
  version?: string | undefined;
21932
+ homeDir?: string | undefined;
21484
21933
  capabilities: Record<string, unknown>;
21485
21934
  features: Record<string, unknown>;
21486
21935
  };
@@ -21491,6 +21940,7 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
21491
21940
  serverId: string;
21492
21941
  hostname?: string | undefined;
21493
21942
  version?: string | undefined;
21943
+ homeDir?: string | undefined;
21494
21944
  capabilities: Record<string, unknown>;
21495
21945
  features: Record<string, unknown>;
21496
21946
  };
@@ -23591,6 +24041,120 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
23591
24041
  thinkingLevel: z.ZodOptional<z.ZodString>;
23592
24042
  isScoped: z.ZodOptional<z.ZodBoolean>;
23593
24043
  }, z.ZodTypeAny, "passthrough">>;
24044
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
24045
+ type: z.ZodLiteral<"agent_set_thinking_request">;
24046
+ requestId: z.ZodString;
24047
+ agentId: z.ZodString;
24048
+ level: z.ZodString;
24049
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24050
+ type: z.ZodLiteral<"agent_set_thinking_request">;
24051
+ requestId: z.ZodString;
24052
+ agentId: z.ZodString;
24053
+ level: z.ZodString;
24054
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24055
+ type: z.ZodLiteral<"agent_set_thinking_request">;
24056
+ requestId: z.ZodString;
24057
+ agentId: z.ZodString;
24058
+ level: z.ZodString;
24059
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
24060
+ type: z.ZodLiteral<"agent_set_thinking_response">;
24061
+ requestId: z.ZodString;
24062
+ payload: z.ZodObject<{
24063
+ agentId: z.ZodString;
24064
+ /** Effective level after provider clamping. */
24065
+ level: z.ZodString;
24066
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24067
+ agentId: z.ZodString;
24068
+ /** Effective level after provider clamping. */
24069
+ level: z.ZodString;
24070
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24071
+ agentId: z.ZodString;
24072
+ /** Effective level after provider clamping. */
24073
+ level: z.ZodString;
24074
+ }, z.ZodTypeAny, "passthrough">>;
24075
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24076
+ type: z.ZodLiteral<"agent_set_thinking_response">;
24077
+ requestId: z.ZodString;
24078
+ payload: z.ZodObject<{
24079
+ agentId: z.ZodString;
24080
+ /** Effective level after provider clamping. */
24081
+ level: z.ZodString;
24082
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24083
+ agentId: z.ZodString;
24084
+ /** Effective level after provider clamping. */
24085
+ level: z.ZodString;
24086
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24087
+ agentId: z.ZodString;
24088
+ /** Effective level after provider clamping. */
24089
+ level: z.ZodString;
24090
+ }, z.ZodTypeAny, "passthrough">>;
24091
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24092
+ type: z.ZodLiteral<"agent_set_thinking_response">;
24093
+ requestId: z.ZodString;
24094
+ payload: z.ZodObject<{
24095
+ agentId: z.ZodString;
24096
+ /** Effective level after provider clamping. */
24097
+ level: z.ZodString;
24098
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24099
+ agentId: z.ZodString;
24100
+ /** Effective level after provider clamping. */
24101
+ level: z.ZodString;
24102
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24103
+ agentId: z.ZodString;
24104
+ /** Effective level after provider clamping. */
24105
+ level: z.ZodString;
24106
+ }, z.ZodTypeAny, "passthrough">>;
24107
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
24108
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
24109
+ requestId: z.ZodString;
24110
+ agentId: z.ZodString;
24111
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24112
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
24113
+ requestId: z.ZodString;
24114
+ agentId: z.ZodString;
24115
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24116
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
24117
+ requestId: z.ZodString;
24118
+ agentId: z.ZodString;
24119
+ }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
24120
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
24121
+ requestId: z.ZodString;
24122
+ payload: z.ZodObject<{
24123
+ agentId: z.ZodString;
24124
+ levels: z.ZodArray<z.ZodString, "many">;
24125
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24126
+ agentId: z.ZodString;
24127
+ levels: z.ZodArray<z.ZodString, "many">;
24128
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24129
+ agentId: z.ZodString;
24130
+ levels: z.ZodArray<z.ZodString, "many">;
24131
+ }, z.ZodTypeAny, "passthrough">>;
24132
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24133
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
24134
+ requestId: z.ZodString;
24135
+ payload: z.ZodObject<{
24136
+ agentId: z.ZodString;
24137
+ levels: z.ZodArray<z.ZodString, "many">;
24138
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24139
+ agentId: z.ZodString;
24140
+ levels: z.ZodArray<z.ZodString, "many">;
24141
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24142
+ agentId: z.ZodString;
24143
+ levels: z.ZodArray<z.ZodString, "many">;
24144
+ }, z.ZodTypeAny, "passthrough">>;
24145
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24146
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
24147
+ requestId: z.ZodString;
24148
+ payload: z.ZodObject<{
24149
+ agentId: z.ZodString;
24150
+ levels: z.ZodArray<z.ZodString, "many">;
24151
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
24152
+ agentId: z.ZodString;
24153
+ levels: z.ZodArray<z.ZodString, "many">;
24154
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
24155
+ agentId: z.ZodString;
24156
+ levels: z.ZodArray<z.ZodString, "many">;
24157
+ }, z.ZodTypeAny, "passthrough">>;
23594
24158
  }, z.ZodTypeAny, "passthrough">>, z.ZodObject<{
23595
24159
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
23596
24160
  requestId: z.ZodString;
@@ -27612,6 +28176,44 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
27612
28176
  thinkingLevel: z.ZodOptional<z.ZodString>;
27613
28177
  isScoped: z.ZodOptional<z.ZodBoolean>;
27614
28178
  }, z.ZodTypeAny, "passthrough">>;
28179
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
28180
+ type: z.ZodLiteral<"agent_set_thinking_request">;
28181
+ requestId: z.ZodString;
28182
+ agentId: z.ZodString;
28183
+ level: z.ZodString;
28184
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
28185
+ type: z.ZodLiteral<"agent_set_thinking_response">;
28186
+ requestId: z.ZodString;
28187
+ payload: z.ZodObject<{
28188
+ agentId: z.ZodString;
28189
+ /** Effective level after provider clamping. */
28190
+ level: z.ZodString;
28191
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
28192
+ agentId: z.ZodString;
28193
+ /** Effective level after provider clamping. */
28194
+ level: z.ZodString;
28195
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
28196
+ agentId: z.ZodString;
28197
+ /** Effective level after provider clamping. */
28198
+ level: z.ZodString;
28199
+ }, z.ZodTypeAny, "passthrough">>;
28200
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
28201
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
28202
+ requestId: z.ZodString;
28203
+ agentId: z.ZodString;
28204
+ }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
28205
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
28206
+ requestId: z.ZodString;
28207
+ payload: z.ZodObject<{
28208
+ agentId: z.ZodString;
28209
+ levels: z.ZodArray<z.ZodString, "many">;
28210
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
28211
+ agentId: z.ZodString;
28212
+ levels: z.ZodArray<z.ZodString, "many">;
28213
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
28214
+ agentId: z.ZodString;
28215
+ levels: z.ZodArray<z.ZodString, "many">;
28216
+ }, z.ZodTypeAny, "passthrough">>;
27615
28217
  }, z.ZodTypeAny, "passthrough"> | z.objectOutputType<{
27616
28218
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
27617
28219
  requestId: z.ZodString;
@@ -29335,6 +29937,44 @@ export declare const topLevelEnvelopeSchema: z.ZodDiscriminatedUnion<"type", [z.
29335
29937
  thinkingLevel: z.ZodOptional<z.ZodString>;
29336
29938
  isScoped: z.ZodOptional<z.ZodBoolean>;
29337
29939
  }, z.ZodTypeAny, "passthrough">>;
29940
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
29941
+ type: z.ZodLiteral<"agent_set_thinking_request">;
29942
+ requestId: z.ZodString;
29943
+ agentId: z.ZodString;
29944
+ level: z.ZodString;
29945
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
29946
+ type: z.ZodLiteral<"agent_set_thinking_response">;
29947
+ requestId: z.ZodString;
29948
+ payload: z.ZodObject<{
29949
+ agentId: z.ZodString;
29950
+ /** Effective level after provider clamping. */
29951
+ level: z.ZodString;
29952
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
29953
+ agentId: z.ZodString;
29954
+ /** Effective level after provider clamping. */
29955
+ level: z.ZodString;
29956
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
29957
+ agentId: z.ZodString;
29958
+ /** Effective level after provider clamping. */
29959
+ level: z.ZodString;
29960
+ }, z.ZodTypeAny, "passthrough">>;
29961
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
29962
+ type: z.ZodLiteral<"agent_thinking_levels_request">;
29963
+ requestId: z.ZodString;
29964
+ agentId: z.ZodString;
29965
+ }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
29966
+ type: z.ZodLiteral<"agent_thinking_levels_response">;
29967
+ requestId: z.ZodString;
29968
+ payload: z.ZodObject<{
29969
+ agentId: z.ZodString;
29970
+ levels: z.ZodArray<z.ZodString, "many">;
29971
+ }, "passthrough", z.ZodTypeAny, z.objectOutputType<{
29972
+ agentId: z.ZodString;
29973
+ levels: z.ZodArray<z.ZodString, "many">;
29974
+ }, z.ZodTypeAny, "passthrough">, z.objectInputType<{
29975
+ agentId: z.ZodString;
29976
+ levels: z.ZodArray<z.ZodString, "many">;
29977
+ }, z.ZodTypeAny, "passthrough">>;
29338
29978
  }, z.ZodTypeAny, "passthrough"> | z.objectInputType<{
29339
29979
  type: z.ZodLiteral<"agent_last_assistant_text_request">;
29340
29980
  requestId: z.ZodString;
package/dist/messages.js CHANGED
@@ -39,12 +39,19 @@ export const helloSchema = z.object({
39
39
  /**
40
40
  * The `server_info` payload carried by the `status` envelope. There is no dedicated welcome
41
41
  * message — the server emits this after accepting the hello, then begins streaming.
42
+ *
43
+ * `homeDir` is the daemon host's home directory (`os.homedir()`), the authoritative value clients
44
+ * expand a `~`-prefixed `cwd`/path against. It is the daemon's home, not the client's: a browser on
45
+ * macOS may drive a Linux daemon (or vice versa), so a client MUST never derive it locally.
46
+ * Optional only for wire compatibility with daemons predating it — a client that gets no value
47
+ * leaves tilde paths unexpanded rather than guessing.
42
48
  */
43
49
  export const serverInfoPayloadSchema = z.object({
44
50
  status: z.literal("server_info"),
45
51
  serverId: z.string(),
46
52
  hostname: z.string().optional(),
47
53
  version: z.string().optional(),
54
+ homeDir: z.string().optional(),
48
55
  capabilities: z.record(z.string(), z.unknown()),
49
56
  features: z.record(z.string(), z.unknown()),
50
57
  });
@@ -576,6 +583,51 @@ export const agentCycleModelResponseSchema = z
576
583
  .passthrough(),
577
584
  })
578
585
  .passthrough();
586
+ /** Thinking level (set) — sprint-070. `level` is a dynamic string (per-model discovery), not an
587
+ * enum, matching `agentSessionConfigSchema.thinkingOptionId`'s convention. The response's
588
+ * `payload.level` is the EFFECTIVE (possibly Pi-clamped) level, never the requested one. */
589
+ export const agentSetThinkingRequestSchema = z
590
+ .object({
591
+ type: z.literal("agent_set_thinking_request"),
592
+ requestId: z.string(),
593
+ agentId: z.string(),
594
+ level: z.string(),
595
+ })
596
+ .passthrough();
597
+ export const agentSetThinkingResponseSchema = z
598
+ .object({
599
+ type: z.literal("agent_set_thinking_response"),
600
+ requestId: z.string(),
601
+ payload: z
602
+ .object({
603
+ agentId: z.string(),
604
+ /** Effective level after provider clamping. */
605
+ level: z.string(),
606
+ })
607
+ .passthrough(),
608
+ })
609
+ .passthrough();
610
+ /** Thinking levels (list) — sprint-070. Live sessions only; drafts answer from the model
611
+ * catalogue client-side (features/thinking-level-selector.md § Level discovery). */
612
+ export const agentThinkingLevelsRequestSchema = z
613
+ .object({
614
+ type: z.literal("agent_thinking_levels_request"),
615
+ requestId: z.string(),
616
+ agentId: z.string(),
617
+ })
618
+ .passthrough();
619
+ export const agentThinkingLevelsResponseSchema = z
620
+ .object({
621
+ type: z.literal("agent_thinking_levels_response"),
622
+ requestId: z.string(),
623
+ payload: z
624
+ .object({
625
+ agentId: z.string(),
626
+ levels: z.array(z.string()),
627
+ })
628
+ .passthrough(),
629
+ })
630
+ .passthrough();
579
631
  /** `/copy` — mirrors Pi RPC `get_last_assistant_text`. */
580
632
  export const agentLastAssistantTextRequestSchema = z
581
633
  .object({
@@ -1079,6 +1131,10 @@ export const sessionMessageSchema = z.discriminatedUnion("type", [
1079
1131
  agentSetModelResponseSchema,
1080
1132
  agentCycleModelRequestSchema,
1081
1133
  agentCycleModelResponseSchema,
1134
+ agentSetThinkingRequestSchema,
1135
+ agentSetThinkingResponseSchema,
1136
+ agentThinkingLevelsRequestSchema,
1137
+ agentThinkingLevelsResponseSchema,
1082
1138
  agentLastAssistantTextRequestSchema,
1083
1139
  agentLastAssistantTextResponseSchema,
1084
1140
  steerAgentRequestSchema,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@av-pi-studio/protocol",
3
- "version": "0.0.99",
3
+ "version": "0.0.101",
4
4
  "files": [
5
5
  "dist",
6
6
  "!dist/**/*.map",