@f-inverse/jammi-client 0.49.0 → 0.50.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.
Files changed (51) hide show
  1. package/README.md +6 -2
  2. package/dist/gen/jammi/v1/audit_pb.d.ts +1 -1
  3. package/dist/gen/jammi/v1/audit_pb.js +1 -1
  4. package/dist/gen/jammi/v1/catalog_pb.d.ts +306 -29
  5. package/dist/gen/jammi/v1/catalog_pb.d.ts.map +1 -1
  6. package/dist/gen/jammi/v1/catalog_pb.js +65 -37
  7. package/dist/gen/jammi/v1/catalog_pb.js.map +1 -1
  8. package/dist/gen/jammi/v1/embedding_pb.d.ts +401 -43
  9. package/dist/gen/jammi/v1/embedding_pb.d.ts.map +1 -1
  10. package/dist/gen/jammi/v1/embedding_pb.js +128 -9
  11. package/dist/gen/jammi/v1/embedding_pb.js.map +1 -1
  12. package/dist/gen/jammi/v1/error_pb.d.ts +994 -24
  13. package/dist/gen/jammi/v1/error_pb.d.ts.map +1 -1
  14. package/dist/gen/jammi/v1/error_pb.js +184 -24
  15. package/dist/gen/jammi/v1/error_pb.js.map +1 -1
  16. package/dist/gen/jammi/v1/eval_pb.d.ts +1 -1
  17. package/dist/gen/jammi/v1/eval_pb.js +1 -1
  18. package/dist/gen/jammi/v1/gang_pb.d.ts +730 -0
  19. package/dist/gen/jammi/v1/gang_pb.d.ts.map +1 -0
  20. package/dist/gen/jammi/v1/gang_pb.js +268 -0
  21. package/dist/gen/jammi/v1/gang_pb.js.map +1 -0
  22. package/dist/gen/jammi/v1/inference_pb.d.ts +69 -32
  23. package/dist/gen/jammi/v1/inference_pb.d.ts.map +1 -1
  24. package/dist/gen/jammi/v1/inference_pb.js +23 -43
  25. package/dist/gen/jammi/v1/inference_pb.js.map +1 -1
  26. package/dist/gen/jammi/v1/job_pb.d.ts +774 -0
  27. package/dist/gen/jammi/v1/job_pb.d.ts.map +1 -0
  28. package/dist/gen/jammi/v1/job_pb.js +154 -0
  29. package/dist/gen/jammi/v1/job_pb.js.map +1 -0
  30. package/dist/gen/jammi/v1/lifecycle_pb.d.ts +1 -1
  31. package/dist/gen/jammi/v1/lifecycle_pb.js +1 -1
  32. package/dist/gen/jammi/v1/peer_pb.d.ts +325 -0
  33. package/dist/gen/jammi/v1/peer_pb.d.ts.map +1 -0
  34. package/dist/gen/jammi/v1/peer_pb.js +138 -0
  35. package/dist/gen/jammi/v1/peer_pb.js.map +1 -0
  36. package/dist/gen/jammi/v1/pipeline_pb.d.ts +218 -10
  37. package/dist/gen/jammi/v1/pipeline_pb.d.ts.map +1 -1
  38. package/dist/gen/jammi/v1/pipeline_pb.js +57 -11
  39. package/dist/gen/jammi/v1/pipeline_pb.js.map +1 -1
  40. package/dist/gen/jammi/v1/training_pb.d.ts +91 -345
  41. package/dist/gen/jammi/v1/training_pb.d.ts.map +1 -1
  42. package/dist/gen/jammi/v1/training_pb.js +18 -76
  43. package/dist/gen/jammi/v1/training_pb.js.map +1 -1
  44. package/dist/gen/jammi/v1/trigger_pb.d.ts +3 -1
  45. package/dist/gen/jammi/v1/trigger_pb.d.ts.map +1 -1
  46. package/dist/gen/jammi/v1/trigger_pb.js.map +1 -1
  47. package/dist/index.d.ts +6 -2
  48. package/dist/index.d.ts.map +1 -1
  49. package/dist/index.js +3 -2
  50. package/dist/index.js.map +1 -1
  51. package/package.json +1 -1
