No description
| .devcontainer | ||
| .forgejo/workflows | ||
| .github | ||
| backend | ||
| frontend | ||
| docker-compose.yaml | ||
| README.md | ||
| specification_sheet.txt | ||
Semflow — Semantic Multiuser Wiki
Local-first, collaborative rich-text wiki with an integrated Django Semantic Graph Sync Engine.
Stack
| Layer | Technology |
|---|---|
| Frontend | TypeScript · BlockSuite · Yjs / y-websocket |
| Backend | Python 3.11 · Django 5 · Django Channels · Daphne |
| Real-time | ypy-websocket (CRDT bridge) · Redis (Channel Layer) |
| Semantics | rdflib · Oxigraph (SPARQL 1.1 Triple Store) |
| Auth | Keycloak · mozilla-django-oidc · PyJWT |
| CI/CD | Forgejo |
Quick start
# 1. Bring up all services
docker compose up -d
# 2. Apply Django migrations
docker compose exec backend python manage.py migrate
# 3. Create a superuser (optional)
docker compose exec backend python manage.py createsuperuser
# 4. Open the frontend dev server
cd frontend && npm install && npm run dev
The editor is served at http://localhost:5173.
Keycloak admin console: http://localhost:8080 (admin / admin).
Oxigraph SPARQL endpoint: http://localhost:7878/query.
Backend development (without Docker)
cd backend
cp .env.example .env # fill in your values
uv sync
uv run python manage.py migrate
uv run python manage.py runserver
Architecture
Browser (BlockSuite + Yjs)
│ ws://…/ws/wiki/<room>?auth_token=<JWT>
▼
Django Channels (Daphne / ASGI)
JWTAuthMiddleware → verifies Keycloak token
WikiSyncConsumer → bridges Channels ↔ ypy-websocket YRoom
│ Y.Doc observer
▼
graph_sync.process_and_export_graph()
rdflib Graph → HTTP PUT → Oxigraph (Named Graph per room)
Environment variables
See backend/.env.example for all required settings.