-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
113 lines (91 loc) · 4.28 KB
/
Makefile
File metadata and controls
113 lines (91 loc) · 4.28 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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
# Makefile
.PHONY: help setup test test-ci lint lint-check lint-format lint-fix lint-typing evals tailwind-build tailwind-watch
help:
@echo "Available commands:"
@echo " make setup - Set up local development environment"
@echo " make test - Run tests with coverage report"
@echo " make lint - Run lint check and format check"
@echo " make lint-check - Run lint check only (ruff)"
@echo " make lint-format - Check code formatting"
@echo " make lint-fix - Fix linting and formatting issues"
@echo " make lint-typing - Run type checking with ty"
@echo " make lock - Update uv lock"
@echo " make integration-tests - Run integration tests"
setup:
@if [ ! -f docker/local/app/config.secrets.env ]; then \
cp docker/local/app/config.secrets.env.example docker/local/app/config.secrets.env && \
echo "Created docker/local/app/config.secrets.env from template."; \
else \
echo "docker/local/app/config.secrets.env already exists, skipping."; \
fi
@if [ ! -f docker/local/gitlab-runner/config.toml ]; then \
cp docker/local/gitlab-runner/config.toml.example docker/local/gitlab-runner/config.toml && \
echo "Created docker/local/gitlab-runner/config.toml from template."; \
else \
echo "docker/local/gitlab-runner/config.toml already exists, skipping."; \
fi
@echo ""
@echo "Next steps:"
@echo " 1. Edit docker/local/app/config.secrets.env and add your API keys"
@echo " (at minimum: one LLM provider key + CODEBASE_GITLAB_AUTH_TOKEN if using GitLab)"
@echo " 2. Start core services: docker compose up --build"
@echo " 3. Optional services:"
@echo " docker compose --profile gitlab up # local GitLab instance"
@echo " docker compose --profile sandbox up # sandbox code executor"
@echo " docker compose --profile mcp up # MCP proxy"
@echo " docker compose --profile full up # all services"
test:
LANGCHAIN_TRACING_V2=false uv run pytest -s tests/unit_tests
lint: lint-check lint-format
lint-check:
uv run --only-group=dev ruff check .
lint-format:
uv run --only-group=dev ruff format . --check
uv run --only-group=dev pyproject-fmt pyproject.toml --check
lint-fix:
uv run --only-group=dev ruff check . --fix
uv run --only-group=dev ruff format .
uv run --only-group=dev pyproject-fmt pyproject.toml
lint-typing:
uv run --only-group=dev ty check daiv
makemessages:
uv run django-admin makemessages --ignore=*/node_modules/* --ignore=.venv --no-location --no-wrap --all
compilemessages:
uv run django-admin compilemessages
integration-tests:
uv run pytest --reuse-db tests/integration_tests --no-cov --log-level=INFO -m diff_to_metadata
swebench:
uv run evals/swebench.py --dataset-path "princeton-nlp/SWE-bench_Verified" --dataset-split "test" --output-path swebench-predictions.json --num-samples 10
swebench-evaluate: swebench-clean
mkdir -p /tmp/swebench
git clone https://github.com/SWE-bench/SWE-bench /tmp/swebench
cd /tmp/swebench; uv venv --python 3.11; uv pip install -e .; uv run -m swebench.harness.run_evaluation \
--dataset_name princeton-nlp/SWE-bench_Verified \
--split dev \
--max_workers 4 \
--predictions_path /tmp/predictions.json \
--run_id 1
swebench-clean:
rm -rf /tmp/swebench
swerebench:
uv run evals/swebench.py --dataset-path "nebius/SWE-rebench-leaderboard" --dataset-split "2026_01" --output-path swerebench-predictions.json --num-samples 1
swerebench-evaluate: swerebench-clean
mkdir -p /tmp/swerebench
git clone https://github.com/SWE-rebench/SWE-bench-fork /tmp/swerebench
cd /tmp/swerebench; uv venv --python 3.11; uv pip install -e .; uv run -m swebench.harness.run_evaluation \
--dataset_name nebius/SWE-rebench-leaderboard \
--split 2026_01 \
--max_workers 4 \
--predictions_path /tmp/predictions.json \
--namespace "swerebench" \
--run_id 1
swerebench-clean:
rm -rf /tmp/swerebench
docs-serve:
uv run --only-group=docs mkdocs serve -o -a localhost:4000 -w docs/
tailwind-build:
docker compose exec app tailwindcss -i daiv/static_src/css/input.css -o daiv/static/css/styles.css --minify
tailwind-watch:
docker compose exec app tailwindcss -i daiv/static_src/css/input.css -o daiv/static/css/styles.css --watch
langsmith-fetch:
uv run langsmith-fetch traces --project-uuid 00d1a04e-0087-4813-9a18-5995cd5bee5c --limit 1 ./daiv-traces