Documentation
¶
Index ¶
- Variables
- type CatalogID
- type CatalogSource
- type CloseSkillSessionRequest
- type CloseSkillSessionResponse
- type CreateSkillSessionRequest
- type CreateSkillSessionRequestBody
- type CreateSkillSessionResponse
- type CreateSkillSessionResponseBody
- type GetSkillsPromptRequest
- type GetSkillsPromptRequestBody
- type GetSkillsPromptResponse
- type GetSkillsPromptResponseBody
- type InvokeSkillToolRequest
- type InvokeSkillToolRequestBody
- type InvokeSkillToolResponse
- type InvokeSkillToolResponseBody
- type ListSkillsRequest
- type ListSkillsRequestBody
- type ListSkillsResponse
- type ListSkillsResponseBody
- type Option
- type RemoveCatalogRequest
- type RemoveCatalogResponse
- type RenderSkillRequest
- type RenderSkillRequestBody
- type RenderSkillResponse
- type Service
- func (s *Service) Close(ctx context.Context) error
- func (s *Service) CloseSession(ctx context.Context, sessionID agentskillsRuntimeSpec.SessionID) error
- func (s *Service) CloseSkillSession(ctx context.Context, req *CloseSkillSessionRequest) (*CloseSkillSessionResponse, error)
- func (s *Service) CreateSkillSession(ctx context.Context, req *CreateSkillSessionRequest) (*CreateSkillSessionResponse, error)
- func (s *Service) GetSkillsPrompt(ctx context.Context, req *GetSkillsPromptRequest) (*GetSkillsPromptResponse, error)
- func (s *Service) InvokeSkillTool(ctx context.Context, req *InvokeSkillToolRequest) (*InvokeSkillToolResponse, error)
- func (s *Service) IsRegistered(value SkillRegistration) bool
- func (s *Service) ListAgentSkills(ctx context.Context, filter *agentskillsRuntime.SkillListFilter) ([]agentskillsRuntimeSpec.SkillRecord, error)
- func (s *Service) ListSkills(ctx context.Context, req *ListSkillsRequest) (*ListSkillsResponse, error)
- func (s *Service) NewSession(ctx context.Context, opts ...agentskillsRuntime.SessionOption) (agentskillsRuntimeSpec.SessionID, []provider.SkillDef, error)
- func (s *Service) NewSessionRegistry(ctx context.Context, sessionID agentskillsRuntimeSpec.SessionID, ...) (*llmtools.Registry, error)
- func (s *Service) RemoveCatalog(ctx context.Context, id CatalogID) error
- func (s *Service) RenderAgentSkill(ctx context.Context, params agentskillsRuntime.RenderSkillParams) (agentskillsRuntime.RenderSkillOut, error)
- func (s *Service) RenderSkill(ctx context.Context, req *RenderSkillRequest) (*RenderSkillResponse, error)
- func (s *Service) SkillsPrompt(ctx context.Context, filter *agentskillsRuntime.SkillFilter) (string, error)
- func (s *Service) SupportsRunScript() bool
- func (s *Service) SyncCatalog(ctx context.Context, id CatalogID) error
- type SkillListFilter
- type SkillPromptFilter
- type SkillRegistration
- type SyncCatalogRequest
- type SyncCatalogResponse
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidRequest = errors.New("invalid Skill runtime request") ErrClosed = errors.New("skill runtime is closed") )
Functions ¶
This section is empty.
Types ¶
type CatalogID ¶ added in v0.2.20
type CatalogID string
CatalogID identifies one independently replaceable runtime catalog. It has no Artifact Store semantics.
type CatalogSource ¶ added in v0.2.20
type CatalogSource interface {
Skills(
ctx context.Context,
catalogID CatalogID,
) ([]SkillRegistration, error)
}
CatalogSource is owned by the runtime package and implemented by a data layer. CatalogID is opaque to runtime. Runtime only receives the Skill registrations needed to reconcile Agent Skills state.
type CloseSkillSessionRequest ¶
type CloseSkillSessionRequest struct {
SessionID agentskillsRuntimeSpec.SessionID `path:"sessionID" required:"true"`
}
type CloseSkillSessionResponse ¶
type CloseSkillSessionResponse struct{}
type CreateSkillSessionRequest ¶
type CreateSkillSessionRequest struct {
Body *CreateSkillSessionRequestBody
}
type CreateSkillSessionRequestBody ¶
type CreateSkillSessionRequestBody struct {
CloseSessionID agentskillsRuntimeSpec.SessionID `json:"closeSessionID,omitempty"`
MaxActivePerSession int `json:"maxActivePerSession,omitempty"`
// Nil means unrestricted and causes no allowed-skills option to be
// installed. A non-nil empty slice means no skill is allowed.
AllowedSkills []provider.SkillDef `json:"allowedSkills,omitempty"`
ActiveSkills []provider.SkillDef `json:"activeSkills,omitempty"`
}
type CreateSkillSessionResponse ¶
type CreateSkillSessionResponse struct {
Body *CreateSkillSessionResponseBody
}
type CreateSkillSessionResponseBody ¶
type CreateSkillSessionResponseBody struct {
SessionID agentskillsRuntimeSpec.SessionID `json:"sessionID"`
ActiveSkills []provider.SkillDef `json:"activeSkills"`
}
type GetSkillsPromptRequest ¶
type GetSkillsPromptRequest struct {
Body *GetSkillsPromptRequestBody
}
type GetSkillsPromptRequestBody ¶
type GetSkillsPromptRequestBody struct {
Filter *SkillPromptFilter `json:"filter,omitempty"`
}
type GetSkillsPromptResponse ¶
type GetSkillsPromptResponse struct {
Body *GetSkillsPromptResponseBody
}
type GetSkillsPromptResponseBody ¶
type GetSkillsPromptResponseBody struct {
Prompt string `json:"prompt"`
}
type InvokeSkillToolRequest ¶
type InvokeSkillToolRequest struct {
Body *InvokeSkillToolRequestBody
}
type InvokeSkillToolRequestBody ¶
type InvokeSkillToolRequestBody struct {
SessionID agentskillsRuntimeSpec.SessionID `json:"sessionID" required:"true"`
ToolName string `json:"toolName" required:"true"`
Args string `json:"args,omitempty"`
}
type InvokeSkillToolResponse ¶
type InvokeSkillToolResponse struct {
Body *InvokeSkillToolResponseBody
}
type InvokeSkillToolResponseBody ¶
type InvokeSkillToolResponseBody struct {
Outputs []llmtoolsSpec.ToolOutputUnion `json:"outputs,omitempty"`
Meta map[string]any `json:"meta,omitempty"`
IsBuiltIn bool `json:"isBuiltIn"`
IsError bool `json:"isError,omitempty"`
ErrorMessage string `json:"errorMessage,omitempty"`
}
type ListSkillsRequest ¶ added in v0.2.20
type ListSkillsRequest struct {
Body *ListSkillsRequestBody
}
type ListSkillsRequestBody ¶ added in v0.2.20
type ListSkillsRequestBody struct {
Filter *SkillListFilter `json:"filter,omitempty"`
}
type ListSkillsResponse ¶ added in v0.2.20
type ListSkillsResponse struct {
Body *ListSkillsResponseBody
}
type ListSkillsResponseBody ¶ added in v0.2.20
type ListSkillsResponseBody struct {
Skills []agentskillsRuntimeSpec.SkillRecord `json:"skills"`
}
type Option ¶ added in v0.2.20
type Option func(*options) error
func WithAgentRuntime ¶ added in v0.2.20
func WithAgentRuntime(value *agentskillsRuntime.Runtime) Option
func WithCatalogSource ¶ added in v0.2.20
func WithCatalogSource(value CatalogSource) Option
func WithRunScripts ¶
type RemoveCatalogRequest ¶ added in v0.2.20
type RemoveCatalogRequest struct {
CatalogID CatalogID `json:"catalogID"`
}
type RemoveCatalogResponse ¶ added in v0.2.20
type RemoveCatalogResponse struct{}
type RenderSkillRequest ¶
type RenderSkillRequest struct {
Body *RenderSkillRequestBody
}
type RenderSkillRequestBody ¶
type RenderSkillResponse ¶
type RenderSkillResponse struct {
Body *agentskillsRuntime.RenderSkillOut
}
type Service ¶ added in v0.2.20
type Service struct {
// contains filtered or unexported fields
}
Service is an application-facing wrapper over agentskills-go/runtime. It deliberately contains no Artifact Store identity or persistence type.
func (*Service) CloseSession ¶ added in v0.2.20
func (*Service) CloseSkillSession ¶ added in v0.2.20
func (s *Service) CloseSkillSession( ctx context.Context, req *CloseSkillSessionRequest, ) (*CloseSkillSessionResponse, error)
func (*Service) CreateSkillSession ¶ added in v0.2.20
func (s *Service) CreateSkillSession( ctx context.Context, req *CreateSkillSessionRequest, ) (*CreateSkillSessionResponse, error)
func (*Service) GetSkillsPrompt ¶ added in v0.2.20
func (s *Service) GetSkillsPrompt( ctx context.Context, req *GetSkillsPromptRequest, ) (*GetSkillsPromptResponse, error)
func (*Service) InvokeSkillTool ¶ added in v0.2.20
func (s *Service) InvokeSkillTool( ctx context.Context, req *InvokeSkillToolRequest, ) (*InvokeSkillToolResponse, error)
func (*Service) IsRegistered ¶ added in v0.2.20
func (s *Service) IsRegistered(value SkillRegistration) bool
func (*Service) ListAgentSkills ¶ added in v0.2.20
func (s *Service) ListAgentSkills( ctx context.Context, filter *agentskillsRuntime.SkillListFilter, ) ([]agentskillsRuntimeSpec.SkillRecord, error)
func (*Service) ListSkills ¶ added in v0.2.20
func (s *Service) ListSkills( ctx context.Context, req *ListSkillsRequest, ) (*ListSkillsResponse, error)
func (*Service) NewSession ¶ added in v0.2.20
func (s *Service) NewSession( ctx context.Context, opts ...agentskillsRuntime.SessionOption, ) (agentskillsRuntimeSpec.SessionID, []provider.SkillDef, error)
func (*Service) NewSessionRegistry ¶ added in v0.2.20
func (s *Service) NewSessionRegistry( ctx context.Context, sessionID agentskillsRuntimeSpec.SessionID, opts ...llmtools.RegistryOption, ) (*llmtools.Registry, error)
func (*Service) RemoveCatalog ¶ added in v0.2.20
func (*Service) RenderAgentSkill ¶ added in v0.2.20
func (s *Service) RenderAgentSkill( ctx context.Context, params agentskillsRuntime.RenderSkillParams, ) (agentskillsRuntime.RenderSkillOut, error)
func (*Service) RenderSkill ¶ added in v0.2.20
func (s *Service) RenderSkill( ctx context.Context, req *RenderSkillRequest, ) (*RenderSkillResponse, error)
func (*Service) SkillsPrompt ¶ added in v0.2.20
func (s *Service) SkillsPrompt( ctx context.Context, filter *agentskillsRuntime.SkillFilter, ) (string, error)
func (*Service) SupportsRunScript ¶ added in v0.2.20
type SkillListFilter ¶ added in v0.2.20
type SkillListFilter struct {
Types []string `json:"types,omitempty"`
NamePrefix string `json:"namePrefix,omitempty"`
LocationPrefix string `json:"locationPrefix,omitempty"`
AllowSkills []provider.SkillDef `json:"allowSkills,omitempty"`
Inserts []document.SkillInsert `json:"inserts,omitempty"`
SessionID agentskillsRuntimeSpec.SessionID `json:"sessionID,omitempty"`
Activity agentskillsRuntimeSpec.SkillActivity `json:"activity,omitempty"`
}
type SkillPromptFilter ¶ added in v0.2.20
type SkillPromptFilter struct {
Types []string `json:"types,omitempty"`
NamePrefix string `json:"namePrefix,omitempty"`
LocationPrefix string `json:"locationPrefix,omitempty"`
AllowSkills []provider.SkillDef `json:"allowSkills,omitempty"`
SessionID agentskillsRuntimeSpec.SessionID `json:"sessionID,omitempty"`
Activity agentskillsRuntimeSpec.SkillActivity `json:"activity,omitempty"`
}
type SkillRegistration ¶ added in v0.2.20
type SkillRegistration struct {
Definition provider.SkillDef `json:"definition"`
Revision string `json:"revision,omitempty"`
}
SkillRegistration is the runtime-owned registration input for one Skill.
type SyncCatalogRequest ¶ added in v0.2.20
type SyncCatalogRequest struct {
CatalogID CatalogID `json:"catalogID"`
}
type SyncCatalogResponse ¶ added in v0.2.20
type SyncCatalogResponse struct{}
Click to show internal directories.
Click to hide internal directories.