Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 1 addition & 10 deletions Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 12 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,9 @@ Enable the trait in Package.swift:
)
```

> [!NOTE]
> MLX supports guided generation (structured output via `@Generable`).

### llama.cpp (GGUF)

Run GGUF quantized models via [llama.cpp](https://github.com/ggml-org/llama.cpp)
Expand Down Expand Up @@ -419,6 +422,7 @@ let response = try await session.respond(

> [!NOTE]
> Image inputs are not currently supported with `LlamaLanguageModel`.
> Guided generation (structured output via `@Generable`) is supported.

### OpenAI

Expand Down Expand Up @@ -657,14 +661,14 @@ swift test

Tests for different language model backends have varying requirements:

| Backend | Traits | Environment Variables |
|---------|--------|----------------------|
| CoreML | `CoreML` | `HF_TOKEN` |
| MLX | `MLX` | `HF_TOKEN` |
| Llama | `Llama` | `LLAMA_MODEL_PATH` |
| Anthropic | — | `ANTHROPIC_API_KEY` |
| OpenAI | — | `OPENAI_API_KEY` |
| Ollama | — | — |
| Backend | Traits | Environment Variables |
| --------- | -------- | --------------------- |
| CoreML | `CoreML` | `HF_TOKEN` |
| MLX | `MLX` | `HF_TOKEN` |
| Llama | `Llama` | `LLAMA_MODEL_PATH` |
| Anthropic | — | `ANTHROPIC_API_KEY` |
| OpenAI | — | `OPENAI_API_KEY` |
| Ollama | — | — |

Example setup for running multiple tests at once:

Expand Down