A powerful Telegram bot that uses large language models (LLMs) to architect fully structured, ready-to-deploy software codebases from user prompts in a matter of seconds.
Single model call for generation to reduce token cost
Supports OpenAI and Claude LLMs
Output zip includes requirement and readme files for setup & usage
Learn More »Try Demo · Deployment · Commands · Contribute
This Telegram bot leverages the power of OpenAI or Claude's large language models to provide full architectured software solutions, zipped and ready to go in your convenient Telegram chat window. The output includes requirement and readme files for easy setup and usage. The bot is capable of generating codebases for a wide range of software projects, from simple command-line applications to complex web applications.
Here is an example of a codebase that was architected for another todo-app
software, given a more detailed context:
todo-app/
├── README.md
├── requirements.txt
└── src/
├── app.py
├── database.py
├── schema.sql
├── todo.py
├── static/
│ ├── css/
│ │ └── styles.css
│ └── js/
│ └── app.js
└── templates/
├── base.html
└── index.html
Just simply prompt the bot with a detailed description of the software you want to build, and it will generate and send the zipped software codebase the Telegram chat.
💡 Tip: The Claude 3 Opus model has proven to be exceptionally more effective at generating the codebases than even the best OpenAI GPT models.
To get your own local instance of the Telegram-AI-Software-Architect
bot up and running, follow these simple steps:
-
Before you continue, you will need to secure either an OpenAI API key or an Anthropic Claude API key.
Option a. Get an OpenAI API key using this guide for reference.
Option b. Get a Claude API key using this link for reference.
💸 Before sure to review pricing for the APIs in deciding which model to use.
-
Choose your preferred model to use for the bot.
If you are using OpenAI, it is recommended to use the latest gpt4 model. If you are using Claude, it is recommended to use the Claude 3 Opus model. The process of generating entire codebases is very complex and requires advanced LLMs. In this case, paying for the best model is worth it.
You will need to find the model code for these. For example, the latest version of the Claude 3 Opus model's code is
claude-3-opus-20240229
. -
Create a new Telegram bot and get the bot token using BotFather. If you don't know how to do so, you can use this guide for reference.
Make sure that you have saved your model APIKEY, model code, and bot token in a safe place. You will need them in the next steps.
Before continuing, ensure that you have docker installed on your system. If you do not, you can download it 🔗 here.
Once you have verified your Docker installation:
-
Pull the Docker image from Docker Hub:
docker pull hschickdevs/ai-software-architect:latest
-
Run the Docker image:
In specifying the environment variables in the run command, as seen adjacent to
-e
, you can use the following reference:API_KEY
: Your API KEY for the model that you chose (OpenAI or Claude)BOT_TOKEN
: Your Telegram bot token received from BotFather.MODEL
: The model that you are using, currently onlyopenai
orclaude
MODEL_CODE (optional)
: The code for the model that you want to use, see Prerequisites for more information. If this is left blank, it will use the default model for your model (gpt-4-0125-preview
foropenai
, andclaude-3-opus-20240229
forclaude
.)
docker run -d --name ai-software-architect \ -e API_KEY=<YOUR_APIKEY> \ -e BOT_TOKEN=<YOUR_TELEGRAM_BOT_TOKEN> \ -e MODEL=<LLM-MODEL> \ -e MODEL_CODE=<LLM_MODEL_CODE> \ hschickdevs/ai-software-architect
-
View the logs:
docker logs -f ai-software-architect
You can also attach to the container to see the logs in real-time:
docker attach ai-software-architect
If you don't see any errors, the bot should now be running! Head to your bot on Telegram and test it out.
Returns all available commands and their descriptions.
🛠️ Generate a software codebase given the context.
For the highest quality output, it is recommended to use the Claude 3 Opus model, as well as provide a detailed context for the software you want to be architected.
For (a very simple) example:
/generate a simple web application that allows users to create, read, update, and delete tasks. The application should be built using the Flask framework and should use a SQLite database to store the tasks.
💬 Ask the model anything and receive a standard response.
For example, the following command asks the bot how Docker works:
/ask How does Docker work?
📞 Contact the developer for support or feedback.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you don't have any ideas, see the open issues for a list of proposed features (and known issues) to address.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under GPLv3.0, a free software license that allows you to use, modify, and distribute the software for personal and commercial use.
However, any changes you make must also be open-sourced under the same license. This ensures that derivative work remains free and open, promoting collaboration and transparency. Importantly, if you distribute the software or any modifications, you must make the source code available and clearly state any changes you've made.
Telegram: @hschickdevs