Commit Graph

1056 Commits

Author SHA1 Message Date
Vijay Janapa Reddi
fdd90ce139 Stabilize dev pre-commit workflow
Add fallback hook dependencies in validate-dev and apply trailing-whitespace fixes to lab plan files so pre-commit no longer fails on auto-modifications.
2026-03-02 10:22:41 -05:00
Vijay Janapa Reddi
a342170b67 Fix pre-commit fallback dependency install
Install rich in validate-dev pre-commit step so book hooks still run when full requirements install partially fails.
2026-03-02 10:16:09 -05:00
Vijay Janapa Reddi
1052b2be31 Update book workflows for volume-only builds
Switch container/baremetal/validate/preview/live flows to vol1+vol2 artifacts, keep baremetal in dev validation, and add stable single-book navbar link.
2026-03-02 09:45:40 -05:00
Vijay Janapa Reddi
a7f9367e42 Merge dev into feature/book-volumes: CI, contributors, workflows
# Conflicts:
#	README.md
2026-03-02 09:38:47 -05:00
Vijay Janapa Reddi
48b519c42e Merge feature/tinytorch-core into feature/book-volumes
# Conflicts:
#	README.md
#	tinytorch/src/01_tensor/01_tensor.py
#	tinytorch/src/15_quantization/ABOUT.md
2026-03-02 09:38:08 -05:00
Vijay Janapa Reddi
0ae4545bbc Enables multi-project contributor additions
Allows a single `@all-contributors` comment to add or update a contributor across multiple projects simultaneously.

Updates the workflow to:
- Detect multiple projects from explicit mentions in the trigger comment.
- Iterate over all detected projects to update their respective `.all-contributorsrc` files and project `README.md` tables.
- Adapt commit messages and bot replies to reflect multi-project changes.

This improves efficiency for managing contributors in multi-project repositories by reducing repetitive commands.
2026-03-02 09:27:59 -05:00
Vijay Janapa Reddi
8abbf533d8 fix(ci): bump R package cache to fix missing ggrepel on Linux builds
- Add -v2 to cache key to invalidate stale R package cache
- Add ggrepel to verification step to catch missing packages early
- Fixes hw_acceleration.qmd build failure (fig-processor-trends chunk)
2026-03-02 08:49:07 -05:00
Vijay Janapa Reddi
7e6cbc96ca Merge remote-tracking branch 'origin/dev' into dev 2026-03-01 18:43:22 -05:00
Vijay Janapa Reddi
7994f91e0e Merge pull request #1178 from salmanmkc/upgrade-github-actions-node24
Upgrade GitHub Actions for Node 24 compatibility
2026-03-01 11:36:51 -05:00
Vijay Janapa Reddi
a78f5dd893 Merge pull request #1201 from harvard-edge/fix/ch15 and resolve README conflict 2026-02-25 08:27:02 -05:00
Vijay Janapa Reddi
ecb3af7fd2 fix(ci): pull before push in all-contributors workflow; add @salmanmkc to tinytorch and kits
- Add git pull --rebase before push so concurrent comment-triggered runs
  don't reject each other (only one of three runs had succeeded for PR 1179).
- Manually add @salmanmkc as code contributor to tinytorch and kits
  (labs was already added by the single successful run).
2026-02-22 14:05:31 -05:00
Vijay Janapa Reddi
7df97bd1a4 Merge pull request #1179 from salmanmkc/upgrade-github-actions-node24-general
Upgrade GitHub Actions to latest versions
2026-02-22 13:44:58 -05:00
Vijay Janapa Reddi
7a5da798dd fix(ci): extract contributor username via regex instead of LLM
The LLM (llama3.1:8b) was hallucinating usernames — e.g. returning
"pipmea" instead of "pipme". Since the username is always present as
an @mention in the trigger line, extract it deterministically via regex
in Step 1 and only use the LLM to classify contribution types.
2026-02-19 12:05:23 -05:00
Salman Muin Kayser Chishti
07d2751b6a Upgrade GitHub Actions to latest versions
Signed-off-by: Salman Muin Kayser Chishti <13schishti@gmail.com>
2026-02-19 09:20:11 +00:00
Salman Muin Kayser Chishti
4cf7a3aca8 Upgrade GitHub Actions for Node 24 compatibility
Signed-off-by: Salman Muin Kayser Chishti <13schishti@gmail.com>
2026-02-19 09:19:52 +00:00
Vijay Janapa Reddi
53066bf5af feat(site): add version badge to navbar with auto-update on release
Display version number and release date (e.g., "v0.1.8 · Feb 7, 2026")
next to the "Under Construction" badge in the top nav bar. Version and
date are declared as top-of-file constants in wip-banner.js for easy
CI sed updates. Publish workflow now bumps 6 files instead of 5.
2026-02-16 12:43:09 -05:00
Vijay Janapa Reddi
9d840fc1a0 Merge branch 'dev' into feature/book-volumes 2026-02-10 13:12:34 -05:00
Vijay Janapa Reddi
956e7277c8 feat(site): auto-generate team page from .all-contributorsrc
Add generate_team.py script that reads .all-contributorsrc and generates
the team.md page automatically. This keeps the website team page in sync
with the README contributors.

