join the nosql movement kneesspoiling the fun for everyone sending billions of requests at the same time is also one of the ways denial of service (doaattacks are performed if you do need to scrape websitescript in time gap between each page request this wayyour scraper more closely mimics the behavior of regular website visitor and you won' blow up their servers luckilythe creators of wikipedia are smart enough to know that this is exactly what would happen with all this information open to everyone they've put an api in place from which you can safely draw your information you can read more about it at you'll draw from the api and python wouldn' be python if it didn' already have library to do the job there are several actuallybut the easiest one will suffice for your needswikipedia activate your python virtual environment and install all the libraries you'll need for the rest of the bookpip install wikipedia pip install elasticsearch you'll use wikipedia to tap into wikipedia elasticsearch is the main elasticsearch python librarywith it you can communicate with your database open your favorite python interpreter and import the necessary librariesfrom elasticsearch import elasticsearch import wikipedia you're going to draw data from the wikipedia api and at the same time index on your local elasticsearch instanceso first you need to prepare it for data acceptance elasticsearch client used to communicate with database client elasticsearch(indexname "medicalclient indices create(index=indexnameindex name create index the first thing you need is client elasticsearch(can be initialized with an address but the default is localhost: elasticsearch(and elasticsearch ('localhost: 'are thus the same thingyour client is connected to your local elasticsearch node then you create an index named "medicalif all goes wellyou should see an "acknowledged:truereplyas shown in figure elasticsearch claims to be schema-lessmeaning you can use elasticsearch without defining database schema and without telling elasticsearch what kind of data it