@chatpanel/sdk 0.27.1 → 0.29.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.
@@ -662,6 +662,16 @@ export declare const OPERATIONS: {
662
662
  readonly pathParams: readonly [];
663
663
  readonly queryParams: readonly [];
664
664
  };
665
+ readonly "runtime.recipe": {
666
+ readonly id: "runtime.recipe";
667
+ readonly method: "GET";
668
+ readonly path: "/v1/runtime/recipe";
669
+ readonly auth: "token";
670
+ readonly since: "0.122.0";
671
+ readonly stream: null;
672
+ readonly pathParams: readonly [];
673
+ readonly queryParams: readonly ["service", "model"];
674
+ };
665
675
  readonly "runtime.plan": {
666
676
  readonly id: "runtime.plan";
667
677
  readonly method: "GET";
@@ -1132,6 +1142,96 @@ export declare const OPERATIONS: {
1132
1142
  readonly pathParams: readonly ["skillId"];
1133
1143
  readonly queryParams: readonly ["workdir"];
1134
1144
  };
1145
+ readonly "skills.file": {
1146
+ readonly id: "skills.file";
1147
+ readonly method: "GET";
1148
+ readonly path: "/skills/{skillId}/file/{path}";
1149
+ readonly auth: "open";
1150
+ readonly since: "0.11.4";
1151
+ readonly stream: null;
1152
+ readonly pathParams: readonly ["skillId", "path"];
1153
+ readonly queryParams: readonly ["workdir"];
1154
+ };
1155
+ readonly "contexts.list": {
1156
+ readonly id: "contexts.list";
1157
+ readonly method: "GET";
1158
+ readonly path: "/v1/contexts";
1159
+ readonly auth: "open";
1160
+ readonly since: "0.141.0";
1161
+ readonly stream: null;
1162
+ readonly pathParams: readonly [];
1163
+ readonly queryParams: readonly [];
1164
+ };
1165
+ readonly "contexts.create": {
1166
+ readonly id: "contexts.create";
1167
+ readonly method: "POST";
1168
+ readonly path: "/v1/contexts";
1169
+ readonly auth: "token";
1170
+ readonly since: "0.141.0";
1171
+ readonly stream: null;
1172
+ readonly pathParams: readonly [];
1173
+ readonly queryParams: readonly [];
1174
+ };
1175
+ readonly "contexts.suggest": {
1176
+ readonly id: "contexts.suggest";
1177
+ readonly method: "POST";
1178
+ readonly path: "/v1/contexts/suggest";
1179
+ readonly auth: "open";
1180
+ readonly since: "0.141.0";
1181
+ readonly stream: null;
1182
+ readonly pathParams: readonly [];
1183
+ readonly queryParams: readonly [];
1184
+ };
1185
+ readonly "contexts.get": {
1186
+ readonly id: "contexts.get";
1187
+ readonly method: "GET";
1188
+ readonly path: "/v1/contexts/{contextId}";
1189
+ readonly auth: "open";
1190
+ readonly since: "0.141.0";
1191
+ readonly stream: null;
1192
+ readonly pathParams: readonly ["contextId"];
1193
+ readonly queryParams: readonly [];
1194
+ };
1195
+ readonly "contexts.remove": {
1196
+ readonly id: "contexts.remove";
1197
+ readonly method: "DELETE";
1198
+ readonly path: "/v1/contexts/{contextId}";
1199
+ readonly auth: "token";
1200
+ readonly since: "0.141.0";
1201
+ readonly stream: null;
1202
+ readonly pathParams: readonly ["contextId"];
1203
+ readonly queryParams: readonly [];
1204
+ };
1205
+ readonly "contexts.edit": {
1206
+ readonly id: "contexts.edit";
1207
+ readonly method: "PATCH";
1208
+ readonly path: "/v1/contexts/{contextId}";
1209
+ readonly auth: "token";
1210
+ readonly since: "0.141.0";
1211
+ readonly stream: null;
1212
+ readonly pathParams: readonly ["contextId"];
1213
+ readonly queryParams: readonly [];
1214
+ };
1215
+ readonly "contexts.items": {
1216
+ readonly id: "contexts.items";
1217
+ readonly method: "POST";
1218
+ readonly path: "/v1/contexts/{contextId}/items";
1219
+ readonly auth: "token";
1220
+ readonly since: "0.141.0";
1221
+ readonly stream: null;
1222
+ readonly pathParams: readonly ["contextId"];
1223
+ readonly queryParams: readonly [];
1224
+ };
1225
+ readonly "contexts.scope": {
1226
+ readonly id: "contexts.scope";
1227
+ readonly method: "GET";
1228
+ readonly path: "/v1/contexts/{contextId}/scope";
1229
+ readonly auth: "open";
1230
+ readonly since: "0.141.0";
1231
+ readonly stream: null;
1232
+ readonly pathParams: readonly ["contextId"];
1233
+ readonly queryParams: readonly [];
1234
+ };
1135
1235
  readonly "fusions.list": {
1136
1236
  readonly id: "fusions.list";
1137
1237
  readonly method: "GET";
@@ -1738,6 +1838,11 @@ export declare class RuntimeApi {
1738
1838
  constructor(rt: Runtime);
1739
1839
  /** The runtime — the process sandbox, what is running now, the container engine, the services. One document for Settings › Runtime. `sandbox` is the bridge's own (`/health.sandbox`: enabled, mode `open` | `allowlist` | `none`, the runtime found, the reason when none, the global `extras`, whether a process can get a session of its own, and `refused` — the last hosts any process was refused, names only). `processes` lists every local MCP server running for the user with its sandbox record and the hosts it was refused, and the warm agent processes. `engines` says which container engine exists (`podman` first, `docker`) and whether it can run a container now; when none does, `install` carries the command for this platform — shown to the person, never run by the gateway. `services` is the catalogue: `searxng` with its state (`no-engine` | `engine-stopped` | `absent` | `stopped` | `running`), its loopback URL and whether it answers. — Gateway 0.19.0+. */
1740
1840
  status(opts?: RequestOptions): Promise<T.RuntimeDocument>;
1841
+ /** What a GGUF repo runs as on this machine, before anything is downloaded. For llama.cpp: the repo's file list read from Hugging Face, and 64 KB of one weights file's header for its architecture. Answers the quant picked (Q4_K_M when none is named), every quant with its size and whether it fits in about three quarters of the machine's memory, the vision projector and the speculative-decoding draft the repo ships (with the `--spec-type` its name means), and the layout chosen — `alt` when the repo also carries the weights as `.gguf_file` and only that layout is one the installed llama.cpp knows. A repo whose architecture the installed llama.cpp cannot load is a 400 with `code: unsupported_arch`. Nothing is saved; a start pulls the same recipe. — Requires the gateway token. Gateway 0.122.0+. */
1842
+ recipe(query: {
1843
+ service?: string;
1844
+ model: string;
1845
+ }, opts?: RequestOptions): Promise<T.RuntimeRecipe>;
1741
1846
  /** Will this local model run now? Weights + the KV cache for the context + 10% headroom, against what is free. Checked against what Heatwatch (an optional macOS tool on `127.0.0.1:7878`) says is reclaimable NOW, with the apps to close when it is short — or, without Heatwatch, against the machine's total memory, and `source` says which (`heatwatch` | `total-memory`). The KV cache is counted from the model's `config.json` when it is in the gateway's model cache (`contextCounted` says whether it was). A model the catalogue does not list needs `need_mb`. A native service's start makes the same check and refuses a model that does not fit what is free, unless the start says `force: true`. `runtime.heatwatch: false` stops the gateway asking Heatwatch. — Gateway 0.74.0+. */
1742
1847
  plan(query?: {
1743
1848
  service?: string;
@@ -1889,6 +1994,14 @@ export declare class SkillsApi {
1889
1994
  }, opts?: RequestOptions): Promise<{
1890
1995
  skill: T.Skill | null;
1891
1996
  }>;
1997
+ /** One reference file a packaged skill ships — what a model opens when the skill's prompt points at it. — Gateway 0.11.4+. */
1998
+ file(skillId: string, path: string, query?: {
1999
+ workdir?: string;
2000
+ }, opts?: RequestOptions): Promise<{
2001
+ ok: boolean;
2002
+ path?: string;
2003
+ text: string;
2004
+ }>;
1892
2005
  }
1893
2006
  /** Remote agents reached over the Agent2Agent protocol — discovery, messages, tasks. */
1894
2007
  export declare class A2aApi {
@@ -1934,6 +2047,70 @@ export declare class A2aApi {
1934
2047
  }>;
1935
2048
  }>;
1936
2049
  }
2050
+ /** What chats, notes and meetings are about, across kinds — made, filed and suggested. */
2051
+ export declare class ContextsApi {
2052
+ private readonly rt;
2053
+ constructor(rt: Runtime);
2054
+ /** The person's contexts — what their chats, notes and meetings are about — with what each holds. A context groups chats, notes and meetings across kinds ("Product launch", "Kitchen remodel"). It is a record in the library every client syncs, so one made here appears in the panel, the desktop and the phones on their next pull. Busiest first. — Gateway 0.141.0+. */
2055
+ list(opts?: RequestOptions): Promise<{
2056
+ ok: boolean;
2057
+ contexts: Array<T.Context>;
2058
+ }>;
2059
+ /** Make a context. — Requires the gateway token. Gateway 0.141.0+. */
2060
+ create(body: T.ContextEdit, opts?: RequestOptions): Promise<{
2061
+ ok: boolean;
2062
+ context: T.Context;
2063
+ }>;
2064
+ /** Which contexts a chat, note or meeting probably belongs to — a suggestion, never filed by itself. By words — the item's title and text against each context's name, keywords and what it already holds. Pass an item's `id`, or a `title` and `text` for something not saved yet. — Gateway 0.141.0+. */
2065
+ suggest(body: {
2066
+ id?: string;
2067
+ title?: string;
2068
+ text?: string;
2069
+ limit?: number;
2070
+ }, opts?: RequestOptions): Promise<{
2071
+ ok: boolean;
2072
+ suggestions: Array<{
2073
+ id: string;
2074
+ title: string;
2075
+ score: number;
2076
+ why: string;
2077
+ }>;
2078
+ }>;
2079
+ /** A context and what it holds — each item by id, kind and title, never its body. — Gateway 0.141.0+. */
2080
+ get(contextId: string, opts?: RequestOptions): Promise<{
2081
+ ok: boolean;
2082
+ context: T.Context;
2083
+ items: Array<{
2084
+ id: string;
2085
+ kind: "chat" | "note" | "meeting" | "brief";
2086
+ title: string;
2087
+ updatedAt: number;
2088
+ }>;
2089
+ }>;
2090
+ /** Delete a context. Its chats, notes and meetings stay. — Requires the gateway token. Gateway 0.141.0+. */
2091
+ remove(contextId: string, opts?: RequestOptions): Promise<{
2092
+ ok: boolean;
2093
+ }>;
2094
+ /** Rename a context, or change its colour, what it is about or its keywords. — Requires the gateway token. Gateway 0.141.0+. */
2095
+ edit(contextId: string, body: T.ContextEdit, opts?: RequestOptions): Promise<{
2096
+ ok: boolean;
2097
+ context: T.Context;
2098
+ }>;
2099
+ /** Put chats, notes or meetings in a context, or take them out — the items themselves are untouched. One write to the context, never to the items; each item keeps its own clock there, so two devices filing at once both count. — Requires the gateway token. Gateway 0.141.0+. */
2100
+ items(contextId: string, body: {
2101
+ add?: Array<string>;
2102
+ remove?: Array<string>;
2103
+ }, opts?: RequestOptions): Promise<{
2104
+ ok: boolean;
2105
+ context: T.Context;
2106
+ }>;
2107
+ /** What a turn inside a context searches (its item ids) and the one line it is told. — Gateway 0.141.0+. */
2108
+ scope(contextId: string, opts?: RequestOptions): Promise<{
2109
+ ok: boolean;
2110
+ ids: Array<string>;
2111
+ line: string;
2112
+ }>;
2113
+ }
1937
2114
  /** Several models as one — union, draft + target, fallback. */
1938
2115
  export declare class FusionsApi {
1939
2116
  private readonly rt;
@@ -2013,6 +2190,7 @@ export declare function buildApi(rt: Runtime): {
2013
2190
  engines: EnginesApi;
2014
2191
  skills: SkillsApi;
2015
2192
  a2a: A2aApi;
2193
+ contexts: ContextsApi;
2016
2194
  fusions: FusionsApi;
2017
2195
  browser: BrowserApi;
2018
2196
  link: LinkApi;
@@ -66,6 +66,7 @@ export const OPERATIONS = {
66
66
  "agents.rate": { id: "agents.rate", method: "POST", path: "/v1/agents/{agentId}/scorecard", auth: "open", since: "0.6.87", stream: null, pathParams: ["agentId"], queryParams: [] },
67
67
  "capabilities.list": { id: "capabilities.list", method: "GET", path: "/v1/capabilities", auth: "open", since: "0.13.0", stream: null, pathParams: [], queryParams: [] },
68
68
  "runtime.status": { id: "runtime.status", method: "GET", path: "/v1/runtime", auth: "open", since: "0.19.0", stream: null, pathParams: [], queryParams: [] },
69
+ "runtime.recipe": { id: "runtime.recipe", method: "GET", path: "/v1/runtime/recipe", auth: "token", since: "0.122.0", stream: null, pathParams: [], queryParams: ["service", "model"] },
69
70
  "runtime.plan": { id: "runtime.plan", method: "GET", path: "/v1/runtime/plan", auth: "open", since: "0.74.0", stream: null, pathParams: [], queryParams: ["service", "model", "ctx", "need_mb"] },
70
71
  "runtime.engine": { id: "runtime.engine", method: "POST", path: "/v1/runtime/engines/{name}", auth: "token", since: "0.19.0", stream: null, pathParams: ["name"], queryParams: [] },
71
72
  "runtime.service": { id: "runtime.service", method: "POST", path: "/v1/runtime/services/{id}", auth: "token", since: "0.19.0", stream: null, pathParams: ["id"], queryParams: [] },
@@ -113,6 +114,15 @@ export const OPERATIONS = {
113
114
  "agents.exportDef": { id: "agents.exportDef", method: "POST", path: "/agent-defs/export", auth: "token", since: "0.48.0", stream: null, pathParams: [], queryParams: [] },
114
115
  "skills.list": { id: "skills.list", method: "GET", path: "/skills", auth: "open", since: "0.6.64", stream: null, pathParams: [], queryParams: ["workdir"] },
115
116
  "skills.get": { id: "skills.get", method: "GET", path: "/skills/{skillId}", auth: "open", since: "0.6.67", stream: null, pathParams: ["skillId"], queryParams: ["workdir"] },
117
+ "skills.file": { id: "skills.file", method: "GET", path: "/skills/{skillId}/file/{path}", auth: "open", since: "0.11.4", stream: null, pathParams: ["skillId", "path"], queryParams: ["workdir"] },
118
+ "contexts.list": { id: "contexts.list", method: "GET", path: "/v1/contexts", auth: "open", since: "0.141.0", stream: null, pathParams: [], queryParams: [] },
119
+ "contexts.create": { id: "contexts.create", method: "POST", path: "/v1/contexts", auth: "token", since: "0.141.0", stream: null, pathParams: [], queryParams: [] },
120
+ "contexts.suggest": { id: "contexts.suggest", method: "POST", path: "/v1/contexts/suggest", auth: "open", since: "0.141.0", stream: null, pathParams: [], queryParams: [] },
121
+ "contexts.get": { id: "contexts.get", method: "GET", path: "/v1/contexts/{contextId}", auth: "open", since: "0.141.0", stream: null, pathParams: ["contextId"], queryParams: [] },
122
+ "contexts.remove": { id: "contexts.remove", method: "DELETE", path: "/v1/contexts/{contextId}", auth: "token", since: "0.141.0", stream: null, pathParams: ["contextId"], queryParams: [] },
123
+ "contexts.edit": { id: "contexts.edit", method: "PATCH", path: "/v1/contexts/{contextId}", auth: "token", since: "0.141.0", stream: null, pathParams: ["contextId"], queryParams: [] },
124
+ "contexts.items": { id: "contexts.items", method: "POST", path: "/v1/contexts/{contextId}/items", auth: "token", since: "0.141.0", stream: null, pathParams: ["contextId"], queryParams: [] },
125
+ "contexts.scope": { id: "contexts.scope", method: "GET", path: "/v1/contexts/{contextId}/scope", auth: "open", since: "0.141.0", stream: null, pathParams: ["contextId"], queryParams: [] },
116
126
  "fusions.list": { id: "fusions.list", method: "GET", path: "/v1/fusions", auth: "open", since: "0.33.0", stream: null, pathParams: [], queryParams: [] },
117
127
  "browser.status": { id: "browser.status", method: "GET", path: "/v1/browser", auth: "token", since: "0.59.0", stream: null, pathParams: [], queryParams: [] },
118
128
  "browser.call": { id: "browser.call", method: "POST", path: "/v1/browser/call", auth: "token", since: "0.59.0", stream: null, pathParams: [], queryParams: [] },
@@ -497,6 +507,10 @@ export class RuntimeApi {
497
507
  status(opts) {
498
508
  return this.rt.request(OPERATIONS["runtime.status"], { path: {}, query: undefined, headers: opts?.headers, body: undefined, opts });
499
509
  }
510
+ /** What a GGUF repo runs as on this machine, before anything is downloaded. For llama.cpp: the repo's file list read from Hugging Face, and 64 KB of one weights file's header for its architecture. Answers the quant picked (Q4_K_M when none is named), every quant with its size and whether it fits in about three quarters of the machine's memory, the vision projector and the speculative-decoding draft the repo ships (with the `--spec-type` its name means), and the layout chosen — `alt` when the repo also carries the weights as `.gguf_file` and only that layout is one the installed llama.cpp knows. A repo whose architecture the installed llama.cpp cannot load is a 400 with `code: unsupported_arch`. Nothing is saved; a start pulls the same recipe. — Requires the gateway token. Gateway 0.122.0+. */
511
+ recipe(query, opts) {
512
+ return this.rt.request(OPERATIONS["runtime.recipe"], { path: {}, query: query, headers: opts?.headers, body: undefined, opts });
513
+ }
500
514
  /** Will this local model run now? Weights + the KV cache for the context + 10% headroom, against what is free. Checked against what Heatwatch (an optional macOS tool on `127.0.0.1:7878`) says is reclaimable NOW, with the apps to close when it is short — or, without Heatwatch, against the machine's total memory, and `source` says which (`heatwatch` | `total-memory`). The KV cache is counted from the model's `config.json` when it is in the gateway's model cache (`contextCounted` says whether it was). A model the catalogue does not list needs `need_mb`. A native service's start makes the same check and refuses a model that does not fit what is free, unless the start says `force: true`. `runtime.heatwatch: false` stops the gateway asking Heatwatch. — Gateway 0.74.0+. */
501
515
  plan(query, opts) {
502
516
  return this.rt.request(OPERATIONS["runtime.plan"], { path: {}, query: query, headers: opts?.headers, body: undefined, opts });
@@ -653,6 +667,10 @@ export class SkillsApi {
653
667
  get(skillId, query, opts) {
654
668
  return this.rt.request(OPERATIONS["skills.get"], { path: { skillId }, query: query, headers: opts?.headers, body: undefined, opts });
655
669
  }
670
+ /** One reference file a packaged skill ships — what a model opens when the skill's prompt points at it. — Gateway 0.11.4+. */
671
+ file(skillId, path, query, opts) {
672
+ return this.rt.request(OPERATIONS["skills.file"], { path: { skillId, path }, query: query, headers: opts?.headers, body: undefined, opts });
673
+ }
656
674
  }
657
675
  /** Remote agents reached over the Agent2Agent protocol — discovery, messages, tasks. */
658
676
  export class A2aApi {
@@ -679,6 +697,43 @@ export class A2aApi {
679
697
  return this.rt.request(OPERATIONS["a2a.agents"], { path: {}, query: undefined, headers: opts?.headers, body: undefined, opts });
680
698
  }
681
699
  }
700
+ /** What chats, notes and meetings are about, across kinds — made, filed and suggested. */
701
+ export class ContextsApi {
702
+ rt;
703
+ constructor(rt) { this.rt = rt; }
704
+ /** The person's contexts — what their chats, notes and meetings are about — with what each holds. A context groups chats, notes and meetings across kinds ("Product launch", "Kitchen remodel"). It is a record in the library every client syncs, so one made here appears in the panel, the desktop and the phones on their next pull. Busiest first. — Gateway 0.141.0+. */
705
+ list(opts) {
706
+ return this.rt.request(OPERATIONS["contexts.list"], { path: {}, query: undefined, headers: opts?.headers, body: undefined, opts });
707
+ }
708
+ /** Make a context. — Requires the gateway token. Gateway 0.141.0+. */
709
+ create(body, opts) {
710
+ return this.rt.request(OPERATIONS["contexts.create"], { path: {}, query: undefined, headers: opts?.headers, body: body, opts });
711
+ }
712
+ /** Which contexts a chat, note or meeting probably belongs to — a suggestion, never filed by itself. By words — the item's title and text against each context's name, keywords and what it already holds. Pass an item's `id`, or a `title` and `text` for something not saved yet. — Gateway 0.141.0+. */
713
+ suggest(body, opts) {
714
+ return this.rt.request(OPERATIONS["contexts.suggest"], { path: {}, query: undefined, headers: opts?.headers, body: body, opts });
715
+ }
716
+ /** A context and what it holds — each item by id, kind and title, never its body. — Gateway 0.141.0+. */
717
+ get(contextId, opts) {
718
+ return this.rt.request(OPERATIONS["contexts.get"], { path: { contextId }, query: undefined, headers: opts?.headers, body: undefined, opts });
719
+ }
720
+ /** Delete a context. Its chats, notes and meetings stay. — Requires the gateway token. Gateway 0.141.0+. */
721
+ remove(contextId, opts) {
722
+ return this.rt.request(OPERATIONS["contexts.remove"], { path: { contextId }, query: undefined, headers: opts?.headers, body: undefined, opts });
723
+ }
724
+ /** Rename a context, or change its colour, what it is about or its keywords. — Requires the gateway token. Gateway 0.141.0+. */
725
+ edit(contextId, body, opts) {
726
+ return this.rt.request(OPERATIONS["contexts.edit"], { path: { contextId }, query: undefined, headers: opts?.headers, body: body, opts });
727
+ }
728
+ /** Put chats, notes or meetings in a context, or take them out — the items themselves are untouched. One write to the context, never to the items; each item keeps its own clock there, so two devices filing at once both count. — Requires the gateway token. Gateway 0.141.0+. */
729
+ items(contextId, body, opts) {
730
+ return this.rt.request(OPERATIONS["contexts.items"], { path: { contextId }, query: undefined, headers: opts?.headers, body: body, opts });
731
+ }
732
+ /** What a turn inside a context searches (its item ids) and the one line it is told. — Gateway 0.141.0+. */
733
+ scope(contextId, opts) {
734
+ return this.rt.request(OPERATIONS["contexts.scope"], { path: { contextId }, query: undefined, headers: opts?.headers, body: undefined, opts });
735
+ }
736
+ }
682
737
  /** Several models as one — union, draft + target, fallback. */
683
738
  export class FusionsApi {
684
739
  rt;
@@ -772,6 +827,7 @@ export function buildApi(rt) {
772
827
  engines: new EnginesApi(rt),
773
828
  skills: new SkillsApi(rt),
774
829
  a2a: new A2aApi(rt),
830
+ contexts: new ContextsApi(rt),
775
831
  fusions: new FusionsApi(rt),
776
832
  browser: new BrowserApi(rt),
777
833
  link: new LinkApi(rt),
@@ -1,3 +1,25 @@
1
+ export interface Context {
2
+ id: string;
3
+ title: string;
4
+ color: "blue" | "orange" | "green" | "purple" | "pink" | "teal" | "gray";
5
+ about: string;
6
+ keywords: Array<string>;
7
+ counts?: {
8
+ chat?: number;
9
+ note?: number;
10
+ meeting?: number;
11
+ brief?: number;
12
+ };
13
+ /** The newest item's time (ms). */
14
+ last?: number;
15
+ updatedAt: number;
16
+ }
17
+ export interface ContextEdit {
18
+ name?: string;
19
+ color?: "blue" | "orange" | "green" | "purple" | "pink" | "teal" | "gray";
20
+ about?: string;
21
+ keywords?: Array<string>;
22
+ }
1
23
  /** A domain object whose shape is owned by `@chatpanel/events`; the SDK carries it as-is. */
2
24
  export interface AnyObject {
3
25
  [key: string]: unknown;
@@ -175,6 +197,37 @@ export interface RuntimeActionResult {
175
197
  note?: string;
176
198
  plan?: RuntimePlan;
177
199
  }
200
+ export interface RuntimeRecipe {
201
+ ok: boolean;
202
+ /** owner/name:QUANT — what to pass as the service's model. */
203
+ model: string;
204
+ quant: string;
205
+ /** The weights' general.architecture; null when the header could not be read. */
206
+ arch?: string | null;
207
+ layout?: "main" | "alt";
208
+ /** The weights file in the repo (the first shard of a split model). */
209
+ main?: string;
210
+ /** Bytes of the weights for this quant. */
211
+ size?: number;
212
+ /** Weights + projector + draft against about three quarters of the memory; null when the memory is unknown. */
213
+ fits?: boolean | null;
214
+ ramGB?: number;
215
+ quants: Array<{
216
+ quant: string;
217
+ size: number;
218
+ fits?: boolean | null;
219
+ }>;
220
+ projector?: null | {
221
+ path: string;
222
+ size?: number;
223
+ };
224
+ draft?: null | {
225
+ path: string;
226
+ size?: number;
227
+ /** llama-server --spec-type: draft-dspark, draft-mtp, draft-eagle3, draft-dflash or draft-simple. */
228
+ spec: string;
229
+ };
230
+ }
178
231
  /** Whether a local model fits in memory (gateway 0.74+) — `GET /v1/runtime/plan`, and on a start the live-memory check refused. */
179
232
  export interface RuntimePlan {
180
233
  ok: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chatpanel/sdk",
3
- "version": "0.27.1",
3
+ "version": "0.29.0",
4
4
  "description": "Typed client for the local ChatPanel gateway — chat through the privacy proxy, search the user's history, read and write memory, follow team runs. Zero dependencies.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",