Repository navigation
Expand file tree
/
Copy pathmise.toml
More file actions
134 lines (115 loc) · 3.8 KB
/
Copy pathmise.toml
File metadata and controls
134 lines (115 loc) · 3.8 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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
[tools]
python = "3.12"
go = "1.26.2"
"go:golang.org/x/tools/gopls" = "0.23.0"
uv = "0.11"
oapi-codegen = "2.7.0"
[tasks.test]
description = "Goのraceテスト・静的検査とworkerのテストを実行する"
depends = ["test-go", "test-worker"]
[tasks.test-go]
description = "Goの全パッケージのraceテストとgo vetを実行する"
dir = "server"
run = ["go test -race ./...", "go vet ./..."]
[tasks.test-worker]
description = "workerのテストを実行する"
run = "uv run --no-sync --project worker python -m unittest discover -s worker/tests"
[tasks.gogen]
description = "Goファイルの生成を実行"
dir = "server"
run = [
"go generate ./...",
"oapi-codegen -config ./api/oapi.model.config.yaml ../openapi.yaml",
"oapi-codegen -config ./api/oapi.interface.config.yaml ../openapi.yaml",
]
[tasks.download-qwen3-vl-embedding]
description = "Qwen3-VL-Embedding wrapperを upstream から取得"
run = [
"mkdir -p worker/scripts",
"curl -fsSL https://raw.githubusercontent.com/QwenLM/Qwen3-VL-Embedding/main/src/models/qwen3_vl_embedding.py -o worker/scripts/qwen3_vl_embedding.py",
]
[tasks.up]
description = "docker compose up --build"
run = "docker compose up --build"
[tasks.down]
description = "docker compose down"
run = "docker compose down"
[tasks.deploy-up]
description = "本番環境をCloudflare Tunnel込みでバックグラウンド起動する"
run = "docker compose --profile tunnel up -d --build"
[tasks.deploy-down]
description = "本番環境(Cloudflare Tunnelを含む)を停止する"
run = "docker compose --profile tunnel down"
[tasks.deploy-ps]
description = "本番環境のコンテナ状態を確認する"
run = "docker compose --profile tunnel ps"
[tasks.deploy-logs]
description = "APIとCloudflare Tunnelのログを表示する"
run = "docker compose --profile tunnel logs --tail=100 api cloudflared"
[tasks.dev-up]
description = "開発環境のコンテナをwatch付きで立ち上げる"
run = "docker compose -f development/compose.yaml up --build --watch"
[tasks.dev-down]
description = "開発環境のコンテナを削除する"
run = "docker compose -f development/compose.yaml down"
[tasks.modal-secret]
description = "deploy/modal/.env を Modal Secret に登録する"
run = """
uv run \
--project worker \
--extra deploy \
modal secret create \
--force embedding-worker \
--from-dotenv deploy/modal/.env
"""
[tasks.modal-run]
description = "Modal worker を手動で1回実行する"
run = """
set -a
. ./deploy/modal/.env
set +a
uv run \
--project worker \
--extra deploy \
modal run worker/modal_app.py
"""
[tasks.modal-deploy-push]
description = "Modal worker を push 起動(run_batch)付きでデプロイする"
run = """
set -a
. ./deploy/modal/.env
set +a
uv run \
--project worker \
--extra deploy \
modal deploy worker/modal_app.py
"""
[tasks.fetch-traq-samples]
description = "traQ messageId からベンチ用画像を fixtures に取得する"
run = """
uv run \
--with requests \
python benchmark/fetch_traq_samples.py
"""
[tasks.modal-cost-bench]
description = "Modal で fixtures 画像の起動込みコスト・時間を測る (A10/T4)"
dir = "."
run = """
uv run \
--project worker \
--extra deploy \
modal run worker/modal_bench_app.py --gpus ${BENCH_GPUS:-A10,T4}
"""
[tasks.benchmark-text]
description = "テキストのみの Embedding API レイテンシを計測する"
run = """
uv run \
--project worker \
--with requests \
python benchmark/benchmark_query_uncached.py \
--api-base-url ${EMBEDDING_API_BASE_URL:-http://localhost:8080} \
--query-count ${QUERY_COUNT:-5} \
--timeout ${EMBEDDING_REQUEST_TIMEOUT_SEC:-0} \
--output ${OUTPUT:-benchmark/benchmark-text-results.jsonl} \
--html-report ${HTML_REPORT:-benchmark/benchmark-report-1024.html}
"""