Table of Contents

Method LoadFromDirectories

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

LoadFromDirectories(IEnumerable<string>, bool, Action<string, Exception>)

Loads skills from multiple directories.

public int LoadFromDirectories(IEnumerable<string> directoryPaths, bool overwrite = false, Action<string, Exception> errorHandler = null)

Parameters

directoryPaths IEnumerable<string>

The paths containing skill subdirectories.

overwrite bool

Whether to overwrite existing skills.

errorHandler Action<string, Exception>

Optional callback for handling parse errors.

Returns

int

The total number of skills successfully loaded.

Examples

Loading skills from multiple directories:

var registry = new SkillRegistry();
var directories = new[] { "./skills", "./plugins", "./custom-skills" };
int loaded = registry.LoadFromDirectories(directories);
Console.WriteLine($"Loaded {loaded} skills from all directories");