Table of Contents
This repository aims to query an SQL database, containing Real State information, using natural language in order to obtain the results. This will be done using LLM to create the queries and pass them to the database
In order to be able to run the application, you will need to download llama model and save it into models/model. For example, for a 8gb VRAM gpu, you can download llama3 model from here. After you have download the model, configured the config files at config, the model config file at models/cfg and the model prompt template at templates/ you can launch the app using the script launch_app.py
In order to make use of the library, one should just follow the next steps:
- Clone the project and install it using:
git clone <repo-url>
- Install the repository:
pip install -e .
-
For using llama-cpp-python library using GPU follow the instructions at llama-cpp-python
-
Rename the config template for the SQL database at config from mysql-template.yaml to mysql.yaml and configure your database.
-
The llm model is configured using the file at models/cfg.
-
Web APP Login users can be set in the file located at config/login.yaml
When coding, just try to follow the PEP8 style and PEP257 numpy/sphinx notation for docstrings. Any code optimisations are greatly appreciated.
Any contributions are greatly appreciated. If you have suggestions that would make the project any better, don't hesitate to contribute. Here is a reminder of the steps:
- Clone the repository:
git clone <repo-url>
- Create your branch:
git checkout -b branchname
- Implement and test your features.
- Add changes:
git add <files-to-add>
- Commit your changes:
git commit -m "<feature-description>"
- Push to the branch:
git push origin branchname
- Request a merge when you are ready.
Enjoy the content! 😄