Get started
Installation
Install the drkm command, start a local isotope or sign in to one you already have, and get the Python SDK where your code runs.
Install the CLI
One command installs drkm on Apple silicon macOS and on x86-64 or ARM64 Linux. Run it as your own user, not as root, with curl on the PATH. It opens your browser to sign in with the account Darkmatter granted installer access to, then carries on by itself. Over SSH it prints a link to open on any device; after you sign in, the page shows a code to paste into the terminal. The installer then downloads the release, verifies its checksum and saves PATH for new terminals. A first install offers to run drkm start right away in the same terminal. What the setup tools print goes to the install log under ~/.local/share/drkm/logs/, and a failure shows the end of that log.
- The release carries its own Python runtime, locked dependencies, terminal and console, so nothing else needs to be on your PATH. Nothing is compiled or fetched from package indexes.
- On Linux, the tools a local isotope needs are installed if missing: Docker Engine and Buildx, k3d, Helm, kubectl and Nebula. Preparing the machine can prompt for your password.
- On macOS the installer prepares nothing else: a Mac runs its isotope without a VM by default. The first
drkm startasks for administrator approval once to install the mesh helper. Onlydrkm start --vminstalls thedrkm-kvmLinux VM and its tools. - Installer access is separate from console accounts and mesh membership. It authorizes downloads and nothing else; contact Darkmatter if sign-in is refused.
curl -fsSL https://drkm.com/install | sh
~/.local/bin/drkm --help
~/.local/bin/drkm --version
Where things live
~/.local/share/drkm: The installation: each release underreleases/, acurrentlink, and install logs underlogs/.~/.local/bin/drkm: The command, linked into the current release.~/.drkm: Your isotope: its data directory, its settings and credentials underisotopes/, and console profiles. Reinstalls and updates never touch it. Read and change the isotope's settings withdrkm config list,get,setandunset.
Running the installer again over an existing installation asks whether to remove it and install fresh or upgrade in place with your settings carried forward. To skip the prompt, set DRKM_INSTALL_REPLACE=yes or no in the environment of the sh process.
# Upgrade in place, settings carried forward
curl -fsSL https://drkm.com/install | DRKM_INSTALL_REPLACE=no sh
# Remove the installation and install fresh; ~/.drkm is kept
curl -fsSL https://drkm.com/install | DRKM_INSTALL_REPLACE=yes sh
Start a local isotope
drkm start provisions the isotope on this machine, prints its address and attaches the terminal workspace. The first start loads the release's prebuilt application image (or builds it when the release has none), creates the local cluster and pulls its service images, so it takes longer than later starts. The console is served at https://drkm.localhost:3756 by default, and every start also prints a name for your local network, https://<callsign>.local.
The first start asks two things:
- Identity. Create the first administrator with a password, or point the isotope at an OIDC provider you already run.
drkm setupcompletes this step on its own, anddrkm setup --filereads it from a private JSON file for unattended installs. - Name. A callsign for the fleet, such as
harbor-mac.--tagsets it without a prompt; leave it blank for a generated one.
It asks nothing about models. The isotope starts without one, and the chat composer's model selector reads Load a model: it offers an administrator the library model sized for this device in one click, with Settings → Models one link away for another model or a provider. drkm models setup makes the same choice in the terminal; see models and inference.
A fresh installation belongs to no mesh. The console and the local isotope work on their own until you create or join a mesh.
# Provision, print the console address, attach the terminal
drkm start
# Name the isotope for the fleet, or choose its ports
drkm start --tag harbor-mac
drkm start --https-port 3756 --http-port 8081
# Start without attaching the terminal
drkm start console
# Finish identity setup later, or choose inference in the terminal
drkm setup
drkm models setup
drkm stop
Sign in to an existing isotope
You do not need a local isotope to work. Sign this terminal in to any isotope you can reach, then use the same drkm console commands against it. After drkm start the terminal already knows your local isotope, so drkm console login with no address signs in there.
- With no flag, it opens your browser to sign in and the session comes back to the terminal. Over SSH it prints a link to open anywhere, and you paste the code the page shows.
--passwordprompts for email and password, where the isotope keeps local accounts.--tokenaccepts an API key.
Keep saved credentials in the OS keyring. For automation, inject an API key from your secret manager into DRKM_TOKEN at runtime; do not save it in a script or file. A saved sign-in is bound to the address it used. For an isotope on a private mesh with its own certificate authority, pass --tls-ca with the CA bundle.
drkm console login https://isotope.example
drkm console whoami
# A private-mesh isotope with its own certificate authority
drkm console --tls-ca /path/to/ca.pem login https://isotope.example --device
# Target an isotope from the environment instead
DRKM_URL=https://isotope.example DRKM_TOKEN="$API_KEY" drkm console jobs
drkm console logout
Get the Python SDK
The SDK is the drkm package on PyPI: Python 3.12 or later, with Pydantic as its one dependency. Where you use it decides how you get it.
- Inside an agent sandbox it is already installed. Code the agent runs can
import drkmat once. - In the installed release, the
drkmcommand’s own Python environment carries it. - In your own environment, install it from PyPI with
pip install drkm, orpip install "drkm[keyring]"to reuse credentials saved bydrkm console login. On an air-gapped machine,pip install ~/.local/share/drkm/current/sdkinstalls the same package from the local release.
Keep the SDK aligned with the release of the isotope you connect to.
python3 -m venv .venv
source .venv/bin/activate
python -m pip install "drkm[keyring]"
python -c "import drkm; help(drkm.connect)"
Update and check versions
drkm update fetches the latest published release, verifies its checksum, upgrades the installation in place and redeploys a running isotope, restoring the previous release if the new one never becomes healthy. Settings and isotope data already stored in the active home ($DRKM_HOME, or ~/.drkm by default) survive the release change. Older installations with a custom data directory need the migration below. A stopped isotope comes up on the new release at its next drkm start.
Installation registers a per-machine update key with the same approval as the download, so later updates need no browser. Isotopes also update themselves once a day unless an administrator turns Automatic updates off in Settings → Updates, where Check for updates and Update now live as well. An update restarts the isotope.
drkm update
drkm --version # the installed product version
drkm version # compares it with the running isotope
drkm version --diagnostics # build identity
# Re-approve this machine after a refused update grant
drkm update --authorize
Before updating a legacy custom data directory
If you set DRKM_HOME and an older installation still uses drkm-local:dataDir in its Pulumi stack, migrate that data before updating. An explicit home disables automatic legacy-data migration. The update removes dataDir from the carried primary stack; the new release reads $DRKM_HOME/data instead. It leaves the old directory in place, but does not find its data automatically.
- Turn off Automatic updates in Settings → Updates. Record the old
dataDirpath from the current release's stack file; resolve a relative path against that release'sinfrastructure/localdirectory. - Stop the old isotope with its existing release and home setting. Back up the complete old data directory and the active home before copying anything; do not copy a running database.
- If
$DRKM_HOME/dataalready exists, stop here: do not overwrite it or merge two isotopes' data. Otherwise copy the entire old data directory to$DRKM_HOME/data, including hidden files, preserving ownership and permissions. Keep the original and backup. - Use the same
DRKM_HOMEfordrkm updateand the nextdrkm start. Confirm the isotope's identity and existing data in the console before re-enabling automatic updates or retiring the old copy.