Python service for cognition-grounded Q&A, on-demand vectorization, and contradiction detection.
python -m venv .venv
source .venv/bin/activate
pip install -e '.[dev]'
uvicorn app.main:app --reloadSet these vars:
CORS_ALLOW_ORIGINS(defaulthttp://localhost:5173, comma-separated for multiple)SUPABASE_URLSUPABASE_SERVICE_ROLE_KEYSUPABASE_JWT_SECRET(optional; local HS256 decode shortcut)OPENAI_API_KEYOPENAI_EMBEDDING_MODEL(defaulttext-embedding-3-small)OPENAI_CHAT_MODEL(defaultgpt-4o-mini)
Create these in your Supabase backend:
supabase/schemas/001_cognition_embedding_state.sqlsupabase/schemas/002_cognition_contradictions.sql