Documentation
¶
Index ¶
- type HuggingFaceModel
- type Option
- type Tool
- func (t *Tool) Description() string
- func (t *Tool) DisplayName() string
- func (t *Tool) Execute(ctx context.Context, args string) (string, error)
- func (t *Tool) Internal() bool
- func (t *Tool) Name() string
- func (t *Tool) Parameters() map[string]interfaces.ParameterSpec
- func (t *Tool) Run(ctx context.Context, input string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HuggingFaceModel ¶
type HuggingFaceModel struct {
ID string `json:"_id"`
ModelID string `json:"modelId"`
Name string `json:"id"`
Description string `json:"description,omitempty"`
URL string `json:"url,omitempty"`
Downloads int `json:"downloads"`
Likes int `json:"likes"`
Private bool `json:"private"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"lastModified,omitempty"`
Tags []string `json:"tags"`
Task string `json:"pipeline_tag"`
LibraryName string `json:"library_name"`
}
type Option ¶
type Option func(*Tool)
Option represents an option for configuring the tool
func WithBaseURL ¶
WithBaseURL sets the base URL for the Hugging Face API
func WithHTTPClient ¶
WithHTTPClient sets the HTTP client for the tool
type Tool ¶
type Tool struct {
// contains filtered or unexported fields
}
Tool implements a Hugging Face model search tool
func (*Tool) Description ¶
Description returns a description of what the tool does
func (*Tool) DisplayName ¶ added in v0.0.53
DisplayName implements interfaces.ToolWithDisplayName.DisplayName
func (*Tool) Parameters ¶
func (t *Tool) Parameters() map[string]interfaces.ParameterSpec
Parameters returns the parameters that the tool accepts
Click to show internal directories.
Click to hide internal directories.