Documentation
¶
Overview ¶
Package imageproviders exposes seshat's image.Generation implementations for direct use by a host application, independent of the agent/tool loop.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GeminiClient ¶
type GeminiClient = internalproviders.GeminiClient
GeminiClient generates images using Google Imagen via the Gemini API.
func NewGemini ¶
func NewGemini(apiKey string, opts ...GeminiOption) *GeminiClient
NewGemini creates a Google Imagen image generation client. apiKey is a Google AI Studio API key (AIza...).
type GeminiOption ¶
type GeminiOption = internalproviders.GeminiOption
GeminiOption configures a GeminiClient.
func WithGeminiAspectRatio ¶
func WithGeminiAspectRatio(ar string) GeminiOption
WithGeminiAspectRatio sets the aspect ratio ("1:1", "3:4", "4:3", "9:16", "16:9").
func WithGeminiBaseURL ¶
func WithGeminiBaseURL(url string) GeminiOption
WithGeminiBaseURL overrides the default Google AI Studio endpoint.
func WithGeminiCount ¶
func WithGeminiCount(n int) GeminiOption
WithGeminiCount sets the number of images to generate (1-4).
func WithGeminiHTTPClient ¶
func WithGeminiHTTPClient(hc *http.Client) GeminiOption
WithGeminiHTTPClient injects a custom HTTP client.
func WithGeminiModel ¶
func WithGeminiModel(model string) GeminiOption
WithGeminiModel sets the Imagen model.
type OpenAIClient ¶
type OpenAIClient = internalproviders.OpenAIClient
OpenAIClient generates images using OpenAI DALL-E (dall-e-3, dall-e-2).
func NewOpenAI ¶
func NewOpenAI(apiKey string, opts ...OpenAIOption) *OpenAIClient
NewOpenAI creates an OpenAI DALL-E image generation client. Pass WithOpenAIBaseURL to point at a self-hosted, OpenAI-API-compatible image generation server instead of the real OpenAI cloud.
type OpenAIOption ¶
type OpenAIOption = internalproviders.OpenAIOption
OpenAIOption configures an OpenAIClient.
func WithOpenAIBaseURL ¶
func WithOpenAIBaseURL(url string) OpenAIOption
WithOpenAIBaseURL overrides the default endpoint (self-hosted server, or a proxy).
func WithOpenAIHTTPClient ¶
func WithOpenAIHTTPClient(hc *http.Client) OpenAIOption
WithOpenAIHTTPClient injects a custom HTTP client.
func WithOpenAIModel ¶
func WithOpenAIModel(model string) OpenAIOption
WithOpenAIModel sets the DALL-E model (e.g. "dall-e-3", "dall-e-2").
func WithOpenAIQuality ¶
func WithOpenAIQuality(q string) OpenAIOption
WithOpenAIQuality sets the quality ("standard" or "hd").
func WithOpenAISize ¶
func WithOpenAISize(size string) OpenAIOption
WithOpenAISize sets the image dimensions (e.g. "1024x1024", "1792x1024").