-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
85 lines (58 loc) · 3.08 KB
/
Makefile
File metadata and controls
85 lines (58 loc) · 3.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
.PHONY: run test contract lint format typecheck precommit-install precommit-run up down seed-lexicon apply-migrations test-db release-list release-create release-ingest release-activate release-deprecate release-validate release-audit benchmark-hot-path worker-once eval-language connector-ingest verify-tier2-wave1 go-live-check
LIMIT ?= 20
ITERATIONS ?= 300
WARMUP ?= 30
P95_BUDGET_MS ?= 150
BUNDLE_DIR ?= templates/go-live
run:
python -m uvicorn sentinel_api.main:app --reload
test:
python -m pytest -q
contract:
python scripts/check_contract.py
lint:
python -m ruff check src scripts tests
format:
python -m ruff format src scripts tests
typecheck:
python -m pyright
precommit-install:
python -m pre_commit install
precommit-run:
python -m pre_commit run --all-files
up:
docker compose up --build
down:
docker compose down -v
seed-lexicon:
python scripts/sync_lexicon_seed.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel --activate-if-none
apply-migrations:
python scripts/apply_migrations.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel
test-db:
SENTINEL_INTEGRATION_DB_URL=postgresql://sentinel:sentinel@localhost:5432/sentinel python -m pytest -q tests/test_lexicon_postgres_integration.py
release-list:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel list
release-create:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel create --version "$(VERSION)"
release-ingest:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel ingest --version "$(VERSION)" --input-path "$(INPUT)"
release-activate:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel activate --version "$(VERSION)"
release-deprecate:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel deprecate --version "$(VERSION)"
release-validate:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel validate --version "$(VERSION)"
release-audit:
python scripts/manage_lexicon_release.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel audit --limit "$(LIMIT)"
benchmark-hot-path:
python scripts/benchmark_hot_path.py --iterations "$(ITERATIONS)" --warmup "$(WARMUP)" --p95-budget-ms "$(P95_BUDGET_MS)"
worker-once:
python scripts/run_async_worker.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel --max-items 20
eval-language:
python scripts/evaluate_language_packs.py --input-path "$(INPUT)" --pretty
connector-ingest:
python scripts/run_partner_connector_ingest.py --database-url postgresql://sentinel:sentinel@localhost:5432/sentinel --connector-name "$(CONNECTOR)" --input-path "$(INPUT)"
verify-tier2-wave1:
python scripts/verify_tier2_wave1.py --registry-path data/langpacks/registry.json --pretty
go-live-check:
python scripts/check_go_live_readiness.py --bundle-dir "$(BUNDLE_DIR)"