-
Install Chrome
-
Install Chromedriver for your Chrome version from chromedriver.chromium.org/downloads
-
Install Python 3.8, 3.9, or 3.10 (more versions could be compatible)
-
Install Selenium 4.0.0 (more versions could be compatible):
pip install selenium==4.0.0
-
Create a
dictionary.json
file, then copy and paste the following content:{}
-
Create a
credentials.json
file, then copy and paste the following content then enter your correct username and password:{ "username" : "your_username", "password" : "your_password" }
-
Open
settings.json
and set your own settings:{ "chromedriver_path" : "C:/Path/to/chromedriver.exe", "headless" : false, "incognito" : false, "mute" : false, "practice" : true }
chromedriver_path
is the full path to the appropriate Chromedriver for your Chrome versionheadless
will make the program run in the background if set totrue
incognito
will open Chrome in incognito mode if set totrue
mute
will mute Chrome if set totrue
practice
will let the program learn and run forever if set totrue
, otherwise, you will be asked to manually enter a skill every time
Note: If
headless
is set totrue
, the program will always run in practice mode
Start main.py
. A new Chrome window with Duolingo will open (unless in headless mode) and the bot will log you in.
The bot will keep making mistakes at first, but once a sentence has been learned, it will be memorized (unless dictionary.json
is erased).
In practice mode, it will keep going to duolingo.com/practice and practice infinitely. Otherwise, it will open duolingo.com/learn, and ask you to open a skill every time.
The supported challenges are:
- Translate, where you are asked to translate from one language to another
- Name, where you must translate a single word
- Form, where you must fill in the blanks
- Select, where you select the picture and translation representing a given word
The listening and speaking challenges are always skipped. There may be other types of challenges I do not know of - When encountering these, the skill will be restarted.