Files
tobayah 5bcb5871b3 feat: scaffold Compass AI-native foundation (Sprint 0+1)
Sprint 0 — .claude/ and project memory:
- ADR-001 AI-native mandates (8 rules: agent-first, schema-first, streaming, eval-driven, cost-aware routing, cache-aware, async-first, observable)
- 3 project skills: compass-architecture (12-pt self-check), compass-clause-taxonomy (13-pt), compass-ai-native-mandates (8-pt)
- CLAUDE.md (project identity, 5 moats, stack, skill priority, security invariants, license PRIVATE, Bridgestone IP risk)
- AGENTS.md (8-subagent topology spec with model + tools + parallelizable + routing)
- .claude/settings.json (permissions + hooks placeholders)

Sprint 1 — monorepo, Python skeleton, hooks:
- Disconnected Lovable: removed lovable-tagger from package.json + vite.config.ts; rewrote README to Compass-focused
- npm workspaces root + apps/web/ (existing frontend moved intact; vite/tailwind/tsconfig paths still relative to apps/web/)
- uv workspace root (12 members): apps/{api,workers,mcp-server} + packages/{core,schemas,prompts,agents,llm-gateway,retrieval,ingestion,evals,jurisdictions}
- apps/api: FastAPI app with /health, /ready, / endpoints + structlog lifespan (smoke-tested: 200 OK + JSON)
- apps/workers: Celery configured (Redis broker, no tasks yet)
- packages/core: auth (User), tenant context, audit log, SSE events, confidence classifier (all stubs except confidence which is functional)
- packages/llm-gateway: working LLMRouter with select_model() per ADR-001 M5 + Langfuse trace wrapper + GatewayRejected if tenant_id/operation missing (M5+M8 enforcement at gateway)
- 6 subagent definitions in .claude/agents/: doc-parser, clause-extractor, clause-reviewer, jurisdiction-checker, rls-auditor, test-writer
- 5 hook scripts in scripts/hooks/: check_destructive_sql, check_secrets_stage, check_git_identity (Bridgestone domain block), format_file (ruff/prettier router), warn_sensitive_paths (prompts/migrations reminders)
- .claude/settings.json hooks block activated (PreToolUse Bash + PowerShell, PostToolUse Edit/Write)
- .env.example template + extended .gitignore (Python, .venv, .uv, secrets, eval results, Hetzner state)

Smoke tests passed:
- npm install (371 packages, no lovable-tagger)
- uv sync --all-packages (297 packages including FastAPI, Celery, LiteLLM, Langfuse, Voyage)
- compass imports: confidence + schemas + jurisdictions + llm-gateway all green
- npm run build (3894 modules transformed, 27s, dist 1.5MB)
- uvicorn serving /health 200 + /ready 200 + / 200 + /docs Swagger UI

Refs: docs/architecture/ADR-001-ai-native.md, docs/handoffs/2026-05-17-sprint0-handoff.md
2026-05-17 15:24:20 +02:00

20 lines
510 B
JSON

{
"name": "compass-contract-hub",
"private": true,
"version": "0.1.0",
"description": "Compass — open-core legal-tech contract management (monorepo root). PRIVATE.",
"workspaces": [
"apps/web"
],
"scripts": {
"dev": "npm run dev --workspace=@compass/web",
"build": "npm run build --workspace=@compass/web",
"lint": "npm run lint --workspace=@compass/web",
"preview": "npm run preview --workspace=@compass/web"
},
"engines": {
"node": ">=20",
"npm": ">=10"
}
}