diff --git a/pkg/tools/execute/server.go b/pkg/tools/execute/server.go index 596db24..5b745aa 100644 --- a/pkg/tools/execute/server.go +++ b/pkg/tools/execute/server.go @@ -122,6 +122,20 @@ func (e *Server) AllowTools() []string { return out } + +// WithToolRegistry attaches a tool registry and session ID to the Server. +func WithToolRegistry(r *Registry, sessionID string) Option { + return func(s *Server) { + s.toolRegistry = r + s.sessionID = sessionID + } +} + +// WithSkillsRegistry attaches a skills registry to the Server. +func WithSkillsRegistry(r *skills.Registry) Option { + return func(s *Server) { s.skillsRegistry = r } +} + // Decl returns a factory for an execute Server with the given working directory. func Decl(cwd string, opts ...Option) func() tools.Server { return func() tools.Server {