Creating good documentation is hard โ but what if your README.md wrote itself?
Introducing the AI-Powered README Generator, a command-line tool that uses Google's Generative AI (Gemini) and LangChain to generate detailed and structured README.md files for public GitHub repositories.
๐ Say goodbye to boring READMEs. Let AI do the heavy lifting.
๐ง What It Does
Given a GitHub repository URL, this tool:
- Connects to the GitHub API to fetch repository contents
- Understands the file structure and purpose
- Uses a Large Language Model (via LangChain + Gemini)
- Generates a professional-quality
README.mdfile โ automatically! - Updates/Creates the
README.mdfile in the github repo if you own it
๐ง Why Use It?
This tool is perfect for:
โ
Instantly generating initial READMEs for new projects
โ
Refreshing stale documentation with up-to-date content
โ
Learning how to integrate LLMs with external APIs in a real-world scenario
๐ฆ Installation
Here's how you can get it up and running in 5 steps:
- Clone the repo
git clone https://github.com/kanugurajesh/DocMind
cd DocMind
- Set up a virtual environment
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
- Install dependencies
pip install -r requirements.txt
- Setup .env file
โ๏ธ How to Use
Just run the main.py script with the GitHub repository URL:
python main.py https://github.com/octocat/Spoon-Knife
๐ It will generate a README_generated.md file in your current directory with the AI-crafted content.
โจ Features
๐ค LLM-Powered Documentation โ Uses Gemini through LangChain to generate context-aware, high-quality markdown.
๐ GitHub Integration โ Fetches the file structure using PyGithub.
๐ป CLI Tool โ Simple and effective to use right from your terminal.
๐ Modular Codebase โ Cleanly separated into agents and utils.
๐ Environment-Based Secrets โ Uses .env for secure API key handling.
๐งช Example
Want to try it on a real-world repo?
python main.py https://github.com/{username}/{repo_name}
Check your project folder โ you'll find a brand new README_generated.md waiting for you โ๏ธ
Github :- https://github.com/kanugurajesh/DocMind

Top comments (0)