Chat models default to png

This commit is contained in:
Alex Gleason committed 2025-12-09 01:24:14 -06:00
1 parent 77f29c12af
commit 4106bc77b3
1 file changed
+3
+3
View File
@@ -58,6 +58,9 @@ export class GenerateImageTool implements Tool<GenerateImageParams> {
modalities: ['image'] as never[], // Type assertion needed as OpenAI SDK doesn't have this typed
});
// Default extension for chat models is png (output_format is ignored)
extension = 'png';
// Extract cost from response
const { usage } = response;
if (usage && 'cost' in usage && typeof usage.cost === 'number') {