@@ -0,0 +1,774 @@
1
+ import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
2
+ import type { CacheOutcome, CachePolicy } from "./inference_pb";
3
+ import type { ContextPredictorSpec, FineTuneConfig, FineTuneSpec, GraphFineTuneSpec } from "./training_pb";
4
+ import type { Message } from "@bufbuild/protobuf";
5
+ /**
6
+ * Describes the file jammi/v1/job.proto.
7
+ */
8
+ export declare const file_jammi_v1_job: GenFile;
9
+ /**
10
+ * The training-kind spec `oneof` `SubmitJob` accepts, plus the client-supplied
11
+ * dedupe key. Mirrors the engine's `TrainingSpec` enum variant-for-variant,
12
+ * field-for-field: a decoded request reconstructs the identical engine spec,
13
+ * so a remote-submitted job is byte-identical to one submitted in-process.
14
+ *
15
+ * @generated from message jammi.v1.job.SubmitJobRequest
16
+ */
17
+ export type SubmitJobRequest = Message<"jammi.v1.job.SubmitJobRequest"> & {
18
+ /**
19
+ * @generated from oneof jammi.v1.job.SubmitJobRequest.spec
20
+ */
21
+ spec: {
22
+ /**
23
+ * @generated from field: jammi.v1.training.FineTuneSpec fine_tune = 1;
24
+ */
25
+ value: FineTuneSpec;
26
+ case: "fineTune";
27
+ } | {
28
+ /**
29
+ * @generated from field: jammi.v1.training.GraphFineTuneSpec graph_fine_tune = 2;
30
+ */
31
+ value: GraphFineTuneSpec;
32
+ case: "graphFineTune";
33
+ } | {
34
+ /**
35
+ * @generated from field: jammi.v1.training.ContextPredictorSpec context_predictor = 3;
36
+ */
37
+ value: ContextPredictorSpec;
38
+ case: "contextPredictor";
39
+ } | {
40
+ case: undefined;
41
+ value?: undefined;
42
+ };
43
+ /**
44
+ * Base encoder to adapt for the two LoRA fine-tune kinds (`local:<path>`, an
45
+ * HF repo id, or a fine-tuned id). Unused by the context-predictor kind (it
46
+ * names its source's embedding model implicitly), so it is empty there.
47
+ *
48
+ * @generated from field: string base_model = 4;
49
+ */
50
+ baseModel: string;
51
+ /**
52
+ * Optional fine-tune hyperparameters for the two LoRA fine-tune kinds; unset
53
+ * applies the engine's defaults. Unused by the context-predictor kind (its
54
+ * budget rides inside `predictor_spec`).
55
+ *
56
+ * @generated from field: optional jammi.v1.training.FineTuneConfig config = 5;
57
+ */
58
+ config?: FineTuneConfig | undefined;
59
+ /**
60
+ * Optional caller-supplied dedupe key, scoped to the session tenant. A
61
+ * second `SubmitJob` carrying the same non-empty key as a still-known prior
62
+ * submission returns that prior job's handle unchanged rather than
63
+ * submitting a duplicate row. Empty (the default) submits unconditionally,
64
+ * matching every pre-existing caller. DURABLE (migration 030): the key
65
+ * lives on the `jobs` row itself under a per-tenant unique index, so the
66
+ * guarantee survives a process restart and a concurrent retry racing the
67
+ * SAME key — the loser's insert is refused by the same compare-and-set
68
+ * that creates the row, never a separate lookup-then-insert window. A
69
+ * pruned row's key is gone with it (nothing resurrects an identity for a
70
+ * key whose row has been deleted); different tenants may reuse the same
71
+ * key freely. Bounded to MAX_IDEMPOTENCY_KEY_BYTES (256 bytes,
72
+ * `jammi_db::catalog::jobs_repo::MAX_IDEMPOTENCY_KEY_BYTES`); a longer key
73
+ * is refused with `INVALID_ARGUMENT` naming the bound, never the key's own
74
+ * value -- Postgres's btree index has a hard row-size ceiling an oversize
75
+ * key can exceed (SQLite has none, so the two backends would otherwise
76
+ * silently diverge on the exact same input).
77
+ *
78
+ * @generated from field: string idempotency_key = 6;
79
+ */
80
+ idempotencyKey: string;
81
+ /**
82
+ * Data-parallel rank count for the two LoRA fine-tune kinds: the wire form of
83
+ * the engine's `TrainingCommon.world_size`, which is why it sits beside
84
+ * `base_model`/`config` rather than inside a per-kind spec — both LoRA kinds
85
+ * fold the same common block, so one field serves both and the two kinds
86
+ * cannot diverge on it. Unused by the context-predictor kind (it carries no
87
+ * common block).
88
+ *
89
+ * `0` means UNSET and resolves to the engine's default of `1` (a single
90
+ * rank), so a caller that never sets it submits exactly the single-rank job
91
+ * it always did and a request encoded without the field decodes identically
92
+ * to one encoded with `0`. Identity-relevant, not a scheduling hint: the rank
93
+ * count fixes the batch layout and the summation order, so it is part of the
94
+ * trained model's producing identity. A count the deployment cannot serve is
95
+ * refused at submit with a typed error rather than silently clamped.
96
+ *
97
+ * @generated from field: uint32 world_size = 9;
98
+ */
99
+ worldSize: number;
100
+ /**
101
+ * Mirrors the engine's `TrainingSpec::FineTune.cache` field for field, the
102
+ * same shared `CachePolicy` enum every other result-table producer verb carries
103
+ * (`jammi.v1.inference.CachePolicy` — imported rather than redeclared, so
104
+ * this and every other producer's cache dial share one wire vocabulary).
105
+ * UNSPECIFIED maps to the engine default (`Bypass`, always train), matching
106
+ * how every other `*_UNSPECIFIED` arm resolves to its engine default; an
107
+ * absent field and an explicit `CACHE_POLICY_BYPASS` are the identical
108
+ * engine outcome. `USE` is REFUSED, typed (`InvalidArgument`), for BOTH LoRA
109
+ * fine-tune kinds: `graph_fine_tune`'s model carries no materialization to
110
+ * probe or record, and model-level cache reuse for the column-source
111
+ * `fine_tune` kind is not supported. `BYPASS`/unset always
112
+ * trains, on either kind. Unused by
113
+ * the context-predictor kind (it carries no `TrainingCommon`, so it has
114
+ * nothing to probe by).
115
+ *
116
+ * @generated from field: jammi.v1.inference.CachePolicy cache = 10;
117
+ */
118
+ cache: CachePolicy;
119
+ };
120
+ /**
121
+ * Describes the message jammi.v1.job.SubmitJobRequest.
122
+ * Use `create(SubmitJobRequestSchema)` to create a new message.
123
+ */
124
+ export declare const SubmitJobRequestSchema: GenMessage<SubmitJobRequest>;
125
+ /**
126
+ * @generated from message jammi.v1.job.SubmitJobResponse
127
+ */
128
+ export type SubmitJobResponse = Message<"jammi.v1.job.SubmitJobResponse"> & {
129
+ /**
130
+ * Server-assigned job id. Read status with `JobStatus`/`WaitJob`.
131
+ *
132
+ * @generated from field: string job_id = 1;
133
+ */
134
+ jobId: string;
135
+ /**
136
+ * The `jobs.kind` tag this job submitted under (e.g. `"fine_tune"`).
137
+ *
138
+ * @generated from field: string kind = 2;
139
+ */
140
+ kind: string;
141
+ /**
142
+ * The deterministic output model id the trained artifact registers under —
143
+ * resolved via the same rule the embedded `TrainingJob::model_id` uses.
144
+ * Empty for a compute kind (no training kinds ever compute this).
145
+ *
146
+ * @generated from field: string output_model_id = 3;
147
+ */
148
+ outputModelId: string;
149
+ };
150
+ /**
151
+ * Describes the message jammi.v1.job.SubmitJobResponse.
152
+ * Use `create(SubmitJobResponseSchema)` to create a new message.
153
+ */
154
+ export declare const SubmitJobResponseSchema: GenMessage<SubmitJobResponse>;
155
+ /**
156
+ * A job's identity, for `WaitJob` and `CancelJob`.
157
+ *
158
+ * @generated from message jammi.v1.job.JobHandle
159
+ */
160
+ export type JobHandle = Message<"jammi.v1.job.JobHandle"> & {
161
+ /**
162
+ * @generated from field: string job_id = 1;
163
+ */
164
+ jobId: string;
165
+ };
166
+ /**
167
+ * Describes the message jammi.v1.job.JobHandle.
168
+ * Use `create(JobHandleSchema)` to create a new message.
169
+ */
170
+ export declare const JobHandleSchema: GenMessage<JobHandle>;
171
+ /**
172
+ * @generated from message jammi.v1.job.JobStatusRequest
173
+ */
174
+ export type JobStatusRequest = Message<"jammi.v1.job.JobStatusRequest"> & {
175
+ /**
176
+ * @generated from field: string job_id = 1;
177
+ */
178
+ jobId: string;
179
+ };
180
+ /**
181
+ * Describes the message jammi.v1.job.JobStatusRequest.
182
+ * Use `create(JobStatusRequestSchema)` to create a new message.
183
+ */
184
+ export declare const JobStatusRequestSchema: GenMessage<JobStatusRequest>;
185
+ /**
186
+ * A job's progress, updated at producer checkpoint boundaries. Field presence
187
+ * distinguishes "no progress recorded yet" from a legal `0`.
188
+ *
189
+ * @generated from message jammi.v1.job.JobProgress
190
+ */
191
+ export type JobProgress = Message<"jammi.v1.job.JobProgress"> & {
192
+ /**
193
+ * @generated from field: optional uint64 rows_done = 1;
194
+ */
195
+ rowsDone?: bigint | undefined;
196
+ /**
197
+ * @generated from field: optional uint64 rows_total = 2;
198
+ */
199
+ rowsTotal?: bigint | undefined;
200
+ /**
201
+ * @generated from field: string phase = 3;
202
+ */
203
+ phase: string;
204
+ };
205
+ /**
206
+ * Describes the message jammi.v1.job.JobProgress.
207
+ * Use `create(JobProgressSchema)` to create a new message.
208
+ */
209
+ export declare const JobProgressSchema: GenMessage<JobProgress>;
210
+ /**
211
+ * A training kind's terminal model result.
212
+ *
213
+ * @generated from message jammi.v1.job.ModelResult
214
+ */
215
+ export type ModelResult = Message<"jammi.v1.job.ModelResult"> & {
216
+ /**
217
+ * @generated from field: string model_id = 1;
218
+ */
219
+ modelId: string;
220
+ /**
221
+ * @generated from field: string artifact_path = 2;
222
+ */
223
+ artifactPath: string;
224
+ /**
225
+ * Run-metrics JSON, present once the run recorded any.
226
+ *
227
+ * @generated from field: optional string metrics_json = 3;
228
+ */
229
+ metricsJson?: string | undefined;
230
+ /**
231
+ * `computed` for a run that trained; `reused_model_artifact` — naming the
232
+ * artifact `artifact_path` also names — for a `CACHE_POLICY_USE` job that
233
+ * completed against an already-published model of the same definition.
234
+ * Observable on the terminal result, never merely inferred from an absent
235
+ * `metrics_json`.
236
+ *
237
+ * @generated from field: jammi.v1.inference.CacheOutcome cache_outcome = 4;
238
+ */
239
+ cacheOutcome?: CacheOutcome | undefined;
240
+ };
241
+ /**
242
+ * Describes the message jammi.v1.job.ModelResult.
243
+ * Use `create(ModelResultSchema)` to create a new message.
244
+ */
245
+ export declare const ModelResultSchema: GenMessage<ModelResult>;
246
+ /**
247
+ * A compute kind's terminal result-table result.
248
+ *
249
+ * @generated from message jammi.v1.job.TableResult
250
+ */
251
+ export type TableResult = Message<"jammi.v1.job.TableResult"> & {
252
+ /**
253
+ * @generated from field: string table = 1;
254
+ */
255
+ table: string;
256
+ /**
257
+ * `computed`, or `reused_table` naming the table for an exact cache hit.
258
+ *
259
+ * @generated from field: jammi.v1.inference.CacheOutcome cache_outcome = 2;
260
+ */
261
+ cacheOutcome?: CacheOutcome | undefined;
262
+ };
263
+ /**
264
+ * Describes the message jammi.v1.job.TableResult.
265
+ * Use `create(TableResultSchema)` to create a new message.
266
+ */
267
+ export declare const TableResultSchema: GenMessage<TableResult>;
268
+ /**
269
+ * @generated from message jammi.v1.job.JobStatusResponse
270
+ */
271
+ export type JobStatusResponse = Message<"jammi.v1.job.JobStatusResponse"> & {
272
+ /**
273
+ * Current lifecycle status: "queued", "running", "completed", or "failed".
274
+ *
275
+ * @generated from field: string status = 1;
276
+ */
277
+ status: string;
278
+ /**
279
+ * The `jobs.kind` tag this job submitted under.
280
+ *
281
+ * @generated from field: string kind = 2;
282
+ */
283
+ kind: string;
284
+ /**
285
+ * @generated from field: jammi.v1.job.JobProgress progress = 3;
286
+ */
287
+ progress?: JobProgress | undefined;
288
+ /**
289
+ * The failure message when `status` is "failed"; empty otherwise.
290
+ *
291
+ * @generated from field: string error = 4;
292
+ */
293
+ error: string;
294
+ /**
295
+ * The output model id the trained artifact registers under, resolved the
296
+ * same way `SubmitJobResponse.output_model_id` is; empty for a compute
297
+ * kind (never populated).
298
+ *
299
+ * @generated from field: string output_model_id = 5;
300
+ */
301
+ outputModelId: string;
302
+ /**
303
+ * The tagged terminal result. Unset until `status` is "completed".
304
+ *
305
+ * @generated from oneof jammi.v1.job.JobStatusResponse.result
306
+ */
307
+ result: {
308
+ /**
309
+ * @generated from field: jammi.v1.job.ModelResult model = 6;
310
+ */
311
+ value: ModelResult;
312
+ case: "model";
313
+ } | {
314
+ /**
315
+ * @generated from field: jammi.v1.job.TableResult table = 7;
316
+ */
317
+ value: TableResult;
318
+ case: "table";
319
+ } | {
320
+ case: undefined;
321
+ value?: undefined;
322
+ };
323
+ /**
324
+ * GPU-acceleration determination for this job, as an opaque, self-describing
325
+ * JSON object — the SAME blob the catalog's `jobs.acceleration_report`
326
+ * column carries. Field presence (not the empty string)
327
+ * distinguishes "no column value" from an already-recorded blob.
328
+ *
329
+ * @generated from field: optional string acceleration_report_json = 8;
330
+ */
331
+ accelerationReportJson?: string | undefined;
332
+ };
333
+ /**
334
+ * Describes the message jammi.v1.job.JobStatusResponse.
335
+ * Use `create(JobStatusResponseSchema)` to create a new message.
336
+ */
337
+ export declare const JobStatusResponseSchema: GenMessage<JobStatusResponse>;
338
+ /**
339
+ * One frame of a `WaitJob` stream: either an in-flight progress update or the
340
+ * terminal `JobStatusResponse` — after which the stream ends.
341
+ *
342
+ * @generated from message jammi.v1.job.JobEvent
343
+ */
344
+ export type JobEvent = Message<"jammi.v1.job.JobEvent"> & {
345
+ /**
346
+ * @generated from oneof jammi.v1.job.JobEvent.event
347
+ */
348
+ event: {
349
+ /**
350
+ * @generated from field: jammi.v1.job.JobProgress progress = 1;
351
+ */
352
+ value: JobProgress;
353
+ case: "progress";
354
+ } | {
355
+ /**
356
+ * @generated from field: jammi.v1.job.JobStatusResponse done = 2;
357
+ */
358
+ value: JobStatusResponse;
359
+ case: "done";
360
+ } | {
361
+ case: undefined;
362
+ value?: undefined;
363
+ };
364
+ };
365
+ /**
366
+ * Describes the message jammi.v1.job.JobEvent.
367
+ * Use `create(JobEventSchema)` to create a new message.
368
+ */
369
+ export declare const JobEventSchema: GenMessage<JobEvent>;
370
+ /**
371
+ * @generated from message jammi.v1.job.ListJobsRequest
372
+ */
373
+ export type ListJobsRequest = Message<"jammi.v1.job.ListJobsRequest"> & {};
374
+ /**
375
+ * Describes the message jammi.v1.job.ListJobsRequest.
376
+ * Use `create(ListJobsRequestSchema)` to create a new message.
377
+ */
378
+ export declare const ListJobsRequestSchema: GenMessage<ListJobsRequest>;
379
+ /**
380
+ * @generated from message jammi.v1.job.ListJobsResponse
381
+ */
382
+ export type ListJobsResponse = Message<"jammi.v1.job.ListJobsResponse"> & {
383
+ /**
384
+ * @generated from field: repeated jammi.v1.job.JobSummary jobs = 1;
385
+ */
386
+ jobs: JobSummary[];
387
+ };
388
+ /**
389
+ * Describes the message jammi.v1.job.ListJobsResponse.
390
+ * Use `create(ListJobsResponseSchema)` to create a new message.
391
+ */
392
+ export declare const ListJobsResponseSchema: GenMessage<ListJobsResponse>;
393
+ /**
394
+ * One job's lifecycle summary: the `JobStatus` projection plus the
395
+ * submit-time identity fields a listing needs to tell jobs apart.
396
+ *
397
+ * @generated from message jammi.v1.job.JobSummary
398
+ */
399
+ export type JobSummary = Message<"jammi.v1.job.JobSummary"> & {
400
+ /**
401
+ * @generated from field: string job_id = 1;
402
+ */
403
+ jobId: string;
404
+ /**
405
+ * The `jobs.kind` tag this job submitted under.
406
+ *
407
+ * @generated from field: string kind = 2;
408
+ */
409
+ kind: string;
410
+ /**
411
+ * @generated from field: string status = 3;
412
+ */
413
+ status: string;
414
+ /**
415
+ * The base model a training kind trains from — the catalog's registered
416
+ * model id (PK-keyed). Empty for a compute kind.
417
+ *
418
+ * @generated from field: string base_model_id = 4;
419
+ */
420
+ baseModelId: string;
421
+ /**
422
+ * The output model id the trained artifact registers under, stamped at
423
+ * submission for a training kind; always empty for a compute kind.
424
+ *
425
+ * @generated from field: string output_model_id = 5;
426
+ */
427
+ outputModelId: string;
428
+ /**
429
+ * Job creation time, as recorded by the catalog (UTC text timestamp).
430
+ *
431
+ * @generated from field: string created_at = 6;
432
+ */
433
+ createdAt: string;
434
+ /**
435
+ * @generated from field: string error = 7;
436
+ */
437
+ error: string;
438
+ /**
439
+ * The instance holding (or, on a terminal job, last holding) the job's
440
+ * claim — for a placed training attempt, the executor the claim moved to.
441
+ * Empty while the job is queued and unclaimed.
442
+ *
443
+ * @generated from field: string claimed_by = 8;
444
+ */
445
+ claimedBy: string;
446
+ /**
447
+ * The instance that ran each rank of the latest training attempt, in rank
448
+ * order (the same id `ListWorkers` reports). Empty for a compute job and
449
+ * until a training attempt records its ranks.
450
+ *
451
+ * @generated from field: repeated string ranks = 9;
452
+ */
453
+ ranks: string[];
454
+ };
455
+ /**
456
+ * Describes the message jammi.v1.job.JobSummary.
457
+ * Use `create(JobSummarySchema)` to create a new message.
458
+ */
459
+ export declare const JobSummarySchema: GenMessage<JobSummary>;
460
+ /**
461
+ * @generated from message jammi.v1.job.CancelJobRequest
462
+ */
463
+ export type CancelJobRequest = Message<"jammi.v1.job.CancelJobRequest"> & {
464
+ /**
465
+ * @generated from field: string job_id = 1;
466
+ */
467
+ jobId: string;
468
+ };
469
+ /**
470
+ * Describes the message jammi.v1.job.CancelJobRequest.
471
+ * Use `create(CancelJobRequestSchema)` to create a new message.
472
+ */
473
+ export declare const CancelJobRequestSchema: GenMessage<CancelJobRequest>;
474
+ /**
475
+ * @generated from message jammi.v1.job.CancelJobResponse
476
+ */
477
+ export type CancelJobResponse = Message<"jammi.v1.job.CancelJobResponse"> & {
478
+ /**
479
+ * `false` when the job was already terminal or absent — cancellation had
480
+ * no effect.
481
+ *
482
+ * @generated from field: bool cancelled = 1;
483
+ */
484
+ cancelled: boolean;
485
+ };
486
+ /**
487
+ * Describes the message jammi.v1.job.CancelJobResponse.
488
+ * Use `create(CancelJobResponseSchema)` to create a new message.
489
+ */
490
+ export declare const CancelJobResponseSchema: GenMessage<CancelJobResponse>;
491
+ /**
492
+ * @generated from message jammi.v1.job.ListWorkersRequest
493
+ */
494
+ export type ListWorkersRequest = Message<"jammi.v1.job.ListWorkersRequest"> & {};
495
+ /**
496
+ * Describes the message jammi.v1.job.ListWorkersRequest.
497
+ * Use `create(ListWorkersRequestSchema)` to create a new message.
498
+ */
499
+ export declare const ListWorkersRequestSchema: GenMessage<ListWorkersRequest>;
500
+ /**
501
+ * @generated from message jammi.v1.job.ListWorkersResponse
502
+ */
503
+ export type ListWorkersResponse = Message<"jammi.v1.job.ListWorkersResponse"> & {
504
+ /**
505
+ * @generated from field: repeated jammi.v1.job.WorkerSummary workers = 1;
506
+ */
507
+ workers: WorkerSummary[];
508
+ };
509
+ /**
510
+ * Describes the message jammi.v1.job.ListWorkersResponse.
511
+ * Use `create(ListWorkersResponseSchema)` to create a new message.
512
+ */
513
+ export declare const ListWorkersResponseSchema: GenMessage<ListWorkersResponse>;
514
+ /**
515
+ * One process currently running the claim loop, joined from `instances` +
516
+ * `workers` (migration 029).
517
+ *
518
+ * @generated from message jammi.v1.job.WorkerSummary
519
+ */
520
+ export type WorkerSummary = Message<"jammi.v1.job.WorkerSummary"> & {
521
+ /**
522
+ * The process's minted-at-construction uuid.
523
+ *
524
+ * @generated from field: string instance_id = 1;
525
+ */
526
+ instanceId: string;
527
+ /**
528
+ * `JAMMI_WORKER_ID`, non-unique — an operator-chosen label, empty when
529
+ * unset.
530
+ *
531
+ * @generated from field: string label = 2;
532
+ */
533
+ label: string;
534
+ /**
535
+ * The machine the process runs on, as its OS names it; empty when the OS
536
+ * reports none.
537
+ *
538
+ * @generated from field: string host = 3;
539
+ */
540
+ host: string;
541
+ /**
542
+ * The `[worker] kinds` configuration this process claims: `"all"` or a
543
+ * comma-joined kind list.
544
+ *
545
+ * @generated from field: string kinds = 4;
546
+ */
547
+ kinds: string;
548
+ /**
549
+ * @generated from field: string started_at = 5;
550
+ */
551
+ startedAt: string;
552
+ /**
553
+ * @generated from field: string last_seen_at = 6;
554
+ */
555
+ lastSeenAt: string;
556
+ /**
557
+ * The claim loop's lifecycle state, exactly as the `workers.state` row
558
+ * carries it: `warming` (the process is preloading; nothing claimed yet),
559
+ * `claiming` (the loop is live), `draining` (a DRAIN is finishing the
560
+ * in-flight job). The row is deleted once the loop has exited.
561
+ *
562
+ * @generated from field: string state = 7;
563
+ */
564
+ state: string;
565
+ /**
566
+ * This worker's device inventory, as `workers.devices` carries it
567
+ * (`jammi_db::catalog::jobs_repo::WorkerRecord::devices`) — a MIRROR of
568
+ * the process's own registration, informational only (never the
569
+ * placement policy's authority).
570
+ *
571
+ * @generated from field: repeated jammi.v1.job.DeviceFact devices = 8;
572
+ */
573
+ devices: DeviceFact[];
574
+ };
575
+ /**
576
+ * Describes the message jammi.v1.job.WorkerSummary.
577
+ * Use `create(WorkerSummarySchema)` to create a new message.
578
+ */
579
+ export declare const WorkerSummarySchema: GenMessage<WorkerSummary>;
580
+ /**
581
+ * One device a worker process names as its own: a KIND (`"cpu"` / `"cuda"`
582
+ * / `"metal"`, opaque here) and its ORDINAL within that kind. Mirrors
583
+ * `jammi_db::catalog::instance::DeviceFact` field for field.
584
+ *
585
+ * @generated from message jammi.v1.job.DeviceFact
586
+ */
587
+ export type DeviceFact = Message<"jammi.v1.job.DeviceFact"> & {
588
+ /**
589
+ * @generated from field: string kind = 1;
590
+ */
591
+ kind: string;
592
+ /**
593
+ * @generated from field: uint32 ordinal = 2;
594
+ */
595
+ ordinal: number;
596
+ };
597
+ /**
598
+ * Describes the message jammi.v1.job.DeviceFact.
599
+ * Use `create(DeviceFactSchema)` to create a new message.
600
+ */
601
+ export declare const DeviceFactSchema: GenMessage<DeviceFact>;
602
+ /**
603
+ * @generated from message jammi.v1.job.PruneJobsRequest
604
+ */
605
+ export type PruneJobsRequest = Message<"jammi.v1.job.PruneJobsRequest"> & {};
606
+ /**
607
+ * Describes the message jammi.v1.job.PruneJobsRequest.
608
+ * Use `create(PruneJobsRequestSchema)` to create a new message.
609
+ */
610
+ export declare const PruneJobsRequestSchema: GenMessage<PruneJobsRequest>;
611
+ /**
612
+ * @generated from message jammi.v1.job.PruneJobsResponse
613
+ */
614
+ export type PruneJobsResponse = Message<"jammi.v1.job.PruneJobsResponse"> & {
615
+ /**
616
+ * Count of terminal job rows deleted by this call.
617
+ *
618
+ * @generated from field: uint64 jobs_deleted = 1;
619
+ */
620
+ jobsDeleted: bigint;
621
+ };
622
+ /**
623
+ * Describes the message jammi.v1.job.PruneJobsResponse.
624
+ * Use `create(PruneJobsResponseSchema)` to create a new message.
625
+ */
626
+ export declare const PruneJobsResponseSchema: GenMessage<PruneJobsResponse>;
627
+ /**
628
+ * JobService — the wire surface over the engine's durable job queue
629
+ * (`jobs`/`instances`/`workers`, migration 029; `jammi_ai::jobs`).
630
+ *
631
+ * `SubmitJob`, `JobStatus`, `WaitJob`, `ListJobs`, `CancelJob`, and
632
+ * `ListWorkers` are imperative session methods, not SQL queries, so they live
633
+ * as typed gRPC RPCs alongside CatalogService / EmbeddingService /
634
+ * InferenceService / PipelineService / EvalService rather than on the Flight
635
+ * SQL surface (which carries query/result only).
636
+ *
637
+ * `JobService` is the kind-agnostic durable job abstraction every compute
638
+ * verb submits through INTERNALLY
639
+ * (`jammi_ai::jobs`, `InferenceSession::run_now`) — but `SubmitJob` itself
640
+ * carries only the three training-kind spec variants (the `oneof`): every
641
+ * other compute verb is SYNCHRONOUS on the wire today. Each keeps its own
642
+ * dedicated request AND response message on its own service (e.g.
643
+ * `PipelineService.BuildNeighborGraph` returns `jammi.v1.embedding.ResultTable`
644
+ * directly) rather than going through `SubmitJobResponse`, so this service's
645
+ * `JobStatus`/`WaitJob` never has a compute-kind row to answer for over the
646
+ * wire (the terminal payload read back is byte-identical to what a `jobs`
647
+ * row of the same kind would resolve to, since both paths run through the
648
+ * same `execute_compute` dispatcher). The service reimplements no training,
649
+ * LoRA, sampling, scan, or compute-verb logic; it is purely a wire adapter
650
+ * over `jammi_ai::jobs`.
651
+ *
652
+ * Tenant scope is read from the request's `SessionTenant` extension, set by
653
+ * the single async tenant-binding layer driven by the engine's
654
+ * `TenantResolver` (default: the `jammi-session-id` header → shared session
655
+ * store) — the one mechanism every gRPC service and Flight SQL bind through.
656
+ * A job row carries the submitting tenant; a peer names an unresolvable job
657
+ * id — `JobStatus`/`WaitJob`/`CancelJob` answer `NOT_FOUND`, never
658
+ * `PERMISSION_DENIED` (matching every other tenant-scoped read in this
659
+ * codebase — a wrong tenant learns nothing about whether the id exists at
660
+ * all). `ListWorkers` reports process/fleet liveness, not a tenant-owned
661
+ * resource, so it carries no per-tenant filter (control-plane allowlisted in
662
+ * `tenant_isolation_oracle.rs`, alongside `GetServerInfo`). Every OTHER rpc on
663
+ * this service — including `PruneJobs` — IS tenant-scoped: there is no
664
+ * exemption for a maintenance verb — it is tenant-scoped like every other
665
+ * job RPC.
666
+ *
667
+ * @generated from service jammi.v1.job.JobService
668
+ */
669
+ export declare const JobService: GenService<{
670
+ /**
671
+ * Submit a training job (`fine_tune` / `graph_fine_tune` /
672
+ * `context_predictor`) and return its durable handle. The job is always
673
+ * accepted and stays `queued` until a worker claims it (or, embedded-side,
674
+ * until `run_now` claims and executes it inline) — there is no `NoWorker`
675
+ * refusal. `output_model_id` is populated via the same `resolve_model_id`
676
+ * rule the embedded `TrainingJob` handle uses, so a remote caller reads the
677
+ * byte-identical deterministic id at submit time. A second `SubmitJob` call
678
+ * carrying the same `idempotency_key` (when non-empty) returns the handle
679
+ * of the job that key first created rather than submitting a duplicate.
680
+ *
681
+ * @generated from rpc jammi.v1.job.JobService.SubmitJob
682
+ */
683
+ submitJob: {
684
+ methodKind: "unary";
685
+ input: typeof SubmitJobRequestSchema;
686
+ output: typeof SubmitJobResponseSchema;
687
+ };
688
+ /**
689
+ * Read a job's current status by id: lifecycle status, kind, progress,
690
+ * failure message, and — once terminal — the tagged result and (for a
691
+ * training kind) the acceleration-report blob. Peer of reading back the
692
+ * embedded `JobHandle`.
693
+ *
694
+ * @generated from rpc jammi.v1.job.JobService.JobStatus
695
+ */
696
+ jobStatus: {
697
+ methodKind: "unary";
698
+ input: typeof JobStatusRequestSchema;
699
+ output: typeof JobStatusResponseSchema;
700
+ };
701
+ /**
702
+ * Stream status updates for one job until it reaches a terminal state, then
703
+ * end the stream after emitting the terminal frame. Polls the job row every
704
+ * 100ms server-side; a client disconnect ends only that wait (the job keeps
705
+ * running) — reconnecting with the same job id resumes the wait and, if the
706
+ * job has already gone terminal, immediately receives the same terminal
707
+ * frame `JobStatus` would report.
708
+ *
709
+ * @generated from rpc jammi.v1.job.JobService.WaitJob
710
+ */
711
+ waitJob: {
712
+ methodKind: "server_streaming";
713
+ input: typeof JobHandleSchema;
714
+ output: typeof JobEventSchema;
715
+ };
716
+ /**
717
+ * List jobs visible to the session tenant, most recent first. Each row is
718
+ * the same lifecycle projection `JobStatus` reads (status, kind, output
719
+ * model id, failure error) plus the submit-time identity (base model,
720
+ * creation time) — a listing of `JobStatus` answers, not a progress
721
+ * surface.
722
+ *
723
+ * @generated from rpc jammi.v1.job.JobService.ListJobs
724
+ */
725
+ listJobs: {
726
+ methodKind: "unary";
727
+ input: typeof ListJobsRequestSchema;
728
+ output: typeof ListJobsResponseSchema;
729
+ };
730
+ /**
731
+ * Request cancellation of a job by id. Idempotent: cancelling an
732
+ * already-terminal or already-cancel-requested job still returns
733
+ * successfully (`cancelled = false` when the request had no effect — the
734
+ * job was already terminal). The executor checks the flag at its next
735
+ * checkpoint; cancellation is therefore cooperative, not immediate.
736
+ *
737
+ * @generated from rpc jammi.v1.job.JobService.CancelJob
738
+ */
739
+ cancelJob: {
740
+ methodKind: "unary";
741
+ input: typeof CancelJobRequestSchema;
742
+ output: typeof CancelJobResponseSchema;
743
+ };
744
+ /**
745
+ * List the engine processes currently running the claim loop
746
+ * (`[worker] enabled = true`), most recently seen first. Fleet/liveness
747
+ * metadata, not a tenant-owned resource — see the service doc.
748
+ *
749
+ * @generated from rpc jammi.v1.job.JobService.ListWorkers
750
+ */
751
+ listWorkers: {
752
+ methodKind: "unary";
753
+ input: typeof ListWorkersRequestSchema;
754
+ output: typeof ListWorkersResponseSchema;
755
+ };
756
+ /**
757
+ * Eagerly delete the CALLER's own terminal (`completed`/`failed`) job rows
758
+ * older than the deployment's `[jobs] retention_days` — tenant-scoped like
759
+ * every other rpc here (never a peer tenant's terminal rows, however old);
760
+ * this RPC only makes that on-demand (e.g. `jammi jobs prune`). Distinct
761
+ * from the process's construction-time sweep, which is not an rpc: it runs
762
+ * once per process boot, before any request is tenant-scoped, and stays
763
+ * global by design (see `InferenceSession::wrap`'s doc) — there is no
764
+ * periodic background sweep besides that one-shot boot pass.
765
+ *
766
+ * @generated from rpc jammi.v1.job.JobService.PruneJobs
767
+ */
768
+ pruneJobs: {
769
+ methodKind: "unary";
770
+ input: typeof PruneJobsRequestSchema;
771
+ output: typeof PruneJobsResponseSchema;
772
+ };
773
+ }>;
774
+ //# sourceMappingURL=job_pb.d.ts.map