# DocsGPT | Open-Source Documentation Assistant

**URL:** <https://onehack.st/t/docsgpt-open-source-documentation-assistant/294436>\
**Category:** Tools & Scripts\
**Tags:** tools, programming, ai, gaming\
**Created:** [October 26, 2024, 7:49pm UTC](https://onehack.st/t/docsgpt-open-source-documentation-assistant/294436 "2024-10-26T19:49:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prometheus](https://onehack.st/user_avatar/onehack.st/prometheus/32/34950_2.png) [@Prometheus](https://onehack.st/u/Prometheus)\
**Post date:** [October 26, 2024, 7:49pm UTC](https://onehack.st/t/docsgpt-open-source-documentation-assistant/294436/1 "2024-10-26T19:49:00Z")

</div>

# DocsGPT 🦖

**Open-Source Documentation Assistant**

**[DocsGPT](https://www.docsgpt.cloud/)** is a cutting-edge open-source solution that streamlines the process of finding information in the project documentation. With its integration of the powerful **GPT** models, developers can easily ask questions about a project and receive accurate answers.

Say goodbye to time-consuming manual searches, and let **[DocsGPT](https://www.docsgpt.cloud/)** help you quickly find the information you need. Try it out and see how it revolutionizes your project documentation experience. Contribute to its development and be a part of the future of AI-powered assistance.

[![link to main GitHub showing Stars number](https://camo.githubusercontent.com/d2f392695bd68c10140e8d173bc9d71c92774c1d889b8530556ea2d2a5648a3c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f61726335332f646f63736770743f7374796c653d736f6369616c)](https://github.com/arc53/DocsGPT) [![link to main GitHub showing Forks number](https://camo.githubusercontent.com/e1b98526c87c0363e43c69a0a426bff73677a3c0f5b9141f674b67c348dd6756/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f61726335332f646f63736770743f7374796c653d736f6369616c)](https://github.com/arc53/DocsGPT) [![link to license file](https://camo.githubusercontent.com/46638aa4db289054e9199852b7428b34539276d205ba499350398671fc222b1a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f61726335332f646f6373677074)](https://github.com/arc53/DocsGPT/blob/main/LICENSE) [![link to discord](https://camo.githubusercontent.com/ee6b0196ebd3f7e624150404eb43b6a4ae270d0b90265f3ddfa39a42f455cb0f/68747470733a2f2f696d672e736869656c64732e696f2f646973636f72642f31303730303436353033333032383737323136)](https://discord.gg/n5BX8dh8rU) [![X (formerly Twitter) URL](https://camo.githubusercontent.com/60305c69a1109f90b6206d6f694659c98ba5d9aacfab752da776448651cbb916/68747470733a2f2f696d672e736869656c64732e696f2f747769747465722f666f6c6c6f772f646f63736770746169)](https://twitter.com/docsgptai)

### 🎃 [Hacktoberfest Prizes, Rules & Q&A](https://github.com/arc53/DocsGPT/blob/main/HACKTOBERFEST.md) 🎃

### Production Support / Help for Companies:

We’re eager to provide personalized assistance when deploying your DocsGPT to a live environment.

[![Let's chat](https://camo.githubusercontent.com/298517cca77af25bc85b9663f5f3981400cbfff904619bffae30dae85f45d5a5/68747470733a2f2f63616c2e636f6d2f626f6f6b2d776974682d63616c2d6461726b2e737667)](https://cal.com/arc53/docsgpt-demo-b2b)

[Send Email 📧](mailto:contact@arc53.com?subject=DocsGPT%20support%2Fsolutions)

[![video-example-of-docs-gpt](https://private-user-images.githubusercontent.com/82649533/376220259-9a1f21de-7a15-4e42-9424-70d22ba5a913.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjk4ODQzNDksIm5iZiI6MTcyOTg4NDA0OSwicGF0aCI6Ii84MjY0OTUzMy8zNzYyMjAyNTktOWExZjIxZGUtN2ExNS00ZTQyLTk0MjQtNzBkMjJiYTVhOTEzLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDEwMjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQxMDI1VDE5MjA0OVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTdjMTUwMjkyOTdhYjA4MWIxNGRlYzBhM2MwZDNkNDgwNDRkMDBlNzgwMjhmODdhYTRkZWY2ZmIxMmM4ZmM4NjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.kthfG4yam3aPJwEvx1krqiYzF4hysEnVlXQlyOlxq8E)](https://private-user-images.githubusercontent.com/82649533/376220259-9a1f21de-7a15-4e42-9424-70d22ba5a913.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjk4ODQzNDksIm5iZiI6MTcyOTg4NDA0OSwicGF0aCI6Ii84MjY0OTUzMy8zNzYyMjAyNTktOWExZjIxZGUtN2ExNS00ZTQyLTk0MjQtNzBkMjJiYTVhOTEzLmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDEwMjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQxMDI1VDE5MjA0OVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTdjMTUwMjkyOTdhYjA4MWIxNGRlYzBhM2MwZDNkNDgwNDRkMDBlNzgwMjhmODdhYTRkZWY2ZmIxMmM4ZmM4NjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.kthfG4yam3aPJwEvx1krqiYzF4hysEnVlXQlyOlxq8E)

## Roadmap

You can find our roadmap [here](https://github.com/orgs/arc53/projects/2). Please don’t hesitate to contribute or create issues, it helps us improve DocsGPT!

## Our Open-Source Models Optimized for DocsGPT:

| Name | Base Model | Requirements (or similar) |
| --- | --- | --- |
| [Docsgpt-7b-mistral](https://huggingface.co/Arc53/docsgpt-7b-mistral) | Mistral-7b | 1xA10G gpu |
| [Docsgpt-14b](https://huggingface.co/Arc53/docsgpt-14b) | llama-2-14b | 2xA10 gpu’s |
| [Docsgpt-40b-falcon](https://huggingface.co/Arc53/docsgpt-40b-falcon) | falcon-40b | 8xA10G gpu’s |

If you don’t have enough resources to run it, you can use bitsnbytes to quantize.

## End to End AI Framework for Information Retrieval

[![Architecture chart](https://private-user-images.githubusercontent.com/15183589/354305009-fc6a7841-ddfc-45e6-b5a0-d05fe648cbe2.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjk4ODQzNDksIm5iZiI6MTcyOTg4NDA0OSwicGF0aCI6Ii8xNTE4MzU4OS8zNTQzMDUwMDktZmM2YTc4NDEtZGRmYy00NWU2LWI1YTAtZDA1ZmU2NDhjYmUyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDEwMjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQxMDI1VDE5MjA0OVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWNlOTk0MjZmYzFkNmQ2ZGIwYThjOTIzYzA1NTdjZmZmMzczMmMwNzhkY2EyZmNmNDhiZmZlOTMxMmE2YzRiYTAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.iwcM34ql_gAmLGbEKLWXUUH3KQpgQFaecSuxs4OpwOk)](https://private-user-images.githubusercontent.com/15183589/354305009-fc6a7841-ddfc-45e6-b5a0-d05fe648cbe2.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjk4ODQzNDksIm5iZiI6MTcyOTg4NDA0OSwicGF0aCI6Ii8xNTE4MzU4OS8zNTQzMDUwMDktZmM2YTc4NDEtZGRmYy00NWU2LWI1YTAtZDA1ZmU2NDhjYmUyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDEwMjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQxMDI1VDE5MjA0OVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWNlOTk0MjZmYzFkNmQ2ZGIwYThjOTIzYzA1NTdjZmZmMzczMmMwNzhkY2EyZmNmNDhiZmZlOTMxMmE2YzRiYTAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.iwcM34ql_gAmLGbEKLWXUUH3KQpgQFaecSuxs4OpwOk)

## Useful Links

- 🔍 🔥 [Cloud Version](https://app.docsgpt.cloud/)
- 💬 🎉 [Join our Discord](https://discord.gg/n5BX8dh8rU)
- 📚 😎 [Guides](https://docs.docsgpt.cloud/)
- 👫 [Interested in contributing?](https://github.com/arc53/DocsGPT/blob/main/CONTRIBUTING.md)
- 📁 🚀 [How to use any other documentation](https://docs.docsgpt.cloud/Guides/How-to-train-on-other-documentation)
- 🏠 🔐 [How to host it locally (so all data will stay on-premises)](https://docs.docsgpt.cloud/Guides/How-to-use-different-LLM)

## Project Structure

- Application - Flask app (main application).
- Extensions - Chrome extension.
- Scripts - Script that creates similarity search index for other libraries.
- Frontend - Frontend uses [Vite](https://vitejs.dev/) and [React](https://react.dev/).

## QuickStart

Note

Make sure you have [Docker](https://docs.docker.com/engine/install/) installed

On Mac OS or Linux, write:

`./setup.sh`

It will install all the dependencies and allow you to download the local model, use OpenAI or use our LLM API.

Otherwise, refer to this Guide for Windows:

1. Download and open this repository with `git clone https://github.com/arc53/DocsGPT.git`
2. Create a `.env` file in your root directory and set the env variables and `VITE_API_STREAMING` to true or false, depending on whether you want streaming answers or not. It should look like this inside:

```auto
LLM_NAME=[docsgpt or openai or others] 
VITE_API_STREAMING=true
API_KEY=[if LLM_NAME is openai]

```

See optional environment variables in the [/.env-template](https://github.com/arc53/DocsGPT/blob/main/.env-template) and [/application/.env\_sample](https://github.com/arc53/DocsGPT/blob/main/application/.env_sample) files.  
3. Run [./run-with-docker-compose.sh](https://github.com/arc53/DocsGPT/blob/main/run-with-docker-compose.sh).  
4. Navigate to [http://localhost:5173/](http://localhost:5173/).

To stop, just run `Ctrl + C`.

## Development Environments

### Spin up Mongo and Redis

For development, only two containers are used from [docker-compose.yaml](https://github.com/arc53/DocsGPT/blob/main/docker-compose.yaml) (by deleting all services except for Redis and Mongo). See file [docker-compose-dev.yaml](https://github.com/arc53/DocsGPT/blob/main/docker-compose-dev.yaml).

Run

```auto
docker compose -f docker-compose-dev.yaml build
docker compose -f docker-compose-dev.yaml up -d

```

### Run the Backend

Note

Make sure you have Python 3.10 or 3.11 installed.

1. Export required environment variables or prepare a `.env` file in the project folder:

- Copy [.env\_sample](https://github.com/arc53/DocsGPT/blob/main/application/.env_sample) and create `.env`.

(check out [`application/core/settings.py`](https://github.com/arc53/DocsGPT/blob/main/application/core/settings.py) if you want to see more config options.)

1. (optional) Create a Python virtual environment: You can follow the [Python official documentation](https://docs.python.org/3/tutorial/venv.html) for virtual environments.

a) On Mac OS and Linux

```auto
python -m venv venv
. venv/bin/activate

```

b) On Windows

```auto
python -m venv venv
 venv/Scripts/activate

```

1. Download embedding model and save it in the `model/` folder: You can use the script below, or download it manually from [here](https://d3dg1063dc54p9.cloudfront.net/models/embeddings/mpnet-base-v2.zip), unzip it and save it in the `model/` folder.

```auto
wget https://d3dg1063dc54p9.cloudfront.net/models/embeddings/mpnet-base-v2.zip
unzip mpnet-base-v2.zip -d model
rm mpnet-base-v2.zip

```

1. Install dependencies for the backend:

```auto
pip install -r application/requirements.txt

```

1. Run the app using `flask --app application/app.py run --host=0.0.0.0 --port=7091`.
2. Start worker with `celery -A application.app.celery worker -l INFO`.

### Start Frontend

Note

Make sure you have Node version 16 or higher.

1. Navigate to the [/frontend](https://github.com/arc53/DocsGPT/tree/main/frontend) folder.
2. Install the required packages `husky` and `vite` (ignore if already installed).

```auto
npm install husky -g
npm install vite -g

```

1. Install dependencies by running `npm install --include=dev`.
2. Run the app using `npm run dev`.

## GitHub:

[https://github.com/arc53/DocsGPT](https://github.com/arc53/DocsGPT)
