Skip to content
codeaz-orgPublic

About

No description, website, or topics provided.

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

Relay

Obsidian, but multiplayer. Bring your team to Claude.

Relay is an open-source collaboration platform where your whole company lives in shared Markdown vaults — real folders of .md files on disk, live-edited by the entire team through a CRDT (Yjs), with an AI chat panel that streams from Anthropic, OpenAI, NVIDIA NIM, or a local Claude Code CLI.

  • Real folders on disk. Every vault is a plain directory of .md files under DATA_DIR/vaults/<vault-id>/. Copy it anywhere → open in Obsidian → it just works.
  • Live multiplayer editing. Yjs handles concurrent edits with zero conflicts. Two people type in the same file → you see each other's cursors.
  • Multi-provider AI. Pick per-message: Anthropic, OpenAI, NIM, or — in self-host mode — the local claude CLI, which gets real filesystem tools inside the vault.
  • AGPLv3. Self-host in one command. Fork it. Or use the hosted plan.

Quickstart (Docker)

cp .env.example .env      # set JWT_SECRET; add ANTHROPIC_API_KEY etc. if you have them
docker compose up --build

Open http://localhost:8080.

Seeded on first boot: demo@relay.dev / relay-demo (one starter vault).

Or sign up with your own email, create a vault, open Manage → create invite link, and paste it into another browser to see live multiplayer.

Quickstart (local dev)

# terminal 1 — API + WS on :4000
cd server && npm install && npm run seed && npm run dev

# terminal 2 — web on :5173  (proxies /api and /ws to :4000)
cd web && npm install && npm run dev

AI providers

Configure via environment on the server. All are optional; the UI shows which ones are ready:

Provider Env var Notes
Anthropic ANTHROPIC_API_KEY claude-opus-4-7 · claude-sonnet-4-6 · haiku-4-5
OpenAI OPENAI_API_KEY gpt-4o · gpt-4o-mini · o1-mini
NVIDIA NIM NVIDIA_NIM_API_KEY Llama-3.3-70B · Nemotron-70B · Mistral-Large-2
Claude Code (none — needs claude on PATH) OSS mode only. Real filesystem tools in vault

Set RELAY_MODE=cloud to disable the claude-code provider (used for the managed cloud build; oss is the default).

How it works

  • Vault = folder. DATA_DIR/vaults/<id>/**/*.md. Yjs is the in-memory truth; the server debounce-persists updates to disk every ~800ms.
  • Sync. One WebSocket per vault, y-websocket protocol. Presence and cursors ride on Yjs Awareness — no separate presence channel.
  • Auth. Bcrypt password hashes, 30-day JWTs. Membership is re-verified on every WS upgrade; roles are owner | editor | viewer.
  • Chat. POST /api/vaults/:id/chat (SSE stream). Each provider is a small async-generator module in server/src/providers/; add a new provider by dropping in a file and registering it in providers/index.js.

See docs/architecture.md for details.

Project layout

relay-platform/
├── docker-compose.yml
├── .env.example
├── LICENSE                    # AGPLv3
├── docs/
│   ├── architecture.md
│   └── self-hosting.md
├── server/                    # Node · Express · SQLite · Yjs · WebSockets
│   ├── src/index.js           #   REST (auth, vaults, invites, chat SSE)
│   ├── src/hub.js             #   WS auth → y-websocket
│   ├── src/vault.js           #   Y.Doc ↔ .md files on disk
│   ├── src/db.js              #   SQLite persistence
│   └── src/providers/         #   anthropic / openai / nvidia-nim / claude-code
└── web/                       # React (Vite) · CodeMirror 6 · yjs · y-codemirror.next
    ├── src/App.jsx            #   routing, marketing, auth, vault list
    └── src/vault.jsx          #   tree · editor · chat panel

Deploying

  • Single box / VPS / Fly / Railway / Render: docker compose up -d behind any TLS proxy. WebSockets pass through the bundled nginx.
  • Split hosting: deploy web/ as static (with rewrites for /api/* and /ws pointing at the server URL), and run server/ on any Node host with a persistent volume for DATA_DIR.
  • Set a strong JWT_SECRET. DATA_DIR (default /app/data) is the only state you need to back up — the SQLite DB and the vaults/ folder.

License

Relay is licensed under the GNU Affero General Public License v3.0 or later. See LICENSE.

The hosted commercial edition (Relay Cloud) is built on the same source code, provided as a service by Relay Labs, Inc. See docs/self-hosting.md if you want to run it yourself.

Security

Report vulnerabilities to security@relay.dev. See SECURITY.md.

About

No description, website, or topics provided.

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages