Polyman Documentation - v3.1.0
    Preparing search index...

    Interface PresetQuirks

    Changes from the default OpenAI-compatible quirks for one server.

    It has the same fields as Partial<Quirks> of the OpenAI-compatible adapter (#76). When that adapter lands, this type can become an alias of Partial<Quirks>.

    interface PresetQuirks {
        streamOptions?: boolean;
        maxTokensField?: "max_tokens" | "max_completion_tokens";
        reasoningFields?: readonly string[];
        repairToolArgs?: boolean;
        tools?: boolean;
        extraBody?: (req: ChatRequest) => Record<string, unknown>;
    }
    Index
    streamOptions?: boolean

    Send stream_options.include_usage.

    maxTokensField?: "max_tokens" | "max_completion_tokens"

    Name of the max output tokens field in the request body.

    reasoningFields?: readonly string[]

    Delta fields that hold reasoning text, checked in order.

    repairToolArgs?: boolean

    Try to fix tool arguments that are not valid JSON.

    tools?: boolean

    Whether the server supports tools at all.

    extraBody?: (req: ChatRequest) => Record<string, unknown>

    More fields for the request body, merged after the standard ones.