Saravanan666/pypi-org huggingface dataset:
Package: docrepr
DocreprDocrepr renders Python docstrings to HTML with Sphinx.
It can generate rich and plain representations of docstrings, alongside additional metadata about the object to which the docstring belongs.
It is based on thesphinxifymodule developed byTim Dumolfor the Sage Notebook and theutils.helpmodule developed byCarlos Cordobafor the Spyder IDE.
Seespyder-ide/docrepr#20for the full history.RationaleFor more on the motivation and design behind Docrepr, see this presentation by Carlos Cordoba at SciPy 2015:DetailsThe module renders a dictionary as returned by IPythonoinspectmodule into a full HTML page (with all assets) from an object's docstring, by using therich_reprfunction of itssphinxifysubmodule.Example of useimportwebbrowserimportnumpyasnpfromIPython.core.oinspectimportInspector# oinfo generatorimportdocrepr# Set module optionsfromdocreprimportsphinxify# html generatoroinfo=Inspector().info(np.sin)oinfo['name']='sin'url=sphinxify.rich_repr(oinfo)webbrowser.open_new_tab(url)LicenseThis project is distributed under the under the terms of theBSD 3-Clause License.
Package: docrobot
一个文档自动处理工具暂时没有啥说明安装:  pip install docrobot升级： pip install --upgrade docrobot然后找到构建环境准备:
python -m pip install -U pip setuptools
pip install pywin32 python-docx openpyxl pyside6 -ihttps://mirrors.aliyun.com/pypi/simple/--trusted-host mirrors.aliyun.com
Package: docrunner
DocrunnerA command line tool which allows you to run the code in your markdown files to ensure that readers always have access to working code.What does it do?Docrunner goes through your markdown file and runs any code in it, providing you safe testing for any markdown documentation. You can specify the path to the markdown file, along with other options, with flags.InstallationUse the package managerpipto install docrunner.pipinstalldocrunnerQuickStartdocrunner--helpLanguage Specific HelpFor help on a specific language, run:docrunner<language>--helpPython Exampledocrunnerpython--markdown-pathexample/example.md--multi-fileThis command executes all python withinexample.mdand does so by putting each snippet of python from this file into a separate file, and running each file. If you don't want each snippet in a separate python file, just remove the --multi-file option.Contributing and Local DevelopmentPlease check theCONTRIBUTINGguidelines for information
on how to contribute to docrunner.Supported LanguagesPython -docrunner python --helpJavascript -docrunner javascript --helpTypescript -docrunner typescript --helpDart -docrunner dart --help
Package: docs2md
docs2mdAutomatically parse python docstrings and convert them to markdown!Installingpip installand you're good to go!https://pypi.org/project/docs2md/InstructionsSimply run thedocs2md.pyfrom the command line to interact with the ol' main function.Note: Program uses f-strings, as such python3.6or above is required.Assuming you'll have a folder structure like so:.
├── foo.py
├── blahbla
│   ├── __init__.py
│   └── blahblah.py
├── LICENSE
└── README.mdRunningpython3 -m docs2md.py .will produce the following:.
├── docs
│   ├── foo.md
│   └── blahbla
│       ├── __init__.md
│       └── blahblah.md
├── foo.py
├── blahbla
│   ├── __init__.py
│   └── blahblah.py
├── LICENSE
└── README.mdThe command line arguments are as follow:positionalarguments:fFileordirectorytoparse!

