pi-rozalia

OpenAI-compatible provider extension for the Pi coding agent — connects to Rozalia AI

Packages

Package details

extension

Install pi-rozalia from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:pi-rozalia
Package
pi-rozalia
Version
0.2.1
Published
Sep 16, 2026
Downloads
733/mo · 733/wk
Author
bozobozo
License
MIT
Types
extension
Size
46.9 KB
Dependencies
0 dependencies · 2 peers
Pi manifest JSON
{
  "extensions": [
    "./extensions"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-rozalia

An extension for the Pi coding agent that connects to a Rozalia AI server via the OpenAI-compatible Chat Completions API.

Prerequisites

  1. Pi Coding Agent installed.
  2. A Rozalia AI server running and accessible.

Installation

pi install npm:pi-rozalia

Configuration

Interactive setup (recommended)

Use Pi's built-in /login command to configure your server and API key:

pi
/login
→ pick "Rozalia"
→ enter server URL (default: https://ai.zygoon.pl/v1)
→ enter API key (optional)

The server URL and API key are stored in ~/.pi/agent/auth.json and reused on subsequent logins.

Environment variables (alternative)

Variable Description Default
ROZALIA_BASE_URL Rozalia AI server base URL https://ai.zygoon.pl/v1
ROZALIA_API_KEY API key for authentication (none)
ROZALIA_TIMEOUT Model discovery timeout in ms 5000
export ROZALIA_API_KEY="your-api-key"

Custom server

Point to any OpenAI-compatible server:

ROZALIA_BASE_URL="https://my-server.example.com/v1" \
ROZALIA_API_KEY="my-key" \
pi

Usage

  1. Launch Pi — the provider loads automatically on startup.

    pi
    
  2. Select a Model — use /model or Ctrl+P to pick from the discovered models.

How It Works

On startup, the extension fetches the model list from the server's /v1/models endpoint and registers each model with Pi. If discovery fails, a single fallback model is registered so you can still try to connect.

The /login flow stores your server URL and API key in Pi's credential store (~/.pi/agent/auth.json). On subsequent logins the stored URL is pre-filled, so you only need to re-enter it if your server changes.

Known Limitations

  • Models stay listed after /logout. Pi's extension API has no logout callback/event for OAuth-backed providers, so this extension has no way to detect that /logout ran and revert the provider to its empty stub. The model list only clears on the next Pi restart. This is a Pi platform limitation, not something this extension can currently work around.

TODO

  • Multi-server support — register each configured server as its own provider with a derived name (e.g. rozalia-localhost-1234), so models from different servers are unambiguous in the picker
  • Model discovery health check — skip servers that fail to respond rather than showing fallback models
  • Support for ROZALIA_MODELS env var — allow overriding the discovered model list with a static list

License

MIT — © 2026 Maciej Borzecki