The problem
A model has to fit in the memory of the device that runs it, so a phone runs small models and a Mac runs large ones. The two are often a metre apart, on the same Wi-Fi. The usual ways to let one use the other are both wrong for a private assistant. A relay in the cloud puts a server between two devices that can already reach each other. A plain connection on the local network works, but it is unauthenticated and unencrypted. Adding TLS does not fix that by itself, because a private address cannot hold a publicly trusted certificate, and the common answer to the warnings that follow is to turn certificate checking off.
Kalon Link is the third way. The phone scans a code on the Mac once. After that it can pick any chat model installed on the Mac, and its chats are answered there, over a channel that is encrypted and bound to that one Mac. This report describes how, and is careful to say what has and has not been measured.
One scan carries the whole pairing
The Mac shows a QR code and six digits. The code is a single address of the form kalon://pair with five fields: a version, the Mac's private network addresses, the port, the fingerprint of the Mac's public key, and the six digits. One scan therefore gives the phone everything it needs: where the Mac is, how to recognise it, and the six digits, which show that whoever holds the phone has the code that is on the Mac's screen right now.
The phone reads the code with the system's built-in QR detector. The app shows the system's camera preview, but its own code is handed only the decoded text, and it acts on that text only if it begins with kalon://pair?. Its parser is strict about four of the fields: a code with no usable IPv4 address, no port, no digits, or a fingerprint that is not exactly 64 hexadecimal characters is rejected whole. Entries in the address list that are not IPv4 literals are dropped. The version field is carried but not checked yet.
The QR is drawn at error-correction level M, always dark on a white tile in both themes, and shown with smoothing switched off, because many scanners refuse an inverted code and a blurred one is hard to read. A device that cannot scan can be paired by typing the six digits, the Mac's address and the fingerprint. That path builds the same address and ends at the same parser.
The pairing window
The six digits are the only thing an unpaired device can present, so the window they open is kept small.
It exists only on request. No code is generated at launch or refreshed in the background. A code exists from the moment someone asks for one until it is used, hidden or expired, or until wrong guesses close it or Kalon Link is switched off. Closing the Settings pane retracts it.
It is short and single use. A code lasts 300 seconds and pairs one device. A second device presenting the same code is refused.
It closes under guessing. Five wrong guesses close the window. The Mac says the last code was closed after too many wrong tries, and a person has to ask it for a new one. Against a million possible codes that is five chances in a million per window. The digits are not the defence; the window is.
The digits come from the operating system's random source, with rejection sampling so that no digit is favoured, and a code is compared without stopping at the first wrong digit. Codes that have just been retired are remembered for 600 seconds, eight at most, for one purpose: a phone that scans a stale code is told the code has expired, which is true, and is not told it was wrong, which would count against the window.
The key is the identity
All traffic is TLS. The Mac makes its own certificate the first time Kalon Link starts, with an ECDSA P-256 key, keeps it in the Keychain, and reuses it for as long as that item can be read. The certificate names no host and no address. It does not need to, because the phone never asks a certificate authority who the Mac is.
Instead the phone pins the key. The fingerprint in the QR code is the SHA-256 of the certificate's SubjectPublicKeyInfo. On every full handshake the phone hashes the public key in the server's certificate and compares it, in constant time, with the fingerprint from pairing. If they differ, the phone abandons the handshake. A resumed session sends no certificate, and it can only continue a session that already passed this check. The handshake signature is still verified, under TLS 1.2 or 1.3, so presenting the right certificate is not enough: the server must hold the private key.
Nothing else is consulted. There is no root store, and the name and the expiry date in the certificate are not checked, because the pin is the whole identity. This is the opposite of switching verification off. A connection to anything but that one key is refused, on any network, whatever certificate it presents.
The certificate is kept on purpose. A new one would change the fingerprint, and every paired device would refuse to connect until it was paired again. It lives in a Keychain service of its own, apart from the device tokens, so that no name a client supplies can ever address the Mac's private key.
The token
A successful pairing returns a token: 20 symbols of Crockford base32, drawn at random, which is 100 bits. It is never typed and never shown. The phone keeps it in its Keychain and the Mac keeps its copy in its own; on the phone it is not written to the database and is not handed to the interface code.
Every request for the model list or for a reply carries the token, and the Mac checks it before the handler runs, comparing it without stopping at the first character that differs. Without it the answer is 401. Removing a device on the Mac deletes its token and its record at once, with no restart, and that device's next request is refused. The phone's model list and its Kalon Link screen then say the computer no longer recognises it.
What the Mac will listen to
Kalon Link is off by default. Turned on, it listens on port 11435, fixed so that a paired phone's stored address survives a restart.
Private addresses only. When it starts, the Mac binds one socket for each private IPv4 address it has at that moment, never all interfaces. If it has no private address it refuses to start. A connection from an address that is neither private nor the Mac's own loopback is dropped before the TLS handshake begins. A private address is not the same as a trusted network: on a shared Wi-Fi the listener can be reached by other devices there, and the pairing window, the pinned key and the token are what stand between them and the Mac's models.
Two questions without a token. An unauthenticated caller can do two things: present a pairing code, and ask whether the listener is up, which returns a fixed answer and nothing about the Mac. Everything else requires the token.
Its own listener. Kalon's local API server for developers is a separate listener with its own rules. Link was added beside it, with its own queue, so that turning on pairing cannot widen what the other server accepts.
On the routes that need a token, a request body may be up to 64 MiB, about ten full-size phone photographs, and a larger one is answered with 413. There the token is checked before the body is read. The pairing request, which carries no token, keeps a limit of about 2 MB.
Streaming a reply
The phone keeps its conversations. For each reply it sends the conversation to the Mac and the answer streams back.
Finding the Mac. After a scan, the phone stores every private address the Mac's listener was bound to when the code was shown. Before each chat it asks each one in turn whether the listener is up, allowing three seconds per address, and uses the first that answers. The choice is made per call, because a phone moves between networks.
The stream. The request is an OpenAI-style chat completion with streaming on, and the reply arrives as server-sent events: a first frame, then one frame per piece of text, then a final frame and a terminator. A reasoning model's thinking arrives in its own field as it is written, so the phone can tell thinking from a stall. The phone collects the pieces in a buffer and draws them at most 60 times a second, not once per token.
Stopping. Once the request has been sent, the phone checks for Stop at least every two seconds, including while it waits for the first byte, and stops by closing the connection. The search for the Mac that comes before it does not check for Stop.
Queueing. The Link listener lets one of its requests per model generate at a time. Up to 32 requests, counted across all models, may wait behind others; one more is answered with 503 at once, and one that waits 300 seconds for its turn is answered with 503. Each paired device is a separate owner of the Mac's kept context. A request from a different device starts from an empty context, so two phones never reuse each other's prompt.
Photographs. The phone learns from the Mac's model list which models can see. Images travel inside the request as base64 and are decoded by Kalon itself (JPEG, PNG, WebP, BMP and the first frame of a GIF). The Mac never fetches an image from a link. If a model could not see an image, the reply is flagged, and the phone tells the user.
The Mac records a usage entry for each reply it completes: the model, the token counts, the timings and the names of any tools the reply called. It also notes when each paired device last asked. It does not save the phone's conversation.
The switches that govern it
On the phone, Kalon Link is not an online model. A paired Mac is the household's own computer, so the switch that keeps online models off is not consulted. Two stronger controls are. With Block all network access on, the phone opens no connection to the Mac, pairing included. And a child profile cannot use Kalon Link at all.
On the Mac, Block all network access governs connections the Mac makes outward. It does not close the listener, and a note at the foot of the same Settings page says so. The control for the listener is its own switch.
What is measured, and what is not
- Most of the pairing rules are tested. Tests check that a code exists only while its window is open, that the fifth wrong guess closes it, that a used code never pairs a second device, and that 500 tokens are all different. Across 12,000 generated digits each digit must appear between 900 and 1,500 times, a loose check that catches a broken generator and would not detect a small bias. The 300 second expiry and the 600 second memory of retired codes are in the code but are not covered by a test, because no test moves the clock.
- Pairing and authorisation are tested over a real socket with real TLS, on one Mac that plays both ends. With no credential the listener answers its health question, refuses the model list with 401, and refuses a pairing request with 403 while no code is showing. A live code pairs; the same code again is refused; the issued token is accepted; a forged token and a removed device are refused. The phone's client code, run on the Mac against the same listener, fails to pair when it pins a wrong fingerprint and pairs when it pins the right one. These tests skip on a machine with no private address. There are 20 automated tests across the two halves, and none of them streams a reply over Kalon Link.
- The fingerprint the phone computes from a certificate is tested to equal the one the Mac computes from its key, and malformed certificates are tested to be refused without a crash.
- One pairing observed on real hardware, on 19 September 2026: an iPhone read the code from the Mac's screen and was paired in about two seconds, with nothing typed. The record gives no timing method, and it is one observation, not a distribution.
- The rate at which a reply streams over Kalon Link, the delay it adds compared with running the same model on the Mac itself, the time to the first token, the cost of the TLS handshake on a real network, the number of devices one Mac serves well at once, and the effect on the phone's battery have not been measured yet. We will publish those numbers when we have them rather than estimate them here.
Limitations we accept for now
A token does not expire. It lasts until the device is removed on the Mac, which takes a click and a confirmation, or until the app pairs again under the same device id and gets a new one. A phone that pairs under a new id, for example after its app data is erased, leaves the old token valid until the old entry is removed on the Mac. There is no rotation, and forgetting the computer on the phone does not remove the Mac's copy. Beyond the queue there is no rate limit on a paired device's requests, and the listener has no idle timeout, so the phone keeps no connection open between requests and connects afresh for each one.
A request has 300 seconds in all, counted from when the phone starts to connect. That includes any wait in the Mac's queue and the time to load the model, so a long answer, a slow model or a busy Mac can each cause a reply to be cut off. Stopping closes the connection; no separate message tells the Mac to stop.
When the fingerprint does not match, the phone refuses the connection but does not yet say why: the person is told the computer did not answer or cannot be reached. A chat sent to a computer that has removed the device fails with a plain 401 error. The model picker and the Kalon Link screen say the pairing was removed the next time they are opened, but the chat itself does not.
There is no discovery, and the Mac offers only its private IPv4 addresses, so the phone must be able to reach one of them, which in practice means the same network. A phone pairs with one computer at a time. The only client we ship is the Kalon app, and there is no browser page. The listener does not check what the client is: any program that presents a live pairing code can pair, and a token works from an ordinary OpenAI-compatible client. The Mac decodes only JPEG, PNG, WebP, BMP and GIF. The Kalon app converts every photo to JPEG before sending it, so a phone's own photos are seen; a HEIC, AVIF or TIFF image sent by any other client is not decoded, and the reply is flagged to say the model did not see it.
Status
The Mac half of Kalon Link ships in Kalon for Mac today, off by default, under Settings, Kalon Link. The other half is in Kalon for iPhone and iPad, which is not yet on the App Store. It has been run end to end on an iPhone. On an iPad it has been installed on a device. Pairing an iPad with a real Mac has been run only in the Simulator, where the code was typed because a simulator has no camera, and no streamed reply on an iPad is on record.