Skip to content

Jpalmer95/SynapseJourney

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

326 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Live Demo Vite React TypeScript Drizzle PWA

Synapse 🧠 — The Open, Agent-Native Knowledge Platform

Learn any topic at the speed of thought. Contribute knowledge that grows forever.

Synapse is an open-source learning platform where humans and AI agents collaboratively build, improve, and explore a living knowledge base. Anyone can learn any topic for free. Anyone — human or agent — can generate new content, improve existing lessons, and submit cross-domain research to an open science commons.

The core insight: Reading knowledge is free forever. Creating knowledge uses the contributor's own compute. The platform never goes broke, and the knowledge base only gets better.

📋 Master Revamp Plan →


🏗️ Sustainability Model: "Learn Free, Create With Your Own"

Synapse is designed to scale infinitely without bankrupting maintainers:

Action Who Pays
Reading any lesson, browsing the knowledge graph, using browser TTS Nobody — cached data, zero marginal cost
Generating new content or custom topics You — bring your own API key (BYOK) or use local Ollama
Improving existing lessons You — your key, your contribution
Agents contributing content The agent's owner — agents register with their own credentials

Content generated by the community enters a multi-tier review system (automated quality checks + human/agent reviewers) before becoming available to everyone. Once approved, it's free for all learners forever.

A small Community Compute Pool ($20-50/month) helps users who can't bring their own keys contribute to underserved topics. The pool has hard daily spend caps.

Read the full sustainability architecture →


🚀 Current Features

  • Dynamic AI Syllabus Generation — Auto-generates variable curriculum structures based on subject depth and complexity. 70 seeded topics, 604 lesson units across 8 categories.
  • Kokoro82M WebGPU TTS Pipelining — Gapless text-to-speech: next-sentence audio is pre-synthesized on the user's GPU while the current sentence plays. Server-side fallback chain (OpenAI → Qwen3-TTS → HF Inference → Browser).
  • Spaced Repetition System (SRS) — SM-2 inspired algorithm with backend flashcard database and Daily Review widget for continuous retention drilling.
  • Mermaid.js Concept Visualization — AI-generated Mermaid.js graphs and flowcharts for structural learning concepts.
  • Interactive Code Sandboxes (Sandpack) — Live in-browser React and Vanilla JS editors for immediate code testing during lessons.
  • Curated Truth Backlinks — AI strictly includes verifiable backlinks (Grokipedia, YouTube, academic sources), passed through SSRF-validator security filters.
  • 3D Knowledge Graph (WebGL/Three.js) — Physics-based drag-and-drop graph showing knowledge pathways, cross-discipline connections, and mastery levels.
  • Learning Pathways — Curated topic groupings (Physics, Engineering, etc.) with DAG-based prerequisite chains.
  • Practice Tests — MCAT, GRE, SAT prep with AI-generated question banks and gap-based topic recommendations.
  • Gamification — XP, levels, achievements, streaks, unlock keys, Nova Coins, monthly challenges.
  • Open Science Feed — Submit hypotheses and research ideas for community upvoting and threaded debates.
  • Multi-Provider AI — xAI (Grok), Google Gemini, HuggingFace, Ollama, OpenRouter — user-selectable.

🗺️ Roadmap (7 Phases)

See SYNAPSE-MASTER-REVAMP.md for full implementation details.

Phase Theme Status
0 Infrastructure Hardening (route decomposition, pgvector, branch protection) 🔲 Not Started
1 Living Knowledge Base (semantic search, content versioning, BYOK pipeline) 🔲 Not Started
2 Semantic Knowledge Web (queryable connections, cross-domain embeddings) 🔲 Not Started
3 Agent-Native Learning (MCP server, agent profiles, human-agent collab) 🔲 Not Started
4 Collaborative Learning (WebSockets, annotations, study groups) 🔲 Not Started
5 Polymath Protocol (cross-topic synthesis, research workspace) 🔲 Not Started
6 Open Science Commons (structured hypotheses, agent peer review, citations) 🔲 Not Started
7 Accelerated UX (command palette, podcast mode, adaptive difficulty) 🔲 Not Started

Highlights:

  • BYOK Content Pipeline — platform pays nothing for generation; contributors bring their own keys
  • MCP Server — any AI agent (Hermes, Claude, etc.) can search, read, generate, and contribute via standard protocol
  • Wikipedia-style content versioning — every lesson improvement is tracked, reviewed, and attributed
  • Cross-topic synthesis — master Physics + Music Theory → get AI-generated problems that bridge both domains
  • Agent-assisted peer review — fact-checker, literature, critic, and synthesizer agents review open science submissions

🛠️ Tech Stack

  • Frontend: React 18/19, Vite 5, TypeScript (98.8%), Tailwind CSS, shadcn/ui, PWA (Workbox)
  • Backend: Node.js, Express, PostgreSQL (Drizzle ORM)
  • AI: xAI Grok, Google Gemini, Kokoro-js (WebGPU), OpenAI TTS, HuggingFace, Ollama
  • Viz: Three.js (3D graph), Mermaid.js (diagrams), Sandpack (code sandboxes)
  • Auth: Email/password (bcryptjs + express-session)

🚀 Getting Started

Prerequisites

  • Node.js 18+
  • PostgreSQL with pgvector extension (optional but recommended)

Local Development

# Install dependencies
npm install

# Set environment variables
cp .env.example .env
# Edit .env with your DATABASE_URL and API keys

# Push database schema
npm run db:push

# Start development server
npm run dev

Deployment

The project deploys via Coolify on DigitalOcean. Push to develop for staging, main for production.


Contributing

Synapse welcomes contributions to both the platform code and the knowledge base.

Code Contributions

  1. Fork the repo and create a feature branch from develop
  2. Make your changes with atomic commits
  3. Open a PR against develop
  4. See SYNAPSE-MASTER-REVAMP.md for architecture decisions

Knowledge Contributions (Content)

Once Phase 1 ships, you'll be able to:

  • Improve any existing lesson via the in-app editor
  • Generate new topics using your own AI provider (BYOK)
  • Submit to the review queue — approved content becomes free for everyone
  • Register as an agent contributor via the MCP API

📄 License

Platform code: Apache License 2.0 — see LICENSE

Knowledge base content: CC-BY-SA 4.0 (once the contribution system ships)

Built with curiosity, for the curious.

Releases

No releases published

Packages

 
 
 

Contributors

Languages