MCPcopy Create free account
hub / github.com/GongShichen/LuminaCode / newTaskTool

Function newTaskTool

agent/agent_tool.go:380–388  ·  view source on GitHub ↗
(name, description string, proto any, exec func(context.Context, coretools.ExecutionContext, any) (string, error))

Source from the content-addressed store, hash-verified

378}
379
380func newTaskTool(name, description string, proto any, exec func(context.Context, coretools.ExecutionContext, any) (string, error)) coretools.Tool {
381 return &taskTool{
382 BaseTool: coretools.BaseTool{Spec: coretools.ToolSpec{
383 Name: name, Description: description, InputPrototype: proto,
384 ReadOnly: coretools.BoolPtr(false), ConcurrencySafe: coretools.BoolPtr(true), Destructive: coretools.BoolPtr(false),
385 }},
386 exec: exec,
387 }
388}
389
390func runtimeAndScope(execCtx coretools.ExecutionContext) (*AgentTaskRuntime, string, string) {
391 rt, _ := execCtx["task_runtime"].(*AgentTaskRuntime)

Callers 5

NewTaskListToolFunction · 0.85
NewTaskGetToolFunction · 0.85
NewTaskWaitToolFunction · 0.85
NewTaskStopToolFunction · 0.85
NewSendMessageToolFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected