Skip to content

Commit

Permalink
Merge pull request #7 from giovannialbero1992/master
Browse files Browse the repository at this point in the history
Added call to llmssettings
  • Loading branch information
AlboCode authored Oct 8, 2024
2 parents d5818fe + 612aaec commit adf369a
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/CCatClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
use Albocode\CcatphpSdk\Clients\HttpClient;
use Albocode\CcatphpSdk\Clients\WSClient;
use Albocode\CcatphpSdk\Model\Api\LLMSetting\LLMSettingsOutput;
use Albocode\CcatphpSdk\Model\Api\LLMsSettings\LLMsSettingsOutput;
use Albocode\CcatphpSdk\Model\Api\Plugin\PluginCollectionOutput;
use Albocode\CcatphpSdk\Model\Api\Plugin\Settings\PluginSettingsOutput;
use Albocode\CcatphpSdk\Model\Api\RabbitHole\AllowedMimeTypesOutput;
Expand Down Expand Up @@ -299,6 +300,12 @@ public function getLLMSettings(string $llm): LLMSettingsOutput
return $this->serializer->deserialize($response->getBody()->getContents(), LLMSettingsOutput::class, 'json', []);
}

public function getLLMsSettings(): LLMsSettingsOutput
{
$response = $this->httpClient->getHttpClient()->get('/llm/settings', []);
return $this->serializer->deserialize($response->getBody()->getContents(), LLMsSettingsOutput::class, 'json', []);
}

/**
* @param string $llm
* @param array<string, mixed> $values
Expand Down
14 changes: 14 additions & 0 deletions src/Model/Api/LLMsSettings/LLMsSettingsOutput.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?php

namespace Albocode\CcatphpSdk\Model\Api\LLMsSettings;

class LLMsSettingsOutput
{

/**
* @var array<string, mixed>
*/
public array $settings;

public string $selectedConfiguration;
}

0 comments on commit adf369a

Please sign in to comment.