This release is a pre-release and may not be stable for production use.
Wikipedia
Wikipedia is a Python library that makes it easy to access and parse data from Wikipedia.
Search Wikipedia, get article summaries, get data like links and images from a page, and more. Wikipedia wraps the MediaWiki API so you can focus on using Wikipedia data, not getting it.
>>> import wikipedia
>>> print wikipedia.summary("Wikipedia")
# Wikipedia (/wkpidi/ or /wkipidi/ WIK-i-PEE-dee-) is a collaboratively edited, multilingual, free Internet encyclopedia supported by the non-profit Wikimedia Foundation...
>>> wikipedia.search("Barack")
# [u'Barak (given name)', u'Barack Obama', u'Barack (brandy)', u'Presidency of Barack Obama', u'Family of Barack Obama', u'First inauguration of Barack Obama', u'Barack Obama presidential campaign, 2008', u'Barack Obama, Sr.', u'Barack Obama citizenship conspiracy theories', u'Presidential transition of Barack Obama']
>>> ny = wikipedia.page("New York")
>>> ny.title
# u'New York'
>>> ny.url
# u'http://en.wikipedia.org/wiki/NewYork'
>>> ny.content
# u'New York is a state in the Northeastern region of the United States. New York is the 27th-most exten'...
>>> ny.links[0]
# u'1790 United States Census'
Installation
To install Wikipedia, simply run:
$ pip install wikipedia
Documentation
Read the docs at https://wikipedia.readthedocs.org/en/latest/.
License
MIT licensed. See the LICENSE file for full details.
Credits
wiki-api by @richardasaurus for inspiration
@nmoroze and @themichaelyang for feedback and suggestions
The Wikimedia Foundation for giving the world free access to data
Metadata
Release files for wikipedia 0.9.5dev
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| wikipedia-0.9.5dev.tar.gz | 15.3 kB | Without provenance | Details for wikipedia-0.9.5dev.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| wikipedia-0.9.5dev.macosx-10.8-intel.exe | Details for wikipedia-0.9.5dev.macosx-10.8-intel.exe |
Total release size: 94.5 kB
Release files / wikipedia-0.9.5dev.tar.gz
| Download URL | wikipedia-0.9.5dev.tar.gz |
|---|---|
| Size | 15.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
39c5a2b63d3d030741e89d9a91941c44fe4622849ccc24a99d8fe717695777e6
|
|
BLAKE2b-256 checksum How to use checksums |
e35361c755b69e24653c3b0a0205206099bc1d96957f3e2166384f932f25479c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / wikipedia-0.9.5dev.macosx-10.8-intel.exe
| Download URL | wikipedia-0.9.5dev.macosx-10.8-intel.exe |
|---|---|
| Size | 79.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6925510aeb8f7354a3a83e4d1dbb8dc06c56ded313dacb7991aa1b221496677c
|
|
BLAKE2b-256 checksum How to use checksums |
1158ea57c9865f042e4cbcced2e1316b02ad9ecbfd3ba72e287068b7bc961bd6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for wikipedia 0.9.5dev
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.