Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
36022ee
Import the frontend into the repo
Pranav-Mathad Oct 17, 2026
2c96b6c
Add MIT license and editorconfig
Pranav-Mathad Oct 17, 2026
0a6a940
Drop bun lockfile and rename frontend package
Pranav-Mathad Oct 17, 2026
e2f246e
Remove unused frontend scaffold files
Pranav-Mathad Oct 17, 2026
a37f976
Remove unused shadcn components
Pranav-Mathad Oct 17, 2026
db207be
Drop next-themes and lovable-tagger
Pranav-Mathad Oct 17, 2026
223f841
Stop committing env files
Pranav-Mathad Oct 17, 2026
32ea2c7
Move mock ERP to tools and make its poller opt-in
Pranav-Mathad Oct 17, 2026
69afe88
Delete one-off extractor check script
Pranav-Mathad Oct 17, 2026
8f09f58
Replace hero_backfill with scripts.backfill
Pranav-Mathad Oct 17, 2026
23ce604
Point dev.sh at the in-repo frontend
Pranav-Mathad Oct 17, 2026
5e10e11
Use a fictional street address
Pranav-Mathad Oct 17, 2026
4b1b159
Pseudonymise names in the eval emails
Pranav-Mathad Oct 17, 2026
02445d1
Scrub real IBANs, names and emails from fixtures
Pranav-Mathad Oct 17, 2026
422c621
Move docs and eval reports under docs/
Pranav-Mathad Oct 17, 2026
adac897
Run the pipeline integration test in the full suite
Pranav-Mathad Oct 17, 2026
1678b55
Clean up test rows in the database
Pranav-Mathad Oct 17, 2026
51e674e
Fix onboarding test assertion
Pranav-Mathad Oct 17, 2026
3b037cf
Don't re-raise signals after approval or rejection
Pranav-Mathad Oct 17, 2026
4a23192
Accept raw_content in trigger_event
Pranav-Mathad Oct 17, 2026
60bbff9
Read CORS origins from KEYSTONE_CORS_ORIGINS only
Pranav-Mathad Oct 17, 2026
f03beb1
Add ARCHITECTURE.md, retire KEYSTONE.md
Pranav-Mathad Oct 17, 2026
72930d2
Remove DEMO_QA.md
Pranav-Mathad Oct 17, 2026
d8aa22e
Rewrite DECISIONS.md as an ADR log
Pranav-Mathad Oct 17, 2026
55f6354
Add EVALUATION.md and a rule-based eval run
Pranav-Mathad Oct 17, 2026
178eab7
Add PROJECT_FACTS.md
Pranav-Mathad Oct 17, 2026
0c2cfbc
Declare the MCP SDK dependency and add server tests
Pranav-Mathad Oct 17, 2026
7c28418
Add MCP tests to PROJECT_FACTS
Pranav-Mathad Oct 17, 2026
b45ab2b
Rewrite the README
Pranav-Mathad Oct 17, 2026
51e50fe
Replace the frontend scaffold README
Pranav-Mathad Oct 17, 2026
69a21fd
Remove the frontend audit doc
Pranav-Mathad Oct 17, 2026
2c775f5
Remove security badge and unused Gradium key
Pranav-Mathad Oct 17, 2026
e857ad3
Replace the Entire broker with an ApprovalBroker protocol
Pranav-Mathad Oct 17, 2026
55d30a6
Rename approval rate module to approval_stats
Pranav-Mathad Oct 17, 2026
ec0d435
Delete empty late_payment rule
Pranav-Mathad Oct 17, 2026
3b7adb9
Remove web enrichment and the regulation watcher
Pranav-Mathad Oct 18, 2026
5c8300e
Put Gemini and Pioneer behind one LLMProvider interface
Pranav-Mathad Oct 18, 2026
3df6e16
Run Ask, drafting and semantic check on any provider
Pranav-Mathad Oct 18, 2026
af67159
Drop pgvector, run on plain Postgres 16
Pranav-Mathad Oct 18, 2026
4e581cd
Replace hardcoded hero UUID with FEATURED_PROPERTY setting
Pranav-Mathad Oct 18, 2026
d16a192
Run every test suite by default
Pranav-Mathad Oct 18, 2026
4fa2556
Fix ruff lint findings
Pranav-Mathad Oct 18, 2026
8f8c87b
Apply ruff format
Pranav-Mathad Oct 18, 2026
a720e4a
Wrap long lines
Pranav-Mathad Oct 18, 2026
4eb5514
Make mypy --strict pass
Pranav-Mathad Oct 18, 2026
8597ee5
Multi-stage backend image with a non-root user
Pranav-Mathad Oct 18, 2026
4041414
Stop scheduler log spam when pollers are off
Pranav-Mathad Oct 18, 2026
44ef269
Run the whole stack with docker compose
Pranav-Mathad Oct 18, 2026
b29fa0c
Document how the stack runs and the scheduled jobs
Pranav-Mathad Oct 18, 2026
2728283
Clean up comments and docstrings
Pranav-Mathad Oct 18, 2026
24db24a
Drop phase references from strings and test names
Pranav-Mathad Oct 18, 2026
c893b4b
Update PROJECT_FACTS after backend cleanup
Pranav-Mathad Oct 18, 2026
0e89f14
Enable strict TypeScript and add typecheck script
Pranav-Mathad Oct 18, 2026
ac07784
Fix ESLint issues and fail on warnings
Pranav-Mathad Oct 18, 2026
f48d656
Typed API client with required VITE_API_BASE_URL
Pranav-Mathad Oct 18, 2026
f833f80
Add query hooks for every resource, drop fixtures
Pranav-Mathad Oct 18, 2026
0ecdad7
Approve and reject signals from the inbox
Pranav-Mathad Oct 18, 2026
b86bbf4
Remove event branding and fake progress indicator
Pranav-Mathad Oct 18, 2026
1514fe7
Add frontend tests
Pranav-Mathad Oct 18, 2026
4fccdf2
Add frontend numbers to PROJECT_FACTS
Pranav-Mathad Oct 18, 2026
fdb5cb7
Don't duplicate activity entries on reprocess
Pranav-Mathad Oct 18, 2026
58b753b
Split the worker into named steps
Pranav-Mathad Oct 18, 2026
6051701
Split the admin router per resource
Pranav-Mathad Oct 18, 2026
5ff4844
Split the properties router per resource
Pranav-Mathad Oct 18, 2026
ec10c07
Refuse to reset non-test cost ledger labels
Pranav-Mathad Oct 18, 2026
ca3a9dd
Enforce one pending signal per natural key
Pranav-Mathad Oct 18, 2026
dcec1e7
Split PropertyDetail into components and hooks
Pranav-Mathad Oct 18, 2026
9e25de4
Drop asyncio mark from sync eval tests
Pranav-Mathad Oct 18, 2026
c5d1066
Add prettier
Pranav-Mathad Oct 18, 2026
4ac279e
Format frontend with prettier
Pranav-Mathad Oct 18, 2026
fa4e0aa
Add sensitive data check script
Pranav-Mathad Oct 18, 2026
132aed3
Add pre-commit hooks
Pranav-Mathad Oct 18, 2026
3762a33
Add history rewrite helper script
Pranav-Mathad Oct 18, 2026
dbc55c2
Add GitHub Actions for backend and frontend
Pranav-Mathad Oct 18, 2026
2ee5e7d
Add release checklist
Pranav-Mathad Oct 18, 2026
5a29789
Document checks, tooling and scheduler limitation
Pranav-Mathad Oct 18, 2026
8c8d23f
Replace em-dashes in frontend copy
Pranav-Mathad Oct 18, 2026
776b2bf
Update PROJECT_FACTS
Pranav-Mathad Oct 18, 2026
27783f5
Hide screenshot table until images exist
Pranav-Mathad Oct 18, 2026
8cc6ba1
Fix activity ticker deployment message
Pranav-Mathad Oct 19, 2026
69a2219
Show a missing key message in Ask
Pranav-Mathad Oct 19, 2026
04c9080
Report how the briefing was produced
Pranav-Mathad Oct 19, 2026
53b2011
Fix missing key message and button wrap on Drafts
Pranav-Mathad Oct 19, 2026
4d3c3c5
Add screenshots to README
Pranav-Mathad Oct 19, 2026
fbed2fd
Update PROJECT_FACTS
Pranav-Mathad Oct 19, 2026
a740dd6
Seed the featured property with history on first start
Pranav-Mathad Oct 19, 2026
ca56dbd
Replace em-dashes in backend code and data
Pranav-Mathad Oct 19, 2026
114f2d1
Replace em-dashes in eval run reports
Pranav-Mathad Oct 19, 2026
42fea81
Retake README screenshots
Pranav-Mathad Oct 19, 2026
7e16b06
Update PROJECT_FACTS
Pranav-Mathad Oct 19, 2026
20f38c8
Count reported incidents in maintenance rules
Pranav-Mathad Oct 19, 2026
b3438df
Retake README screenshots
Pranav-Mathad Oct 19, 2026
90e7326
Update PROJECT_FACTS
Pranav-Mathad Oct 19, 2026
3a09a8a
fix(renderer): label master data in English property files
Pranav-Mathad Oct 20, 2026
51fa301
feat(frontend): new icons, page metadata and optional repo and previe…
Pranav-Mathad Oct 20, 2026
504523f
feat(frontend): design tokens and shared UI primitives
Pranav-Mathad Oct 20, 2026
5178886
feat(frontend): replace the Compare page with inbox Search
Pranav-Mathad Oct 20, 2026
b02577a
feat(frontend): redesigned header with a mobile menu and repo link
Pranav-Mathad Oct 20, 2026
4cdd74a
feat(frontend): portfolio stats in place of the activity ticker
Pranav-Mathad Oct 20, 2026
fd3035c
feat(frontend): restyle the inbox
Pranav-Mathad Oct 20, 2026
ee129e9
feat(frontend): start reply drafts from the property's recent messages
Pranav-Mathad Oct 20, 2026
f42bde5
feat(frontend): restyle the property page, Ask panel and modals
Pranav-Mathad Oct 20, 2026
baccfa5
feat(frontend): branded not-found page
Pranav-Mathad Oct 20, 2026
a173748
docs(frontend): describe Search, the new primitives and optional env …
Pranav-Mathad Oct 20, 2026
c73cf4a
docs: rewrite the README and refresh the screenshots
Pranav-Mathad Oct 20, 2026
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
20 changes: 20 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Keep the backend build context to what the image needs.
.git
.venv
venv
**/__pycache__
**/*.pyc
.pytest_cache
.mypy_cache
.ruff_cache
.env
.env.*
!.env.example
Extracted
frontend
docs
eval
tools
**/tests
conftest.py
*.log
18 changes: 18 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 4

