This project is for redmine issues auto reply by using a local knowleage database.
graph TD
A[Start] --> B[Fetch unanswered questions from Redmine]
B --> C[Send questions to large language model]
C --> D[Retrieve answers from local knowledge base]
D --> E[Post answers to Redmine]
E --> F[Add answered questions and answers to local knowledge base]
F --> G[Wait for next interval]
G --> B
-
Redmine Integration
- Periodically fetch unanswered questions from Redmine.
- Post answers back to Redmine.
-
Large Language Model (LLM) Integration
- Send unanswered questions to the LLM.
- Retrieve answers from the LLM based on the local knowledge base.
-
Local Knowledge Base Management
- Query the local knowledge base for answers.
- Update the local knowledge base with new answered questions and their answers.
-
Scheduler
- Manage the periodic fetching and processing of unanswered questions.
-
Fetch Unanswered Questions from Redmine
- Connect to the Redmine API.
- Retrieve a list of questions that have not been answered.
-
Send Questions to Large Language Model
- Format the questions appropriately.
- Send the questions to the large language model (LLM).
-
Retrieve Answers from Local Knowledge Base
- Query the local knowledge base using the LLM.
- Fetch relevant information to answer the questions.
-
Post Answers to Redmine
- Format the answers.
- Post the answers back to Redmine via the Redmine API.
-
Add Answered Questions and Answers to Local Knowledge Base
- Update the local knowledge base with the newly answered questions and their answers.
-
Wait for Next Interval
- Wait for a predefined interval before repeating the process.
- Redmine API: For fetching and posting questions.
- Langchain: For integrating with the large language model.
- Local Knowledge Base: For storing and retrieving knowledge.
- Python: For scripting and automation.
- Scheduler (e.g., Cron, APScheduler): For periodic execution.
To set up this project, follow these steps:
-
Clone the repository:
git clone https://github.com/Xianleewu/redminegpt cd redminegpt
-
Install the required dependencies:
python3 -m pip install -r requirements.txt
-
Configure the Redmine and LLM API credentials in the
config.py
file.redmine server REDMINE_SERVER = { "host": 'http://127.0.0.1:3000', "user": 'gptbot', "password": 'password', } # QAnything remote server QANYTHING_REMOTE_SERVER = { "app_key": '', "app_secret": '', "kb_id": '', }
-
Run the bot:
python3 main.py
TODO
-
Connect with Redmine via REST API
-
Auto reply new issues
-
QAnythingRemote support
-
Auto gen local database acording to redmine closed issues
-
QAnythingLocal support
-
LangchainChatChat support
-
Dify support
If you would like to contribute to this project, please submit a pull request or open an issue on GitHub.