Explore word families through interactive visual graphs
WordFam is a web application that generates and visualizes morphological word families, helping users understand relationships between words through etymology, derivations, and semantic connections.
- Interactive Graph Visualization - Explore word relationships with Cytoscape.js
- Multiple Data Sources - Combines WordNet, Datamuse API, morphological analysis, and embeddings
- Smart Word Validation - Ensures only real words appear in graphs
- Etymology-Based Filtering - Distinguishes true derivations from false cognates
- Compound Word Detection - Recognizes phrasal verbs and compound words
- Word Definitions - Click any node to see its definition
- Fast Performance - Parallel API calls for sub-5-second response times
- Python 3.10+
- Node.js 16+
- npm or yarn
cd backend
python -m venv .venv
.venv\Scripts\activate # Windows
source .venv/bin/activate # Mac/Linux
pip install -r requirements.txt
python -m uvicorn app:app --reloadBackend runs on http://localhost:8000
cd frontend
npm install
npm run devFrontend runs on http://localhost:3000
WordFam/
├── backend/
│ ├── models/ # Pydantic response models
│ ├── services/ # Core engines (WordNet, Datamuse, morphology, etc.)
│ ├── utils/ # Caching utilities
│ └── app.py # FastAPI application
├── frontend/
│ ├── src/
│ │ ├── components/ # React components (GraphView, SearchBar, InfoPanel)
│ │ ├── App.jsx # Main app
│ │ └── index.css # Global styles
│ └── package.json
└── README.md
Backend:
- FastAPI - High-performance async web framework
- NLTK WordNet - Lexical database for derivations
- Datamuse API - Word associations and validations
- Sentence Transformers - Semantic similarity embeddings
- Free Dictionary API - Word definitions
Frontend:
- React - UI framework
- Cytoscape.js - Graph visualization
- Axios - HTTP client
- Vite - Build tool
- Input: User enters a word (e.g., "happy")
- Processing: Backend queries multiple sources in parallel:
- WordNet for derivations
- Datamuse for related words
- Morphology engine for variants
- Compound words database
- Etymology validation
- Validation: All words verified to exist in dictionaries
- Graph Building: Nodes (words) and edges (relationships) constructed
- Visualization: Interactive graph rendered with color-coded relationships
- 🔴 Red - Root word / High relevance
- 🩷 Pink - Morphological derivations
- 💗 Light Pink - Semantic relations
Returns word family graph data:
{
"nodes": [{"id": "happy", "label": "happy", "score": 1.0, "definition": "..."}],
"edges": [{"source": "happy", "target": "happiness", "type": "morphological"}],
"synonyms": ["joyful", "glad"],
"semantic": ["pleased", "content"],
"meta": {"definition": "...", "etymology": "..."}
}- run → runner, running, runway, runaway, rerun, overrun
Developed during CS Girlies Hackathon 2025
MIT License