optionalarguments:-h,--helpshowthishelpmessageandexit-d[DOCS_DIR],--docs-dir[DOCS_DIR]Documentationdirectoryinwhichyour.mdfileswillbesaved.Defaultsto[cwd]/docs-p,--just-printPrintstheresultsinsteadofcreatingawholefile!-s[SAVE_IMPORT],--save-import[SAVE_IMPORT]Whetheryou'll want to save the imports to anotherfile. Simply place the path of the txt file you'llwanttosaveyourimportsto--testRunsdoctest!How does this work anyway?If the input is a directory,doc2md.pywill glob all of the files looking for python
files and then look for doctrings.Note: That the program will also include the__init__and main files, as these
can include critical declarations.Theyield_docstringsfunction will use python's abstract syntax tree module to look
for docstrings near the following nodes:FunctionDef:def foo()...AsyncFunctionDef:def async foo()...ClassDef:class foo:...Module:"""docstrings at the start of a file"""And automatically generate a simple markdown based on them.
Feel free to perouse this repo's docs folder, which was
naturally created using this tool.The program will also look for the following nodes:ImportFromImportAnd mentions the fact that a python file imports from this or that
module.(This is useful to keep track of dependencies, and you can save these
separately using the -s flag)As of the moment of writting, the program does not yet include
global variables or data. Although I'm partial to including them
in a future update.
Package: docs2tops
docs2tops stands for documents to topics.What it basically does is:extracting ngrams from the documentsextracting meaningful moregrams (2 or more grams)creates semi-automated dictionary - if user provided some possible topics, docs2tops provides similar keywords per topics providedcreates fully-automated dictionaryin both cases (either user inputs some topics or not), docs2tops returns 2 dictionaries.
if user did not provide any topic, first dictionary will be empty with a message only.in all cases, fully-automated dictionary will be created.docs2tops function takes list of documents
optionally, you can provide candidate_topics_list, moregrams_sample_size.docs2tops(docs_input_list, candidate_topics_list=None, moregrams_sample_size=None)installationRun the following to install:pipinstalldocs2topsusagefromdocs2topsimportdocs2topsimportpandasaspddf=pd.read_csv(r"C:\Users\my_file.csv")docs=df['my_texual_content'].to_list()candidate_topics_list=['smell','taste','delivery','packaging']moregrams_sample_size=100user_input_dict,fully_auto_dict=docs2tops(docs_input_list=docs,candidate_topics_list=candidate_topics_list,moregrams_sample_size=moregrams_sample_size)list_dicts=[user_input_dict,fully_auto_dict]forresultinlist_dicts:print(result)print('number of topics: ',len(result))print('---')Developing docs2topsto install docs2tops, along with the tools you need to develop and run tests, run the following in your virtual environment:pipinstall-e.[dev]
Package: docs2txt
docs2txtA simple program to download documentation from docs.rs and convert it into a plaintext file.Free software: MIT licenseDocumentation:https://docs2txt.readthedocs.io.FeaturesRustDownload documentation from docs.rs and convert it into a plaintext file.UsageCreate a virtual environment and install the packagepython-mvenv venvInstall the package withpip install docs2txtActivate the virtual environmentOSX / Linux:source venv/bin/activateWindows:venv\Scripts\activateRun the program:python-mdocs2txtExamplesTo download the documentation of the redb crate and save it to a folder on your desktop named “Rust Docs”:python-mdocs2txtdocs-rs--urlhttps://docs.rs/redb/1.0.4/redb/--output-dir'~/Desktop/RustDocs'History0.1.0 (2023-07-09)First release on PyPI.0.1.1 - 0.1.4 (2023-07-09)Bug Fixes0.1.5 (2023-07-09)Updated Readme with usage and example0.1.6 (2023-07-09)Added History
Package: docsbackup
# docsbackupThis tool can take a list of URLs to google documents and saves them with a
timestamp. It can be used to include shared documents in backups and/or
extract reference versions at specific points in time.
The list of URLs can be provided in different formats or can be extracted by
scanning through documents. The extraction is based on a prior conversion
with [Pandoc](http://pandoc.org).# InstallThe fastest way to install docsbackup is to use your systems tools:pip install docsbackupTo use the latest test version check out the test.pypi server:pip install –index-urlhttps://test.pypi.org/simpledocsbackup## RequirementsAll required packages are listed inenvironment.yaml. In case you
installed docsbackup via a package management system like pip, anaconda,
miniconda, … all dependencies should already be installed automatically.# Getting StartedAfter installation rundocsbackup –helpto get a first overview of
command line options and usage.## Further readingFor details about the used tools and formats following links may provide
more details.[Pandoc](http://pandoc.org/)[YAML specification](http://yaml.org/spec/)) and the
[ruamel.yaml](https://yaml.readthedocs.io/en/latest/basicuse.html)
package.# Developing docsbackupContributions are very welcome! Write issues for feature requests or
directly file a pull-request with your contribution and/or contact me
directly!## TestsThis project uses the [PyTest framework](https://docs.pytest.org/en/latest/)
with tests defined in the [tests/](tests/) sudirectory. It is added into the
setuptools config, so that it can be run withpython setup.py testThis automatically tests a temporarily packaged version.Alternatively you can runpytestmanually with all it [glory
details](https://docs.pytest.org/en/latest/usage.html).## ReleasesThe release workflow is mostly automated and is in the [release/](release/)
folder.
Package: docsbot
DocsBot 使用说明DocsBot 是一个简单的命令行小工具，用对话的方式，快速查询本地的文档库（Word、PDF、PPT等）快速开始 Quick Start安装方法1：通过pip 安装$pipinstalldocsbot-ihttps://pypi.tuna.tsinghua.edu.cn/simple安装方法2：通过Docker运行dockerrun-ti-e"OPENAI_PROXY=http://192.168.3.112:8001"-e"OPENAI_API_KEY=sk-xxxxxxxxxxxxxxxxxxxxx"datamini/docsbot使用$ docsbot
Please enter your OpenAI Key: sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
usage: chatbase [-h] {addbase,listbase,deletebase,query} ...

positional arguments:
  {addbase,listbase,deletebase,query}

options:
  -h, --help            show this help message and exit
  
  
$ docsbot addbase /Users/lele/Downloads/laws

Using vector store:  Qdrant
loading from dir: /Users/lele/Downloads/laws
Added 4 document(s) to base base000x7uvrvegk9vv
Added /Users/lele/Downloads/laws with ID base000x7uvrvegk9vv

$ docsbot listbase
+---------------------+-------------------------------+---------+
|          ID         |            Location           |  Count  |
+---------------------+-------------------------------+---------+
| base000x7uvrvegk9vv | /Users/lele/Downloads/laws | 4 files |
+---------------------+-------------------------------+---------+

$ docsbot query base000x7uvrvegk9vv

Using vector store:  [Qdrant]-base000sxgohnz1b2r8@http://127.0.0.1:6333 
请输入您的问题：我租了3年，没给钱，合法吗
【回答】： 不合法。根据第721条，承租人应当按照约定的期限支付租金，如果没有约定或者约定不明确，租赁期限不满一年的，应当在租赁期限届满时支付；租赁期限一年以上的，应当在每届满一年时支付，剩余期限不满一年的，应当在租赁期限届满时支付。因此，没有按照约定的期限支付租金是不合法的。
【来源】：
1. 文件：/tmp/laws/中华人民共和国民法典.docx
   内容1. 第七百二十一条  承租人应当按照约定的期限支付租金。对支付租金的期限没有约定或者约定不明确，依据本法第五百一十条的规定仍不能确定，租赁期限不满一年的，应当在租赁期限届满时支付；租赁期限一年以上的，应当在每届满一年时支付，剩余期限不满一年的，应当在租赁期限届满时支付。
   内容2. 第七百二十二条  承租人无正当理由未支付或者迟延支付租金的，出租人可以请求承租人在合理期限内支付；承租人逾期不支付的，出租人可以解除合同。  第七百二十三条  因第三人主张权利，致使承租人不能对租赁物使用、收益的，承租人可以请求减少租金或者不支付租金。  第三人主张权利的，承租人应当及时通知出租人。命令和参数以下是 DocsBot 支持的命令及其参数：$docsbotaddbase<dir># 用于添加一个新的资料库。 `<dir>`: 要添加的资料库的目录路径。$docsbotlistbase# 用于列出所有已添加的资料库。$docsbotdeletebase<baseid># 用于删除一个已添加的资料库。 `<baseid>`: 要删除的资料库的ID。$docsbotquery<baseid>[--debug]# 用于查询一个资料库。 `<baseid>`: 要查询的资料库的ID。 `--debug`: 是否显示调试信息。$docsbotshowconfig# 用于显示当前的配置信息。配置项Home目录docsbot默认使用目录$HOME/.docsbot来存储自己的配置信息、资料库的元信息与索引数据等。# 该目录中的文件和文件夹docsbot.env--配置文件base_data.json--资料库的元信息，比如ID、目录、文件数vectors--对资料库Embedding后的向量索引数据的存储目录配置文件第一次运行时，请根据提示设置OpenAI的Key，docsbot自动保存到配置文件$HOME/.docsbot/docsbot.env中。所有的配置项如下：OPENAI_API_KEY=xxxxxxxxx   # OpenAI的API Key，必须（第一次运行时，会提示输入）
OPENAI_PROXY="http://192.168.3.112:8001" # 代理，可选
HTTP_PROXY_FOR_GLOBAL_ACCESS="http://192.168.3.112:8001"  # 默认使用OPENAI_PROXY
VECTOR_STORE_TYPE="Chroma"  # 索引类型，目前支持Chroma（默认）、Qdrant
QDRANT_SERVER_URL="http://192.168.1.22:6333" # Qdrant的地址，当VECTOR_STORE_TYPE="Qdrant"时必须FAQQ：由于众所周知的原因，如何设置OPENAI的代理？在配置文件中，增加如下配置项：OPENAI_PROXY="http://192.168.3.112:8001"Q：如何更换向量数据库为Qdrant？在配置文件中，增加如下配置项（修改为真实的Qdrant地址）：VECTOR_STORE_TYPE="Qdrant"
QDRANT_SERVER_URL="http://192.168.1.22:6333"Q：如何打开调试模式？在命令行中增加--debug参数即可。$docsbotquerybase000x7uvrvegk9vv--debugRelease Notes详见：文档如何发布（Release）一个新的版本在docsbot/version.py 中更新一个新的版本号使用以下git命令添加一个新的tag# 修改版本号为新的版本号gittag0.1.13# push到远程仓库gitpushorigin0.1.13提交新的Tag之后，Github Action会自动触发如下两个任务：构建新的Python包docsbot，以Git Tag作为版本号，并推送到Pypi.org构建新的Docker Imagedatamini/docsbot，以Git Tag作为Image Tag，并推送到Docker Hub
Package: docscan
DocscanDocscan is a document scanner. Take a photo of your documents and frame it.InstallationInstall it from pypipipinstalldocscanUsage as a cliScan from a remote imagecurl-shttp://input.png|docscan>output.pngScan from a local filedocscanpath/to/output.pngpath/to/input.pngUsage as a libraryInapp.pyimportsysfromdocscan.docimportscansys.stdout.buffer.write(scan(sys.stdin.buffer.read()))Then runcat input.png | python app.py > out.pngLicenseCopyright (c) 2020-presentDaniel GatisLicensed underMIT LicenseBuy me a coffeeLiked some of my work? Buy me a coffee (or more likely a beer)
Package: docs-chat-bot
chat plugin for mkdocsInstalationpython3-mpipinstalldocs-chat-botUsageAdd chat plugin to your mkdocs.yml file.example:plugins:-chatdocs_chat_endpoint:"http://localhost:7999/chat"Before using the chatbot, there are three essential tasks to complete:Indexing the documentsRunning a document chatbot serverThis guide will walk you through each step to ensure a seamless experience with the chatbot.Indexing the documentsTo enable the chatbot to access and retrieve information from your documents, they must be indexed first. Indexing the documents will create a searchable data structure that allows the chatbot to quickly locate relevant information when responding to user queries.Theindexing_docscommand is used to index a collection of documents using the OpenAI Embedding Interface.usage:indexing_docs--dir[markdowndocumentdir]--api-key[openaiapikey]This command indexes the documents in the specified directory using the OpenAI Embedding Interface, with the following options:--dir: Specifies the directory containing the markdown documents to be indexed.--api-key: Sets the API key used to authenticate with the OpenAI API.AttentionPlease be aware that this tool does not provide automatic document segmentation functionality. To ensure optimal usage with the ChatGPT API, it is crucial to follow the guidelines for document segmentation provided below.Document Segmentation GuidelinesManual segmentation: If a Markdown file is too large, you must manually split it into smaller segments. Ensure that each segment has a gap of 100 spaces.Segment length: Each document segment should not exceed 2,000 words. Exceeding this limit may result in segments that are too large to fit within the constraints of the ChatGPT API.How to Segment DocumentsOpen the large Markdown file in a text editor of your choice.Identify a suitable point in the document to split it into smaller segments. This could be a natural break, such as a section or chapter boundary.Separate the segments with 100 spaces, ensuring that each segment does not exceed the 3,000-word limit.Running a document chatbot serverOnce your documents are indexed, you will need to set up and run a document chatbot server. The server is responsible for processing user input, searching the indexed documents, and returning appropriate responses based on the information found within the documents.docs_chat_bot_server --indexed-docs [indexed document] --api-key [openai API key]This command launches the chatbot server with the following options:--indexed-docs: Specifies the file containing indexed documents to be used by the chatbot server for retrieving information.--api-key: Sets the API key used to authenticate with external openai chatgpt services.
Package: docscov
DocsCov is a Sphinx extension that allows you to show a badge showing
documentation coverage for C++ (or any other Doxygen supported) code.Getting StartedFirst, install it by (requires python 3.6+):pip install docscovYou need to use Doxygen to generate XML data about the source files. To do that,
add the following to your Doxygen configuration: (not needed if you’re using
tools like Breathe or Exhale, you should have this already)GENERATE_XML = YESThis will generate XML data about source files. Now just adddocscovto your
Sphinx extensions and add the following to yourconf.py:docscov_config={"xml_dir":"<path to generated XML by Doxygen>"}It’ll places a JSON file inside built documentations, which can be used withShieldsto make a dynamic badge, updated each time
documentations are built.Getting the badgeTo get the badge do the following:Get the URL to your generated documentations (withhttp://orhttps://)Replace the:with%3Ain the URLReplace all slashes (/) in the text you got by completing step 2Replace<url>in the following text with the text you got by completing
step 3, and the text you’ll get is the URL to your badge that can be placed in
your README:https://img.shields.io/endpoint?url=<url>%2F_static%2Fdocscov.jsonExample:https://pypp.readthedocs.io/en/latestwill be converted to this
after following above:https://img.shields.io/endpoint?url=https%3A%2F%2Fpypp.readthedocs.io%2Fen%2Flatest%2F_static%2Fdocscov.jsonConfigurable optionsYou can configure DocsCov with the following options:xml_dir:Value type:strDescription:Path to Doxygen XML outputroot_dir:Value type:strDescription:Path to process relative directories.Notes:Optional.Default:'.'badge_label:Value type:strDescription:The label of badge.Notes:Optional.Default:'docscov'scope:Value type:listDescription:Coverage scope. Possible values of elements:public: Include public members of classesprotected: Include protected members of classesprivate: Include private members of classesall: All of aboveNotes:Optional.Default:['all']kind:Value type:listDescription:Kind of definitions to include in coverage. Possible values
of elements:classdefineenumenumvaluefilefriendfunctionnamespacepagesignalslotstructtypedefunionvariableall: All of aboveNotes:Optional.Default:['all']
Package: docscraper
OverviewThedocscraperpackage is ascrapyspider for crawling a given set of
websites and dowloading all available documents with a given set of file
extensions. The package is intended to be called from a Python script.Getting StartedYou can get started by downloading the package withpip:$ pip install docscraperOnce the package is installed, you can use it with scrapy directly in your
Python script to download files from websites as follows:>>> import docscraper
>>> allowed_domains = ["books.toscrape.com"]
>>> start_urls = ["https://books.toscrape.com"]
>>> extensions = [".html", ".pdf", ".docx", ".doc", ".svg"]
>>> docscraper.crawl(allowed_domains, start_urls, extensions=extensions)
Package: docsdk
docsdk-pythonThis is the official Python SDK v2 for theDocSDKAPI v2.
For API v1, please usev1 branchof this repository.Installationpip install docsdkCreating API Clientimport docsdk

  docsdk.configure(api_key = 'API_KEY', sandbox = False)Or set the environment variableDOCSDK_API_KEYand use:import docsdk

  docSDK.default()Creating JobsimportdocSDKdocsdk.configure(api_key='API_KEY')docsdk.Job.create(payload={"tasks":{'import-my-file':{'operation':'import/url','url':'https://my-url'},'convert-my-file':{'operation':'convert','input':'import-my-file','output_format':'pdf','some_other_option':'value'},'export-my-file':{'operation':'export/url','input':'convert-my-file'}}})Downloading FilesDocSDK can generate public URLs for usingexport/urltasks. You can use these URLs to download output files.exported_url_task_id="84e872fc-d823-4363-baab-eade2e05ee54"res=docsdk.Task.wait(id=exported_url_task_id)#Waitforjobcompletionfile=res.get("result").get("files")[0]res=docsdk.download(filename=file['filename'],url=file['url'])print(res)Uploading FilesUploads to DocSDK are done viaimport/uploadtasks (see thedocs). This SDK offers a convenient upload method:job=docsdk.Job.create(payload={'tasks':{'upload-my-file':{'operation':'import/upload'}}})upload_task_id=job['tasks'][0]['id']upload_task=docsdk.Task.find(id=upload_task_id)res=docsdk.Task.upload(file_name='path/to/sample.pdf',task=upload_task)res=docsdk.Task.find(id=upload_task_id)Webhook SigningThe node SDK allows to verify webhook requests received from DocSDK.payloadString='...';#TheJSONstringfromtherawrequestbody.signature='...';#Thevalueofthe"DocSDK-Signature"header.signingSecret='...';#Youcanfinditinyourwebhooksettings.isValid=docsdk.Webhook.verify(payloadString,signature,signingSecret);#returnstrueorfalseUnit Tests# Run Task tests
$ python tests/unit/testTask.py

# Run Job tests
$ python tests/unit/testJob.py

# Run Webhook tests
$ python tests/unit/testWebhookSignature.pyIntegration Tests# Run Integration test for task
$ python tests/integration/testTasks.py 

# Run Integration test for Job
$ python tests/integration/testJobs.pyResourcesAPI v2 DocumentationDocSDK Blog
Package: doc-search
Doc-searchA simple package for searching documentationFeaturesBoth async and sync supportutilizes a cache to limit the number of requests being madeworks for any documentation that is built with sphinxExampleasyncioimportasynciofromdoc_searchimportAsyncScraperscraper=AsyncScraper()asyncdefmain(query):results=awaitscraper.search(query,page="https://docs.python.org/3/")#returns a list of tuples in the format of [(item, url), (item, url)...]ifnotresults:print("no results were found")else:foritem,urlinresults:#loop through the list of resultsprint(f"{item}|{url}")#print out each resultasyncio.run(main("str.split"))# to view the cache# print(scraper.cache)syncfromdoc_searchimportSyncScraperscraper=SyncScraper()results=scraper.search("resize",page="https://pillow.readthedocs.io/en/stable/")ifnotresults:print("no results were found")else:foritem,urlinresults:#loop through the list of resultsprint(f"{item}|{url}")#print out each resultBetaOffers searches forCandC++docs using thescraper.search_candscraper.search_cppmethodsEX:scraper=SyncScraper()results=scraper.search_c("printf")
Package: docserver
Author:Keith Gaughandocserveris a lightweight, user-friendly documentation server.ContentsInstallationReskinningTestingInstallationTo install from PyPI:$ pip install docserverYou can use docserver straight out of the box by running the module:$ python -m docserverAnd to show the help:$ python -m docserver --helpThe WSGI app itself is exposed asdocserver.DocServer. If you want to use a
bundle store path or frontpage template other than the default, you can set
the environment variablesDOCSERVER_STOREandDOCSERVER_TEMPLATErespectively.ReskinningIf you want to use a skin other than the default skin, you can use he default
skin as the basis for a new one. To print out the default skin:python -m docserver --print-templateThe template engine used ispystache.TestingUse the following to run the test suite:$ python setup.py testIf you’re considering contributing back, make sure you run the testsuite
against all the supported versions of Python. You can usetoxto do this:$ toxOr withdetox:$ detoxTo install additional versions of Python for testing, I recommendpyenv.