Commit Graph

9 Commits

Author SHA1 Message Date
Vijay Janapa Reddi
fe16495652 Fix 'TinyTorch already exists' error in GIF generation
Clean /tmp/TinyTorch before EACH GIF generation, not just once at the start.

VHS executes real commands and captures actual output, so if /tmp/TinyTorch exists from a previous GIF, the git clone will fail with 'already exists' error.

Now each GIF gets a clean environment:
  🧹 Cleaning /tmp/TinyTorch for this GIF...

This ensures GIF 01 shows successful clone on every generation.
2025-11-28 06:20:33 +01:00
Vijay Janapa Reddi
e77d29bb54 Regenerate all demo GIFs with environment activation
All 4 GIFs now properly activate the environment before running tito commands.

Changes:
- GIF 01: Updated with measured timing (9s setup, 3s clone)
- GIF 02: Added 'source activate.sh' before tito module commands
- GIF 03: Added 'source activate.sh' before tito milestones commands
- GIF 04: Added 'source activate.sh' before tito community commands

File sizes:
- 01-zero-to-ready.gif: 467KB → 514KB
- 02-build-test-ship.gif: 200KB → 1.3MB (added activation)
- 03-milestone-unlocked.gif: 87KB → 1.1MB (added activation)
- 04-share-journey.gif: 108KB → 942KB (added activation)

All GIFs now show working commands with proper activation sequence.
2025-11-28 06:18:21 +01:00
Vijay Janapa Reddi
1f5d05c0a6 Add 'source activate.sh' to all demo GIFs that use tito commands
Fixed GIFs 02, 03, and 04 to activate the environment before running tito commands.

Without activation, tito commands fail with 'command not found' error.

Each GIF now starts with:
  Type "source activate.sh"
  Sleep 300ms
  Enter
  Sleep 1s

This ensures tito is available in PATH before any tito commands execute.

GIF 01 already had activation as part of the setup workflow demo.
2025-11-28 06:11:14 +01:00
Vijay Janapa Reddi
aa28976edd Add execution timing measurements for accurate VHS delays
Test script now measures actual execution time for every command using Python's time.time(), outputting recommendations to /tmp/tinytorch_timing.txt.

Measured timings:
- git clone: 3s (varies by network, using safe 3s)
- setup-environment.sh: 9s (measured 8.6s)
- tito system health: 0.5s (show for 3s for readability)
- tito module status: 0.2s (show for 3s)
- tito logo: 0.1s (show for 6s)

Updated 01-zero-to-ready.tape with measured delays to ensure:
- GIF shows actual command completion
- No typing ahead before previous command finishes
- Realistic demo of student experience

This fixes the issue where VHS would type commands faster than they execute.
2025-11-28 06:06:47 +01:00
Vijay Janapa Reddi
09cde682b1 Remove cleanup command from demo GIF, handle in scripts instead
Students should see the clean first-time workflow, not our test infrastructure.

Changes:
- VHS tape: Shows 'cd /tmp' then 'git clone' (no rm -rf)
- generate.sh: Cleans /tmp/TinyTorch BEFORE running VHS
- test_demo_workflow.sh: Already cleaned before testing
- README: Documents the separation of concerns

This presents the ideal student experience while maintaining reproducibility:
- Students: See clean setup flow (cd → clone → setup)
- Scripts: Handle cleanup behind the scenes
- Tests: Validate fresh environment every time

GIF size: 494KB → 467KB (optimized further)
2025-11-28 05:54:12 +01:00
Vijay Janapa Reddi
391a54a39d Add comprehensive demo workflow documentation
Document the improved demo testing and generation workflow:
- Explains test_demo_workflow.sh purpose and usage
- Describes cleanup strategy to prevent 'directory exists' errors
- Provides troubleshooting guide for common issues
- Documents best practices for updating demo commands
- Maps file locations and workflow architecture

This ensures future demo updates maintain quality and accuracy.
2025-11-28 05:44:08 +01:00
Vijay Janapa Reddi
e8a55f4252 Update demo GIFs with improved workflow and command fixes
Regenerated all 4 demo GIFs with:
- Added cleanup step (rm -rf /tmp/TinyTorch) to prevent "directory exists" errors
- Fixed command names (tito status → tito module status)
- Validated workflow with test_demo_workflow.sh script

The test script ensures reproducible demo generation by:
1. Cleaning /tmp/TinyTorch before clone
2. Running actual setup and TITO commands
3. Logging all output for verification

GIF sizes after regeneration:
- 01-zero-to-ready.gif: 814KB → 494KB (optimized)
- 02-build-test-ship.gif: 200KB (stable)
- 03-milestone-unlocked.gif: 86KB → 87KB
- 04-share-journey.gif: 105KB → 108KB
2025-11-28 05:43:17 +01:00
Vijay Janapa Reddi
2d3440722d Add demo workflow testing and update VHS tapes
- Create comprehensive test script for demo workflow validation
- Clean /tmp/TinyTorch before cloning to avoid conflicts
- Test full workflow: clone, setup, tito commands
- Update VHS tapes with proper cleanup steps
- Fix command names (tito status -> tito module status)
- Regenerate all 4 demo GIFs with corrected commands
- Log all test output for validation
2025-11-28 05:41:12 +01:00
Vijay Janapa Reddi
32bdfcddf4 Add demo GIFs and generation scripts
- Generated 4 carousel GIFs using VHS (1.2MB total)
  - 01-zero-to-ready.gif (814KB)
  - 02-build-test-ship.gif (200KB)
  - 03-milestone-unlocked.gif (86KB)
  - 04-share-journey.gif (105KB)

- Added VHS tape files for reproducible generation
- Added scripts: generate.sh, optimize.sh, validate.sh
- Fixed paths from site/ → docs/ structure

GIFs show:
1. Quick setup (clone, setup, activate, status, logo)
2. Module workflow (start, work, complete, import)
3. Milestone recreation (Rumelhart 1986)
4. Community engagement (join, update)

To regenerate: bash docs/_static/demos/scripts/generate.sh
2025-11-28 05:25:12 +01:00