Cli-as-a-Service
Shift from "run-and-exit" to persistent sessions with continuous instruction flow and context preservation.
Transforming AI CLI Agents into Production-Ready Interactive Services
go get github.com/hrygo/hotplexpackage main
import (
"context"
"fmt"
"time"
"github.com/hrygo/hotplex"
)
func main() {
opts := hotplex.EngineOptions{
Timeout: 5 * time.Minute,
PermissionMode: "bypassPermissions",
AllowedTools: []string{"Bash", "Edit", "Read", "FileSearch"},
}
engine, _ := hotplex.NewEngine(opts)
defer engine.Close()
cfg := &hotplex.Config{
WorkDir: "/tmp/ai-sandbox",
SessionID: "user-123",
TaskInstructions: "You are a senior Go systems engineer.",
}
ctx := context.Background()
err := engine.Execute(ctx, cfg, "Refactor the main.go",
func(eventType string, data any) error {
if eventType == "answer" {
fmt.Printf("🤖 %v\n", data)
}
return nil
})
}HotPlex provides official SDKs for multiple languages:
| SDK | Status | Description |
|---|---|---|
| Go SDK | ✅ Stable | Native Go integration |
| Python SDK | ✅ Stable | WebSocket client for Python |
| TypeScript SDK | ✅ Stable | TypeScript/JavaScript client |
We are actively evolving HotPlex to become the definitive execution engine for the Local AI ecosystem.