Django REST + Socket.IO backend for the Dietrich Analysis Research Education (DARE) Platform.
- What is DARE?
- Overview
- Quick Start
- Documentation
- Tech Stack
- What is included in this repo?
- What is not included in this repo?
- Stay in touch
- Acknowledgements
- Contributors
- License
The Dietrich Analysis Research Education (DARE) Platform is an open-source, multi-LLM research and conversation platform. It provides a single, vendor-agnostic interface to OpenAI, Anthropic Claude, Google Gemini, and self-hosted LLaMA models, with file-grounded retrieval (RAG), Model Context Protocol (MCP) tool integration, visual multi-step workflows, and real-time streaming. DARE is built for researchers and institutions that need more than a chatbot — document intelligence, reproducible workflows, and per-user usage tracking in one place.
This repository is the DARE backend — the Django ASGI service that powers the platform. It handles:
- Real-time streaming chat across providers
- Document upload, processing, and RAG over vector stores (Pinecone, Weaviate)
- Multi-step AI workflow execution via a visual DAG builder
- Token usage tracking and per-user billing
- Access-code based registration for institutional deployments
- Inter-service authentication for partner platforms (e.g. SocraticBooks)
DARE runs standalone. The DARE backend and frontend are all you need to run the platform — nothing else is required. SocraticBooks is a separate, optional platform built on top of DARE.
flowchart TB
clients["Clients\nDARE Frontend, partner frontends, mobile"]
subgraph backend["DARE Backend (Django ASGI)"]
auth["Auth / Users"]
chat["Conversations + Chat"]
files["Files / RAG"]
workflows["Workflow Engine"]
services["Service Layer\nLLM, vector, MCP, email"]
end
postgres["Postgres"]
redis["Redis + RQ"]
vectors["Vector Stores\nPinecone / Weaviate"]
llms["LLM APIs\nOpenAI, Claude, Gemini"]
ollama["Ollama\nself-hosted models"]
clients <-->|REST + Socket.IO| backend
auth --> postgres
chat --> services
files --> services
workflows --> services
services --> postgres
services --> redis
services --> vectors
services --> llms
services --> ollama
See docs/architecture.md for the full diagram and docs/architecture/overview.md for component-level detail.
# 1. Clone
git clone <repo-url> dare-backend && cd dare-backend
# 2. Configure
cp .example.env .env
# Edit .env. At minimum, set DJANGO_SECRET_KEY and one provider key
# such as OPENAI_API_KEY, CLAUDE_API_KEY, or GEMINI_API_KEY.
# 3. Build and start the backend stack
docker compose up --build -d
# 4. Create an admin user
docker compose exec web python manage.py createsuperuser
# 5. Check health
docker compose ps
curl http://localhost:8000/api/health/
curl http://localhost:8000/api/ready/The API will be available at http://localhost:8000/. The OpenAPI schema is served at
http://localhost:8000/api/schema/. Swagger UI is routed at http://localhost:8000/api/docs/, but
it loads Swagger assets from a CDN, so use the raw schema if the UI does not render in an offline or
restricted network.
Docker Compose starts the API server, RQ worker, Postgres + pgvector, Redis, and Weaviate. Optional Ollama and Weaviate console services are available through Compose profiles. See INSTALL.md for details.
Use this path when you want the Django process running directly on your machine.
cp .example.env .env
python3.13 -m venv .venv
source .venv/bin/activate
pip install -r requirements/local.txt
python manage.py migrate
uvicorn dare.asgi:application --host 0.0.0.0 --port 8000 --reloadIn a second terminal, start a worker:
source .venv/bin/activate
OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES python -Wd manage.py rqworker default -v 3Redis must be running for Socket.IO pub/sub and background jobs. See INSTALL.md for complete Docker, local, and production guidance.
| Doc | What's in it |
|---|---|
| INSTALL.md | Full deployment guide — Docker and bare metal |
| docs/configuration.md | Every environment variable, with type, default, and description |
| docs/architecture.md | Component diagram and request flows |
| docs/admin-guide.md | User/role management, access codes, analytics |
| CONTRIBUTING.md | Issues, pull requests, coding standards |
| CHANGELOG.md | Release notes |
| SECURITY.md | Vulnerability disclosure process |
| docs/integration/socraticbooks-dare-proxy.md | DARE/SocraticBooks integration contract and update rules |
| docs/architecture/socketio-events.md | Socket.IO event reference |
| docs/api/dare-backend.md | REST API reference |
| docs/code-standards.md | Coding conventions |
- Python 3.13, Django 5.1, Django REST Framework
- Django Channels + python-socketio for real-time streaming
- Django RQ + Redis for background jobs
- PostgreSQL (production) / SQLite (local dev)
- Weaviate and Pinecone for vector storage
- Ollama for self-hosted LLaMA models
- Django apps for auth/users, conversations + chat, files/RAG, and the workflow engine
core/services/— the service layer (LLM providers, vector stores, MCP, email)docs/— architecture, configuration, admin, API reference, deployment, and integration guides- Docker Compose stack (API, RQ worker, Postgres + pgvector, Redis, Weaviate) and
requirements/ - Supporting docs —
INSTALL.md,CONTRIBUTING.md,CHANGELOG.md,SECURITY.md,BRAND.md
- dare-frontend — the React/TypeScript web client (run it separately)
- socraticbooks-backend and socraticbooks-react — the SocraticBooks platform that proxies to DARE
- External infrastructure you provide yourself — LLM provider API keys, an Ollama host for self-hosted models, and managed Postgres/Redis/vector-store instances in production
- Found a bug or have a feature request? Open an issue on the project's GitHub repository.
- Questions or general inquiries? Email the project team at vks@andrew.cmu.edu.
- Security disclosures: see SECURITY.md.
DARE is an Open Forum for AI (OFAI) initiative, Carnegie Mellon University Libraries.
The DARE name and marks are owned by Carnegie Mellon University. Use of the name, wordmark, Scotty dog mark, header lockup, and footer badge is governed by the DARE Brand Guidelines & Usage Policy, independently of the software license.
This software integrates with third-party APIs (Anthropic, OpenAI, Google, and others); use of those APIs is subject to each provider's own Terms of Service.
DARE is built and maintained by contributors at Carnegie Mellon University and in the open-source community.
Creators
Sayeed Choudhury Creator |
![]() Vincent Sha Creator |
![]() George Cann Creator |
Team
![]() Carl Skipper Contributor |
Muhammad Abdurrehman Team Lead |
Brian Wingenroth Developer |
Farhat Abbas Developer |
Hariss M. Developer |
Eira Khan QA |
This project is licensed under the GNU Affero General Public License v3.0 (AGPL-3.0-only). The software license does not grant rights to the DARE name or marks; see the DARE Brand Guidelines & Usage Policy.
See the LICENSE file for the full license text, or visit https://www.gnu.org/licenses/agpl-3.0.en.html.


