Skip to content

Commit 893aa8b

Browse files
authored
Merge pull request #270 from deucebucket/fix/openai-compatible-provider
fix: make local AI providers model-agnostic
2 parents 6c254fc + 108246e commit 893aa8b

23 files changed

Lines changed: 1188 additions & 279 deletions

.github/workflows/code-quality.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,11 @@ jobs:
5050
python -m pip install --upgrade pip
5151
pip install -r requirements.txt
5252
53-
- name: Run Naming Tests
54-
run: python test-env/test-naming-issues.py
53+
- name: Run Tests
54+
run: |
55+
python test-env/test-naming-issues.py
56+
python test-env/test-ai-providers.py
57+
python test-env/test-ai-provider-integration.py
5558
5659
version-check:
5760
runs-on: ubuntu-latest

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,17 @@
22

33
All notable changes to Library Manager will be documented in this file.
44

5+
## [0.9.0-beta.155] - 2026-07-15
6+
7+
### Added
8+
- **Generic local AI provider** - Added a user-configured OpenAI-compatible provider for llama.cpp, LM Studio, vLLM, LocalAI, and similar servers. Library Manager discovers live model IDs from `/v1/models`, supports optional bearer authentication, and uses `/v1/chat/completions` across text verification, localization, and transcript identification.
9+
10+
### Fixed
11+
- **Ollama model selection is no longer locked to a hardcoded model** - Removed runtime and UI fallbacks to specific Ollama model names. Model discovery now accepts `name`, `model`, and string response shapes, excludes embedding-only entries, keeps the model field editable, and auto-selects only when the server exposes exactly one model. Native Ollama requests use bounded structured output, including an explicit array schema for multi-book batches, and both local-provider paths prevent runaway responses.
12+
- **Skaldleita transcripts now reach AI fallbacks** - When Skaldleita transcribes audio but cannot identify the book, the transcript continues through the configured provider chain instead of ending the audio-identification attempt early.
13+
- **Provider selection configures working fallback chains** - Setup and Settings automatically place the selected AI provider into the text and audio fallback chains while preserving Skaldleita as the first hosted audio-identification service.
14+
- **Provider secrets stay server-side** - New and updated `secrets.json` files enforce `0600` permissions, provider keys remain excluded from `config.json`, and Settings receives only configured/not-configured state instead of raw stored tokens.
15+
516
## [0.9.0-beta.154] - 2026-07-14
617

718
### Fixed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@
1616

1717
## Recent Changes (stable)
1818

19+
> **beta.155** - **Local AI Is Provider-Agnostic**
20+
> - Added llama.cpp and generic OpenAI-compatible API support with live `/v1/models` discovery.
21+
> - Removed hardcoded Ollama model fallbacks and fixed `undefined` model entries across API response shapes.
22+
> - Skaldleita transcripts now continue into the selected AI fallback instead of stopping early.
23+
1924
> **beta.150** - **Fix: Hosted AI Model Picker Uses Live Provider Models** (Issue #216)
2025
> - Replaced stale hardcoded Gemini/OpenRouter model dropdowns with editable model fields backed by live provider model lists.
2126
> - Gemini models load from the configured Gemini key; OpenRouter models load from OpenRouter's `/models` endpoint.
@@ -419,6 +424,14 @@ See [docs/DOCKER.md](docs/DOCKER.md) for detailed setup guides.
419424
- Multiple model options
420425
- Free tier available
421426

427+
**Ollama**
428+
- Self-hosted with live model discovery from the user's server
429+
- No hardcoded model requirement
430+
431+
**llama.cpp / OpenAI-compatible**
432+
- Works with llama.cpp, LM Studio, vLLM, LocalAI, and compatible `/v1` APIs
433+
- Live model discovery and optional API-key authentication
434+
422435
---
423436

424437
## API Reference
@@ -561,7 +574,7 @@ The idea for **Skaldleita** (audio fingerprinting + narrator voice identificatio
561574
## Contributing
562575

563576
Pull requests welcome! Ideas:
564-
- [ ] Ollama/local LLM support
577+
- [x] Ollama and generic local LLM support
565578
- [ ] Cover art fetching
566579
- [x] Metadata embedding (added in v0.9.0-beta.20)
567580
- [ ] Movie/music library support

0 commit comments

Comments
 (0)