automate-docs 0.0.7
A tool to automate readme generation
License: MIT
Requires Python: >=3.6
Keywords: readme, automation, readme, git

# Automate Docs

## Project Description

Automate Docs is a powerful tool designed to streamline the process of generating informative and structured README files for GitHub repositories. Leveraging the capabilities of Liberty GPT, this tool analyzes your project's structure and content to produce a professional README that enhances documentation quality and aids project comprehension.

## Key Features

- **Repository Cloning:** Automatically clone any GitHub repository to analyze its structure and content.
- **Detailed Project Analysis:** Generate a comprehensive project tree for an in-depth understanding of the repository's layout.
- **Intelligent Content Extraction:** Extracts and analyzes key contents from pertinent files within the project.
- **AI-Powered README Generation:** Utilizes advanced AI to craft high-quality README.md documents tailored to your project specifics.
- **Backup and Update Mechanism:** Prior to generating a new README, existing files are backed up to prevent data loss.
- **User-Friendly Command Line Interface:** Offers simple command-line operations for effortless usage.

## Technology Stack

- **Python:** Core programming language used in the development of this tool.
- **Liberty GPT:** Artificial Intelligence from Liberty Mutual, used for generating README contents.
- **Git:** Utilized for repository cloning and management.

## Installation Instructions

To set up and use Automate Docs, follow these steps:

1. **Obtain Liberty GPT API Access Key:**
   - Visit the [CORTEX webpage](https://cortex-lab.lmig.com/me), log in, and navigate to the USER ACCESS TOKENS section.
   - Copy the **User Token** and create a `.env` file to store it as `"ACCESS_KEY="`.

2. **Clone the Repository:**
   ```bash
   git clone https://github.com/lmigtech/automate-docs.git
   cd automate-docs
   ```

3. **Setup Virtual Environment:**
   Run the setup script corresponding to your operating system:
   - **Windows:**
     ```bash
     chmod +x windows_setup.sh
     ./windows_setup.sh
     ```
   - **macOS:**
     ```bash
     chmod +x macos_setup.sh
     ./macos_setup.sh
     ```

4. **Run the Main Script:**
   Start the README generation process by specifying the repository.
   ```bash
   python automate_readme/main.py [repository URL]
   ```

## Usage Examples

Here is an example command to generate a README for a repository:

```bash
python automate_readme/main.py https://github.com/user/repository.git
```

This command clones the specified repository, analyzes its structure, and generates a README.md within the cloned directory.

### Important: 
The cloned repository files will be stored under `temp_repo_analysis/cloned_repo`.

## Project Structure Overview

The Automate Docs project is organized as follows:

```
automate-docs/
├── automate_docs.egg-info/
├── automate_readme/
│   ├── __init__.py
│   ├── main.py
│   └── request.py
├── bin/
│   └── runMain
├── devEnv/
├── temp_repo_analysis/
├── LICENSE
├── README.md
├── setup.py
└── requirements.txt
```

- **`automate_readme`:** Contains the main logic for README generation.
- **`temp_repo_analysis`:** Directory where analysis outputs and cloned project files are stored.
- **`setup.py`:** Instructions for packaging the application.
- **`README.md`:** Documentation for the project.

## Configuration Details

- **AI Access Key:** Ensure API keys are securely stored as environment variables for authentication.
- **File Inclusion/Exclusion:** Customize file types for inclusion or exclusion via `main.py`.

## Contributing Guidelines

Contributions are welcome! To contribute:

1. Fork the repository and create your branch from `main`.
2. Make your changes, ensuring comprehensive testing.
3. Submit a pull request for review.

## License Information

This project is licensed under the [MIT License](LICENSE). This specifies open-source permissions for use, modification, and distribution of the software. Please review the license to understand your legal rights and responsibilities.

---

Feel free to customize this README further to suit the specific details and requirements of your project.