[*.{ts,tsx,js,jsx,json,yml,yaml,css,html}]
indent_size = 2

[*.md]
trim_trailing_whitespace = false

[Makefile]
indent_style = tab
42 changes: 21 additions & 21 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,15 @@ DATABASE_URL=postgresql+asyncpg://keystone:keystone@localhost:5433/keystone
# Sync variant for scripts / migrations that prefer psycopg2.
DATABASE_URL_SYNC=postgresql://keystone:keystone@localhost:5433/keystone

# --- Google DeepMind (Gemini) ---
GEMINI_API_KEY=replace-me
# --- LLM ---
# Everything runs without a key: extraction falls back to rules and signal
# drafts to templates. LLM_PROVIDER picks the backend: gemini (default) or pioneer.
LLM_PROVIDER=gemini
GEMINI_API_KEY=
GEMINI_FLASH_MODEL=gemini-2.5-flash
GEMINI_PRO_MODEL=gemini-2.5-pro
GEMINI_EMBED_MODEL=text-embedding-004

# --- Tavily ---
TAVILY_API_KEY=replace-me

# --- Entire (approval layer) ---
ENTIRE_API_KEY=replace-me
ENTIRE_BASE_URL=https://api.entire.example

# --- Pioneer / Fastino (learning layer) ---
PIONEER_API_KEY=replace-me

