Skip to content

Commit

Permalink
1452: Code review fixes - mostly typos
Browse files Browse the repository at this point in the history
Co-authored-by: Jeppe Kuhlmann Andersen <78410897+jekuaitk@users.noreply.github.com>
  • Loading branch information
cableman and jekuaitk committed May 28, 2024
1 parent 62fb3e4 commit ebcd13d
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion llm_services.info.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: "Large language model services"
description: 'Large language module services to communicat with the models.'
description: 'Large language module services to communicate with the models.'
type: module
core_version_requirement: ^10
configure: llm_services.plugin_settings_local_tasks
2 changes: 1 addition & 1 deletion llm_services.links.task.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
llm_services.plugin_settings_tasks:
title: 'LLM Services settings'
title: 'LLM services settings'
route_name: llm_services.plugin_settings_local_tasks
base_route: llm_services.plugin_settings_local_tasks
deriver: Drupal\llm_services\Plugin\Derivative\LocalTask
2 changes: 1 addition & 1 deletion llm_services.routing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ llm_services.plugin_settings_local_tasks:
path: '/admin/config/llm_services/settings/{type}'
defaults:
_controller: '\Drupal\llm_services\Controller\LocalTasksController::dynamicTasks'
_title: 'LLM Services settings'
_title: 'LLM services settings'
type: ''
requirements:
_permission: 'administer site'
2 changes: 1 addition & 1 deletion src/Client/Ollama.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class Ollama {
* @param string $url
* The URL of the Ollama server.
* @param int $port
* The port that Ollama is listing on.
* The port that Ollama is listening on.
*/
public function __construct(
private readonly string $url,
Expand Down
2 changes: 1 addition & 1 deletion src/Drush/Commands/LlmServicesCommands.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public function installModel(string $provider, string $name): void {
#[CLI\Argument(name: 'provider', description: 'Name of the provider (plugin).')]
#[CLI\Argument(name: 'name', description: 'Name of the model to use.')]
#[CLI\Argument(name: 'prompt', description: 'The prompt to generate a response for.')]
#[CLI\Usage(name: 'llm:model:completion ollama llama2 "Why is the sky blue?"', description: 'Install LLama2 modul in Ollama')]
#[CLI\Usage(name: 'llm:model:completion ollama llama2 "Why is the sky blue?"', description: 'Prompt LLama2')]
public function completion(string $provider, string $name, string $prompt): void {
$provider = $this->providerManager->createInstance($provider);

Expand Down
2 changes: 1 addition & 1 deletion src/Exceptions/LLMException.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace Drupal\llm_services\Exceptions;

/**
* Base execution that all other exceptions should extend.
* Base exception that all other exceptions should extend.
*
* This will enable other modules to use this exception as an catch all.
*/
Expand Down
4 changes: 2 additions & 2 deletions src/Form/SettingsForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ public function buildForm(array $form, FormStateInterface $form_state): array {

$form['provider'] = [
'#type' => 'select',
'#title' => $this->t('Log provider'),
'#description' => $this->t('Select the logger provider you which to use'),
'#title' => $this->t('Provider'),
'#description' => $this->t('Select the provider you wish to use'),
'#options' => $options,
'#default_value' => $config->get('provider'),
];
Expand Down
2 changes: 1 addition & 1 deletion src/Model/MessageRoles.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@
*/
enum MessageRoles: string {
case Assistant = 'assistant';
case System = "system";
case System = 'system';
case User = 'user';
}

0 comments on commit ebcd13d

Please sign in to comment.