- Add tinytorch/site/scripts/generate_team.py
- Update both deploy workflows to run the script before building
- Contributors added via @all-contributors now appear on the website

The script runs during site build, so team.md stays fresh with each deploy.
2026-02-05 20:25:02 -05:00
Vijay Janapa Reddi
852bc5c2fc fix(ci): download slide decks from release during deployment
Slides were not loading on the live site because the PDFs exist in a
GitHub Release (tinytorch-slides-v0.1.0) but were never downloaded
during the build process. The .gitignore has *.pdf which prevents
slides from being committed to git.

Add a step to both deployment workflows to download all slide PDFs
from the release and inject them into _static/slides/ before deploy.

Fixes harvard-edge/cs249r_book#1162
2026-02-05 15:43:55 -05:00
Vijay Janapa Reddi
3a2b1bf482 fix(ci): use head_ref for PR branch in fresh install test
On PR events, github.ref_name resolves to the merge ref (e.g.
"1159/merge") which doesn't exist on raw.githubusercontent.com,
causing a 404. Use github.head_ref (the actual source branch)
for PRs, falling back to ref_name for push events.

Also adds -f flag to curl so HTTP errors fail immediately with
a clear message instead of silently saving the 404 HTML page.
2026-02-04 10:06:25 -05:00
Vijay Janapa Reddi
0be9325fbe fix(workflow): deterministic project detection in all-contributors
LLM now only parses username + contribution types (strict 2-field JSON).
Project detection is fully deterministic from file paths:
  tinytorch/ → tinytorch, book/ → book, kits/ → kits, labs/ → labs

If project cannot be determined, the bot asks the user instead of
silently defaulting to book. Also removes @AndreaMattiaGaravagno
from book/.all-contributorsrc (was incorrectly added there by the
old workflow — their PR only touched tinytorch/ files).
2026-02-04 10:03:20 -05:00
Vijay Janapa Reddi
83a3ce3712 fix(ci): use pull_request_target for auto-label write permissions
Fork PRs downgrade GITHUB_TOKEN to read-only, causing 403 when
applying labels. pull_request_target runs in the base repo context
and grants the declared write permissions.
2026-02-03 22:08:20 -05:00
Vijay Janapa Reddi
05500f6bc2 refactor(workflow): add site_only option to TinyTorch publish workflow
Instead of a separate workflow, adds a 'site_only' boolean checkbox
to the existing Publish (Live) workflow. When checked:
- Skips version bump (pyproject.toml, badges, installer, announcement)
- Skips PDF generation
- Skips tag creation and GitHub Release

The build & deploy steps still run identically. One workflow, two modes.
Removes the previously added tinytorch-deploy-site-only.yml.
2026-02-03 14:26:14 -05:00
Vijay Janapa Reddi
a143385f86 feat(workflow): add website-only deploy for TinyTorch (no version bump)
Adds a new workflow 'TinyTorch · 🌐 Deploy Site Only' for deploying
website content updates without triggering version bumps, tags, or
releases. Ideal for:
- Typo fixes
- Team page updates
- CSS/styling changes
- Documentation updates

Use 'Publish (Live)' for versioned releases, 'Deploy Site Only' for
quick website-only updates.
2026-02-03 14:22:40 -05:00
Vijay Janapa Reddi
637eea332b refactor(workflows): rename Publish (Dev) to Preview (Dev)
Clearer naming convention:
- Preview (Dev) = deploy to dev preview site (temporary/staging)
- Publish (Live) = deploy to production (permanent/public)

Renamed files:
- tinytorch-publish-dev.yml → tinytorch-preview-dev.yml
- kits-publish-dev.yml → kits-preview-dev.yml
- labs-publish-dev.yml → labs-preview-dev.yml
- book-deploy-preview.yml → book-preview-dev.yml

Updated workflow names to use 👁️ Preview (Dev) icon/naming.
2026-01-29 15:11:01 -05:00
Vijay Janapa Reddi
9e56fc2e2e fix(ci): default to all tests on all platforms + align with CLI naming
- Default test_type: quick → all (run full validation by default)
- Default os: linux → all (test both platforms by default)
- Rename 'release' → 'user-journey' to match CLI --user-journey flag
- Fix 'standard' to correctly stop at stage 5 (was running user-journey)
- Reorder options to show defaults first in dropdown
2026-01-29 12:43:32 -05:00
Vijay Janapa Reddi
08278a8a6b chore(workflows): differentiate Validate and Publish icons
- Change Validate (Dev) icon from 💯 to  for Book and TinyTorch
- Change Update PDFs icon from 📄 to 📑 (bookmark tabs)
- Fix workflow_run references to match exact workflow names

