tools

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 9, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MCPTool

type MCPTool struct {
	// contains filtered or unexported fields
}

MCPTool wraps an MCP tool to implement eino's InvokableTool interface

func (*MCPTool) Info

func (t *MCPTool) Info(ctx context.Context) (*schema.ToolInfo, error)

Info returns the tool information for eino

func (*MCPTool) InvokableRun

func (t *MCPTool) InvokableRun(ctx context.Context, argumentsInJSON string, opts ...tool.Option) (string, error)

InvokableRun implements the InvokableTool interface

type MCPToolManager

type MCPToolManager struct {
	// contains filtered or unexported fields
}

MCPToolManager manages MCP tools and clients

func NewMCPToolManager

func NewMCPToolManager() *MCPToolManager

NewMCPToolManager creates a new MCP tool manager

func (*MCPToolManager) Close

func (m *MCPToolManager) Close() error

Close closes all MCP clients

func (*MCPToolManager) GetTools

func (m *MCPToolManager) GetTools() []tool.BaseTool

GetTools returns all loaded tools

func (*MCPToolManager) LoadTools

func (m *MCPToolManager) LoadTools(ctx context.Context, config *config.Config) error

LoadTools loads tools from MCP servers based on configuration

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL