Skip to content

Commit

Permalink
MBS-9373: Fix missing sizes option for dall-e-3 via azure
Browse files Browse the repository at this point in the history
  • Loading branch information
PhMemmel committed Sep 13, 2024
1 parent bb6db9a commit dcf2e1a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/dalle/classes/connector.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
namespace aitool_dalle;

use local_ai_manager\base_connector;
use local_ai_manager\base_instance;
use local_ai_manager\local\prompt_response;
use local_ai_manager\local\unit;
use local_ai_manager\local\usage;
Expand Down Expand Up @@ -109,6 +110,8 @@ public function get_available_options(): array {
];
break;
case 'dall-e-3':
// We assume that if using Azure (in which we would have PRECONFIGURED_MODEL as model) we only can deploy dall-e-3.
case base_instance::PRECONFIGURED_MODEL:
$options['sizes'] = [
['key' => '1024x1024', 'displayname' => get_string('squared', 'local_ai_manager') . ' (1024px x 1024px)'],
['key' => '1792x1024', 'displayname' => get_string('landscape', 'local_ai_manager') . ' (1792px x 1024px)'],
Expand Down

0 comments on commit dcf2e1a

Please sign in to comment.