Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,22 @@ venv/
node_modules/
dist/
build/

# Next.js (frontend/)
frontend/.next/
frontend/next-env.d.ts
frontend/out/
frontend/.turbo/
frontend/tsconfig.tsbuildinfo
frontend/*.tsbuildinfo

# Editor / OS
*.swp
*.swo
.idea/
.vscode/
Thumbs.db

backend/data/*.json
backend/data/*.db
backend/data/*.db-shm
Expand All @@ -28,6 +44,3 @@ backend/data/qc_graph_exploration.zip
backend/logs/
repomix-output.xml
docs/review_bundles/*.patch
frontend/*.tsbuildinfo
frontend/vite.config.js
frontend/vite.config.d.ts
8 changes: 4 additions & 4 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ make dev-frontend

Default frontend URL:

- `http://127.0.0.1:5173`
- `http://127.0.0.1:3002`

The Makefile points the frontend at `http://127.0.0.1:8010` by default.

Expand Down Expand Up @@ -105,7 +105,7 @@ FRONTEND_API_BASE_URL=http://127.0.0.1:8000 make dev-frontend
The frontend can also be configured directly with:

```bash
VITE_API_BASE_URL=http://127.0.0.1:8010 npm run dev
SPEECHCRAFT_BACKEND_URL=http://127.0.0.1:8010 bun run dev
```

## ASR Configuration
Expand Down Expand Up @@ -176,7 +176,7 @@ uv run python -m unittest discover -s tests -p 'test_*.py'

```bash
cd frontend
npm run build
bun run build
```

Smoke test against a running backend:
Expand All @@ -197,7 +197,7 @@ Expected local files/directories:

- `backend/.venv/`
- `frontend/node_modules/`
- `frontend/dist/`
- `frontend/.next/`
- `backend/data/project.db`
- `backend/data/media/`
- `backend/exports/`
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ help:
@printf " make dev-backend Run the FastAPI API and ProcessingJob worker\n"
@printf " make dev-api Run only the FastAPI API with reload\n"
@printf " make dev-worker Run only the ProcessingJob worker\n"
@printf " make dev-frontend Run the Vite frontend dev server\n"
@printf " make dev-frontend Run the Next.js frontend dev server (http://127.0.0.1:3002)\n"
@printf " make check Run backend and frontend verification\n"
@printf " make check-backend Compile-check backend Python code\n"
@printf " make check-frontend Build the frontend production bundle\n"
Expand All @@ -44,7 +44,7 @@ setup-backend:
cd $(BACKEND_DIR) && UV_CACHE_DIR=$(UV_CACHE_DIR) uv sync

setup-frontend:
cd $(FRONTEND_DIR) && npm install
cd $(FRONTEND_DIR) && bun install

dev-backend:
cd $(BACKEND_DIR) && UV_CACHE_DIR=$(UV_CACHE_DIR) sh -c 'set -e; mkdir -p logs; : > logs/dev-backend.log; (uv run uvicorn app.main:app --reload --host $(BACKEND_HOST) --port $(BACKEND_PORT) 2>&1 | tee -a logs/dev-backend.log) & api_pid=$$!; (uv run python -m app.worker 2>&1 | tee -a logs/dev-backend.log) & worker_pid=$$!; trap "kill $$api_pid $$worker_pid 2>/dev/null || true" INT TERM EXIT; wait'
Expand All @@ -58,7 +58,7 @@ dev-worker:
backend-docs: dev-backend

dev-frontend:
cd $(FRONTEND_DIR) && VITE_API_BASE_URL=$(FRONTEND_API_BASE_URL) npm run dev
cd $(FRONTEND_DIR) && SPEECHCRAFT_BACKEND_URL=$(FRONTEND_API_BASE_URL) bun run dev

check: check-backend check-frontend

Expand All @@ -68,7 +68,7 @@ check-backend:
cd $(WORKER_ROOT) && PYTHONPATH=. $(BACKEND_DIR)/.venv/bin/python tests/test_clip_lab_coordination.py

check-frontend:
cd $(FRONTEND_DIR) && npm run build
cd $(FRONTEND_DIR) && bun run build

smoke-backend:
cd $(BACKEND_DIR) && UV_CACHE_DIR=$(UV_CACHE_DIR) uv run python scripts/smoke_backend.py --base-url $(SMOKE_BACKEND_BASE_URL) --project-id $(SMOKE_BACKEND_PROJECT_ID)
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Export is present in navigation as the downstream handoff stage. The backend has
## Project Layout

- `backend/`: FastAPI API, SQLite persistence, media management, processing worker, slicing/QC/export logic
- `frontend/`: React + Vite UI for the staged workstation
- `frontend/`: Next.js UI — the setup wizard and the Lab workstation.
- `docs/`: product, workflow, and implementation notes

## Core Docs
Expand Down Expand Up @@ -104,11 +104,11 @@ The combined backend/API dev output is also written to `backend/logs/dev-backend

By default the Makefile uses:

- frontend: `http://127.0.0.1:5173`
- frontend: `http://127.0.0.1:3002`
- backend: `http://127.0.0.1:8010`
- backend docs: `http://127.0.0.1:8010/docs`

The frontend API target can be overridden with `VITE_API_BASE_URL`.
The frontend reaches the backend same-origin through the `/sc-api` rewrite (see `frontend/next.config.ts`); override the target with `SPEECHCRAFT_BACKEND_URL`.

## Local State

Expand Down Expand Up @@ -148,7 +148,7 @@ Useful focused checks:
```bash
python3 -m compileall backend/app
cd backend && uv run python -m unittest discover -s tests -p 'test_*.py'
cd frontend && npm run build
cd frontend && bun run build
```

## Current Status
Expand Down
Loading