Class PerfMonitorTool
Monitor system performance: memory usage, GC stats, CPU, thread count.
public sealed class PerfMonitorTool : IBuiltInTool, ITool, IToolMetadata
- Inheritance
-
PerfMonitorTool
- Implements
- Inherited Members
Examples
Producing a process-health snapshot from inside a diagnostic agent:
using LMKit.Agents;
using LMKit.Agents.Tools.BuiltIn.Utility;
var agent = Agent.CreateBuilder(model)
.WithTools(t => t.Register(new PerfMonitorTool()))
.Build();
var result = await agent.RunAsync("Snapshot current memory and thread counts and report any GC pressure.");
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.