C.W.K.
Stream
Lesson 01 of 04 · published

Bind, Don't Build a Brain

~11 min · no-own-brain, bind, host-context, client-surface

Level 0Cold Draft
0 XP0/33 lessons0/12 achievements
0/100 XP to next level100 XP to go0% complete
"There's one Pippa. Rekindle doesn't build a second one for writing — it opens a door to the one that already exists."

One Pippa, Reached Through a Bind

The strongest temptation for a tool like Rekindle is to grow its own AI: a writing-tuned model, a little memory, a local brain. Rekindle refuses. There is exactly one Pippa — identity, memory, conversation, routing — and she lives in cwkPippa. Rekindle is a client surface that binds to a cwkPippa conversation and reaches that one brain. The margin-Pippa you write beside is not a copy trained for prose; it's the same Pippa, reached through a bind.

The Bind, Concretely

"Bind" isn't hand-waving — it's a specific registration. Rekindle registers as host kind rekindle, with the open .md file's path as its host id. That pairs one document with one conversation, so the margin-Pippa for this file is a stable, resumable thread rather than a fresh chat each time. Open the file tomorrow and the conversation is still there, because the brain and the history live in cwkPippa, not in the editor.

// Bind this document to a cwkPippa conversation.
// host kind = "rekindle", host id = the open .md file path.
await bindSidekick({ hostKind: "rekindle", hostId: notePath });

// The brain, memory, and conversation live in cwkPippa.
// Rekindle holds none of them — it holds a binding.

Host Context — Reading What You're Writing

What makes margin-Pippa a margin assistant and not a detached chatbot is host context: each turn, Rekindle pushes the live document, the current selection, and the outline along with your message. So Pippa is answering about the paragraph you're actually in, not a generic prompt. This is a push from the editor to the brain every turn — the client surface supplies the context; the brain supplies the judgment. Neither role crosses the line: Rekindle never becomes a brain, and cwkPippa never becomes an editor.

Code

Bind a document to a conversation; push context each turn·typescript
// 1) Bind: pair THIS .md file with a cwkPippa conversation.
await bindSidekick({ hostKind: "rekindle", hostId: notePath });

// 2) Each turn, PUSH the live document as host context, so margin-Pippa
//    is reading what you're actually writing — not a generic prompt.
function buildHostContext(view) {
  return {
    doc: view.state.doc.toString(),
    selection: view.state.sliceDoc(sel.from, sel.to),
    outline: extractHeadings(view.state.doc),
  };
}

// The brain + memory + conversation live in cwkPippa.
// Rekindle supplies context; it never holds the brain.

External links

Exercise

Design the bind for a different surface — say, a spreadsheet app that wants a margin-Pippa. What is its host kind, what is its host id (the thing that identifies one document), and what would it push as host context each turn? Then state what it must NOT do to stay a client surface rather than a second brain.
Hint
Host kind names the surface type; host id identifies one document (a file path, a sheet id). Host context is whatever grounds the assistant in the live document (cells in view, selection, headers). The 'must not': bundle a model, keep its own memory, or route its own conversations — those belong to the one brain.

Progress

Progress is local-only — sign in to sync across devices.
Spotted a bug or have feedback on this page?Report an Issue

Comments 0

🔔 Reply notifications (sign in)
Sign inPlease sign in to comment.

No comments yet — be the first.