mirror of
https://github.com/mudler/LocalAI.git
synced 2026-11-06 04:23:15 -05:00
test: fix the mock chat window, the MCP route scan and the add-on index
A chat now reports the window of its model, so the mock model with no context_size got the 4096 default and the tool schemas of a chat no longer fit: six Chats specs got no answer. Give the mock model a window that fits. The MCP route scan read every file under the package, including the test binaries that a macOS run builds there, and found the route names in them. It reads only Go source now. Regenerate the add-on library index for the new Memory description. Assisted-by: Claude:claude-sonnet-5-5 go ginkgo sh
This commit is contained in:
3 files changed
+13
-9
No files matched your search
@@ -332,7 +332,7 @@
|
||||
- "review-comment-pr"
|
||||
- id: "memory"
|
||||
name: Short memory
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
version: "0.0.0-development"
|
||||
channel: "development"
|
||||
artifact: "oci://quay.io/go-skynet/local-ai-addons:memory-development"
|
||||
@@ -345,12 +345,12 @@
|
||||
identity: "https://github.com/mudler/LocalAI/.github/workflows/addons-package.yml@refs/heads/master"
|
||||
ui:
|
||||
title: "Short memory"
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
mainPage: "memory"
|
||||
icon: "ui/icon.png"
|
||||
- id: "memory"
|
||||
name: Short memory
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
version: "0.0.0-development"
|
||||
channel: "development"
|
||||
artifact: "oci://quay.io/go-skynet/local-ai-addons:memory-development"
|
||||
@@ -363,12 +363,12 @@
|
||||
identity: "https://github.com/mudler/LocalAI/.github/workflows/addons-package.yml@refs/heads/master"
|
||||
ui:
|
||||
title: "Short memory"
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
mainPage: "memory"
|
||||
icon: "ui/icon.png"
|
||||
- id: "memory"
|
||||
name: Short memory
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
version: "0.0.0-development"
|
||||
channel: "development"
|
||||
artifact: "oci://quay.io/go-skynet/local-ai-addons:memory-development"
|
||||
@@ -381,12 +381,12 @@
|
||||
identity: "https://github.com/mudler/LocalAI/.github/workflows/addons-package.yml@refs/heads/master"
|
||||
ui:
|
||||
title: "Short memory"
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
mainPage: "memory"
|
||||
icon: "ui/icon.png"
|
||||
- id: "memory"
|
||||
name: Short memory
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
version: "0.0.0-development"
|
||||
channel: "development"
|
||||
artifact: "oci://quay.io/go-skynet/local-ai-addons:memory-development"
|
||||
@@ -399,7 +399,7 @@
|
||||
identity: "https://github.com/mudler/LocalAI/.github/workflows/addons-package.yml@refs/heads/master"
|
||||
ui:
|
||||
title: "Short memory"
|
||||
description: "Your chats keep short notes about you, read them before they answer, and save a new one only after you confirm it."
|
||||
description: "Your chats keep short notes about you and read them before they answer. By default a new note is saved only after you confirm it; you can choose to have it saved at once with an Undo, or never."
|
||||
mainPage: "memory"
|
||||
icon: "ui/icon.png"
|
||||
- id: "office"
|
||||
|
||||
@@ -26,7 +26,8 @@ var _ = Describe("host access and the MCP tools", func() {
|
||||
root := "."
|
||||
var hits []string
|
||||
Expect(filepath.Walk(root, func(path string, info os.FileInfo, err error) error {
|
||||
if err != nil || info.IsDir() || strings.HasSuffix(path, "_test.go") {
|
||||
// Only source files: a test binary built into the tree holds the names too.
|
||||
if err != nil || info.IsDir() || !strings.HasSuffix(path, ".go") || strings.HasSuffix(path, "_test.go") {
|
||||
return err
|
||||
}
|
||||
b, rerr := os.ReadFile(path)
|
||||
|
||||
@@ -117,6 +117,9 @@ var _ = BeforeSuite(func() {
|
||||
modelConfig := map[string]any{
|
||||
"name": "mock-model",
|
||||
"backend": "mock-backend",
|
||||
// A chat reports the window of the model, and the tool schemas of a
|
||||
// chat no longer fit in the default one.
|
||||
"context_size": 32768,
|
||||
"parameters": map[string]any{
|
||||
"model": "mock-model.bin",
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user