# --- Aikido (security scan badge) ---
AIKIDO_API_KEY=replace-me

# --- Gradium (optional stretch TTS) ---
GRADIUM_API_KEY=replace-me
PIONEER_API_KEY=
PIONEER_MODEL=claude-sonnet-4-6

# --- IMAP (Phase 1 email ingestion) ---
IMAP_HOST=imap.gmail.com
Expand All @@ -42,5 +30,17 @@ IMAP_MAILBOX=INBOX
# --- Slack webhook (Phase 2) ---
SLACK_SIGNING_SECRET=replace-me

# --- Mock ERP (Phase 2) ---
MOCK_ERP_URL=http://localhost:8001
# --- Featured property ---
# The property the UI opens first: a property UUID or any of its aliases.
# FEATURED_PROPERTY=EH-029

# --- Browser access ---
# Comma-separated origins allowed to call the API from a browser. The default
# (when unset) covers local frontends on ports 8080-8082, 5173, 4173 and 3000.
# KEYSTONE_CORS_ORIGINS=http://localhost:8080

# --- ERP payments feed ---
# Leave empty to disable the ERP poller. To try it locally run
# `uvicorn tools.mock_erp.main:app --port 8001` and set this to
# http://localhost:8001.
MOCK_ERP_URL=
85 changes: 85 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
name: CI

