Saravanan666/pypi-org huggingface dataset:
Package: wikipsy
WikiPsyProvides multiple functionalities for scraping wikipedia, the centerpoint being getting to psychology or philosophy.InstallationUse pip:pipinstallwikipsyAnd then run❯ wikipsy --help
                                                                                                                                                                                          
 Usage: wikipsy [OPTIONS] COMMAND [ARGS]...                                                                                                                           
                                                                                                                                                                                          
╭─ Options ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --install-completion          Install completion for the current shell.                                                                                                                │
│ --show-completion             Show completion for the current shell, to copy it or customize the installation.                                                                         │
│ --help                        Show this message and exit.                                                                                                                              │
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ graph-multiple  Given multiple wikipedia pages, scrapes and generated a directed graphviz source file showing the those articles' path to Psychology. For ease of use, direct the      │
│                 output of this command into a graphviz dot file.                                                                                                                       │
│ psychology      Scrapes the leading hyperlink of Wikipedia pages recursively until the page "Psychology" is reached.                                                                   │
│ scrape          Scrape a Wikipedia page for its hyperlinks. Ignores the topmost note section and links in parenthetical sentences.                                                     │
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
Package: wikipya
📚 wikipyaA simple async python library for search pages and images in wikis🛠 Usage# Import wikipyafromwikipyaimportWikipya# Create Wikipya object with Wikipedia methodswiki=Wikipya(lang="en").get_instance()# or use other MediaEiki server (or other service, but this is'n fully supported now)wikipya=Wikipya(url="https://ipv6.lurkmo.re/api.php",lurk=True,prefix="").get_instance()# for use Lurkmore (russian). simple and fast# Get a pages list from searchsearch=awaitwiki.search("test")# Get a pages list from opensearchopensearch=awaitwiki.opensearch("test")# Get page class# You can give to wiki.page() search item, title of page, page id# Search item (supported ONLY by wiki.search)page=awaitwiki.page(search[0])# Page titlepage=awaitwiki.page("git")# Pageidpage=awaitwiki.page(800543)print(page.html)# Get page htmlprint(page.parsed)# Get html cleared of link, and other non-formating tags# Get imageimage=awaitwiki.image(page.title)# may not work in non-wikipedia services, check true prefix, or create issueprint(image.source)# Image urlprint(image.width)# Image widthprint(image.height)# Image height🎉 FeaturesFull asyncSupport of other instances of MediaWikiSupport cleaning of HTML with TgHTMLUses models bypydantic🚀 InstallTo install, run this code:pip install wikipya
Package: wikipyedia-md
Wikipyedia_mdA python package for converting Wikipedia articles to Markdown format.UsageInstall the packagepipinstallwikipyedia-mdFetch, parse and save a list of articles from urls as .md files in the output dirrectoryfromwikipyedia_mdimportarticles_to_markdownurls=["https://en.wikipedia.org/wiki/Computer_science",# ...]articles_to_markdown(urls,output_dir="./articles")Or you can do it manuallyimportrequestsfromwikipyedia_md.html_filteringimportfilter_htmlfromwikipyedia_md.wiki_parserimportparse_articleurls=["https://en.wikipedia.org/wiki/Computer_science",# ...]forurlinurls:response=requests.get(url,timeout=10)content=response.textmodified_html=filter_html(content)article=parse_article(modified_html)file_name=url.split("/")[-1]+".md"article.save_md(f"{output_dir}/{file_name}")By default filter_html filters out common html elements that would mess with the markdown output, you can modify the elements if you want by passing a list of elementsfromwikipyedia_mdimportIGNORE_ELEMENTScustom_elements=IGNORE_ELEMENTScustom_elements.extend(["img",# ...])modified_html=filter_html(content,filter_elements=custom_elements)ContributingContributions to this package are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.ReferencesGithub RepositoryPyPI package
Package: wikirate4py
OfficialWikiRate‘s wrapper for PythonFull Documentation:https://wikirate4py.readthedocs.io/Official Slack ChannelInstallationThe easiest way to install the latest version from PyPI is by using pip:$ pip install wikirate4pyYou can also use Git to clone the repository from GitHub to install the latest development version:$ git clone https://github.com/wikirate/wikirate4py.git
$ cd wikirate4py
$ pip install .Alternatively, install directly from the GitHub repository:$ pip install git+https://github.com/wikirate/wikirate4py.gitPython 3.6 - 3.9 are supported.Usagewikirate4py makes it trivial to interact with WikiRate’s API:>>>fromwikirate4pyimportAPI>>>api=API('your_api_token')>>>company=api.get_company(7217)# returns company given company's numeric identifier>>>company.name'Adidas AG'>>>company.headquarters'Germany'DataFramesFrom 1.2.0 version of wikirate4py library allows users to transform WikiRateEntity objects to DataFrames.
A usage example can be found below:fromwikirate4pyimportAPIfromwikirate4py.utilsimportto_dataframeapi=API('your_api_token')cursor=wikirate4py.Cursor(api.get_metric_answers,metric_name="Revenue EUR",metric_designer="Clean Clothes Campaign",year=2020)answers=[]whilecursor.has_next():answers+=cursor.next()print(to_dataframe(answers).to_string())ContributingBug reports, feature suggestions requests are welcome on GitHub athttps://github.com/wikirate/wikirate4py/issues.LicenseThe library is available as Open Source under the terms of theGNU General Public License v3 (GPLv3).
Package: wikireader
WikiReaderWikiReaderis a simple wikipedia browser tool writen in Python for reading Wikipedia
articles without distraction. It uses Suckless' dmenu for finding articles.It is written for my own purposes and is deliberately kept simple.InstallationTo install WikiReader, simply run:pipinstallwikireaderWikiReader was written in Python 3.8.5 and had dmenu as an external dependency.
To install dmenu:On Debian/UbuntusudoaptinstalldmenuOn Arch Linux:pacman-SdmenuWikiReader also relies on PyQt5, so it needs the dependencies of that package as well.UsageRun the commandwikireader. A dmenu instance will popup on your screen. Here you can write a
keyword or query. The dmenu will disappear and reappear with suggestions to articles. After
chosing one, the article will be loaded and shown in a simplified html form.ConfigConfiguration is still in it's early stages. The first implementation is in
version 0.0.4. At the moment you can only set the theme.
The config folder is in~/.config/wikireader/. There will be aconfig.json.
If it is not there, run the wikireader command once. The program will create
the folder and the default config files. There will be a css folder as well
with availabel themes, at the moment only a dark- and a light theme. Be free to
create your own theme, but beware that you give it a different name.
In the config.json you can set the theme, by setting the css filename without
the.cssextentsion:{"theme":"light"}The default is dark as I prefer that.LicenceThe package is released under MIT license.
Package: wikiscraper
wikiscraperEasy scraper that extracts data from Wikipedia articles thanks to its URL slug : title, images, summary, sections paragraphs, sidebar infoDeveloped by Alexandre MEYERThis work is licensed under aCreative Commons Attribution 4.0 International License.Installation$pipinstallwikiscraperInitializationImportimportwikiscraperaswsMain request# Set the language page in Wikipedia for the query# (ISO 639-1 & by default "en" for English)ws.lang("fr")# Search and get content by the URL slug of the article# (Example : https://fr.wikipedia.org/wiki/Paris)result=ws.searchBySlug("Paris")ExamplesTitle H1 & URL# Get article's titleresult.getTitle()# Get article's URLresult.getURL()Sidebar# Get value of the sidebar information labelresult.getSideInfo("GentilÃ©")Abstract# Get all paragraphs of abstractprint(result.getAbstract())# Get the second paragraph of abstractprint(result.getAbstract()[1])# Optional : Get the x paragraphs, starting from the beginningprint(result.getAbstract(2))Images# Get all illustration imagesimg=result.getImage()# Get a specific image thanks to its position in the pageprint(img[0])# Main imageSections# Get table of contents# Only first headlinesprint(result.getContentsTable())# All headelines (first and second levels)print(result.getContentsTable(subcontents=True))# Get paragraphs from a specific section thanks to the parents' header title# All optional args : .getSection(h2Title, h3Title, h4Title)# Exemple : https://fr.wikipedia.org/wiki/Paris#Politique_et_administrationprint(result.getSection('Politique et administration','Statut et organisation administrative','Historique')[0])Errors"Unable to find the requested query: please check the spelling of the slug"Check if the spelling of the slug is correctCheck if the article existsCheck if the language set for the query matches with the slug (by default the search is for English articles)Versions1.1.0 = Error Handling1.0.0 = init
Package: wiki-scraper
Wikipedia ScraperA library for scraping data from Wikipedia. Can be useful in Natural Language Processing, text processing etc. The library can also perform certain tasks on the scrpaed text such as removing punctutations,numbers,citations, converting text into lower case and tokenizationInstallationpip install wiki-scraperGet StartedHow to scrape data from the wikipedia article using this libraryfrom wiki_scraper import WikiScraperscraper = WikiScraper('India')
text = WikiScraper.get_data(remove_punctuations=False,remove_numbers=False,lower_case=False,remove_citations=False,tokenization=False)
Package: wikiseriesarjanlib
Lib to use Wikipedia to query TV seriesDocumentation:https://wikiseriesarjanlib.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (25-05-2023)First code creation
Package: wikiseriesasorkunlib
This my projectDocumentation:https://wikiseriesasorkunlib.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (26-04-2023)First code creation0.1.0 (26-04-2023)
Package: wikiseriesbaslib
Library to use wikipedia to query tv series episode listDocumentation:https://wikiseriesbaslib.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (25-05-2023)First code creation0.1.0 (25-05-2023)first release.
Package: wikiseriesbrentlib
A library interfacing with wikipedia to retrieve tv series informationDocumentation:https://wikiseriesbrentlib.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (26-04-2023)First code creation0.1.0 (26-04-2023)my first ever pypi package :)
Package: wikiseriesbrenttoolcli
a cli tool to use wikipedia to retrieve tv series informationDocumentation:https://wikiseriesbrenttoolcli.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (01-05-2023)First code creation0.1.0 (01-05-2023)first release
Package: wikiseriesevilib
Library to use Wikipedia to query tv series episodes listsDocumentation:https://wikiseriesevilib.readthedocs.org/en/latestDevelopment WorkflowThe workflow supports the following stepslinttestbuilddocumentuploadgraphThese actions are supported out of the box by the corresponding scripts under _CI/scripts directory with sane defaults based on best practices.
Sourcing setup_aliases.ps1 for windows powershell or setup_aliases.sh in bash on Mac or Linux will provide with handy aliases for the shell of all those commands prepended with an underscore.The bootstrap script creates a .venv directory inside the project directory hosting the virtual environment. It uses pipenv for that.
It is called by all other scripts before they do anything. So one could simple start by calling _lint and that would set up everything before it tried to actually lint the projectOnce the code is ready to be delivered the _tag script should be called accepting one of three arguments, patch, minor, major following the semantic versioning scheme.
So for the initial delivery one would call$ _tag –minorwhich would bump the version of the project to 0.1.0 tag it in git and do a push and also ask for the change and automagically update HISTORY.rst with the version and the change provided.So the full workflow after git is initialized is:repeat as necessary (of course it could be test - code - lint :) )codelinttestcommit and pushdevelop more through the code-lint-test cycletag (with the appropriate argument)buildupload (if you want to host your package in pypi)document (of course this could be run at any point)Important InformationThis template is based on pipenv. In order to be compatible with requirements.txt so the actual created package can be used by any part of the existing python ecosystem some hacks were needed.
So when building a package out of thisdo notsimple call$ python setup.py sdist bdist_eggas this will produce an unusable artifact with files missing.Instead use the provided build and upload scripts that create all the necessary files in the artifact.Project FeaturesTODOHistory0.0.1 (25-05-2023)First code creation0.1.0 (25-05-2023)first release