File size: 1,468 Bytes
d787a09
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
.DEFAULT_GOAL := help
PY ?= python3
PORT ?= 8000

.PHONY: help install demo run test eval ingest fmt docker docker-up clean

help: ## Show this help
	@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | \
	  awk 'BEGIN {FS = ":.*?## "}; {printf "  \033[36m%-12s\033[0m %s\n", $$1, $$2}'

install: ## Install runtime + dev dependencies
	$(PY) -m pip install -r requirements-dev.txt

demo: ## Run the app locally (offline, no keys) -> http://127.0.0.1:8000
	@echo "ParaPilot running at http://127.0.0.1:$(PORT)  (offline stub provider)"
	$(PY) -m uvicorn app.main:app --host 127.0.0.1 --port $(PORT) --reload

run: ## Run the app without auto-reload
	$(PY) -m uvicorn app.main:app --host 127.0.0.1 --port $(PORT)

test: ## Run the test suite (offline)
	PARAPILOT_PROVIDER=stub $(PY) -m pytest -q

eval: ## Run the anti-hallucination eval (grounded vs plain-LLM baseline)
	PARAPILOT_PROVIDER=stub $(PY) -m app.eval.run_eval \
	  --json app/eval/results/latest.json --md app/eval/results/table.md

ingest: ## Refresh the corpus from live IL sources (writes to data/corpus/_fetched/)
	$(PY) -m app.rag.ingest.run_ingest

docker: ## Build the Docker image
	docker build -t parapilot:latest .

docker-up: ## Run via docker-compose -> http://127.0.0.1:8000
	docker compose up --build

clean: ## Remove caches and the local SQLite DB
	rm -rf .pytest_cache **/__pycache__ *.egg-info parapilot.db
	find . -name '__pycache__' -type d -prune -exec rm -rf {} + 2>/dev/null || true