Class FileSystemCopyTool
Copies a file or directory to a new location.
public sealed class FileSystemCopyTool : IBuiltInTool, ITool, IToolMetadata
- Inheritance
-
FileSystemCopyTool
- Implements
- Inherited Members
Examples
Backing up a folder before a destructive operation:
using LMKit.Agents;
using LMKit.Agents.Tools.BuiltIn.IO;
var agent = Agent.CreateBuilder(model)
.WithTools(t => t.Register(new FileSystemCopyTool()))
.Build();
var result = await agent.RunAsync(@"Copy C:\app\config to C:\app\config.bak before applying changes.");
Constructors
- FileSystemCopyTool()
Initializes a new instance with default settings.
- FileSystemCopyTool(FileSystemToolOptions)
Initializes a new instance with custom options.
Properties
- Description
Gets a concise description of what the tool does.
- InputSchema
Gets the JSON Schema defining the expected input arguments.
- Name
Gets the stable, unique identifier for this tool.
Methods
- InvokeAsync(string, CancellationToken)
Executes the tool with the specified JSON arguments.