Skip to main content

๐Ÿš€ Generate awesome README.md files from the terminal, powered by OpenAI's GPT language model APIs ๐Ÿ’ซ

Project description


README-AI

โ—ฆ Generate beautiful and informative README.md documents.

โ—ฆ Developed with OpenAI's GPT language model APIs.


Markdown OpenAI Python pytest Bash Anaconda

PyPI - License PyPI - Python Version GitHub license GitHub last commit

๐Ÿ“– Table of Contents


๐Ÿ“ Overview

README-AI is a powerful, user-friendly command-line tool that generates extensive README markdown documents for your software and data projects. By providing a remote repository URL or directory path to your codebase, this tool will document your entire project, leveraging the capabilities of large language models and OpenAI's GPT APIs.

๐ŸŽฏ Motivation

Simplifies the process of writing and maintaining high-quality project documentation. My aim for this project is to provide all skill levels a tool that improves their technical workflow, in an efficient and user-friendly manner. Ultimately, the goal of README-AI is to improve the adoption and usability of open-source projects, enabling everyone to better understand and use open-source tools.

โš ๏ธ Disclaimer

README-AI is currently under development and has an opinionated configuration and setup. While this tool provides an excellent starting point for documentation, its important to review all text generated by the OpenAI API to ensure it accurately represents your codebase. Ensure all content in your repository is free of sensitive information before executing.

Additionally, frequently monitor your API usage and costs by visiting the OpenAI API Usage Dashboard.


๐Ÿ‘พ Demo

demo video

โš™๏ธ Features

1.
๐Ÿ‘‡

๐Ÿ“‘ Codebase Documentation

โ—ฆ Repository File Summaries

  • Code summaries are generated for each file via OpenAI's gpt-3.5-turbo engine.
  • The File column in the markdown table contains a link to the file on GitHub.
docs

โ’‰
๐Ÿ‘‡

๐ŸŽ– Badges

โ—ฆ Introduction, Badges, & Table of Contents

  • The OpenAI API is prompted to create a 1-sentence phrase describing your project.
  • Project dependencies and metadata are visualized using Shields.io badges.
  • Badges are sorted by hex code, displayed from light to dark hues.
docs

โ’Š
๐Ÿ‘‡

๐Ÿงš Prompted Text Generation

โ—ฆ Features Table & Overview

  • Detailed prompts are embedded with repository metadata and passed to the OpenAI API.
    • Features table highlights various technical attributes of your codebase.
    • Overview section describes your project's use case and applications.
features overview

โ’‹
๐Ÿ‘‡

๐ŸŒฒ Repository Tree

tree

โ’Œ
๐Ÿ‘‡

๐Ÿ“ฆ Dynamic User Setup Guides

โ—ฆ Installation, Usage, & Testing

  • Generates instructions for installing, using, and testing your codebase.
  • README-AI currently supports this feature for code written with:
    • Python, Rust, Go, C, Kotlin, Java, JavaScript, TypeScript.
getting_started

โ’
๐Ÿ‘‡

๐Ÿ‘ฉโ€๐Ÿ’ปContributing Guidelines & more!

contribute

โ’Ž
๐Ÿ‘‡

๐Ÿ’ฅ Example Files

Markdown example files generated by the README-AI app!

Example File Repository Language Bytes
1๏ธโƒฃ readme-python.md readme-ai Python

19,839

2๏ธโƒฃ readme-typescript.md chatgpt-app-react-typescript TypeScript, React

988

3๏ธโƒฃ readme-javascript.md assistant-chat-gpt-javascript JavaScript, React

212

4๏ธโƒฃ readme-kotlin.md file.io-android-client Kotlin, Java, Android

113,649

5๏ธโƒฃ readme-rust-c.md rust-c-app C, Rust

72

6๏ธโƒฃ readme-go.md go-docker-app Go

41

7๏ธโƒฃ readme-java.md java-minimal-todo Java

17,725

8๏ธโƒฃ readme-fastapi-redis.md async-ml-inference Python, FastAPI, Redis

355

9๏ธโƒฃ readme-mlops.md mlops-course Python, Jupyter

8,524

๐Ÿ”Ÿ readme-pyflink.md flink-flow PyFlink

32

โ’
๐Ÿ‘‡

๐Ÿ“œ Custom README templates coming soon!

Developing a feature that allows users to select from a variety of README formats and styles.

Custom templates will be tailored for use-cases such as data, ai & ml, research, minimal, and more!

๐Ÿ” Return


๐Ÿš€ Getting Started

โœ”๏ธ Dependencies

Before you begin, ensure that you have the following prerequisites installed:

  • Python 3.9 or higher
  • Conda or Poetry package manager (recommended)
  • Access to the OpenAI API (see the setup guide below)

๐Ÿ“‚ Repository

Most user's will run README-AI using the command-line, specifying their repository on run-time. However, if you would like to use the default configuration, you will need to update the configuration file with your repository's remote URL (GitHub, GitLab) or local directory path on your machine.

[git]
repository = "Insert your repository URL or local path here!"

๐Ÿ” OpenAI API

To use the README-AI application, you will need to create an account with OpenAI to generate an API key. The steps below outline this setup process:

OpenAI API User Guide
  1. Go to the OpenAI website.
  2. Click the "Sign up for free" button.
  3. Fill out the registration form with your information and agree to the terms of service.
  4. Once logged in, click on the "API" tab.
  5. Follow the instructions to create a new API key.
  6. Copy the API key and keep it in a secure place.

