Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Command ¶
type Command interface {
Name() string
Description() string
Run(ctx context.Context, args string) error
}
Command is a slash-command handler. Run is called with the trimmed arg string (everything after `/<name>`).
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry maps names to commands. Project-scoped commands shadow user-scoped commands which shadow built-ins; for MVP we only have built-ins so we register everything via Register.
type Skill ¶
type Skill struct {
// contains filtered or unexported fields
}
Skill is a user-defined slash command loaded from disk. Frontmatter fields are surfaced via Description(); the body is a `text/template` rendered against `{ Args }` and submitted as the next user message.
The submitter receives both the rendered text AND the skill's `allowed-tools` list so the host can apply a per-turn registry restriction in addition to forwarding the message. Empty list = no restriction.
func LoadSkills ¶
LoadSkills scans the user dir (`~/.enso/skills`) and the project dir (`./.enso/skills`) for `*.md` files and returns parsed Skill values. Project skills shadow user skills on name collision.
func (*Skill) AllowedTools ¶
func (*Skill) Description ¶
func (*Skill) SetSubmitter ¶
SetSubmitter binds the skill to a callback that injects the rendered text as the next user message and, if non-empty, applies the skill's `allowed-tools` restriction for that turn. Returns the same skill for chaining.