Skip to content

Commit 1c31268

Browse files
authored
refactor: move remaining api packages to core (#1731)
* core 1 * api/openai/files fix * core 2 - core/config * move over core api.go and tests to the start of core/http * move over localai specific endpoints to core/http, begin the service/endpoint split there * refactor big chunk on the plane * refactor chunk 2 on plane, next step: port and modify changes to request.go * easy fixes for request.go, major changes not done yet * lintfix * json tag lintfix? * gitignore and .keep files * strange fix attempt: rename the config dir?
1 parent 316de82 commit 1c31268

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+1441
-1207
lines changed

.gitignore

+3-1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ local-ai
2121
!charts/*
2222
# prevent above rules from omitting the api/localai folder
2323
!api/localai
24+
!core/**/localai
2425

2526
# Ignore models
2627
models/*
@@ -34,6 +35,7 @@ release/
3435
.idea
3536

3637
# Generated during build
37-
backend-assets/
38+
backend-assets/*
39+
!backend-assets/.keep
3840
prepare
3941
/ggml-metal.metal

Makefile

+3-1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ BUILD_ID?=git
4444

4545
TEST_DIR=/tmp/test
4646

47+
TEST_FLAKES?=5
48+
4749
RANDOM := $(shell bash -c 'echo $$RANDOM')
4850

4951
VERSION?=$(shell git describe --always --tags || echo "dev" )
@@ -337,7 +339,7 @@ test: prepare test-models/testmodel grpcs
337339
export GO_TAGS="tts stablediffusion"
338340
$(MAKE) prepare-test
339341
HUGGINGFACE_GRPC=$(abspath ./)/backend/python/sentencetransformers/run.sh TEST_DIR=$(abspath ./)/test-dir/ FIXTURES=$(abspath ./)/tests/fixtures CONFIG_FILE=$(abspath ./)/test-models/config.yaml MODELS_PATH=$(abspath ./)/test-models \
340-
$(GOCMD) run github.com/onsi/ginkgo/v2/ginkgo --label-filter="!gpt4all && !llama && !llama-gguf" --flake-attempts 5 --fail-fast -v -r $(TEST_PATHS)
342+
$(GOCMD) run github.com/onsi/ginkgo/v2/ginkgo --label-filter="!gpt4all && !llama && !llama-gguf" --flake-attempts $(TEST_FLAKES) --fail-fast -v -r $(TEST_PATHS)
341343
$(MAKE) test-gpt4all
342344
$(MAKE) test-llama
343345
$(MAKE) test-llama-gguf

api/localai/backend_monitor.go

-162
This file was deleted.

0 commit comments

Comments
 (0)