Foundation (phase 01, verified): - FastAPI app: /api/health, /api/suggestions, /api/chat (placeholder), static frontend served locally (no CDN) - Postgres 17 + pgvector via db/Containerfile + compose.yaml (podman compose up -d db), Alembic initial migration (documents, chunks with vector(768), query_log) - LLM client targeting https://aipi.reeseapps.com/v1 (turbo/embed); scripts/llm_probe.py verified models + 768-dim embeddings live - Conditional debugpy: imported only when DEBUGPY=1 (attach on demand, :5678); logging config for clean single-line logs - Frontend shell: mobile-first chat + Sources pages, tokens, a11y baselines - Tests: 24 unit+integration (99% coverage on app/), ruff + pyright clean, Playwright smoke E2E (3 tests) against a deterministic mock LLM - Planning: .agent/PLAN.md (architecture + LOCKED decisions), AGENTS.md, 6 user stories, 7 phase files (one story / one phase / one Playwright suite each)
50 lines
1.3 KiB
YAML
50 lines
1.3 KiB
YAML
# Brain of Reese — service orchestration.
|
|
#
|
|
# Development: podman compose up -d # starts Postgres 17 + pgvector
|
|
# Full stack: podman compose --profile prod up -d # adds the app container
|
|
#
|
|
# The `db` image is built locally from `./db` (base: docker.io/postgres:17,
|
|
# extended with the pgvector extension) so no non-official base image is used.
|
|
|
|
name: brain-of-reese
|
|
|
|
services:
|
|
db:
|
|
build:
|
|
context: ./db
|
|
image: brain-of-reese/db:pg17-vector
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_USER: reese
|
|
POSTGRES_PASSWORD: reese
|
|
POSTGRES_DB: brain_of_reese
|
|
ports:
|
|
- "5432:5432"
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U reese -d brain_of_reese"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 12
|
|
|
|
app:
|
|
build:
|
|
context: .
|
|
image: brain-of-reese/app:latest
|
|
restart: unless-stopped
|
|
profiles: ["prod"]
|
|
depends_on:
|
|
db:
|
|
condition: service_healthy
|
|
environment:
|
|
BOR_ENVIRONMENT: production
|
|
BOR_DATABASE_URL: postgresql+psycopg://reese:reese@db:5432/brain_of_reese
|
|
BOR_LLM_BASE_URL: https://aipi.reeseapps.com/v1
|
|
# BOR_LLM_API_KEY: provide via shell env or your own env file — never commit it
|
|
ports:
|
|
- "8000:8000"
|
|
|
|
volumes:
|
|
pgdata:
|