Table of Contents

Constructor SkillWatcher

Namespace
LMKit.Agents.Skills
Assembly
LM-Kit.NET.dll

SkillWatcher(SkillRegistry, IEnumerable<string>, TimeSpan?)

Initializes a new instance of the SkillWatcher class.

public SkillWatcher(SkillRegistry registry, IEnumerable<string> directories, TimeSpan? debounceDelay = null)

Parameters

registry SkillRegistry

The skill registry to update when changes are detected.

directories IEnumerable<string>

The directories to watch for skill changes.

debounceDelay TimeSpan?

The delay before processing file changes. Defaults to DefaultDebounceDelay.

Examples

Creating a watcher for multiple directories:

var registry = new SkillRegistry();
var directories = new[] { "./skills", "./plugins" };
using var watcher = new SkillWatcher(registry, directories);
watcher.Start();

Exceptions

ArgumentNullException

Thrown when registry or directories is null.

SkillWatcher(SkillRegistry, string, TimeSpan?)

Initializes a new instance of the SkillWatcher class for a single directory.

public SkillWatcher(SkillRegistry registry, string directory, TimeSpan? debounceDelay = null)

Parameters

registry SkillRegistry

The skill registry to update when changes are detected.

directory string

The directory to watch for skill changes.

debounceDelay TimeSpan?

The delay before processing file changes. Defaults to DefaultDebounceDelay.