Skip to main content

A Python package that uses OpenAI to check if numbers are even

Project description

openai_is_even

A Python package that uses OpenAI to check if numbers are even ✨

Description

Instead of using boring traditional math to check if a number is even, this package asks OpenAI's GPT model to determine the evenness of numbers with AI-powered vibes.

Installation

pip install openai-is-even

Or with uv:

uv add openai-is-even

Requirements

  • Python >= 3.10
  • OpenAI API key set in the OPENAI_API_KEY environment variable

Usage

export OPENAI_API_KEY=your_key_here
from openai_is_even import openai_is_even

# Check if numbers are even
result = openai_is_even(4)  # Returns True
result = openai_is_even(3)  # Returns False

Development

This project uses uv for dependency management.

Setup

# Clone the repository
git clone https://github.com/d-costa/openai_is_even.git
cd openai_is_even

# Install dependencies
uv sync

# Set up your OpenAI API key
export OPENAI_API_KEY="your-api-key-here"

Running Tests

uv run pytest -v

Disclaimer

This package is for entertainment and educational purposes. Please use traditional mathematical operations to check if numbers are even. 😄

Inspired by https://github.com/abyesilyurt/vibesort

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openai_is_even-1.0.1.tar.gz (1.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

openai_is_even-1.0.1-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file openai_is_even-1.0.1.tar.gz.

File metadata

  • Download URL: openai_is_even-1.0.1.tar.gz
  • Upload date:
  • Size: 1.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.8

File hashes

Hashes for openai_is_even-1.0.1.tar.gz
Algorithm Hash digest
SHA256 ca018d2063afb400e3811ac8272bf4fb7718997c9c68c3c1920d3f37974ca3e9
MD5 0e07a3c6538b19637441d9866d6e968e
BLAKE2b-256 567336126cdf6ce67bbe2e5737c43ed8d62b97922bfb8d793b173825ed9c2dff

See more details on using hashes here.

File details

Details for the file openai_is_even-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for openai_is_even-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2a6bcebbc604cf5838d99407d49f48f1107ddc137c612887fdaf3258b603a3a6
MD5 9dc7c07cf2bce9a89df14dc8c1f20a29
BLAKE2b-256 bcc91a569dff3e7a591dfc3333536b0003c02c2d98343c4db4d8685521da7e19

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page