Skip to main content

This package ask_openai provides a single minimal implementation of a function decorator ask.

If the decorated function raises an error, the decorator asks OpenAI / GPT-3 to explain it to you.

Use as follows:

import os
from ask_openai import ask

ask = ask(api_key=os.environ['OPENAI_API_KEY'], logger=print)


@ask
def f(x):
    return 1 / 0

This will print something like:

OpenAI explanation: Division by zero is an error because a number cannot be divided by 0.

Metadata

Release files for ask-openai 0.1.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ask-openai 0.1.7
File Size Uploaded Provenance
ask_openai-0.1.7.tar.gz 1.8 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for ask-openai 0.1.7
File Interpreter ABI Platform
ask_openai-0.1.7-py3-none-any.whl Python 3 none any Details

Total release size: 3.8 kB

Release files / ask_openai-0.1.7.tar.gz

Download URL ask_openai-0.1.7.tar.gz
Size 1.8 kB
Tags Source
SHA-256 checksum
How to use checksums
93460974f1eb620fefe433f393eeadbd11e37b03bb57c0d463bd5fc4c569cd06
BLAKE2b-256 checksum
How to use checksums
b29c9f7a891629bc325005f1d66503b26e2cd04b8f88f2b977f7d5540bc6495d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.1 CPython/3.10.9 Linux/5.15.0-56-generic

Release files / ask_openai-0.1.7-py3-none-any.whl

Download URL ask_openai-0.1.7-py3-none-any.whl
Size 2.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a2d60830765c3d043487ff810146eee4692e1c5dab8dd067f1d9f6e173ee8145
BLAKE2b-256 checksum
How to use checksums
8f33250980fdd2577af863f7f0ee8e0956bf50b63ca7fbfbd8d7d73682d57eb3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.1 CPython/3.10.9 Linux/5.15.0-56-generic

Security for ask-openai 0.1.7

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page