This project uses Python to play the WikiGame automatically.
-
Random : If the end page is not found, chooses a random link
Unlikely to succeed -
With NLP : Chooses the word closest to the target in the page using similarity computed with spacy
-
Max : similarity is computed as the max similarity between words from the two strings
Could get stuck in pages about Turkey (country) when trying to get to Bacon -
Mean : Similarity is computed as the average similarity between words from the two strings
Better when facing the previous issue
-
Requestto call the Wikipedia APIBeautifulSoupto parse htmlSpacyto find similarities with NLP
Download ressource (https://spacy.io/models/en) :
- Small :
python -m spacy download en_core_web_sm - Medium :
python -m spacy download en_core_web_md - Large :
python -m spacy download en_core_web_lg
In spacyTools.py choose between 'sm', 'md' and 'lg' by editing the following line :
nlp = spacy.load('en_core_web_lg')
python main.py
