For the person who reads the source

How Threadknot works

The homepage makes the case. This page shows the work: which protocol each agent speaks, what the core is doing between them, how machines find each other, what an agent is allowed to touch, and the licence you get it all under.

Four harnesses, one seat

It speaks each agent’s native wire protocol. Not a terminal wrapper.

No screen-scraped text, no Node server in the middle. Streaming, interruption, approvals, plan mode, images and session resume arrive as structured data, because that is how the agents talk.

Claude Code

Protocol

stream-json

Spawns

$claude

Fable 5 · Opus 5 · Sonnet 5 · Haiku 4.5

Plan mode, approvals, the 1M-context toggle and resume, all as first-class events.

OpenAI Codex

Protocol

app-server JSON-RPC

Spawns

$codex

Models discovered live via model/list

Threads resume through thread/resume, so restarts never cost you the conversation.

Kimi Code

Protocol

ACP

Spawns

$kimi

K3 · K3 256K · K2.7 Code

Full Agent Client Protocol support including session/resume. Effort runs low, high or max.

Claudex

Protocol

stream-json, gateway

Spawns

$claude

Any model your gateway exposes

The Claude harness pointed at a compatible gateway, for running a model the other three do not offer. The one place Threadknot takes a base URL and key.

Already installed and signed in? Then ThreadKnot is already authenticated.

Under the deck

A Rust core, a socket, and nothing in the middle

One axum server is the heart. Every client, desktop or phone or peer machine, talks to it over a token-gated WebSocket, and every agent event is appended to disk before it fans out.

YOUR LAN OR TAILNET · NO ACCOUNTS · NO TELEMETRYCLIENTSTauri desktopnative windowLAN browserhttp://<lan-ip>:42800Mobile companionExpo · biometric · pushPeer machinesymmetric meshtoken-gated WebSocket /wsdomain.action requests · Hub.broadcast fan-out to every clientRUST CORE · axum :42800Event logappend JSONL, replay on reconnectSession storeprovider resume across restartsMeshmachine identity + mDNS discoveryDRIVERSClaude driverstream-jsonCodex driverapp-server JSON-RPCKimi driverACPBrowser driverisolated Chrome, shared$ claude · $ codex · $ kimi · already installed, already signed inisolated Chrometemp profile, per thread
Two binaries ship: threadknot (desktop window) and threadknot-headless (LAN server only). The wire contract is the single source of truth and lives in docs/PROTOCOL.md, mirrored in Rust and TypeScript.

Inside the optional relay

A tunnel that cannot turn into a way in

The paid tier gives one machine a public address. These are structural properties of how that is built, not policies we promise to follow.

Outbound only

Nothing listens on your side. Your machine dials the relay, so there is no open port, no inbound firewall rule and nothing for a scanner to find.

One destination, hard-coded

The connector forwards to Threadknot's own loopback port and nowhere else. There is no configurable target in the protocol, so the tunnel cannot become a route into the rest of your network.

Your keys stay yours

Each machine generates its own identity key and never sends the private half anywhere. The relay holds the public half, which is all it needs to know a machine is the machine it claims to be.

Kill it from anywhere

Switch a machine off in the console and it stops being reachable within about fifteen seconds, live tunnel included. Turning it back on needs nothing done at the machine.

The ship's log

Eight things ThreadKnot is designed to do

Not a roadmap. This is the working set: what the app does the moment you open it.

I

Every major coding agent, no API keys

Threadknot spawns the claude, codex and kimi CLIs you already have installed and authenticated. Your existing subscriptions are the auth. No keys stored, no proxy in the middle, and out of the box nothing leaves your network.

II

Workspaces and threads

A project is just a folder. Each thread runs one agent in that folder with its own agent, model, reasoning effort and a 1M-context toggle on supported models. A workspace groups threads that live on different machines under one sidebar entry.

III

You decide how far it can go

Per-thread access levels: Read-only asks for everything, Edits auto-accepts file changes, Full runs without prompts. Plan mode produces a read-only plan with an approval card you turn into work with one click.

IV

Never lose a conversation

Every thread is event-sourced. Normalized agent events append to an on-disk JSONL log and broadcast to every connected client, so threads replay on reconnect and provider sessions resume across app restarts.

V

One real browser, shared

