-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathjustfile
More file actions
94 lines (70 loc) · 2.78 KB
/
Copy pathjustfile
File metadata and controls
94 lines (70 loc) · 2.78 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
86
87
88
89
90
91
92
93
94
# Hinbox task runner
# Run `just` or `just --list` to see available commands.
set dotenv-load
# Default: show available recipes
default:
@just --list
# ─── Processing ───────────────────────────────────────
# Process articles and extract entities
process *args:
uv run python -m src.process_and_extract {{args}}
# Process articles for a specific domain
process-domain domain *args:
uv run python -m src.process_and_extract --domain {{domain}} {{args}}
# Quick: process one article with verbose output
test-run:
uv run python -m src.process_and_extract --limit 1 -v --force
# ─── Web Interface ────────────────────────────────────
# Start the web interface (http://localhost:5001)
frontend:
@echo "Open http://localhost:5001 in your browser"
uv run python -m src.frontend
alias web := frontend
alias ui := frontend
# ─── Data Management ──────────────────────────────────
# Check article database statistics
check *args:
uv run python scripts/check_articles_parquet.py {{args}}
alias stats := check
# Reset processing status of all articles
reset:
#!/usr/bin/env bash
read -p "This will reset ALL articles. Are you sure? (y/N): " response
if [[ "$response" == [yY] ]]; then
uv run python scripts/reset_processing_status.py
else
echo "Reset cancelled."
fi
# Fetch Miami Herald articles
fetch-miami:
uv run python scripts/get_miami_herald_articles.py
# Import Miami Herald articles from JSONL
import-miami:
uv run python scripts/import_miami_herald_articles.py
# ─── Domain Management ────────────────────────────────
# Initialize a new domain configuration
init domain:
uv run python scripts/init_domain.py {{domain}}
# List available domain configurations
domains:
uv run python scripts/list_domains.py
# ─── Code Quality ─────────────────────────────────────
# Format code (ruff fix + format)
format:
uv run ruff check . --select F401,F841 --fix --exclude "__init__.py" --isolated
uv run ruff check . --select I --fix --ignore D
uv run ruff format .
# Lint code (ruff check + format verification)
lint:
uv run ruff check .
uv run ruff format --check .
# Run tests
test *args:
uv run pytest tests/ -v {{args}}
# Run CI-equivalent checks (what GitHub Actions runs on PRs)
ci:
uv run ruff check .
uv run ruff format --check .
uv run pytest tests/ -v -m "not asyncio" --tb=short
# Format then lint
check-code: format lint