@ornncompute/cli 1.0.342 → 1.0.344
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/package.json
CHANGED
|
@@ -68,7 +68,7 @@ function postInference(fetcher, path6, body2, listingId2, signal) {
|
|
|
68
68
|
method: "POST",
|
|
69
69
|
headers: {
|
|
70
70
|
"Content-Type": "application/json",
|
|
71
|
-
"X-Ornn-Listing-Id": listingId2
|
|
71
|
+
...listingId2 !== void 0 && { "X-Ornn-Listing-Id": listingId2 }
|
|
72
72
|
},
|
|
73
73
|
body: JSON.stringify(body2),
|
|
74
74
|
signal
|
|
@@ -246,6 +246,7 @@ var apiType = z2.enum(inferenceApiTypes).optional();
|
|
|
246
246
|
var timestamp = z2.iso.datetime({ offset: true });
|
|
247
247
|
var limit = z2.coerce.number().int().min(1).max(100).optional();
|
|
248
248
|
var listingId = z2.strictObject({ listing_id: z2.uuid() });
|
|
249
|
+
var listingPin = z2.uuid().optional().describe("Pin an exact offer. Omit to choose by lowest input price, then lowest output price.");
|
|
249
250
|
var page = z2.strictObject({ after: text.optional(), limit });
|
|
250
251
|
var rates = {
|
|
251
252
|
provider_input_usd_per_million_tokens: z2.string().nullable().optional(),
|
|
@@ -405,12 +406,12 @@ var inferenceCapabilities = [
|
|
|
405
406
|
operation({
|
|
406
407
|
command: ["completions", "create"],
|
|
407
408
|
description: "Call an inference model using a Chat Completions body. Generation parameters pass through unchanged. Spends the organization's credits; returns the upstream JSON response. MCP uses non-streaming responses.",
|
|
408
|
-
input: z2.strictObject({ listing_id:
|
|
409
|
+
input: z2.strictObject({ listing_id: listingPin, body: completionBody }),
|
|
409
410
|
mcpInput: z2.strictObject({
|
|
410
|
-
listing_id:
|
|
411
|
+
listing_id: listingPin,
|
|
411
412
|
body: completionBody.extend({ stream: z2.literal(false).nullable().optional() })
|
|
412
413
|
}),
|
|
413
|
-
usage: "--body JSON --listing-id UUID",
|
|
414
|
+
usage: "--body JSON [--listing-id UUID]",
|
|
414
415
|
write: true,
|
|
415
416
|
execute: async (ctx, { body: body2, listing_id }) => {
|
|
416
417
|
if (body2.stream && ctx.cli?.interaction?.format !== "human") {
|
|
@@ -426,14 +427,14 @@ var inferenceCapabilities = [
|
|
|
426
427
|
command: ["decisions", "create"],
|
|
427
428
|
description: "Ask questions about input using a Decisions model. Returns the provider's answers and spends the organization's credits at the listing's rates.",
|
|
428
429
|
input: z2.strictObject({
|
|
429
|
-
listing_id:
|
|
430
|
+
listing_id: listingPin,
|
|
430
431
|
body: z2.looseObject({
|
|
431
432
|
model: text,
|
|
432
433
|
input: z2.union([z2.string(), z2.array(z2.looseObject({}))]),
|
|
433
434
|
questions: z2.array(z2.looseObject({}))
|
|
434
435
|
})
|
|
435
436
|
}),
|
|
436
|
-
usage: "--body JSON --listing-id UUID",
|
|
437
|
+
usage: "--body JSON [--listing-id UUID]",
|
|
437
438
|
write: true,
|
|
438
439
|
execute: async (ctx, { body: body2, listing_id }) => {
|
|
439
440
|
if (!ctx.fetchResponse)
|