export function translateTools(tools) {
    return tools.map(t => ({
        type: 'function',
        function: {
            name: t.name,
            ...(t.description !== undefined && { description: t.description }),
            parameters: t.input_schema,
        },
    }));
}
export function translateToolChoice(choice) {
    if (choice === undefined)
        return undefined;
    switch (choice.type) {
        case 'auto': return 'auto';
        case 'any': return 'required';
        case 'none': return 'none';
        case 'tool': return { type: 'function', function: { name: choice.name } };
    }
}
//# sourceMappingURL=tools.js.map