Reviewed initial context sharing problems.
UnderstandAdded MCP server to project configuration.
EditConfirmed MCP server build is live but untested end-to-end.
VerifyCleared MCP authentication for all users.
Editlast chat we shipped an mcp server for ramify. see the convo leading up to it and th eprobelms i was trying to solve for regarding conrtext sharing. how far along did we get
You started with two problems, sharing canvas context quickly and joining canvases together. The first is solved for agents and live in prod; the second hasn't been started.
harbor. You pasted the same draft twice, and pi couldn't see any of the canvas research.https://ramify.lakshyaag.com/mcp. PR #1 is merged and main matches the deploy.list_canvases lists canvases with their card titles.read_canvas gives one canvas as an outline.read_cards returns full card text, with sources on request.search_cards searches across every canvas..pi/mcp.json now points at prod, but it is still untracked.Hole.rootId doesn't permit today.can you add mcp for prod ramify here to this project claude mcp
The prod Ramify server is added to this project's Claude config, in a new .mcp.json at the repo root.
It isn't connected yet: run /mcp in Claude Code, pick ramify, and sign in through the browser. You may need to restart the session first for it to show up.
.mcp.json is untracked, like .pi/. It holds only the URL, so it is safe to commit.
check
It works from Claude Code against prod: signed in, listed your 10 canvases, and search for "healthcare index" found the two matching cards in the Military-Industrial Complex canvas.
The list also reflects new work since the last session: that canvas now has 8 cards, including "Search Index" and "Environment — Usually".
okay cool. what next should we explore. i think first on the ramify view under the user tab maybe add a section for mcp or maybe on homepag? idont really know but i think ti should be advertisied
I'd put it in two places, because they do different jobs: the account menu is where a signed-in reader gets the connection details, and the signed-out intro page is where it gets advertised.
https://ramify.lakshyaag.com/mcp and a copy button. It already has Usage and Models as sections, so this fits without new layout.One catch with the account menu alone is that it's hidden behind the avatar, so nobody finds it by accident. That's why the intro point matters.
Do you want the first pass to be the URL and copy button only, or to include the connected-agents list with revoke?
ya add it ; on intro page you can update copy to less self-relfection and more product first. confirm with me. we can keep just 3 no need to add new 4 but reolace one with mcp
The Agents section is in the account menu; the intro page is untouched until you confirm the copy below.
https://ramify.lakshyaag.com/mcp and local dev shows localhost.The change is in src/components/Account.tsx and src/index.css.
| Now | Proposed | |
|---|---|---|
| Lede | A research agent I built to see how far branching answers could go. Ask it something, then pull on any phrase in the answer. | A research agent that answers on a canvas. Ask a question, then select any phrase in the answer to go deeper. |
| Point 1 | Watch it work: Every card lists the searches it ran, the pages it read, how long it took and what it cost. | Unchanged |
| Point 2 | Branch from any phrase: Select words in an answer and they get a researched card of their own. The one you were reading stays where it was. | Unchanged |
| Point 3 | Still an experiment: I'm working out what the canvas is good for. For now you can rearrange it, draw on it and leave notes. | Bring it to your agent: Connect Claude, pi or Cursor over MCP, and it can search and read everything you've researched. |
| Line above the example | Below, one question I asked it: N cards, N sources, about $X. | Below, an example exploration: N cards, N sources, about $X. |
Replacing point 3 drops the only mention that you can rearrange, draw on and annotate the canvas. The example below it still lets a visitor do that.
Is this copy good to apply, or do you want changes?
run local stack
improve the bring it your agent part - lets add icons for harnesses and make it look pretty like the rest - use claude code, pi, opencode as examples
Local stack is up on port 8788 (8787 was taken by your personal-website dev server). Now fetching icons for Claude Code, pi and opencode to build the agent point.
The local stack is running at http://localhost:8788, and the intro page now has the product-first copy and the agent point with icons.
Port 8787 was already taken by your personal-website dev server, so Ramify moved to 8788. Google sign-in may not work there if only the 8787 redirect is registered with Google; I haven't tried it.
public/agents/, taken from each project's own favicon.Screenshots:
on bring your agent part also add in a 4th that canm be any mcp-enabld harness ; search onlien for best term
The fourth chip is in: "any MCP client", with the MCP project's own icon. It shows on the intro page and in the account menu, and you can see it at http://localhost:8788.
Sources:
[Image #1] looks shit improve
[Image: source: /var/folders/c_/9rljm9bd0rsg15b7_8s11yvc0000gn/T/rex-clipboard-E16AB2A9-93C7-4A88-AEEB-7DD790D4FB29.png]
ok commit push and deploy
Committed, pushed to main and deployed; https://ramify.lakshyaag.com now serves the new intro copy and the three agent icons.
.mcp.json and .pi/ are still untracked.Screenshot of the shipped agent point: /private/tmp/claude-501/-Users-lakshyaag-Projects-Personal-rabbit-hole/ff36edf4-1a4f-4912-bc0b-1705d03c1a5e/scratchpad/intro-crop.png
also can you fix the page title to be more detemrinsitic? right now i tihnk it shows the canvas or slected node's title on all - lets fix that
The tab title now depends only on which page you're on, not on which card is open. It's a local change in src/App.tsx, not committed or deployed.
| Page | Title |
|---|---|
| Home | Ramify |
| Signed-out intro | Ramify |
| A canvas | <canvas title> · Ramify |
| Sign-in for an agent | Sign in · Ramify |
| Consent for an agent | Allow access · Ramify |
◌ prefix while a card on the canvas is still researching, so you can tell from another tab when a run finishes. Say if you want that gone too.ok push deploy
The title fix is committed, pushed to main and deployed to https://ramify.lakshyaag.com, which responds normally after the deploy.
I haven't checked the canvas and home titles on prod, since they need your signed-in session. The local dev server is still running on port 8788, and .mcp.json and .pi/ are still untracked.
now lets think about exposing write featujres on the mcp for the agent to collaborate with. brainstorm and itnerview me
Here's the brainstorm; the questions follow in a dialog.
| Write | What it does | Cost to build |
|---|---|---|
| Leave a note | A sticky note on a canvas or beside a card, such as "used this in the harbor draft" or "this contradicts the paper" | Small: a note is one row, like the ones you make by hand |
| Bring its own content | A card the agent writes itself, with no research run, such as your blog draft or what it found in a codebase | Small to medium: a new kind of card that didn't come from a question |
| Ask Ramify to research | Branch a researched card from an existing card, or start a new canvas from a question | Largest: see the constraint below |
| Organise | Rename a canvas, move or link cards across canvases, prune branches | Medium, and it overlaps with "joining canvases" |
| Attach evidence | Add a source or a quote to an existing card | Small |
"Bring its own content" is the half of your original problem that's still open. On day one pi couldn't see the canvases, which is solved, and the canvas couldn't see your draft, so you pasted it into an ask.
canvases:read only. Writing should be a separate scope, so existing connections stay read-only until you approve again.Add-only, in two steps: notes and agent-written cards first, then research runs once the server can save them. Everything an agent writes is marked with which agent wrote it, and nothing of yours can be edited or deleted.
Reading how the page saves and loads a canvas, so I can answer "how can this be done properly" from the actual code.
Done properly, it comes down to two things: the server saving its own runs, and the open page learning that rows were added. Because you chose add-only, there is nothing to merge or conflict.
So "live" reduces to one missing piece: telling the open page that a new card or note exists.
1. The server saves a run's card itself. This is needed whatever you choose for live view.
src/lib/apply.ts) is already a pure function, so the run can use it on the server and write the finished card to the database.2. The open page learns about new rows. There are two sound ways.
| Refetch on focus | Push channel | |
|---|---|---|
| How | The page re-reads the canvas when you return to the tab, and adds rows it doesn't have | One small Durable Object per canvas holds a WebSocket to each open page. An agent's write pokes it, and the page fetches the new rows |
| When it updates | When you switch from the terminal to the browser | Within a second, even with both windows side by side |
| Cost | Small, no new infrastructure | A new Durable Object and a socket in the page. It sleeps when idle, so it costs nothing at rest |
| Later use | None | The same channel would sync two of your own devices |
In both, the database stays the only source of truth; the push channel carries "something changed", never the content.
Build piece 1, then refetch on focus. Your loop is agent in the terminal, then a look at the browser, and focus covers that. Add the push channel only if you find yourself watching both side by side.
For the mock spending cap, I'd hard-code 10 agent-started runs per account per day until the user-level cap exists.
The interview has settled the design: three add-only write tools on existing canvases, marked with the agent that wrote them, behind a separate consent.
| Question | Decision |
|---|---|
| What agents write | Notes, cards with their own content, and Ramify research runs |
| Where | Under an existing card only. No new canvases, no loose cards |
| Edit rights | Add only. Agents can't change or delete anything, including their own writes |
| Provenance | Every agent-written card and note shows which agent made it |
| Spending | A cap on agent-started runs, hard-coded for now, user-level later |
| Run timing | The tool returns the new card's id at once, and the agent reads it later |
| Open canvas | New cards and notes appear when you return to the tab |
| Interfaces | Agent-started research cards get no designer interface |
| Tool | What it does |
|---|---|
add_note(card_id, text) | A sticky note beside a card |
add_card(card_id, title, text) | A card with the agent's own content, branching from that card |
ask(card_id, question) | A Ramify research run branching from that card. Returns the card id with status running |
canvases:write scope. Existing connections stay read-only until you approve again, and the consent page says the agent can add to your canvases and spend research runs.read_canvas and read_cards show the author on agent-written items, and notes appear in the outline.Nothing is built yet.
ok build it all. you can keep deploying to main and testing with pi - ramify should be installed globally
Still reading the code I need before building: how the canvas lays out cards and notes, the consent page, and how the page asks a follow-up.
Checking how prod stores the registered agents (pi, Claude Code) so each write can be labelled with the agent's name; then I start building.
assume no existing users - no need to edsign around that
Shared code is moved and the server-side card save is written; fixing a type error, then the run's Durable Object and the MCP write tools.
The three write operations are written on the server. Now wiring them into the MCP server as tools, with the write scope and the agent's name.
The page now shows who added a card or note. Next: the page picking up agent writes when you return to the tab, then tests and deploy.
Now the tests: update the existing ones for the new scope and add tests for the write tools and the server-side save.
The build passed all 113 tests; the commit-push-deploy command is taking longer than expected, so I'm checking where it's stuck.
The signing key is loaded from the keychain now; the earlier commit attempt failed because it was waiting on the key's passphrase. Retrying the commit, push and deploy.
ok never mind pi are you done
The build is done and live on prod, but it has not been used end to end by a real agent, so treat the write tools as untested in practice.
add_note, add_card and ask, alongside the four read tools. Each adds under an existing card and is signed with the agent's name.Every existing connection is now refused, because old tokens only have the read scope. That includes this Claude Code session's Ramify connection.
/mcp-auth ramify failed with "Failed to write OAuth credentials for ramify to the OS secure credential store". That is pi's keychain write on this machine, not the server. I closed the pi pane I opened.ssh-add; I did not bypass signing..mcp.json and .pi/ are still not committed.reauth got rejected. can you clear mcp auths on server for everyone?
Every agent connection on the server is cleared: all 5 client registrations, 3 consents and 3 refresh tokens are deleted. Your Google sign-in, sessions and canvases are untouched.
Each agent now registers fresh and gets both scopes on the next sign-in:
/mcp, pick ramify, and authenticate again./mcp-auth ramify. If it still fails with the "OS secure credential store" error from before, that is pi's keychain write on this machine and clearing the server won't fix it.Any access token an agent already holds stops working within its expiry, and none can be renewed. I haven't retried a sign-in myself, since it needs you in the browser.