mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-04 23:16:57 +08:00
feat: add MCP tools registration to LLM service
- Add RegisterTools method to ILLMService interface - Create shared MCP to eino tool converter - Auto-register built-in uixt tools in XTDriver initialization - Refactor MCPHost to use shared converter - Add comprehensive test coverage for tool conversion This enables doubao-1.5-thinking-vision-pro model to access MCP tools through function calling mechanism.
This commit is contained in:
@@ -77,6 +77,15 @@ func (p *Planner) RegisterTools(tools []*schema.ToolInfo) error {
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "failed to register tools")
|
||||
}
|
||||
|
||||
var toolNames []string
|
||||
for _, tool := range tools {
|
||||
toolNames = append(toolNames, tool.Name)
|
||||
}
|
||||
log.Debug().Strs("tools", toolNames).
|
||||
Str("model", string(p.modelConfig.ModelType)).
|
||||
Msg("registered tools to model")
|
||||
|
||||
p.model = toolCallingModel
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user