On this page

plugins add

Install a plugin package from the CLI and verify it registered

One command installs a plugin package and tells you exactly which plugins registered — or exits non-zero if nothing did.

Diagram

yes

no

🖥️ praisonai plugins add pkg

📦 pip / uv install

🔍 discover_entry_points

🆕 New plugins?

✅ Registered table

🛑 exit 1

Previously a package could pip install cleanly yet register nothing — a silent failure. plugins add turns that into a surfaced non-zero exit.

Quick Start#

  1. Install a plugin
    bash
    praisonai plugins add praisonai-my-plugin
  2. Upgrade an installed plugin
    bash
    praisonai plugins add praisonai-my-plugin --upgrade
  3. Verify without installing
    bash
    praisonai plugins add praisonai-my-plugin --dry-run

    --dry-run skips installation and reports whether anything new would register from what’s already installed.


How It Works#

The command snapshots registered plugins, installs, refreshes discovery, then reports the diff.

Diagram
PluginManagerpip / uvplugins addUserPluginManagerpip / uvplugins addUseralt[not –dry-run]praisonai plugins add pkgsnapshot registered names (before)install pkgexit codediscover_entry_points()registered names (after)table of new plugins OR exit 1
StepWhat happens
SnapshotRecords current entry-point plugin names via get_plugin_manager().list_plugins()
InstallSkipped on --dry-run; otherwise runs the resolved installer command
Refreshget_plugin_manager().discover_entry_points() scans the praisonai.plugins group
Diffsorted(after − before) — new names become table rows

Options#

Argument / flagTypeDefaultDescription
packagepositional str(required)pip requirement spec — anything pip install / uv pip install accepts (name, name==1.2.3, VCS URL, path, extras)
--dry-runflagFalseSkip installation; run discovery only. Exits non-zero if nothing new is discovered
--upgrade, -UflagFalseAppend --upgrade so an already-installed package is upgraded
--globalflagFalseInstall into the ambient/system environment instead of the CLI interpreter

How the Installer Is Chosen#

The command pins installation to the interpreter running the CLI so the package lands where discovery will look — not in a nearby .venv that uv might auto-discover.

Diagram

yes

no

yes

no

yes

no

uv on PATH?

–global?

–global?

uv pip install –system

uv pip install –python <sys.executable>

pip install

<python> -m pip install

--upgrade appends --upgrade to whichever command runs, then the package spec.


Exit Codes#

SituationExit code
At least one new plugin registered0
Installer command returned non-zero1
Install succeeded but nothing new discovered1
--dry-run and nothing new discovered1
praisonaiagents not importable at all1

Output Shape#

A successful run prints a Rich table titled Registered N plugin(s) from <package>:

text
        Registered 1 plugin from praisonai-my-plugin
┏━━━━━━━━━━━━━━━┳━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Plugin        ┃ Type      ┃ Hooks                  ┃
┡━━━━━━━━━━━━━━━╇━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩
│ my_plugin     │ plugin    │ before_tool,after_tool │
└───────────────┴───────────┴────────────────────────┘

On --dry-run the title verb is Discovered instead of Registered.


Common Patterns#

Default (pin to CLI interpreter)

bash
praisonai plugins add praisonai-my-plugin

When uv is present, the package is pinned to the CLI interpreter so discovery finds it — not a nearby .venv.

Global install

bash
praisonai plugins add praisonai-my-plugin --global

Installs into the ambient/system environment (uv pip install --system, or plain pip install).

CI verification

bash
praisonai plugins add praisonai-my-plugin --dry-run

Fails the job (exit 1) if the package no longer registers after another change — a cheap regression guard.


Best Practices#

Use –dry-run in CI to catch silent breakage

A package can install cleanly yet register nothing. --dry-run exits non-zero when discovery finds nothing new, turning a silent failure into a failed check.

Prefer the default over –global

The default pins to the CLI interpreter so the plugin is discoverable by the same process. Reach for --global only when you deliberately want the system environment.

Pin versions for reproducible installs

Pass a full spec like praisonai-my-plugin==1.2.3 so the installed version is deterministic across machines.

Inspect after installing

Run praisonai plugins list to see everything registered, not just what this command added.