Build stage-one evidence extractor MVP
CI / test (push) Failing after 11m13s

This commit is contained in:
2026-10-01 22:16:29 +08:00
commit d30892168e
26 changed files with 2250 additions and 0 deletions
+28
View File
@@ -0,0 +1,28 @@
name: CI
on:
push:
pull_request:
jobs:
test:
runs-on: ces-ci
env:
CUDA_VISIBLE_DEVICES: ""
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v6
with:
enable-cache: true
- name: Reuse runner PyTorch and install lightweight dependencies
run: |
uv venv --system-site-packages --python python .venv-ci
uv pip install --python .venv-ci/bin/python numpy pillow pyyaml scipy pytest ruff
- name: Lint
run: .venv-ci/bin/ruff check .
- name: Unit tests
run: .venv-ci/bin/pytest
- name: End-to-end CPU smoke test
run: |
.venv-ci/bin/python -m data.build_splits --config configs/mvp.yaml --small
.venv-ci/bin/python train_extractor.py --config configs/mvp.yaml --backbone tiny --epochs 1
+27
View File
@@ -0,0 +1,27 @@
name: GPU smoke
on:
workflow_dispatch:
jobs:
extractor:
runs-on: gpu
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v6
with:
enable-cache: true
- name: Verify CUDA
run: nvidia-smi
- name: Reuse runner PyTorch and install lightweight dependencies
run: |
uv venv --system-site-packages --python python .venv-gpu
uv pip install --python .venv-gpu/bin/python numpy pillow pyyaml scipy transformers pytest ruff
- name: Verify PyTorch sees the GPU
run: |
.venv-gpu/bin/python -c "import torch; assert torch.cuda.is_available(); print(torch.__version__, torch.version.cuda, torch.cuda.get_device_name(), torch.cuda.get_device_capability())"
- name: Build smoke dataset
run: .venv-gpu/bin/python -m data.build_splits --config configs/mvp.yaml --small
- name: Train extractor
run: .venv-gpu/bin/python train_extractor.py --config configs/mvp.yaml --backbone clip --epochs 1