Skip to main content

A package leveraging ChatGPT to print out motivational quotes and one-liners.

Project description

Motivate Me

This simple Python package leverages ChatGPT to provide motivation to help you out.

This README file serves as the package's documentation.

Installation

Install using pip:

pip install motivate-me

Usage

Ensure that your OpenAI key is an environmental variable. You can do this a few ways:

  1. Placing it in your .env file and sourcing it (. .env)
  2. Exporting the key: export OPENAI_API_KEY="your_key"

Assuming your OpenAI key is in your environmental variables:

>>> import os
>>> from motivate_me import motivate
>>> motivate(os.environ['OPEN_AI_KEY'])
Believe in yourself and your abilities, success is within your reach. Keep pushing forward with determination and watch your achievements unfold.

This will print out a motivational one-liner. We can change this to a quote by passing in type = "quote" as a parameter

>>> motivate(os.environ['OPEN_AI_KEY'], type = "quote")
"Don't be a pessimist, it won't work anyway!" - Yogi Berra.

You can also increase the number of (maximum) characters for the quote by passing in n_words (default: 30):

>>> motivate(os.environ['OPEN_AI_KEY'], n_words = 100)

Note that this may not necessarily give you a 100 word quote; this just increases the number of words that can be allocated in a quote.

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

motivate-me-0.1.0a1.tar.gz (3.2 kB view hashes)

Uploaded Source

Built Distribution

motivate_me-0.1.0a1-py3-none-any.whl (3.3 kB view hashes)

Uploaded Python 3

Supported by

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