Overview
Loop supports extensions written in Rhai, a lightweight embedded scripting language for Rust. Extensions let you register custom commands, hook into agent events, and add custom logic to your workflow.Setup
Place Rhai extension scripts in~/.loop/agent/extensions/:
Available APIs
Register Commands
Create custom slash commands:Notifications
Send notifications to the TUI:Extension Loading
Extensions are loaded at startup and when you run/reload. They execute in a sandboxed Rhai engine with access to Loop’s extension API.
Limitations
The Rhai extension system currently provides:register_command— Register custom slash commandsnotify— Send notifications to the TUI
For declarative lifecycle hooks without scripting, see Hooks in the Features section.