Install
LoopKing ships as a PyPI package loopking with one console script: loop.
Three install paths, in order of recommendation.
Recommended: uv tool install
Best for "install once, run anywhere, isolated from your project." uv
manages the venv for you.
uv tool install loopking
which loop # → ~/.local/bin/loop
loop --help
# Upgrade later
uv tool upgrade loopking
# Remove
uv tool uninstall loopking
Alternative: pipx install
Equivalent for pipx users:
pipx install loopking
loop --help
Try-without-install: uvx
Run any loop subcommand without installing — fresh, isolated venv each time:
uvx --from loopking loop --help
uvx --from loopking loop launch cookbook/data-contract/data-contract.loop.md
One-shot local dev
From a clone of the repo (contributors / editors):
git clone https://github.com/kingkillery/loopking
cd loopking
uv sync
uv run loop --help
Verify
loop --help # → 7 subcommands (run, launch, compile, new, registry, tools, runs)
loop run --help # → dry-run is the default
loop prints the help inside a Rich panel and exits 0.
Requirements
- Python ≥ 3.12
uv,pipx, oruvxinstalled (any of them — pick your favourite)
From source / contribution
git clone https://github.com/kingkillery/loopking
cd loopking
uv sync
uv run pytest -q
PyPI publish (maintainers only)
A twine upload is a one-shot that needs your own PyPI token. From the
maintainer machine:
uv run --no-project --with build python -m build --sdist --wheel --outdir dist
# inspect dist/, then:
uv run --no-project --with twine python -m twine upload dist/loopking-*.tar.gz dist/loopking-*.whl
The loopking package name is available on PyPI and the loop console script is
not yet claimed for this namespace.
What's NOT installed by loopking
The loop CLI is a local-first engine. Cloud-hosted features (shared loop
registry, tool/MCP profile sync, run metadata upload) need:
- A
loopking.yamlfile in your project root (template:loop new). - A
LOOPKING_TOKENenvironment variable for the bearer token, or a tenant token (lk_<id>_<secret>) issued by the hosted admin endpoint.
See RUNBOOK.md for the hosted side.