Coder Social home page Coder Social logo

sent-hen / chat-gpt-api-token-generator Goto Github PK

View Code? Open in Web Editor NEW

This project forked from thehalvo/chat-gpt-api-token-generator

0.0 0.0 0.0 1 KB

A Python script to automatically generate short stories based on a preset prompt using OpenAI's GPT-3.5 API.

Python 100.00%

chat-gpt-api-token-generator's Introduction

Chat GPT API Token Generator

A Python script to automatically generate short stories based on a preset prompt using OpenAI's GPT-3.5 API. It's primary purpose is to use up tokens over an hour, so that your OpenAI account is billed at least $1, thereby giving you access to GPT-4 the following month.

Table of Contents

  1. Requirements
  2. Installation
  3. Usage
  4. Contribution
  5. Disclaimer

Requirements

  • Python 3.x
  • OpenAI Python package
  • An OpenAI API key

Installation

  1. Clone this repository:

    git clone https://github.com/thehalvo/Chat-GPT-API-Token-Generator.git
  2. Navigate into the project directory and install required packages:

    cd Chat-GPT-API-Token-Generator

Usage

  1. Set your OpenAI API key as an environment variable:

    export OPENAI_API_KEY="your-api-key-here"
  2. Run the script:

    python generator.py

This will generate random stories every 5 seconds. Please be aware that this might quickly use up your API quota, so use it judiciously. I recommend setting your API limit to $2 in your OpenAI settings before using this script.

Contribution

Feel free to fork the project, open a pull request, or submit suggestions and bugs as issues.

Disclaimer

This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with OpenAI. Be aware of the OpenAI API rate limits and the API usage cost when running the script.

chat-gpt-api-token-generator's People

Contributors

thehalvo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.