This makes it easier to visually distinguish between Validate and
Publish operations in the GitHub Actions UI.
2026-01-29 07:33:06 -05:00
Vijay Janapa Reddi
9e5ffac705 ci: enable User Journey for 'all' test type (dev/main pushes) 2026-01-28 10:09:10 -05:00
Vijay Janapa Reddi
ede0c5d28e ci: run User Journey on standard test type (dev/main pushes) 2026-01-28 09:48:37 -05:00
Vijay Janapa Reddi
e3ff3f1587 chore: swap Stage 6/7 order - Fresh Install before User Journey 2026-01-28 09:31:49 -05:00
Vijay Janapa Reddi
43010f202d chore: rename Stage 6 from Release to User Journey 2026-01-28 09:30:00 -05:00
Vijay Janapa Reddi
a70c724a02 fix: export failure now blocks progress + add user journey test
Bug Fix:
- Export failures now return early in module complete, preventing
  progress from being updated when export fails. This fixes the issue
  where students could start Module 02 even though tensor.py was
  never exported.

New --user-journey test:
- Simulates exact student flow: module start --no-jupyter → module complete
- Runs milestones at natural unlock checkpoints (not all at end)
- Milestone checkpoints: after modules 03, 08, 09, 13, 19
- Explicit step-by-step output for easy CI debugging

New --no-jupyter flag:
- Added to 'tito module start' for CI/testing
- Creates notebook but skips opening Jupyter

Ref: https://github.com/harvard-edge/cs249r_book/discussions/1147
2026-01-28 09:28:15 -05:00
Vijay Janapa Reddi
c2ecffa772 style(ci): simplify workflow name 2026-01-27 21:18:02 -05:00
Vijay Janapa Reddi
b49615100c feat(ci): add PDF-only update workflow
Allows updating paper and guide PDFs without version bumps or site changes.
2026-01-27 21:16:40 -05:00
Vijay Janapa Reddi
216b70a3ca style(ci): use 100 emoji for dev publish 2026-01-27 10:40:24 -05:00
Vijay Janapa Reddi
f65a85966b style(ci): use check mark for dev publish, rocket for live publish 2026-01-27 10:37:13 -05:00
Vijay Janapa Reddi
1dab173c50 style(ci): use 100 emoji for validate actions 2026-01-27 10:32:04 -05:00
Vijay Janapa Reddi
39324d4176 style(ci): use check mark emoji for validate actions 2026-01-27 10:31:43 -05:00
Vijay Janapa Reddi
0c6fe7c390 style(ci): use rocket emoji for publish actions 2026-01-27 10:26:19 -05:00
Vijay Janapa Reddi
cbf8017a26 style(ci): add action emojis to workflow names for visual scanning
Add separator and action-specific emojis to make it easier to visually
distinguish between workflow types (Build/Publish/Validate) at a glance.

Pattern: Category emoji + Name · Action emoji + Action
- 🔨 Build
- 📤 Publish
- 🔍 Validate
- 🐳 Container
- 🧹 Cleanup
- 🔗 Link Check
- ❤️ Health Check
2026-01-27 10:24:58 -05:00
Vijay Janapa Reddi
5d0ef80aec feat(ci): auto-generate release notes with contributors 2026-01-27 09:02:03 -05:00
Vijay Janapa Reddi
da97497546 Merge branch 'dev' 2026-01-27 08:55:07 -05:00
Vijay Janapa Reddi
2179d07483 fix: improve all-contributors project detection and add config
- Add configuration block at top for easy customization
- Fix project detection to check trigger line first (not just issue context)
- Improve LLM prompt with explicit JSON schema and examples
- Add project aliases support (e.g., 'tito' -> 'tinytorch')
- Fix @ngbolin contribution type (test -> doc)
2026-01-27 08:25:14 -05:00
Vijay Janapa Reddi
827e3b4aac Merge dev: only run validate on dev push 2026-01-26 15:15:06 -05:00
Vijay Janapa Reddi
849ab0befa fix(ci): only run validate workflow on dev push, not main 2026-01-26 15:14:51 -05:00
Vijay Janapa Reddi
450b1db0c9 Merge dev: use windows-2022 for D: drive fix 2026-01-26 15:10:23 -05:00
Vijay Janapa Reddi
dda4326fd3 fix(ci): use windows-2022 to avoid D: drive issue on windows-latest (2025) 2026-01-26 15:10:09 -05:00
Vijay Janapa Reddi
84d46048dc Merge dev: enable debug logging for Windows investigation 2026-01-26 15:02:42 -05:00
Vijay Janapa Reddi
4cc97325a4 debug(ci): enable runner debug logging to investigate Windows D:\a issue 2026-01-26 15:02:28 -05:00
Vijay Janapa Reddi
bb224b7fbc Merge dev: Windows non-blocking CI 2026-01-26 14:50:32 -05:00