https://github.com/deepset-ai/prompthub-py

https://github.com/deepset-ai/prompthub-py

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.3%) to scientific vocabulary
Last synced: 5 months ago · JSON representation

Repository

Basic Info
  • Host: GitHub
  • Owner: deepset-ai
  • License: apache-2.0
  • Language: Python
  • Default Branch: main
  • Size: 41 KB
Statistics
  • Stars: 3
  • Watchers: 2
  • Forks: 3
  • Open Issues: 1
  • Releases: 0
Created almost 3 years ago · Last pushed almost 3 years ago
Metadata Files
Readme License

README.md

Prompt Hub Python Client

PyPI - Version Tests

A simple client to fetch prompts from Prompt Hub using its REST API.

Usage

First step is obviously installation:

pip install prompthub-py

Then you can import Prompt, that class is all you're going to need.

```python import prompthub

To load from a JSON file

p = prompthub.from_json("./path/to/my/prompt.json")

To load from a YAML file

p = prompthub.from_yaml("./path/to/my/prompt.yaml")

To load from Prompt Hub

p = prompthub.fetch("deepset/question-answering")

To get the prompt text (see Prompt class)

p.text ```

If you want to use a different Prompt Hub you must set the PROMPTHUB_MAIN_ENDPOINT environment variable to your main endpoint.

If the environment variable is not set the default api.prompthub.deepset.ai will be used.

Testing

To run tests locally first install dev dependencies, we use poetry to manage our dependencies:

poetry install --with=dev

Run Prompt Hub locally with a set of fake prompts:

docker run -p80:80 --volume $PWD/test/fake_prompts:/prompts deepset/prompthub

And then run tests:

poetry run pytest test

Owner

  • Name: deepset
  • Login: deepset-ai
  • Kind: organization
  • Email: hello@deepset.ai
  • Location: Berlin, Germany

Building enterprise search systems powered by latest NLP & open-source.

GitHub Events

Total
Last Year

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 1
  • Total pull requests: 7
  • Average time to close issues: N/A
  • Average time to close pull requests: about 13 hours
  • Total issue authors: 1
  • Total pull request authors: 2
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.14
  • Merged pull requests: 6
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • bilgeyucel (1)
Pull Request Authors
  • ZanSara (6)
  • silvanocerza (1)
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 41,554 last-month
  • Total docker downloads: 42
  • Total dependent packages: 1
  • Total dependent repositories: 7
  • Total versions: 10
  • Total maintainers: 1
pypi.org: prompthub-py
  • Versions: 10
  • Dependent Packages: 1
  • Dependent Repositories: 7
  • Downloads: 41,554 Last month
  • Docker Downloads: 42
Rankings
Downloads: 1.1%
Docker downloads count: 3.2%
Average: 3.7%
Dependent packages count: 4.8%
Dependent repos count: 5.5%
Maintainers (1)
Last synced: 5 months ago