An interactive web application documenting my systematic exploration of Reinforcement Learning algorithms, built with math and physics intuition.
This project serves multiple purposes:
- Personal Learning: A structured approach to mastering RL from first principles
- Interactive Documentation: Each algorithm includes theory, implementation, and runnable demos
- Portfolio Showcase: Demonstrating technical skills and learning methodology
- Knowledge Sharing: Making RL accessible through interactive explanations
- Slide-based Theory: Each algorithm has comprehensive slides explaining concepts
- Interactive Code: Python implementations running directly in the browser via PyScript
- Learning Notes: Personal insights, questions, and connections to math/physics
- Progressive Learning: Algorithms ordered from foundational to advanced
- Frontend: Pure HTML/CSS/JavaScript (no build process needed)
- Python Execution: PyScript - Run Python in the browser
- Syntax Highlighting: Prism.js - Beautiful code display
- Deployment: GitHub Pages (static site hosting)
- Styling: Custom CSS with modern design and dark theme
- Clean & Modern: Professional dark theme optimized for readability
- Fully Responsive: Works seamlessly on desktop, tablet, and mobile
- Interactive: Live code execution, slide navigation, smooth animations
- Accessible: Keyboard navigation, semantic HTML, high contrast
- Multi-Armed Bandit
- ฮต-greedy strategy
- Upper Confidence Bound (UCB)
- Thompson Sampling
- Interactive comparison demo
- Q-Learning - Temporal Difference learning for discrete spaces
- SARSA - On-policy TD control
- Policy Gradient - Direct policy optimization (REINFORCE)
- Deep Q-Network (DQN) - Deep RL with experience replay
- Actor-Critic - Hybrid value and policy methods
- PPO - Proximal Policy Optimization
- A3C - Asynchronous Advantage Actor-Critic
-
Clone the repository
git clone https://github.com/yourusername/Reinforcement-Learning.git cd Reinforcement-Learning -
Open in browser Simply open
index.htmlin your web browser. No build process required!Or use a local server:
# Python python -m http.server 8000 # Node.js npx serve # VS Code # Use "Live Server" extension
-
Navigate to:
http://localhost:8000
Reinforcement-Learning/
โโโ index.html # Main landing page
โโโ css/
โ โโโ styles.css # Global styles
โโโ js/
โ โโโ main.js # Main JavaScript
โโโ algorithms/
โ โโโ multi-armed-bandit/
โ โโโ index.html # Algorithm page with slides
โ โโโ algorithm.css # Page-specific styles
โ โโโ mab_demo.py # Python implementation
โโโ assets/
โ โโโ images/ # Images and diagrams
โโโ README.md # This file
-
Push your code to GitHub
git add . git commit -m "Initial commit: RL Journey web app" git branch -M main git remote add origin https://github.com/yourusername/Reinforcement-Learning.git git push -u origin main
-
Enable GitHub Pages
- Go to your repository on GitHub
- Click "Settings" โ "Pages"
- Under "Source", select "main" branch and "/" root
- Click "Save"
-
Access your site
- Your site will be live at:
https://yourusername.github.io/Reinforcement-Learning/ - It may take a few minutes to deploy
- Your site will be live at:
Create .github/workflows/deploy.yml:
name: Deploy to GitHub Pages
on:
push:
branches: [main]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./This project embodies a unique learning approach:
- Building intuition from first principles
- Leveraging math and physics background
- Deriving formulas and understanding proofs
- Every concept includes runnable code
- Interactive parameters to explore behavior
- Visualizations of algorithm performance
- Documenting questions and insights
- Exploring "why" not just "how"
- Connecting concepts across domains
- Using Claude Code, GitHub Copilot for implementation
- Leveraging AI for explanations and debugging
- Demonstrating modern development workflow
- Start with Multi-Armed Bandit - Foundation concepts
- Read the slides - Understand theory step-by-step
- Review learning notes - See thought process and insights
- Run the code - Modify parameters and experiment
- Ask questions - Use AI tools to deepen understanding
- Demonstrates self-directed learning ability
- Shows technical implementation skills (web dev + ML)
- Exhibits communication through clear documentation
- Proves modern tooling proficiency (PyScript, Git, etc.)
Contributions welcome! To add an algorithm:
- Create folder:
algorithms/algorithm-name/ - Add
index.htmlwith slides and code - Add
algorithm.cssfor custom styling - Include
.pyimplementation file - Update main
index.htmlwith new card - Submit PR with description
| Technology | Purpose | Why Chosen |
|---|---|---|
| PyScript | Run Python in browser | No backend needed, pure frontend solution |
| Prism.js | Syntax highlighting | Beautiful, lightweight, extensible |
| Pure CSS | Styling | Full control, no framework overhead |
| GitHub Pages | Hosting | Free, integrated with Git, easy deployment |
| NumPy (via Pyodide) | Scientific computing | Standard for numerical Python |
- Add visualization library (Plotly.js/D3.js)
- Implement algorithm comparison dashboard
- Add Jupyter notebook integration
- Create video walkthroughs
- Add search functionality
- Implement dark/light theme toggle
- Add progress tracking system
- Include quiz/exercise sections
This project is open source and available under the MIT License.
- Built with PyScript
- Syntax highlighting by Prism.js
- Developed with assistance from Claude (Anthropic) and GitHub Copilot
- Inspired by the RL community and open-source learning resources
Author: [Your Name]
- GitHub: @yourusername
- Email: your.email@example.com
- LinkedIn: Your LinkedIn
Built with โค๏ธ, curiosity, and a deep appreciation for the beauty of reinforcement learning
Last updated: November 2024