pareta 2.1.0 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -99,13 +99,13 @@ declare class EvalSet extends BaseModel {
99
99
  get itemCount(): number | null;
100
100
  get scoringStrategy(): string | null;
101
101
  /** The one-sentence success criterion this set was created with (CB1:
102
- * DATA + INTENT). Required at create. */
103
- get intent(): string | null;
102
+ * DATA + PROMPT). Required at create. */
103
+ get prompt(): string | null;
104
104
  }
105
105
  /**
106
- * One proposed grading contract for an uploaded dataset (a row of
107
- * `ProposalResult.proposals`). `warning` is set on the custom-eval floor when
108
- * the data looks extraction-shaped (judge grading is weaker there).
106
+ * One proposed way to score an uploaded dataset (a row of
107
+ * `ProposalResult.proposals`). `warning` is set on a "custom-eval" proposal
108
+ * when the data looks extraction-shaped (judge grading is weaker there).
109
109
  */
110
110
  declare class ContractProposal extends BaseModel {
111
111
  get taskId(): string | null;
@@ -114,10 +114,10 @@ declare class ContractProposal extends BaseModel {
114
114
  get warning(): string | null;
115
115
  }
116
116
  /**
117
- * The binder's answer for `evals.proposeContract` (POST
118
- * /v1/eval-sets/propose-contract): which grading contract(s) fit your data
119
- * under your stated intent. Nothing is persisted — confirm by passing the
120
- * chosen `taskId` (or letting `create` auto-bind a clean single proposal).
117
+ * Pareta's answer for `evals.proposeContract` (POST
118
+ * /v1/eval-sets/propose-contract): how your data could be scored under your
119
+ * stated prompt. Nothing is persisted — confirm by passing the chosen
120
+ * `taskId` (or letting a task-less `create` use a clean single proposal).
121
121
  */
122
122
  declare class ProposalResult extends BaseModel {
123
123
  get proposals(): ContractProposal[];
@@ -125,16 +125,17 @@ declare class ProposalResult extends BaseModel {
125
125
  get split(): Raw | null;
126
126
  get conflict(): Raw | null;
127
127
  get closestTask(): string | null;
128
- get intent(): string | null;
128
+ get prompt(): string | null;
129
129
  get message(): string | null;
130
- /** True when the binder matched exactly ONE homogeneous SPECIFIC contract at
131
- * high/medium confidence and no conflict/split — the case `create` auto-binds
132
- * without a human confirming. The `custom-eval` universal FLOOR is EXCLUDED:
133
- * the binder offers it only when no specific contract fits, and per the
134
- * precision ladder the floor is a CHOICE — the user opts in with
135
- * `task: "custom-eval"`, never a silent auto-bind. */
130
+ /** True when exactly ONE homogeneous SPECIFIC task matched at high/medium
131
+ * confidence with no conflict/split — the case a task-less `create`
132
+ * proceeds with, no human confirming. `custom-eval` (a judge panel grading
133
+ * each answer against your prompt) is EXCLUDED: it is offered only when
134
+ * nothing specific fits, and using it is the user's CHOICE — opt in with
135
+ * `task: "custom-eval"`, never silently. */
136
136
  get isClean(): boolean;
137
- /** The task `create` would auto-bind, or null if the result isn't clean. */
137
+ /** How a task-less `create` would score this set, or null if the result
138
+ * isn't clean (pass `task` yourself). */
138
139
  get boundTask(): string | null;
139
140
  }
140
141
  /**
@@ -330,16 +331,17 @@ declare class Tasks {
330
331
  /**
331
332
  * `client.evals` — eval sets + runs (bring-your-own-data evaluation).
332
333
  *
333
- * // An eval set is DATA + INTENT (v2, breaking): intent REQUIRED, task
334
- * // OPTIONAL — the binder resolves your intent + the data's shape.
335
- * await pa.evals.proposeContract({ items: [...], intent: "…" }); // preview
336
- * const set = await pa.evals.sets.create({ items: [...], intent: "…" }); // auto-binds
334
+ * // An eval set is DATA + PROMPT (v3, breaking): prompt REQUIRED, task
335
+ * // OPTIONAL — Pareta works out how to score the results from your
336
+ * // prompt + the data's shape.
337
+ * await pa.evals.proposeContract({ items: [...], prompt: "…" }); // preview
338
+ * const set = await pa.evals.sets.create({ items: [...], prompt: "…" }); // clean match used automatically
337
339
  * await pa.evals.sets.uploadDocument(set.id, file, { idx, fieldName }); // blob tasks
338
340
  * const run = await pa.evals.runs.create({ evalSet: set.id, models: [...], wait: true });
339
- * // or, in one call: runs.create({ items, intent: "…", models, wait: true })
341
+ * // or, in one call: runs.create({ items, prompt: "…", models, wait: true })
340
342
  *
341
- * `create` (and the inline `runs.create` sugar) require `intent`; with no
342
- * `task` they call `proposeContract` and auto-bind ONLY a clean single
343
+ * `create` (and the inline `runs.create` sugar) require `prompt`; with no
344
+ * `task` they call `proposeContract` and accept ONLY a clean single
343
345
  * high/medium match — a conflict, split, or ambiguity throws with the
344
346
  * proposals so you pin `task`.
345
347
  *
@@ -357,21 +359,21 @@ declare class EvalSets {
357
359
  private readonly client;
358
360
  constructor(client: Transport);
359
361
  /**
360
- * Persist an eval set from your rows. `intent` is REQUIRED (v2): one sentence
361
- * on what the model should do with each item. `task` is OPTIONAL — omit it and
362
- * the binder resolves your intent + the data's shape to a grading contract
363
- * (auto-binds a clean single match; throws with the proposals otherwise). Pass
364
- * `task` to pin one explicitly.
362
+ * Persist an eval set from your rows. `prompt` is REQUIRED (v3): one sentence
363
+ * on what the model should do with each item. `task` is OPTIONAL — omit it
364
+ * and Pareta works out how to score the results from your prompt + the
365
+ * data's shape (a clean single match is used; anything ambiguous throws with
366
+ * the proposals). Pass `task` to pin one explicitly.
365
367
  */
366
368
  create(params: {
367
369
  items: Array<Record<string, unknown>>;
368
- intent: string;
370
+ prompt: string;
369
371
  task?: string;
370
372
  name?: string;
371
373
  }): Promise<EvalSet>;
372
- /** Internal: the binder call `create` uses when no task is pinned. Public on
374
+ /** Internal: the propose call `create` uses when no task is pinned. Public on
373
375
  * `Evals` as `proposeContract`; kept here so `sets.create` can reach it. */
374
- proposeContract(items: Array<Record<string, unknown>>, intent: string): Promise<ProposalResult>;
376
+ proposeContract(items: Array<Record<string, unknown>>, prompt: string): Promise<ProposalResult>;
375
377
  list(): Promise<EvalSet[]>;
376
378
  retrieve(evalSetId: string): Promise<EvalSet>;
377
379
  delete(evalSetId: string): Promise<void>;
@@ -390,7 +392,7 @@ interface EvalRunCreateParams {
390
392
  evalSet?: string;
391
393
  task?: string;
392
394
  items?: Array<Record<string, unknown>>;
393
- intent?: string;
395
+ prompt?: string;
394
396
  models: string[];
395
397
  frontier?: FrontierSpec;
396
398
  name?: string;
@@ -416,14 +418,15 @@ declare class Evals {
416
418
  constructor(client: Transport);
417
419
  private readonly client;
418
420
  /**
419
- * Which grading contract fits your data under your stated `intent`? Stateless
421
+ * How would your data be scored under your stated `prompt`? Stateless
420
422
  * discovery — nothing is persisted. Returns a ProposalResult (ranked
421
- * proposals, the auto-bind decision, conflict/split reporting). `sets.create`
422
- * calls this under the hood; use it directly to preview the binding first.
423
+ * proposals, the task a task-less create would use, conflict/split
424
+ * reporting). `sets.create` calls this under the hood; use it directly to
425
+ * preview the scoring first.
423
426
  */
424
427
  proposeContract(params: {
425
428
  items: Array<Record<string, unknown>>;
426
- intent: string;
429
+ prompt: string;
427
430
  }): Promise<ProposalResult>;
428
431
  /**
429
432
  * The frontier (vendor) roster you can evaluate against. With `task`, each is
@@ -712,7 +715,7 @@ declare class Pareta implements Transport {
712
715
  stream<T = unknown>(method: string, path: string, opts?: StreamOptions): AsyncGenerator<T>;
713
716
  }
714
717
 
715
- declare const VERSION = "2.1.0";
718
+ declare const VERSION = "3.0.0";
716
719
 
717
720
  /**
718
721
  * Typed error hierarchy for the Pareta SDK — a faithful port of the Python
package/dist/index.d.ts CHANGED
@@ -99,13 +99,13 @@ declare class EvalSet extends BaseModel {
99
99
  get itemCount(): number | null;
100
100
  get scoringStrategy(): string | null;
101
101
  /** The one-sentence success criterion this set was created with (CB1:
102
- * DATA + INTENT). Required at create. */
103
- get intent(): string | null;
102
+ * DATA + PROMPT). Required at create. */
103
+ get prompt(): string | null;
104
104
  }
105
105
  /**
106
- * One proposed grading contract for an uploaded dataset (a row of
107
- * `ProposalResult.proposals`). `warning` is set on the custom-eval floor when
108
- * the data looks extraction-shaped (judge grading is weaker there).
106
+ * One proposed way to score an uploaded dataset (a row of
107
+ * `ProposalResult.proposals`). `warning` is set on a "custom-eval" proposal
108
+ * when the data looks extraction-shaped (judge grading is weaker there).
109
109
  */
110
110
  declare class ContractProposal extends BaseModel {
111
111
  get taskId(): string | null;
@@ -114,10 +114,10 @@ declare class ContractProposal extends BaseModel {
114
114
  get warning(): string | null;
115
115
  }
116
116
  /**
117
- * The binder's answer for `evals.proposeContract` (POST
118
- * /v1/eval-sets/propose-contract): which grading contract(s) fit your data
119
- * under your stated intent. Nothing is persisted — confirm by passing the
120
- * chosen `taskId` (or letting `create` auto-bind a clean single proposal).
117
+ * Pareta's answer for `evals.proposeContract` (POST
118
+ * /v1/eval-sets/propose-contract): how your data could be scored under your
119
+ * stated prompt. Nothing is persisted — confirm by passing the chosen
120
+ * `taskId` (or letting a task-less `create` use a clean single proposal).
121
121
  */
122
122
  declare class ProposalResult extends BaseModel {
123
123
  get proposals(): ContractProposal[];
@@ -125,16 +125,17 @@ declare class ProposalResult extends BaseModel {
125
125
  get split(): Raw | null;
126
126
  get conflict(): Raw | null;
127
127
  get closestTask(): string | null;
128
- get intent(): string | null;
128
+ get prompt(): string | null;
129
129
  get message(): string | null;
130
- /** True when the binder matched exactly ONE homogeneous SPECIFIC contract at
131
- * high/medium confidence and no conflict/split — the case `create` auto-binds
132
- * without a human confirming. The `custom-eval` universal FLOOR is EXCLUDED:
133
- * the binder offers it only when no specific contract fits, and per the
134
- * precision ladder the floor is a CHOICE — the user opts in with
135
- * `task: "custom-eval"`, never a silent auto-bind. */
130
+ /** True when exactly ONE homogeneous SPECIFIC task matched at high/medium
131
+ * confidence with no conflict/split — the case a task-less `create`
132
+ * proceeds with, no human confirming. `custom-eval` (a judge panel grading
133
+ * each answer against your prompt) is EXCLUDED: it is offered only when
134
+ * nothing specific fits, and using it is the user's CHOICE — opt in with
135
+ * `task: "custom-eval"`, never silently. */
136
136
  get isClean(): boolean;
137
- /** The task `create` would auto-bind, or null if the result isn't clean. */
137
+ /** How a task-less `create` would score this set, or null if the result
138
+ * isn't clean (pass `task` yourself). */
138
139
  get boundTask(): string | null;
139
140
  }
140
141
  /**
@@ -330,16 +331,17 @@ declare class Tasks {
330
331
  /**
331
332
  * `client.evals` — eval sets + runs (bring-your-own-data evaluation).
332
333
  *
333
- * // An eval set is DATA + INTENT (v2, breaking): intent REQUIRED, task
334
- * // OPTIONAL — the binder resolves your intent + the data's shape.
335
- * await pa.evals.proposeContract({ items: [...], intent: "…" }); // preview
336
- * const set = await pa.evals.sets.create({ items: [...], intent: "…" }); // auto-binds
334
+ * // An eval set is DATA + PROMPT (v3, breaking): prompt REQUIRED, task
335
+ * // OPTIONAL — Pareta works out how to score the results from your
336
+ * // prompt + the data's shape.
337
+ * await pa.evals.proposeContract({ items: [...], prompt: "…" }); // preview
338
+ * const set = await pa.evals.sets.create({ items: [...], prompt: "…" }); // clean match used automatically
337
339
  * await pa.evals.sets.uploadDocument(set.id, file, { idx, fieldName }); // blob tasks
338
340
  * const run = await pa.evals.runs.create({ evalSet: set.id, models: [...], wait: true });
339
- * // or, in one call: runs.create({ items, intent: "…", models, wait: true })
341
+ * // or, in one call: runs.create({ items, prompt: "…", models, wait: true })
340
342
  *
341
- * `create` (and the inline `runs.create` sugar) require `intent`; with no
342
- * `task` they call `proposeContract` and auto-bind ONLY a clean single
343
+ * `create` (and the inline `runs.create` sugar) require `prompt`; with no
344
+ * `task` they call `proposeContract` and accept ONLY a clean single
343
345
  * high/medium match — a conflict, split, or ambiguity throws with the
344
346
  * proposals so you pin `task`.
345
347
  *
@@ -357,21 +359,21 @@ declare class EvalSets {
357
359
  private readonly client;
358
360
  constructor(client: Transport);
359
361
  /**
360
- * Persist an eval set from your rows. `intent` is REQUIRED (v2): one sentence
361
- * on what the model should do with each item. `task` is OPTIONAL — omit it and
362
- * the binder resolves your intent + the data's shape to a grading contract
363
- * (auto-binds a clean single match; throws with the proposals otherwise). Pass
364
- * `task` to pin one explicitly.
362
+ * Persist an eval set from your rows. `prompt` is REQUIRED (v3): one sentence
363
+ * on what the model should do with each item. `task` is OPTIONAL — omit it
364
+ * and Pareta works out how to score the results from your prompt + the
365
+ * data's shape (a clean single match is used; anything ambiguous throws with
366
+ * the proposals). Pass `task` to pin one explicitly.
365
367
  */
366
368
  create(params: {
367
369
  items: Array<Record<string, unknown>>;
368
- intent: string;
370
+ prompt: string;
369
371
  task?: string;
370
372
  name?: string;
371
373
  }): Promise<EvalSet>;
372
- /** Internal: the binder call `create` uses when no task is pinned. Public on
374
+ /** Internal: the propose call `create` uses when no task is pinned. Public on
373
375
  * `Evals` as `proposeContract`; kept here so `sets.create` can reach it. */
374
- proposeContract(items: Array<Record<string, unknown>>, intent: string): Promise<ProposalResult>;
376
+ proposeContract(items: Array<Record<string, unknown>>, prompt: string): Promise<ProposalResult>;
375
377
  list(): Promise<EvalSet[]>;
376
378
  retrieve(evalSetId: string): Promise<EvalSet>;
377
379
  delete(evalSetId: string): Promise<void>;
@@ -390,7 +392,7 @@ interface EvalRunCreateParams {
390
392
  evalSet?: string;
391
393
  task?: string;
392
394
  items?: Array<Record<string, unknown>>;
393
- intent?: string;
395
+ prompt?: string;
394
396
  models: string[];
395
397
  frontier?: FrontierSpec;
396
398
  name?: string;
@@ -416,14 +418,15 @@ declare class Evals {
416
418
  constructor(client: Transport);
417
419
  private readonly client;
418
420
  /**
419
- * Which grading contract fits your data under your stated `intent`? Stateless
421
+ * How would your data be scored under your stated `prompt`? Stateless
420
422
  * discovery — nothing is persisted. Returns a ProposalResult (ranked
421
- * proposals, the auto-bind decision, conflict/split reporting). `sets.create`
422
- * calls this under the hood; use it directly to preview the binding first.
423
+ * proposals, the task a task-less create would use, conflict/split
424
+ * reporting). `sets.create` calls this under the hood; use it directly to
425
+ * preview the scoring first.
423
426
  */
424
427
  proposeContract(params: {
425
428
  items: Array<Record<string, unknown>>;
426
- intent: string;
429
+ prompt: string;
427
430
  }): Promise<ProposalResult>;
428
431
  /**
429
432
  * The frontier (vendor) roster you can evaluate against. With `task`, each is
@@ -712,7 +715,7 @@ declare class Pareta implements Transport {
712
715
  stream<T = unknown>(method: string, path: string, opts?: StreamOptions): AsyncGenerator<T>;
713
716
  }
714
717
 
715
- declare const VERSION = "2.1.0";
718
+ declare const VERSION = "3.0.0";
716
719
 
717
720
  /**
718
721
  * Typed error hierarchy for the Pareta SDK — a faithful port of the Python
package/dist/index.mjs CHANGED
@@ -172,7 +172,7 @@ function parseSSE(reader, opts) {
172
172
  }
173
173
 
174
174
  // src/version.ts
175
- var VERSION = "2.1.0";
175
+ var VERSION = "3.0.0";
176
176
 
177
177
  // src/money.ts
178
178
  var MICRO_PER_CENT = 10000n;
@@ -370,9 +370,9 @@ var EvalSet = class extends BaseModel {
370
370
  return this.raw.scoring_strategy ?? null;
371
371
  }
372
372
  /** The one-sentence success criterion this set was created with (CB1:
373
- * DATA + INTENT). Required at create. */
374
- get intent() {
375
- return this.raw.intent ?? null;
373
+ * DATA + PROMPT). Required at create. */
374
+ get prompt() {
375
+ return this.raw.prompt ?? null;
376
376
  }
377
377
  };
378
378
  function evalSetFromCreate(raw) {
@@ -411,23 +411,24 @@ var ProposalResult = class extends BaseModel {
411
411
  get closestTask() {
412
412
  return this.raw.closest_task ?? null;
413
413
  }
414
- get intent() {
415
- return this.raw.intent ?? null;
414
+ get prompt() {
415
+ return this.raw.prompt ?? null;
416
416
  }
417
417
  get message() {
418
418
  return this.raw.message ?? null;
419
419
  }
420
- /** True when the binder matched exactly ONE homogeneous SPECIFIC contract at
421
- * high/medium confidence and no conflict/split — the case `create` auto-binds
422
- * without a human confirming. The `custom-eval` universal FLOOR is EXCLUDED:
423
- * the binder offers it only when no specific contract fits, and per the
424
- * precision ladder the floor is a CHOICE — the user opts in with
425
- * `task: "custom-eval"`, never a silent auto-bind. */
420
+ /** True when exactly ONE homogeneous SPECIFIC task matched at high/medium
421
+ * confidence with no conflict/split — the case a task-less `create`
422
+ * proceeds with, no human confirming. `custom-eval` (a judge panel grading
423
+ * each answer against your prompt) is EXCLUDED: it is offered only when
424
+ * nothing specific fits, and using it is the user's CHOICE — opt in with
425
+ * `task: "custom-eval"`, never silently. */
426
426
  get isClean() {
427
427
  const props = this.proposals;
428
428
  return this.homogeneous && this.conflict == null && this.split == null && props.length === 1 && (props[0].confidence === "high" || props[0].confidence === "medium") && Boolean(props[0].taskId) && props[0].taskId !== "custom-eval";
429
429
  }
430
- /** The task `create` would auto-bind, or null if the result isn't clean. */
430
+ /** How a task-less `create` would score this set, or null if the result
431
+ * isn't clean (pass `task` yourself). */
431
432
  get boundTask() {
432
433
  return this.isClean ? this.proposals[0].taskId : null;
433
434
  }
@@ -776,37 +777,37 @@ async function toBlob(file, mimeOverride) {
776
777
  const mime = mimeOverride || "application/octet-stream";
777
778
  return { blob: new Blob([bytes], { type: mime }), filename: "upload", size: bytes.byteLength, mime };
778
779
  }
779
- function requireIntent(intent) {
780
- const s = (intent ?? "").trim();
780
+ function requirePrompt(prompt) {
781
+ const s = (prompt ?? "").trim();
781
782
  if (!s) {
782
783
  throw new ParetaError(
783
- 'intent is required: one sentence describing what the model should do with each item (e.g. "extract vendor, total and date from each invoice"). Pass intent to evals.create / proposeContract.'
784
+ 'prompt is required: one sentence describing what the model should do with each item (e.g. "extract vendor, total and date from each invoice"). Pass prompt to evals.create / proposeContract.'
784
785
  );
785
786
  }
786
787
  return s.slice(0, 500);
787
788
  }
788
- function itemsJsonl(task, items, intent, name) {
789
+ function itemsJsonl(task, items, prompt, name) {
789
790
  if (!items || items.length === 0) throw new ParetaError("items is required and must be non-empty");
790
791
  const jsonl = items.map((it) => JSON.stringify(it)).join("\n");
791
792
  return {
792
793
  files: { items: { filename: `items.${task}.jsonl`, content: jsonl, contentType: "application/jsonl" } },
793
- data: { task_id: task, intent, name: name || `sdk eval set (${items.length} items)` }
794
+ data: { task_id: task, prompt, name: name || `sdk eval set (${items.length} items)` }
794
795
  };
795
796
  }
796
- function proposeMultipart(items, intent) {
797
+ function proposeMultipart(items, prompt) {
797
798
  if (!items || items.length === 0) throw new ParetaError("items is required and must be non-empty");
798
799
  const jsonl = items.map((it) => JSON.stringify(it)).join("\n");
799
800
  return {
800
801
  files: { items: { filename: "items.jsonl", content: jsonl, contentType: "application/jsonl" } },
801
- data: { intent }
802
+ data: { prompt }
802
803
  };
803
804
  }
804
805
  function bindError(result) {
805
- const intent = result.intent ?? "";
806
+ const prompt = result.prompt ?? "";
806
807
  if (result.conflict) {
807
808
  const c = result.conflict;
808
809
  return new ParetaError(
809
- `intent '${intent}' describes a different job than the data's shape supports (reads as '${c.intended_task}': ${c.reasoning}). Pass a task to pin a contract, or revise the intent.`
810
+ `prompt '${prompt}' describes a different job than the data's shape supports (reads as '${c.intended_task}': ${c.reasoning}). Pass a task to pin the task, or revise the prompt.`
810
811
  );
811
812
  }
812
813
  if (result.split) {
@@ -819,14 +820,14 @@ function bindError(result) {
819
820
  if (props.length === 1 && props[0].taskId === "custom-eval") {
820
821
  const warn = props[0].warning ? ` (${props[0].warning})` : "";
821
822
  return new ParetaError(
822
- `no specific grading contract fits this data for intent '${intent}'. The custom-eval universal floor is available \u2014 it grades by judged win-rate vs the frontier anchor.${warn} Pass task: "custom-eval" to use it, or revise the data/intent for a specific contract.`
823
+ `no ready-made scorer fits this data for prompt '${prompt}'. A judge panel can grade each answer against what you asked for (win rate vs gpt-5.5) \u2014 pass task: "custom-eval" to use it.${warn} Or revise the data/prompt so a specific task fits.`
823
824
  );
824
825
  }
825
826
  const options = props.map((p) => p.taskId).filter(Boolean);
826
827
  if (options.length === 0 && result.closestTask) options.push(result.closestTask);
827
828
  const hint = options.length ? ` Candidates: ${options.join(", ")}.` : "";
828
829
  return new ParetaError(
829
- `could not confidently bind a grading contract for intent '${intent}'.${hint} Pass a task to pin one, or inspect evals.proposeContract({ items, intent }).`
830
+ `couldn't work out how to score this for prompt '${prompt}'.${hint} Pass a task to choose yourself, or inspect evals.proposeContract({ items, prompt }).`
830
831
  );
831
832
  }
832
833
  function mergeCandidates(models, frontierIds) {
@@ -850,27 +851,27 @@ var EvalSets = class {
850
851
  }
851
852
  client;
852
853
  /**
853
- * Persist an eval set from your rows. `intent` is REQUIRED (v2): one sentence
854
- * on what the model should do with each item. `task` is OPTIONAL — omit it and
855
- * the binder resolves your intent + the data's shape to a grading contract
856
- * (auto-binds a clean single match; throws with the proposals otherwise). Pass
857
- * `task` to pin one explicitly.
854
+ * Persist an eval set from your rows. `prompt` is REQUIRED (v3): one sentence
855
+ * on what the model should do with each item. `task` is OPTIONAL — omit it
856
+ * and Pareta works out how to score the results from your prompt + the
857
+ * data's shape (a clean single match is used; anything ambiguous throws with
858
+ * the proposals). Pass `task` to pin one explicitly.
858
859
  */
859
860
  async create(params) {
860
- const intent = requireIntent(params.intent);
861
+ const prompt = requirePrompt(params.prompt);
861
862
  let task = params.task;
862
863
  if (task == null) {
863
- const proposal = await this.proposeContract(params.items, intent);
864
+ const proposal = await this.proposeContract(params.items, prompt);
864
865
  task = proposal.boundTask ?? void 0;
865
866
  if (task == null) throw bindError(proposal);
866
867
  }
867
- const { files, data } = itemsJsonl(task, params.items, intent, params.name);
868
+ const { files, data } = itemsJsonl(task, params.items, prompt, params.name);
868
869
  return this.client.request("POST", BASE2, { files, data, cast: evalSetFromCreate });
869
870
  }
870
- /** Internal: the binder call `create` uses when no task is pinned. Public on
871
+ /** Internal: the propose call `create` uses when no task is pinned. Public on
871
872
  * `Evals` as `proposeContract`; kept here so `sets.create` can reach it. */
872
- proposeContract(items, intent) {
873
- const { files, data } = proposeMultipart(items, requireIntent(intent));
873
+ proposeContract(items, prompt) {
874
+ const { files, data } = proposeMultipart(items, requirePrompt(prompt));
874
875
  return this.client.request("POST", PROPOSE, { files, data, cast: proposalResult });
875
876
  }
876
877
  list() {
@@ -941,11 +942,11 @@ var EvalRuns = class {
941
942
  let evalSet = params.evalSet;
942
943
  if (evalSet == null) {
943
944
  if (!params.items) {
944
- throw new ParetaError("pass evalSet: <id>, or items (+ intent) to create one");
945
+ throw new ParetaError("pass evalSet: <id>, or items (+ prompt) to create one");
945
946
  }
946
947
  evalSet = (await this.sets.create({
947
948
  items: params.items,
948
- intent: params.intent,
949
+ prompt: params.prompt,
949
950
  task: params.task,
950
951
  name: params.name
951
952
  })).id ?? void 0;
@@ -989,13 +990,14 @@ var Evals = class {
989
990
  }
990
991
  client;
991
992
  /**
992
- * Which grading contract fits your data under your stated `intent`? Stateless
993
+ * How would your data be scored under your stated `prompt`? Stateless
993
994
  * discovery — nothing is persisted. Returns a ProposalResult (ranked
994
- * proposals, the auto-bind decision, conflict/split reporting). `sets.create`
995
- * calls this under the hood; use it directly to preview the binding first.
995
+ * proposals, the task a task-less create would use, conflict/split
996
+ * reporting). `sets.create` calls this under the hood; use it directly to
997
+ * preview the scoring first.
996
998
  */
997
999
  proposeContract(params) {
998
- return this.sets.proposeContract(params.items, params.intent);
1000
+ return this.sets.proposeContract(params.items, params.prompt);
999
1001
  }
1000
1002
  /**
1001
1003
  * The frontier (vendor) roster you can evaluate against. With `task`, each is