/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 * @generated-id: e01a16ab4844
 */
import * as z from "zod/v4";
import { remap as remap$ } from "../../lib/primitives.js";
import { smartUnion } from "../../types/smartUnion.js";
/** @internal */
export const FIMCompletionRequestStop$outboundSchema = smartUnion([z.string(), z.array(z.string())]);
export function fimCompletionRequestStopToJSON(fimCompletionRequestStop) {
    return JSON.stringify(FIMCompletionRequestStop$outboundSchema.parse(fimCompletionRequestStop));
}
/** @internal */
export const FIMCompletionRequest$outboundSchema = z.object({
    model: z.string(),
    temperature: z.nullable(z.number()).optional(),
    topP: z.nullable(z.number()).optional(),
    maxTokens: z.nullable(z.int()).optional(),
    stream: z.boolean().default(false),
    stop: z.nullable(smartUnion([z.string(), z.array(z.string())])).optional(),
    randomSeed: z.nullable(z.int()).optional(),
    metadata: z.nullable(z.record(z.string(), z.any())).optional(),
    prompt: z.string(),
    suffix: z.nullable(z.string()).optional(),
    minTokens: z.nullable(z.int()).optional(),
    promptCacheKey: z.nullable(z.string()).optional(),
}).transform((v) => {
    return remap$(v, {
        topP: "top_p",
        maxTokens: "max_tokens",
        randomSeed: "random_seed",
        minTokens: "min_tokens",
        promptCacheKey: "prompt_cache_key",
    });
});
export function fimCompletionRequestToJSON(fimCompletionRequest) {
    return JSON.stringify(FIMCompletionRequest$outboundSchema.parse(fimCompletionRequest));
}
//# sourceMappingURL=fimcompletionrequest.js.map