feat(evals): improve dashboard UX with integrated iterations and tooltips #88
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # GitHub Pages deployment for DuoPulse site with Pattern Evaluation Dashboard | |
| name: Build & Deploy Site | |
| on: | |
| # Run on pushes to main | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'site/**' | |
| - 'tools/evals/**' | |
| - 'src/Engine/**' | |
| - 'tools/pattern_viz.cpp' | |
| - '.github/workflows/pages.yml' | |
| # Run tests on PRs | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - 'site/**' | |
| - 'tools/evals/**' | |
| - 'src/Engine/**' | |
| - 'tools/pattern_viz.cpp' | |
| - '.github/workflows/pages.yml' | |
| # Allow manual trigger | |
| workflow_dispatch: | |
| # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
| permissions: | |
| contents: write | |
| pages: write | |
| id-token: write | |
| # Allow only one concurrent deployment | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| # Run tests first | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| submodules: recursive | |
| - name: Install test dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y build-essential catch2 | |
| - name: Run unit tests | |
| run: make test | |
| # Build and deploy site | |
| build: | |
| runs-on: ubuntu-latest | |
| needs: test | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| submodules: recursive | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Build pattern_viz | |
| run: make pattern-viz | |
| - name: Generate evaluation data | |
| run: make evals-generate | |
| - name: Run evaluations | |
| run: make evals-evaluate | |
| - name: Generate sensitivity matrix | |
| run: make sensitivity-matrix | |
| - name: Extract metrics history | |
| run: make metrics-history | |
| - name: Parse iteration logs | |
| run: node scripts/iterate/parse-iterations.js | |
| - name: Update baseline | |
| if: github.event_name == 'push' || github.event_name == 'workflow_dispatch' | |
| run: | | |
| node scripts/update-baseline.js --metrics=tools/evals/public/data/expressiveness.json | |
| - name: Configure git for tagging | |
| if: github.event_name == 'push' || github.event_name == 'workflow_dispatch' | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| - name: Tag baseline | |
| if: github.event_name == 'push' || github.event_name == 'workflow_dispatch' | |
| run: | | |
| bash scripts/tag-baseline.sh --push | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| # NOTE: baseline.json updates are NOT auto-committed due to branch protection | |
| # on main. Baseline tags are created above. To update baseline.json in the | |
| # repo, manually commit and create a PR. | |
| - name: Assemble site | |
| run: | | |
| # Create build directory | |
| mkdir -p _site | |
| # Copy landing page | |
| cp site/index.html _site/ | |
| cp site/styles.css _site/ | |
| # Copy evals to /evals subdirectory | |
| mkdir -p _site/evals | |
| cp -r tools/evals/public/* _site/evals/ | |
| - name: Setup Pages | |
| uses: actions/configure-pages@v4 | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: '_site' | |
| deploy: | |
| # Only deploy on push to main, not on PRs | |
| if: github.event_name == 'push' || github.event_name == 'workflow_dispatch' | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| needs: build | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |