HLock: Harness Portability for Agent Configs A tool called hlock was released to package and portably restore AI agent harnesses — the harness version, models, MCP servers, skills, plugins, instruction files and config — into a single hashed harness.lock file that can be committed to git and rehydrated on any machine. Installed via pip, uv or pipx, hlock offers pin, check, sync, launch and run commands modeled on uv and npm, keeps API keys and tokens out of the lock as HLOCK_SECRET_* placeholders, and supports per-contributor locks at .hlock/locks/harness..lock for team repositories. The tool also provides hlock migrate to move a lock between harnesses such as Claude Code and Codex, hlock localize to convert a lock to an open-source harness with models served by Ollama or LM Studio, and hlock meta, which hands install, bootstrap-evals and update jobs to an agent and checks every result. Your agent harness made portable. Your agent is more than a model. It's a harness, MCP servers, skills, and config, hand-tuned on one machine. hlock is the missing harness packaging layer: harness.lock tracks all of its dependencies, so you can commit it to git and restore it anywhere. pip install hlock uv add hlock add to a project uv tool install hlock or install the CLI globally uvx hlock --help pipx install hlock Lock the harness you already have ¶ lock-the-harness-you-already-have If you've used uv , cargo , or npm , you already know the shape of hlock : | You know this from package managers | In hlock | |---|---| | uv.lock / Cargo.lock | harness.lock , the lockfile reference/lockfile/ : every dependency of your harness, pinned and hashed | | pip freeze | hlock pin guides/pin/ : record the setup you already have, and re-pin as it grows | | --locked check | hlock check guides/pin/ keep-it-honest-with-check : show what changed since the pin | | uv sync / npm ci | hlock sync guides/sync/ : rehydrate the locked setup on any machine | | uv run | hlock launch guides/launch/ and hlock run reference/cli/ run : start sessions and run prompts on the locked setup | - Pin everything The harness version, models, MCP servers, skills, plugins, instruction files, and config, each with a digest. Claude Code, Codex, Pi, OpenCode, autonomous agents like OpenClaw, and more reference/harnesses/ . - Secrets stay out API keys and tokens become HLOCK SECRET placeholders, so the lock is safe to commit. You supply the values when you sync. - Rehydrate anywhere hlock sync restores the setup on a new machine, in an isolated directory, or in a Docker image, and tells you exactly what it can't do for you. - Launch from the lock hlock launch starts your harness in an isolated environment that matches the lock, with none of the unlocked config on your machine. Manage your team's agents ¶ manage-your-teams-agents Contributors to one repository rarely share an agent setup: one uses Claude Code with hand-written skills, another uses Codex with a different model. Each person can commit their own lock to .hlock/locks/harness.