From 0c1c6d137a2d13a1070e16652978deb31f5805ae Mon Sep 17 00:00:00 2001 From: David Thorpe Date: Sun, 2 Feb 2025 21:59:11 +0100 Subject: [PATCH] Updated --- README.md | 10 +++++----- pkg/mistral/chat_completion_test.go | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 2cea2bd..99b2c64 100644 --- a/README.md +++ b/README.md @@ -24,13 +24,13 @@ docker run ghcr.io/mutablelogic/go-llm:latest --help # Interact with Claude to retrieve news headlines, assuming # you have an API key for Anthropic and NewsAPI docker run \ - --interactive -e MISTRAL_API_KEY -e NEWSAPI_KEY \ + -e OLLAMA_URL -e MISTRAL_API_KEY -e NEWSAPI_KEY \ ghcr.io/mutablelogic/go-llm:latest \ - chat claude-3-5-haiku-20241022 --prompt "What is the latest news?" + chat mistral-small-latest --prompt "What is the latest news?" --no-stream ``` -See below for more information on how to use the command-line tool (or how to install it -if you have a `go` compiler). +See below for more information on how to use the command-line tool (or how to +install it if you have a `go` compiler). ## Programmatic Usage @@ -250,7 +250,7 @@ Run "llm --help" for more information on a command. ## Contributing & Distribution -*This module is currently in development and subject to change*. Please do file +_This module is currently in development and subject to change_. Please do file feature requests and bugs [here](https://github.com/mutablelogic/go-llm/issues). The [license is Apache 2](LICENSE) so feel free to redistribute. Redistributions in either source code or binary form must reproduce the copyright notice, and please link back to this diff --git a/pkg/mistral/chat_completion_test.go b/pkg/mistral/chat_completion_test.go index 41afb88..b44d5ff 100644 --- a/pkg/mistral/chat_completion_test.go +++ b/pkg/mistral/chat_completion_test.go @@ -128,7 +128,7 @@ func Test_chat_002(t *testing.T) { } }) t.Run("PresencePenalty", func(t *testing.T) { - r, err := client.ChatCompletion(context.TODO(), model.UserPrompt("What is the temperature in London?"), mistral.WithPresencePenalty(-2)) + r, err := client.ChatCompletion(context.TODO(), model.UserPrompt("What is the temperature in London?"), llm.WithPresencePenalty(-2)) if assert.NoError(err) { assert.Equal("assistant", r.Role()) assert.Equal(1, r.Num()) @@ -137,7 +137,7 @@ func Test_chat_002(t *testing.T) { } }) t.Run("FrequencyPenalty", func(t *testing.T) { - r, err := client.ChatCompletion(context.TODO(), model.UserPrompt("What is the temperature in London?"), mistral.WithFrequencyPenalty(-2)) + r, err := client.ChatCompletion(context.TODO(), model.UserPrompt("What is the temperature in London?"), llm.WithFrequencyPenalty(-2)) if assert.NoError(err) { assert.Equal("assistant", r.Role()) assert.Equal(1, r.Num())