on:
push:
branches: [main]
pull_request:

permissions:
contents: read

concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true

jobs:
backend:
name: Backend (lint, types, tests)
runs-on: ubuntu-latest
services:
# The same image docker-compose.yml uses. The test fixtures apply the
# schema and migrations to the empty database themselves.
postgres:
image: postgres:16
env:
POSTGRES_DB: keystone
POSTGRES_USER: keystone
POSTGRES_PASSWORD: keystone
ports:
- 5432:5432
options: >-
--health-cmd "pg_isready -U keystone -d keystone"
--health-interval 3s
--health-timeout 3s
--health-retries 20
env:
DATABASE_URL: postgresql+asyncpg://keystone:keystone@localhost:5432/keystone
DATABASE_URL_SYNC: postgresql://keystone:keystone@localhost:5432/keystone
# No LLM keys: tests that need one, or the private dataset, skip with a
# reason (shown by -rs).
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
cache: pip
cache-dependency-path: pyproject.toml
- name: Install
run: pip install -e ".[dev]"
- name: Ruff
run: |
ruff check .
ruff format --check .
- name: Sensitive data
run: python scripts/check_sensitive_data.py
- name: Mypy
run: mypy
- name: Pytest
run: pytest -rs

frontend:
name: Frontend (lint, types, tests, build)
runs-on: ubuntu-latest
defaults:
run:
working-directory: frontend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
# Matches the build stage in frontend/Dockerfile.
node-version: "20"
cache: npm
cache-dependency-path: frontend/package-lock.json
- name: Install
run: npm ci
- name: Prettier
run: npm run format:check
- name: ESLint
run: npm run lint
- name: Typecheck
run: npm run typecheck
- name: Vitest
run: npm test
- name: Build
run: npm run build
27 changes: 27 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Install once with `pre-commit install`; run on everything with
# `pre-commit run --all-files`. CI runs the same checks (see
# .github/workflows/ci.yml), so a commit that passes here passes there.
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Keep in step with the ruff version installed by `pip install -e ".[dev]"`.
rev: v0.17.1
hooks:
- id: ruff-check
- id: ruff-format

- repo: local
hooks:
- id: prettier
name: prettier (frontend)
# Uses the prettier pinned in frontend/package.json; run `npm ci` in
# frontend/ first.
entry: npm --prefix frontend exec --no -- prettier --write --ignore-unknown --ignore-path frontend/.prettierignore
language: system
files: ^frontend/
pass_filenames: true

- id: sensitive-data
name: no blocked addresses, IBANs or Cloud Run URLs
entry: python scripts/check_sensitive_data.py
language: python
types: [text]
Loading
Loading