Learn Spanish vocabulary through flashcards generated from real Spanish texts.
FlashRead analyzes Spanish books, articles, or any text you provide, extracts the most common words, and presents them as interactive flashcards. The more you read in Spanish, the better your vocabulary becomes.
- Python 3.7 or higher
- just command runner (optional but recommended)
# Clone the repository
git clone https://github.com/yourusername/flashread.git
cd flashread
# Option 1: Using just (recommended)
just setup
source .venv/bin/activate
# Option 2: Manual setup
python3 -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
pip install -e .Create a corpus/ folder and add any Spanish text files (.txt) you want to learn from:
mkdir corpus
# Add your Spanish books, articles, or texts as .txt files
# Example: corpus/mi-libro-favorito.txtIdeas for texts:
- Spanish news articles
- Spanish Wikipedia pages
- Public domain Spanish literature from Project Gutenberg
- Transcripts of Spanish podcasts or videos
- Spanish song lyrics
# Process your texts and build vocabulary
python flashread.py generate
# Launch the flashcard app
python flashread.py runOr with just:
just generate
just runOnce launched, you'll see an interactive window with:
- Word Display: A random Spanish word from your corpus appears at the top
- Click to Continue: Click on the word to see the next one
- Settings (cogwheel icon): Customize your learning experience
- Word Length: Focus on shorter or longer words using the min/max sliders
- Starting Letters: Toggle specific letters on/off to practice words beginning with certain letters
- Display Case: Choose lowercase, UPPERCASE, or Title Case
- Hyphenation: Show syllable breaks to help with pronunciation (e.g., "es-pa-ñol")
| Command | Description |
|---|---|
python flashread.py generate |
Process corpus and create vocabulary |
python flashread.py generate --plot |
Also generate a word frequency chart |
python flashread.py generate --force |
Regenerate even if data exists |
python flashread.py run |
Launch the flashcard app |
If you have just installed:
| Command | Description |
|---|---|
just setup |
Create virtual environment and install |
just generate |
Process corpus texts |
just run |
Launch flashcard app |
just clean |
Remove generated files |
Run just without arguments to see all available commands.
- Text Processing: FlashRead reads all
.txtfiles in yourcorpus/folder - Word Extraction: Common Spanish stopwords (like "el", "la", "de") are filtered out
- Frequency Analysis: Words are ranked by how often they appear
- Vocabulary Creation: Only words appearing 3+ times are included (configurable)
- Flashcard Display: Words are shown randomly with your chosen filters
flashread/
├── src/ # Application source code
├── corpus/ # Your Spanish text files (you create this)
├── data/ # Generated vocabulary data (auto-created)
├── flashread.py # Main entry point
├── justfile # Task runner commands
└── requirements.txt # Python dependencies
- Start with texts you enjoy - Learning is easier when the content interests you
- Use the length filter - Begin with shorter words (4-6 letters) and gradually increase
- Focus on letter groups - Practice words starting with letters you find challenging
- Enable hyphenation - Helps you understand Spanish syllable patterns
- Add more texts over time - Your vocabulary grows as your corpus grows
Make sure you have:
- Created the
corpus/directory - Added at least one
.txtfile with Spanish text - Run
python flashread.py generatebefore running the app
Try relaxing your filters:
- Increase the max length slider
- Enable more starting letters
- The settings panel shows how many words match your current filters
On first run, FlashRead downloads required language data from NLTK. This happens automatically but requires an internet connection.
Contributions are welcome! See CONTRIBUTE.md for development setup.
# Development setup
just setup-dev
# Run tests
just test
# Format code
just formatMIT License - see LICENSE for details.