A powerful Python project implementing AI-driven Wordle solving strategies with multiple heuristics, batch performance testing, and interactive gameplay.
This project implements an AI-powered Wordle game solver capable of:
- Interactive Player vs AI gameplay
- AI vs AI comparisons
- Batch testing for heuristic performance
- Real-time strategy visualization
With multiple heuristics and solver strategies, this project provides insights into optimal word-guessing algorithms.
-
🧠 Advanced AI Solvers Supports Constraint-Based Problem (CBP) and A* Optimized Solver with multiple heuristics.
-
🎯 Heuristic Strategies Includes Entropy, Minimax, Expected Size, Hybrid, Positional, and Cached heuristics for optimal guessing.
-
📊 Batch Performance Testing Analyze solver efficiency over hundreds of secret words.
-
🖥️ Interactive UI Built with Gradio for a clean and user-friendly interface.
-
🏆 AI vs AI Comparison Test multiple solvers against the same word to identify the most efficient strategy.
# Clone the repository
git clone https://github.com/DishankVyas/AI-Wordle-Solver
cd ai-wordle
# Install dependencies
pip install -r requirements.txt
# Run the application
python wordle_ai.pyNote: Requires Python 3.9+ and the Gradio library.
Play against AI:
- Select "CBP AI" or "A* AI".
- Input your guess.
- Observe AI's response in real time.
Batch Testing Example:
# Run batch analysis for 100 words
from batch_test import run_batch
run_batch('entropy', num_words=100)Query Solver Efficiency:
# Compare heuristics
from heuristics import compare_solvers
compare_solvers(['entropy', 'minimax', 'hybrid'])| Heuristic | Description | Best Use Case |
|---|---|---|
| Hybrid | Switches between entropy & minimax dynamically | Overall best performance |
| Fast Entropy | Approximate Shannon entropy calculation | High accuracy, moderate speed |
| Minimax | Minimizes worst-case candidate set | Fast decision making |
| Expected Size | Minimizes expected remaining words | Lightweight computations |
| Positional | Entropy calculated per letter position | Position-aware guessing |
| Cached | Memoized computations for repeated patterns | Batch processing |
- Average guesses to solve a word
- Success/failure rates
- Time per guess
- Heuristic comparison charts
- Multiplayer Wordle challenges
- Difficulty levels for players
- AI learning via reinforcement learning
- Online leaderboard integration
- Enhanced analytics dashboards
- Dishank Vyas
- Krishna Shetty
- Pal Soni
Contributions are welcome!
- Fork the repository.
- Create a new feature branch:
git checkout -b feature/your-feature-name
- Commit your changes:
git commit -m 'Add your feature' - Push to GitHub:
git push origin feature/your-feature-name
- Open a Pull Request 🙌