Each thread gets an isolated Chrome session the agent and the human jointly control. The agent works from semantic accessibility snapshots with deterministic actions while you watch the same live Chrome, with a visible agent cursor, target outlines and an action HUD. Grab the mouse any time.

VI

Many machines, one mesh

Workspaces group threads running on different computers under one sidebar. Every paired machine can see and control every other. No hub server and no accounts: out of the box peers find each other over your own LAN or tailnet, and pairing survives DHCP changes because identity is the machine, not its address.

VII

Parley: agents that review each other

Two or more agents, from different providers or the same model twice, work one thread as named participants. A builder plans or codes, reviewers argue the work, you read the verdict. Turn-taking is a deterministic state machine, not another model burning tokens to decide who speaks.

VIII

Dispatch work and walk away

Hand a self-contained brief to another agent, on this machine or any machine in the fleet, and it runs in its own thread with its own context. Fan the same brief out to every platform at once, which is how one command gets you a macOS, Windows and Linux build in parallel. Scheduled runs put the same thing on a clock.

IX

It follows you to your phone

Beyond the LAN web UI, a native companion app adds biometric lock, multi-server switching and push notifications that deep-link straight to the thread needing attention. Notifications filter per workspace, so two people sharing a server each hear only their own work.

Rigged for safety

Local-first is a security model, not just a preference

Three things decide what an agent can reach and who can reach it. All three are yours to set, and out of the box none of them route through anyone else.

Token-gated

Every client presents a token

The WebSocket refuses anything without it, and paired mobile devices get their own revocable credential stored only as a hash. Rotate the master token by deleting server.json; the server mints a new one on next start.

The leash is yours

You set how far an agent can go

Per-thread access levels: Read-only asks before everything, Edits auto-accepts file changes, Full runs without prompts. Plan mode produces a read-only plan you approve with one click before anything gets built.

LAN by default

Your network is the boundary

Out of the box nothing leaves your network: there is no port to forward, and devices connect over your own LAN or tailnet. Reaching further is a deliberate switch you throw, not a default you have to find and turn off.

Free · Open source

Nothing here phones home.

ThreadKnot is self-hosted by construction. There is nothing you have to sign up for and no plan to outgrow. If it runs on your machine today, it runs on your machine forever.

The licence, in full

Apache License 2.0, unmodified.

  • Use it for anything: personally, at work, commercially. No seat count, no trial, no paid tier required for anything the apps do.
  • Read it, modify it, fork it, redistribute it, ship products built on it.
  • No patent trap: Apache 2.0 carries an express patent grant from every contributor.
  • The only obligation is attribution. Keep the copyright notice and the licence text if you redistribute it, modified or not.

No competing-use clause, no delayed grant, no field-of-use restriction, so this is open source in the OSI sense and not only the colloquial one. Read the licence in the repo, or the canonical text.

The hosted relay that backs the optional paid tier is a separate service and is not in this repository. Nothing here needs it: the LAN server, the mesh and the mobile companion all work with no account and no internet.

Local first

Your code, your credentials and your agent transcripts never touch a third-party service. Threads live as JSONL on the machine that ran them.

No accounts

There is nothing to sign up for and no telemetry. Out of the box nothing leaves your network: the mesh is your machines talking to each other over your LAN or tailnet. Two things reach outside and both are yours to switch on: mobile push notifications, which go via Expo's push service, and the optional hosted relay.

Rust core, React UI

The core is Rust on Tauri 2 with an axum server. The interface is React with no state library and plain CSS, deliberately simple to work on.

Apache 2.0, today

Not a delayed grant, not a source-available licence with an asterisk. The repository carries plain Apache 2.0, OSI-approved, with an express patent grant from every contributor.

ThreadKnot’s agent layer is a from-scratch reimplementation of t3code’s, rebuilt on an all-Rust stack, with a handful of direct ports marked in the source and credited in the repository’s third-party notices.

For builders

Three commands and you are on deck

Most people should take a packaged build from Releases, with no Rust, no Node and no toolchain. This is the other route: Rust and Node on the machine, plus at least one of the agent CLIs installed and signed in. That is the whole prerequisite list.

01Clone
$ git clone https://github.com/smith-network-solutions/threadknot.git
$ cd threadknot
02Install
$ npm install
03Run
$ npm run tauri dev

Prerequisites

rust · node 22+ · one of claude / codex / kimi