Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶ added in v0.1.0
type Client interface {
// Return the provider name
Name() string
// ListModels returns the list of available models
ListModels(context.Context, ...opt.Opt) ([]schema.Model, error)
// GetModel returns the model with the given name
GetModel(context.Context, string, ...opt.Opt) (*schema.Model, error)
}
Client is the interface that wraps basic LLM client methods
type Downloader ¶ added in v0.1.0
type Downloader interface {
// DownloadModel downloads the specified model, and otherwise loads the model if already present
DownloadModel(context.Context, string, ...opt.Opt) (*schema.Model, error)
// DeleteModel deletes the specified model from local storage
DeleteModel(context.Context, schema.Model) error
}
Downloader is an interface for managing model files
type Embedder ¶ added in v0.1.0
type Embedder interface {
// Embedding generates an embedding vector for a single text
Embedding(context.Context, schema.Model, string, ...opt.Opt) ([]float64, error)
// BatchEmbedding generates embedding vectors for multiple texts
BatchEmbedding(context.Context, schema.Model, []string, ...opt.Opt) ([][]float64, error)
}
Embedder is an interface for generating text embeddings
type Generator ¶ added in v0.1.0
type Generator interface {
// WithoutSession sends a single message and returns the response (stateless)
WithoutSession(context.Context, schema.Model, *schema.Message, ...opt.Opt) (*schema.Message, *schema.Usage, error)
// WithSession sends a message within a session and returns the response (stateful)
WithSession(context.Context, schema.Model, *schema.Conversation, *schema.Message, ...opt.Opt) (*schema.Message, *schema.Usage, error)
}
Generator is an interface for generating response messages and conducting conversations
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
llm
command
|
|
|
etc
|
|
|
_old/deepseek
deepseek implements an API client for Deepseek's LLM https://api-docs.deepseek.com/
|
deepseek implements an API client for Deepseek's LLM https://api-docs.deepseek.com/ |
|
_old/ollama
ollama implements an API client for ollama https://github.com/ollama/ollama/blob/main/docs/api.md
|
ollama implements an API client for ollama https://github.com/ollama/ollama/blob/main/docs/api.md |
|
_old/openai
openai implements an API client for OpenAI https://platform.openai.com/docs/api-reference
|
openai implements an API client for OpenAI https://platform.openai.com/docs/api-reference |
|
pkg
|
|
|
homeassistant
homeassistant implements an API client for Home Assistant API https://developers.home-assistant.io/docs/api/rest/
|
homeassistant implements an API client for Home Assistant API https://developers.home-assistant.io/docs/api/rest/ |
|
mcp
Implements an MCP server based on the following specification: https://modelcontextprotocol.io/specification/2025-03-26/basic/lifecycle
|
Implements an MCP server based on the following specification: https://modelcontextprotocol.io/specification/2025-03-26/basic/lifecycle |
|
newsapi
newsapi implements an API client for NewsAPI (https://newsapi.org/docs)
|
newsapi implements an API client for NewsAPI (https://newsapi.org/docs) |
|
provider/anthropic
anthropic implements an API client for the Anthropic Messages API.
|
anthropic implements an API client for the Anthropic Messages API. |
|
provider/google
google implements an API client for the Google Gemini REST API.
|
google implements an API client for the Google Gemini REST API. |
|
provider/mistral
mistral implements an API client for the Mistral AI API.
|
mistral implements an API client for the Mistral AI API. |
|
ui
Package ui defines the interface for chat user interfaces.
|
Package ui defines the interface for chat user interfaces. |
|
ui/bubbletea
Package bubbletea implements ui.ChatUI for interactive terminals using the Charm bubbletea framework.
|
Package bubbletea implements ui.ChatUI for interactive terminals using the Charm bubbletea framework. |
|
ui/command
Package command implements shared slash-command handling for chat UIs.
|
Package command implements shared slash-command handling for chat UIs. |
|
ui/telegram
Package telegram implements ui.ChatUI for Telegram bots using telebot v4.
|
Package telegram implements ui.ChatUI for Telegram bots using telebot v4. |
|
weatherapi
weatherapi implements an API client for WeatherAPI https://www.weatherapi.com/docs/
|
weatherapi implements an API client for WeatherAPI https://www.weatherapi.com/docs/ |
Click to show internal directories.
Click to hide internal directories.