โš ๏ธ Note

  • To maximize your experience with README-AI, it is recommended to set up a payment method on OpenAI's website. By doing so, you gain access to more powerful language models like gpt-3.5-turbo. Without a payment method, your usage will be restricted to the base gpt-3 models. This limitation might lead to less precise README files or potential errors during the generation process.

  • When using a payment method, make sure you have sufficient credits to run the README-AI application. Additionally, remember to regularly monitor your API usage and costs by visiting the OpenAI API Usage Dashboard. Please note that this API is not free and you will be charged for each request made, which can accumulate rapidly.

  • The generation of the README.md file should typically complete in under 1 minute. If it takes longer than a few minutes, please terminate the process.


๐Ÿ“ฆ Installation

  1. Clone the readme-ai repository to your local machine.
git clone https://github.com/eli64s/readme-ai
  1. Navigate to the readme-ai directory.
cd readme-ai
  1. Use one of the following methods to install the required dependencies:

Pip (PyPI Package)

pip install readmeai

Bash

bash setup/setup.sh

Conda

conda create -n readmeai python=3.9 -y && \
conda activate readmeai && \
pip install -r requirements.txt

Poetry

poetry install

Docker

docker pull zeroxeli/readme-ai:0.0.6

๐ŸŽฎ Using README-AI

Use the command-line to provide the OpenAI API key (if not already set) and specify an output path for your README file, along with the path to your local repository or remote code repository. You can also provide the output path in the configuration file

Command-Line Arguments:

  • -k or --api-key: Your OpenAI API key.
  • -o or --output: The output path for your README.md file.
  • -r or --repository: The URL or path to your code repository.
  • -t or --template: The README template format to use. (coming soon!)
  • l or --language: The language of text written in the README file (coming soon!)

Pip (PyPI Package)

readmeai --api-key "YOUR_API_KEY" --output readme-ai.md --repository https://github.com/eli64s/readme-ai

# Or export your OpenAI API key as an environment variable
export OPENAI_API_KEY="YOUR_API_KEY"
readmeai -o readme-ai.md -r https://github.com/eli64s/readme-ai

Conda

python readmeai/main.py --api-key "YOUR_API_KEY" --output readme-ai.md --repository https://github.com/eli64s/readme-ai

# Or export your OpenAI API key as an environment variable
conda activate readmeai
export OPENAI_API_KEY="YOUR_API_KEY"
python readmeai/main.py -o readme-ai.md -r https://github.com/eli64s/readme-ai

Poetry

poetry shell
export OPENAI_API_KEY="YOUR_API_KEY"
poetry run python readmeai/main.py -o readme-ai.md -r https://github.com/eli64s/readme-ai

Docker

docker run -it \
-e OPENAI_API_KEY="YOUR_API_KEY" \
-v "$(pwd)":/app zeroxeli/readme-ai:0.0.6 \
readmeai -o readme-ai.md -r https://github.com/eli64s/readme-ai

๐Ÿงช Running Tests

To run the unit-tests for README-AI, use the following command.

bash scripts/test.sh

๐Ÿ” Return


๐Ÿ›  Future Development

  • Add additional language support for populating the installation, usage, and test README sections.
  • Upload the readme-ai CLI tool to PyPI under the module name readmeai.
  • Design and implement a variety of README template formats for different use-cases.
  • Add support for writing the README in any language (i.e. CN, ES, FR, JA, KO, RU).
  • Create UI with Textual or another framework to improve user experience.

๐Ÿ“’ Changelog

Changelog


๐Ÿค Contributing

Contributing Guidelines


๐Ÿ“„ License

MIT


๐Ÿ‘ Acknowledgments

Badges

๐Ÿ” Return


Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

readmeai-0.0.62.tar.gz (25.4 kB view details)

Uploaded Source

Built Distribution

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

readmeai-0.0.62-py3-none-any.whl (23.5 kB view details)

Uploaded Python 3

File details

Details for the file readmeai-0.0.62.tar.gz.

File metadata

  • Download URL: readmeai-0.0.62.tar.gz
  • Upload date:
  • Size: 25.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/21.6.0

File hashes

Hashes for readmeai-0.0.62.tar.gz
Algorithm Hash digest
SHA256 29c1fbb7f9a5e78bc84d5626f8df2645fdf33947e3a0c6ec9635b94c25445bd6
MD5 d096a4b70397441ae5127468d0a0ce06
BLAKE2b-256 1bd1bd2070f53e2e47ca1ed958e7d0f83b410989e0071878e9dc2b0626304118

See more details on using hashes here.

File details

Details for the file readmeai-0.0.62-py3-none-any.whl.

File metadata

  • Download URL: readmeai-0.0.62-py3-none-any.whl
  • Upload date:
  • Size: 23.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/21.6.0

File hashes

Hashes for readmeai-0.0.62-py3-none-any.whl
Algorithm Hash digest
SHA256 ed1283eefce2ffc27925ae04fc0ffe79a2b4994c29cad0ccb1e63975f8d267bd
MD5 9a921e2e82e03f37151ecb4fd99d863b
BLAKE2b-256 1cf69107ab2dc15f2f62e0f8f9412dbfc5f55b7c3fa6a172d0fbe5c66ea53bf4

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