Skip to main content

pipe-pai is a simple command-line tool that allows you to interact with OpenAI models through Unix pipes

Project description

pipe-pai

pipe-pai is a simple command-line tool that allows you to interact with OpenAI models through Unix pipes. Use it like this: ... | pai - hence the name "pipe-pie".

Installation

Install via pipx (recommended):

pipx install pipe-pai

Or with pip:

pip install pipe-pai

Ensure your OpenAI API key is set in the environment:

export OPENAI_API_KEY="your_api_key_here"

Usage

Pipe a prompt to pai and receive the model's response on stdout:

echo "Write a haiku about the sea" | pai

Specify a different model or API key:

echo "Tell me a joke" | pai --model gpt-4 --api-key $OPENAI_API_KEY

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

pipe_pai_tool-0.1.0.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

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

pipe_pai_tool-0.1.0-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file pipe_pai_tool-0.1.0.tar.gz.

File metadata

  • Download URL: pipe_pai_tool-0.1.0.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for pipe_pai_tool-0.1.0.tar.gz
Algorithm Hash digest
SHA256 15145803103a9d9a9c3e57978ca24279ed8da44fe048c0f3ad5e66089210c5b5
MD5 64142247243e26b711f885ec2109b964
BLAKE2b-256 595a7b11121916a538635c28164471fc30329a5ade44a3c16f5a3ee94bfc740b

See more details on using hashes here.

File details

Details for the file pipe_pai_tool-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pipe_pai_tool-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for pipe_pai_tool-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 484d45b9a34e9044bdc2525e7e1cec9e5dc09b2f1b0581fe5a0195759be8d6fa
MD5 adcc211dd83a31006afa80827924ab09
BLAKE2b-256 991eaee2f20d2a4547d3fd86ad3ab351e267c71f52e3b39a6f4ed99ce574d4d4

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