name: publish-webx-metrics on: push: branches: [ main ] workflow_dispatch: schedule: - cron: '*/30 * * * *' # every 30 minutes (adjust) jobs: publish: runs-on: ubuntu-latest permissions: contents: read steps: - uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v5 with: python-version: '3.11' - name: Install run: | python -m pip install --upgrade pip # Use your pinned requirements; adjust if needed if [ -f requirements/dev.txt ]; then pip install -r requirements/dev.txt; fi if [ -f requirements.txt ]; then pip install -r requirements.txt; fi - name: Run OME-1 (or your chosen experiment) run: | # Prefer your Makefile targets if present if [ -f Makefile ]; then make ome1 else python experiments/autopoiesis_ab_test/run_experiment.py --config config.yaml --output results/ fi - name: Build metrics.json run: | python scripts/generate_metrics_payload.py \ --receipt receipt_ome1.json \ --out metrics.json \ --source-repo matverse-acoa/core \ --source-commit ${{ github.sha }} - name: Install HF CLI run: | curl -LsSf https://hf.co/cli/install.sh | bash - name: Upload to HF dataset env: HF_TOKEN: ${{ secrets.HF_TOKEN }} run: | hf auth login --token "$HF_TOKEN" --add-to-git-credential hf upload MatverseHub/WebX metrics.json --repo-type=dataset --path metrics/metrics.json