Sanctum is an experimental scripture study toolkit built with Next.js for the frontend and FastAPI services for backend processing. It explores ideas like spaced repetition, pivot detection in text, and journaling prompts to deepen scriptural engagement.
- Scripture flashcards powered by the SM-2 spaced repetition algorithm
- Text analysis service that finds chiastic and golden ratio patterns
- Journaling endpoints to record impressions and fulfillment notes
- Firebase Auth based user authentication (planned)
This project uses npm workspaces. Installing from the root will install frontend dependencies. Backend dependencies must be installed separately.
npm install
npm run install:backendCopy .env.example to .env and adjust as needed:
cp .env.example .envSANCTUM_API_KEY is used to protect the FastAPI endpoints. If not set, the services run in development mode and allow all requests while logging a warning. Always set a strong key in production.
Start the backend Python API services with ngrok tunneling:
npm run dev:backendIn another terminal, run the Next.js frontend:
npm run devThe app will be available at http://localhost:9002.
This repo uses Black and Prettier via pre-commit. Install the hooks once with:
pip install pre-commit
pre-commit installYou can manually format the code at any time using:
npm run formatSee CONTRIBUTING.md for details on how to contribute and run tests.
This project is licensed under the MIT License.