Saravanan666/pypi-org huggingface dataset:
Package: gptprobe
gptprobeSimple example:from gptprobe.askfor.dictfrompoorlyformattedtext import ask_for_text_from_poorly_formatted_dict_text
messy_dict_text = """ Final score are 
                                  Australia  1 
                                  Brazil     2
                                    bummer """
print(ask_for_text_from_poorly_formatted_dict_text(text = messy_dict_text))The result is:{"Australia": "1", "Brazil": "2"}This package contains simple and complex multi-step interrogations intended to yield structured data, including patterns where ChatGPT4 tries to
help itself out of a rut, rephrases questions, ratifies answers using a different key, tries to reformat its own responses, and so forth. It may help with your own unmanned missions into the galactic brain.Install & environ setuppip install gptprobeThen fromopen ai developerhelp yourself to a key and inject into environment somehow. E.g.import os 
os.environ['OPEN_AI_KEY'] = 'sk-ekOvFjAHKETQYABBADABBADDAYADDA'Maybe you want to mimicgptprobe/public_setenv.pyand import NOTHING from it in your scripts.User GuideSee theREADMEin the askfor directory.See theexamples.TroubleshootingFile anissue. Pull requests are welcomed.
Package: gptpy
GPTPy: Your kind Python guide, powered by AI to fix errors and explain codeInstallationpipinstall-UgptpyUsageSimply run your codegptpyrunnable_python_code.py..or run with argumentsgptpyrunnable_python_code.py--arg1=1--arg2=2ExampleHere's a simple Python code, which has a syntax error.# test.pydefadd(a,b):print("a + b)If you runtest.py, you will get an error.$ python test.py 
  File "~/test.py", line 1
    print("a + b)
                 ^
SyntaxError: EOL while scanning string literalNow, let's usegptpyto fix the error.$ gptpy test.py 
--------------------------------------------------
[GPTPy] Your code has an error!
[GPTPy] Error Reason: 

# The user code is missing a closing quotation mark.
SyntaxError: EOL while scanning string literal

[GPTPy] Here's fixed code:

print("a + b")
--------------------------------------------------LimitationsGPT-3 is not perfect. It may not be able to fix all errors.It may take a while to get the result.
Package: gptq
🔮 GPTQ - Accurate Post-Training Compression for Generative Pretrained TransformersThis repo is a extended and polished version of the original code for the paperGPTQ: Accurate Post-training Compression for Generative Pretrained Transformers.🔥 SOTA on LLM PTQAn efficient implementation of the GPTQ algorithm2/3/4/8-bit quantized matrix full-precision vector product CUDA kernelBug fix for old consumer-grade GPU📥 Installationpipinstallgptq🛟 Install PyTorchgptqrequires PyTorch and GPU, and installing PyTorch with CUDA is tricky. To install PyTorch correctly, the following steps are recommended:runnvcc --versionto get the version. For example, the following result means we have cuda compiler version 116nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2022 NVIDIA Corporation
Built on Tue_Mar__8_18:18:20_PST_2022
Cuda compilation tools, release 11.6, V11.6.124
Build cuda_11.6.r11.6/compiler.31057947_0runpip install light-the-torchto install lttrunltt install --pytorch-computation-backend=cu116 torch torchvision torchaudioto install the torch suite. Please replace the116according to your environment!TODOGPTQ with CNNAlgorithm credits go toIST Austria Distributed Algorithms and Systems Lab
Package: gptq-api
GPTQAPI ServerLLM API server for AutoGPTQ model. This server is designed to be compatible with the OpenAI API, allowing you to seamlessly use OpenAI clients with it.InstallationBefore you can run the server, you need to install the necessary package. You can do this easily withpip:pipinstallgptq-apiUsageTo run the GPTQAPI Server, use the following command:python-mgptqapi.server[model-name][port]Themodel-nameargument is mandatory while theportargument is optional, if not provided, it will use 8000 as the default.You can also configure the server using a.envfile for convenience. Here's an example:# .env file
MODEL_NAME=robinsyihab/Sidrap-7B-v2-GPTQ
PORT=8000
WORKERS=1
SYSTEM_PROMPT=This.envfile sets default values for the model name, the port the server will listen on, the number of worker processes, and the system prompt which can be used to customize behavior.API SchemaThis server follows the OpenAI API schema, allowing for seamless integration with OpenAPI client libraries. You can utilize all typical endpoints as if you were using the actual OpenAI API, making it easier to integrate into your existing infrastructure if you're familiar with the OpenAI platform.Environment VariablesHere is a list of environment variables you can use to configure the server:MODEL_NAME: (required) Identifies which AutoGPTQ model to use.PORT: (optional) Specifies the port number on which to run the API server.WORKERS: (optional) Defines the number of worker processes for handling requests.SYSTEM_PROMPT: (optional) Sets the system prompt for the model if needed.[] Robin Syihab (@anvie)
Package: gptransits
gptransitsFit planetary transits and stellar signals at the same time with the help of gaussian processesInstallationAll python dependencies necessary for gptransits are available in pip (one of the package dependencies requires numpy to be installed beforehand). These can be seen insetup.py.gptransitscan be installed from pip:pipinstallgptransitsOr from the source:gitclonehttps://github.com/Fill4/gptransits.gitcdgptransits
pythonsetup.pyinstallGetting startedScript template (or ipython/jupyter notebook):importgptransitsmodel=gptransits.Model("lightcurve_file.txt","config_file.py")model.run()model.analysis(plot=True,fout="results_file.txt")The model is initialized by providing a light curve file and a configuration file.model=gptransits.Model("lightcurve_file.txt","config_file.py")The configuration file follows the structure in config_template.py. The available settings options can be seen insettings.py.The light curve file follows the format:#            time (days)              flux (frac)          flux_err (frac)
0.000000000000000000e+00 9.995755553299999763e-01 5.522560000000000197e-05
2.043337615740740618e-02 9.992535114099999616e-01 5.521756000000000196e-05
4.086675347222221838e-02 9.992965459599999489e-01 5.521029000000000160e-05Running the MCMC algorithm to sample the posterior:model.run()Analysis calls a collection of functions that evaluate the MCMC convergence:model.analysis(plot=True,fout="results_file.txt")The plot flag defines if the analysis also creates some plots of interest, in a created figures folder.The fout flag, if defined, defines the file where the calculated results for the model parameters are saved.Some examples ready to be run are available in theexamplesfolder.Each folder has a light curve and a configuration file. Light curve files have the .lc extension.The output folder saves the chain and posterior probabilities from emcee in case the save flag is set in the configuration.The figures folder holds the plots from the analysis function.
Package: gpt-repl
gpt-replInteractively play with GPT-based tools from the terminalDescriptionChatGPT needs a power-user mode.gpt-replgives you a terminal UI for interacting with ChatGPT and other GPT-based tools.The default mode,synth-chat, uses a ChatGPT-like chatbot built directly from GPT-3. It supports features not possible with ChatGPT, including:Write the prefix of the next responseGive instructions that will always be followed and never forgettenThis project is still in theearly stagesof development. It will have bugs and frequent breaking changes.InstallFor now, Python >=3.9 is required. Usepip3instead ofpipif necessary.pipinstall-Ugpt-replIf you don't have an OpenAI API keycreate one hereand set it:exportOPENAI_API_KEY="<your api key>"Usagegpt-repl@my-thread[-mmode-name]Usegpt-repl modesto list available REPL modes andgpt-repl threadsto list open threads.Inside the REPL, type.helpfor a list of commands and keyboard shortcuts.TipsConversation SeedsConversation seeds give you extremely strong influence over the chatbot's behavior..seed You must write your message using only lowercase lettersAll future responses will only use lowercase letters (usually). Seeds are never forgotten. Seeds are best phrased as statements of fact or commands. See.helpfor examples.Forced Response PrefixIf you aren't getting a response you like, you can directly specify how the next response must start using:>. For example, if you send:Give me Pong in Pygame :> Here is the code:Then the response will start withHere is the code:.Useful CommandsSee.helpfor a full list, but these are some particularly important commands:.clearorC-x + C-cto clear the screen.neworC-x + C-nto reset the thread.redoorC-x + C-rto resample the response.undoorC-x + C-uto rewrite your most recent messageCustom ModesAdd a Python file thatlooks like thisto$GPT_REPL_CONFIG_PATH/plugins/. By default this will be~/.config/gpt_repl/plugins/.Seegpt_repl/modesfor more complete examples.DevelopmentTo installgpt-replfrom source:gitclonegit@github.com:veered/gpt-repl.gitcdgpt-repl
pipinstall-Uflit
flitinstall-sScreenshot
Package: gptrepo
gptrepoThis is a fork of the very excellentgpt-repository-loaderby mpoon.Usagepipinstallgptrepogptrepo# now output.txt should appear in the current directoryThis tool concatenates through all the files in the repo and adds ai prompts which can be used for chat gpt conversations.Simply open up the file, copy and paste it into the chat gpt window and then ask your question about the code.This will be particularly useful when chat gpt4-32k is released. Right now this will only work on very small repos.gptrepois a command-line tool that converts the contents of a Git repository into a text format, preserving the structure of the files and file contents. The generated output can be interpreted by AI language models, allowing them to process the repository's contents for various tasks, such as code review or documentation generation.ContributingSome context around building this islocated here. Appreciate any issues and pull requests in the spirit of having mostly GPT build out this tool. UsingChatGPT Plusis recommended for quick access to GPT-4.Running TestsTo run the tests forgptrepo, follow these steps:Ensure you have Python 3 installed on your system.Navigate to the repository's root directory in your terminal.Run the tests with the following command:toxNow, the test harness is added to thegptrepoproject. You can run the tests by executing the commandtoxin your terminal.LicenseThis project is licensed under the MIT License - see the LICENSE file for details.Versions1.0.3: Remove media files from concatenation.
Package: gpt-repository-loader
gpt-repository-loadergpt-repository-loaderis a command-line tool that converts the contents of a Git repository into a text format, preserving the structure of the files and file contents. The generated output can be interpreted by AI language models, allowing them to process the repository's contents for various tasks, such as code review or documentation generation.Installation & Usagepip install gpt-repository-loaderinstall the project locally.Now you'll be able to use the console scriptgpt-repository-loaderwith any project.gpt-repository-loader /path/to/git/repository -cthis will copy the content of the project into clipboard which you can directly paste intoYou can also now usegpt-repository-loaderas a library.fromgpt_repository_loaderimportgit_repo_to_textrepo_text=git_repo_to_text('/path/to/repository')ContributingSome context around building this islocated here. Appreciate any issues and pull requests in the spirit of having mostly GPT build out this tool. UsingChatGPT Plusis recommended for quick access to GPT-4.Getting Started with contributionTo get started withgpt-repository-loader, follow these steps:Ensure you have Python 3 installed on your system.Clone or download thegpt-repository-loaderrepository.Navigate to the repository's root directory in your terminal.Rungpt-repository-loaderwith the following command:pythongpt_repository_loader.py/path/to/git/repositoryReplace/path/to/git/repositorywith the path to the Git repository you want to process.The tool will generate an output.txt file containing the text representation of the repository. You can now use this file as input for AI language models or other text-based processing tasks.Running TestsTo run the tests forgpt-repository-loader, follow these steps:Ensure you have Python 3 installed on your system.Navigate to the repository's root directory in your terminal.Run the tests with the following command:python-munittesttest_gpt_repository_loader.pyNow, the test harness is added to thegpt-repository-loaderproject. You can run the tests by executing the commandpython -m unittest test_gpt_repository_loader.pyin your terminal.LicenseThis project is licensed under the MIT License - see the LICENSE file for details.
Package: gpt-review
gpt-reviewA Python based CLI and GitHub Action to use Open AI or Azure Open AI models to review contents of pull requests.How to install CLIFirst, install the package viapip:pipinstallgpt-reviewGPT API credentialsYou will need to provide an OpenAI API key to use this CLI tool. In order of precedence, it will check the following methods:Presence of a context file atazure.yamlor whereverCONTEXT_FILEpoints to. Seeazure.yaml.templatefor an example.AZURE_OPENAI_API_URLandAZURE_OPENAI_API_KEYto connect to an Azure OpenAI API:exportAZURE_OPENAI_API=<yourazureapiurl>exportAZURE_OPENAI_API_KEY=<yourazurekey>OPENAI_API_KEYfor direct use of the OpenAI APIexportOPENAI_API_KEY=<youropenaikey>AZURE_KEY_VAULT_URLto use Azure Key Vault. Put secrets for the url atazure-open-aiand the API Keyazure-openai-key, then run:exportAZURE_KEY_VAULT_URL=https://<keyvault_name>.vault.azure.net/
azloginMain CommandsTo show help information about available commands and their usage, run:gpt--helpTo display the current version of this CLI tool, run:gpt--versionHere are the main commands for using this CLI tool:1. Ask a QuestionTo submit a question to GPT and receive an answer, use the following format:gptask"What is the capital of France?"You can customize your request using various options like maximum tokens (--max-tokens), temperature (--temperature), top-p value (--top-p), frequency penalty (--frequency-penalty), presence penalty (--presence-penalty), etc.Ask a Question about a FileTo submit a question to GPT with a file and receive an answer, use the following format:gptask--filesWordDocument.docx"Summarize the contents of this document."2. Review a PRTo review a PR, use the following format:gptgithubreview\--access-token$GITHUB_ACCESS_TOKEN\--pull-request$PULL_REQUEST_NUMBER\--repository$REPOSITORY_NAME3. Generate a git commit message with GPTTo generate a git commit message with GPT after having added the files, use the following format:gitadd.

gptgitcommitFor more detailed information on each command and its options, run:gptCOMMAND--helpReplace COMMAND with one of the main commands listed above (e.g., 'ask').Developer SetupTo install the package in development mode, with additional packages for testing, run the following command:pipinstall-e.[test]
Package: gpt-review-with-precondition
gpt-review-with-preconditionsummerynotion 上にある技術文書を前提とした PR レビューを行いますfor userEnvioronment Variablesinstallpipinstallgpt-review-with-preconditionsave-precondition コマンドsave-precondition${NOTION_DATABASE_ID}notion document を取得して前提条件のためのデータを保存します。NOTION_DATABASE_ID
指定した id の Notion Database から ドキュメントを取得します。inputs/notion_database_query.jsonで取得条件を指定できます。inputs/notion_document_ids.jsonに指定された id のドキュメントも併せて取得します。// example notion_database_query{"filter":{"or":[{"property":"status","select":{"equals":"approved"}},{"property":"status","select":{"equals":"posted"}},]}}// example notion_document_ids["id1","id2"]gpt-review-with-precondition コマンドgpt-review-with-precondition前提条件付きでinputs/prompt.mdに記載されたプロンプトを実行します。for developer setuppipinstallpoetry
makeinstall
Package: gptrim
gptrim is a Python library designed to help you trim text inputs, making
it easier to fit more content within GPT’s context window. By
tokenizing, stemming, and removing spaces, this library prepares your
text inputs for efficient processing with GPT models.Installationpip install gptrimUsagefromgptrimimporttrimtext="This is an example sentence to demonstrate gptrim usage."trimmed_text=trim(text)print(trimmed_text)
Package: gptroles
GPT RolesSimple PyQT chatbox that connects to a chat session with ChatGPT, along with some extra desktop integration features.Written as an experiment with Qt and understanding the role of LLMs in virtual assistant applications.RoleplayerIt has a "roleplaying" root prompt that attempts to make implementing more roles into ChatGPT easier.
You can add "roles" to the root prompt, by default there are some roles related to commands and programming.You can also change the root prompt to something else entirely, there's a list of some prompts that are sourced online, see features.Command RoleNot fully implemented- RoleGPT can request web pages or from APIs to answer your questions.
    e.g. get current prices or latest news.
- Provide basic shell commands that will be automatically be run, to find or list files etc
- Instructions to format markdown for the programming featuresApp FeaturesProgramming related features:- Run shell or python code in markdown blocks directly in the chat interface
- Edit the markdown blocks in the chat box
- Copy or save markdown blocks to a fileAdditional features:- Easily switch or add more "roles"
- Remove the roleplaying root prompt and set it as you please
- List roles from jailbreakchat.com and set them as the root promptChat related features:- TODO Shows which messages are in the current prompt chain and can be added/removed
- TODO Show alternate choices and commit to conversationInstalling/RunningFrom pipInstall the module and install desktop launcher integration:pip install gptroles && ./install.shFrom source with Poetrypoetryinstall&&poetryrunmainPackaged AppImage/PyInstallerTODODevelopment installationUse thedev.shscript.# This only needs to be run once./dev.shbuild&&./dev.shsysinstall&&./dev.shinstall# Then you can run with the install and dev environment matching code./dev.shrun
Package: gpt-scrapper
GPT Code ScrapperThe simple code that scraps the code for the further analysis by the ChatGPT.Github:https://github.com/danpeczek/gpt-scrapperInstallation$pipinstallgpt-scrapperUsageUsage:gpt-scrapper[OPTIONS]PATHOptions:-e,--extensionsTEXTExtensionstosearchfor--helpShowthismessageandexit.The result scrapped code should be available in theoutput.txtfile.LicenseMIT LICENSE
Package: gpt-scrolls
gpt-scrollsA collaborative collection of open-source safe GPT-3 prompts that work wellFeel free to contribute your prompts!Getting StartedTo use gpt-scrolls, you'll need access to the OpenAI API. If you haven't,sign up for the beta.$ pip install gpt-scrolls
$ export OPENAI_API_KEY=...
$ python -c "import scrolls; print(scrolls.run('creative/philosopher'))"

I perused with interest and some confusion the very detailed description of autonomous society as envisioned by the creators of this simulation, for it reminded me of the doomed civilization of the Onos; they too desired self-replicating programs, a necessary foundation in real-space for artificial intelligence; and the created what they thought was self-replicating, except that they had no command over the experiment; it was uncontrollable, and indeed uncontrollable in about 90 minutes.

$ python -c "import scrolls; print(scrolls.run('creative/business-ideas'))"
Last Mile - Same day delivery service that picks and takes out the trash and deliversRunning scrolls in your own appimport scrolls

idea = scrolls.run('creative/business-ideas')
print(idea)Running locallyIf you want to use gpt-scrolls withoutpipby cloning the repo:$ git clone git@github.com:maraoz/gpt-scrolls.git
$ cd gpt-scrolls/
$ python3 -m venv .scrolls-env
$ source .scrolls-env/bin/activate
(.scrolls-env) $ pip install -r requirements.txt
(.scrolls-env) $ export OPENAI_API_KEY=...
(.scrolls-env) $ python scrolls/run.py "top10/women"
~~~Rosa Parks

2. ~~~Cleopatra

3. ~~~Joan of Arc

4. ~~~Madonna

5. ~~~Queen Elizabeth I

6. ~~~Elizabeth II

7. ~~~Tamar

8. ~~~Billie Jean King

9. ~~~Catherine the Great

10. ~~~Elizabeth INote: I'm planning to turn this into a easy-to-use CLI tool.Design goalsgpt-scroll prompts should aim to be:effective: they should reliably produce desired classes of outpuptsefficient: they should be as short as possiblesafe: they should minimize appearance of toxic/harmful outputHave this in mind for any contribution. (eg: if you find that a prompt works equally well without one example, you might submit a PR to remove that example, citing efficiency)
Package: gptsubtitler
SubtitlerAutomatically subtitle any video spoken in any language to a language of your choice using AI.Models used:OpenAI whisper C++ port- for audio-to-textFacebook M2M10- for translationTools used:ffmpegPlease don't forget to star the repository if you find it useful or educational!Before:https://github.com/extremq/subtitler/assets/45830561/49f6ecce-cfdc-4f1c-97eb-07a36ac841c9After (in Romanian -model_type=medium, language_model_type=base):https://github.com/extremq/subtitler/assets/45830561/20bc5169-0ce3-47cd-adb7-15d75daf27f4SetupInstall usingpip.pip install gptsubtitlerInstallffmpeg:# Ubuntu or Debiansudoaptupdate&&sudoaptinstallffmpeg# MacOSbrewinstallffmpeg# Windows using Chocolatey https://chocolatey.org/chocoinstallffmpegQuick guideExample usage for adding subtitles and translating them in Romanian:Command line:gptsubtitlersoldier.mp4--source_languageen--target_languagero--captioning_model_typemedium--language_model_typebaseOr in PythonfromgptsubtitlerimportTranscriber# I strongly recommend using the "medium" model_type.Transcriber.transcribe("soldier.mp4",source_language="en",target_language="ro",captioning_model_type="medium",language_model_type="base")You can also use theTranslatorclass fromtranslator.pyif you just want to translate some text.Example usage for translating from English to Romanian:fromgptsubtitlerimportTranslatorprint(Translator.translate("Hi!",target_language="ro",source_language="en"))If you have generated a.srtfile and just want to add subtitles:fromgptsubtitlerimportcreate_video_with_subtitlescreate_video_with_subtitles("video.mp4","output.srt","video_subtitled.mp4")OptionsArgs:
    video_file (str): Path to video file.

    output_video_file (str, optional): Path to output video file. Defaults to video_file_subtitled.

    output_subtitle_file (str, optional): Path to output SRT file. Defaults to "output.srt".

    source_language (str, optional): Source language for translation. Defaults to en.

    target_language (str, optional): Target language for translation. Defaults to None.

    captioning_model_type (str, optional): Model type. Defaults to "base".

    language_model_type (str, optional): Language model type. Defaults to "base".

    model_dir (str, optional): Path to model directory. Defaults to None.Available options forcaptioning_model_type(the audio to text model):tinybase - defaultsmallmediumlargeAvailable options forlanguage_model_type(the language translator model):base - defaultlarge