Documentation
¶
Index ¶
- type AgentOptions
- type ClientOptions
- type InMemoryConfigStore
- type LLMOptions
- type RedisConfig
- type RestateConfig
- type SDK
- func (c *SDK) CustomPrompt(loader prompts.PromptLoader) *prompts.SimplePrompt
- func (c *SDK) NewAgent(options *AgentOptions) *agents.Agent
- func (c *SDK) NewConversationManager(opts ...history.ConversationManagerOptions) *history.CommonConversationManager
- func (c *SDK) NewLLM(opts LLMOptions) llm.Provider
- func (c *SDK) NewRestateAgent(options *AgentOptions) *agents.Agent
- func (c *SDK) NewTemporalAgent(options *AgentOptions) *agents.Agent
- func (c *SDK) Prompt(prompt string) *prompts.SimplePrompt
- func (c *SDK) RemotePrompt(name, label string) *prompts.SimplePrompt
- func (c *SDK) ServeHTTP(w http.ResponseWriter, r *http.Request)
- func (c *SDK) StartRestateService(host, port string)
- func (c *SDK) StartTemporalService()
- type ServerConfig
- type TemporalConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AgentOptions ¶
type AgentOptions struct {
Name string
LLM llm.Provider
Tools []core.Tool
Output map[string]any
History *history.CommonConversationManager
Parameters responses.Parameters
Instruction core.SystemPromptProvider
McpServers []agents.MCPToolset
}
type ClientOptions ¶
type ClientOptions struct {
ServerConfig ServerConfig
// Set this if you are using the SDK without the LLM Gateway server.
// If `LLMConfigs` is set, then `ApiKey` will be ignored.
LLMConfigs gateway.ConfigStore
RestateConfig RestateConfig
TemporalConfig TemporalConfig
RedisConfig RedisConfig
}
type InMemoryConfigStore ¶
type InMemoryConfigStore struct {
// contains filtered or unexported fields
}
InMemoryConfigStore implements gateway.ConfigStore for SDK use. It holds API keys and provider configs in memory.
func NewInMemoryConfigStore ¶
func NewInMemoryConfigStore(configs []*gateway.ProviderConfig) *InMemoryConfigStore
NewInMemoryConfigStore creates a config store with full provider options.
func (*InMemoryConfigStore) GetProviderConfig ¶
func (s *InMemoryConfigStore) GetProviderConfig(providerName llm.ProviderName) (*gateway.ProviderConfig, error)
func (*InMemoryConfigStore) GetVirtualKey ¶
func (s *InMemoryConfigStore) GetVirtualKey(secretKey string) (*gateway.VirtualKeyConfig, error)
type LLMOptions ¶
type LLMOptions struct {
Provider llm.ProviderName
Model string
}
type RedisConfig ¶ added in v0.1.11
type RedisConfig struct {
Endpoint string
}
type RestateConfig ¶
type RestateConfig struct {
Endpoint string
}
type SDK ¶
type SDK struct {
// contains filtered or unexported fields
}
func New ¶
func New(opts *ClientOptions) (*SDK, error)
func (*SDK) CustomPrompt ¶
func (c *SDK) CustomPrompt(loader prompts.PromptLoader) *prompts.SimplePrompt
func (*SDK) NewConversationManager ¶
func (c *SDK) NewConversationManager(opts ...history.ConversationManagerOptions) *history.CommonConversationManager
func (*SDK) NewLLM ¶
func (c *SDK) NewLLM(opts LLMOptions) llm.Provider
NewLLM creates a new LLMClient that provides access to multiple LLM providers.
func (*SDK) NewRestateAgent ¶
func (c *SDK) NewRestateAgent(options *AgentOptions) *agents.Agent
func (*SDK) NewTemporalAgent ¶ added in v0.1.11
func (c *SDK) NewTemporalAgent(options *AgentOptions) *agents.Agent
func (*SDK) RemotePrompt ¶
func (c *SDK) RemotePrompt(name, label string) *prompts.SimplePrompt
func (*SDK) StartRestateService ¶
func (*SDK) StartTemporalService ¶ added in v0.1.11
func (c *SDK) StartTemporalService()
type ServerConfig ¶
type TemporalConfig ¶ added in v0.1.11
type TemporalConfig struct {
Endpoint string
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.