A mobile app that helps you find related "secret code" words for the Spanish word game. Enter Spanish words, and the app groups them by semantic similarity and suggests related words using FastText embeddings, WordNet hypernyms, and ConceptNet cultural relations.
- Enter one or more Spanish words into the app
- The app groups your words by semantic similarity (cosine similarity on FastText embeddings)
- For each group, it finds the top related words from a 50K-word Spanish vocabulary
- If the suggestions aren't helpful, tap "Not convinced" to see more
Behind the scenes, the app uses:
- FastText embeddings (300-dimensional, we use half of them) for semantic similarity
- WordNet hypernyms to find words that share a common category
- ConceptNet cultural relations to capture associations beyond pure word-vector similarity
secret-code-cheat/
├── asset-parser/ # Python pipeline that generates app assets
│ ├── get_words.py # Downloads Spanish word list (top 50K)
│ ├── generate_embeddings.py # Generates FastText embedding chunks
│ ├── generate_hypernyms.py # Generates WordNet hypernym mappings
│ ├── generate_cultural_relations.py # Generates ConceptNet relation map
│ └── generate_all.py # Runs the full pipeline
└── expo-app/ # React Native (Expo) mobile app
├── App.tsx # Main UI
└── src/
├── embeddings.ts # Loads and caches embeddings
├── hypernyms.ts # Loads and caches hypernyms
├── culturalRelations.ts # Loads and caches cultural relations
└── search.ts # Similarity search and word grouping
- Python 3.10+ (for the asset pipeline)
- Node.js 18+ and npm (for the Expo app)
- Expo CLI (
npx expo) - An Android emulator or physical device with Expo Go
The app requires pre-generated embedding and language data files. Run the asset pipeline first:
cd asset-parser
python -m venv venv && source venv/bin/activate
pip install -r requirements.txtThen run each step of the pipeline:
python get_words.py # Download + extract top 50K Spanish words
python generate_embeddings.py # Generate embeddings (downloads ~4GB FastText model on first run)
python generate_hypernyms.py # Generate hypernym mappings via NLTK WordNet
python generate_cultural_relations.py # Download ConceptNet + generate cultural relationsOr run everything at once:
python generate_all.pyThe generated .ejson files are automatically copied into expo-app/assets/.
cd expo-app
npm install
npx expo startThen press:
ato open on Android emulatorwto open in a web browser- Scan the QR code with Expo Go on a physical device
- The FastText model (
cc.es.300.bin) is ~4 GB and downloaded automatically on the first run ofgenerate_embeddings.py. It is gitignored. - All generated asset files (
.ejson) are gitignored. You must run the asset pipeline before the app will work. - The embeddings are split into chunks (max 100 MB each). With 50K words this produces 2 chunks.