[vc_headings linewidth=”0″ borderwidth=”1″ borderclr=”#000000″ title=”Chat2DB” google_fonts=”font_family:Comfortaa%3A300%2Cregular%2C700|font_style:700%20bold%20regular%3A700%3Anormal” titlesize=”60″ titleclr=”#000000″]Smart SQL client with ChatGPT[/vc_headings]
Chat2DB is an open-source tool for multiple databases from Alibaba. Unlike traditional database clients like Navicat and DBeaver, Chat2DB has AIGC capabilities that can turn natural language into SQL, and vice versa. It can also give SQL optimization tips to boost developers’ efficiency. It is a tool for database developers in the AI era, and even non-SQL users can use it to query data and generate reports quickly.
[vc_headings style=”theme4″ borderclr=”#000000″ style2=”image” title=”Features” google_fonts=”font_family:Comfortaa%3A300%2Cregular%2C700|font_style:700%20bold%20regular%3A700%3Anormal” lineheight=”3″ titlesize=”40″ titleclr=”#000000″ image_id=”2871″][/vc_headings]
Windows
MacOS ARM64
MacOS X64
JAR
AI Configuration
CONFIGURE OPENAI
Option (1): To access the ChatSql feature of OPENAI, you need to satisfy two requirements:
- You need an OPENAI_API_KEY.
- To access the OPENAI website from the client’s network, you may need a VPN if you are in China. Make sure your VPN works well, or use the network proxy settings in the client to specify the HOST and PORT.
Option (2): Unified Proxy Service
- No OPENAI_API_KEY is required.
- You can access the service without using a proxy or VPN, provided that you have a network connection.
đłDocker installation
docker pull chat2db/chat2db:latest
âď¸ Operating Environment
Note: If local debugging is required
- Java runtime Open JDK 17
- JRE reference packaging and deployment method of jre.
- Node runtime environment Node16 Node.js.
đťÂ Local Debugging
- git clone to local
$ git clone git@github.com:alibaba/Chat2DB.git
- Front-End installation
$ cd Chat2DB/ali-dbhub-client
$ npm install # Mounting front-end dependency
$ npm run build:prod # Package js to the source directory on the back end
- Backend debug
$ cd ../ali-dbhub-server
$ mvn clean install # maven 3.8 or later needs to be installed
$ cd ali-dbhub-server/ali-dbhub-server-start/target/
$ java -jar -Dchatgpt.apiKey=xxxxx ali-dbhub-server-start.jar # To launch the chat application, you need to enter the ChatGPT key for the chatgpt.apiKey. Without entering it, you won't be able to use the AIGC function.
$ # open http://127.0.0.1:10821 to start debug Note: Front-end installation is required
- Front-End debug
$ cd Chat2DB/ali-dbhub-client
$ npm install
$ npm run start
$ # open http://127.0.0.1:10821 to start Front-End debug
$ # Note Front-end page completely depends on the service, so front-end students need to debug the back-end project
To debug the front end, you need to map the resources. You can use XSwitch and add this configuration file.
{
"proxy": [
[
"http://127.0.0.1:10821/(.*).js$",
"http://127.0.0.1:8001/$1.js",
],
[
"http://127.0.0.1:10821/(.*).css$",
"http://127.0.0.1:8001/$1.css",
],
[
"http://127.0.0.1:10821/static/front/(.*)",
"http://127.0.0.1:8001/$1",
],
[
"http://127.0.0.1:10821/static/(.*)$",
"http://127.0.0.1:8001/static/$1",
],
],
}
[mvc_advanced_button align=”center” btn_text=”Github” icon_size=”25″ use_theme_fonts=”yes” btn_icon=”fab fa-github” btn_url=”url:https%3A%2F%2Fgithub.com%2Falibaba%2FChat2DB|target:_blank” btn_clr=”#ffffff” btn_bg=”#0a0a0a” btn_radius=”50″]
[mvc_advanced_button align=”center” btn_text=”Website” icon_size=”25″ use_theme_fonts=”yes” btn_url=”url:https%3A%2F%2Fchat2db.opensource.alibaba.com%2F|target:_blank” btn_clr=”#ffffff” btn_bg=”#4785f7″ btn_radius=”50″ btn_icon=”fas fa-globe”]
[mvc_advanced_button align=”center” btn_text=”EMail” icon_size=”25″ use_theme_fonts=”yes” btn_icon=”far fa-envelope” btn_url=”url:mailto%3A1558143046%40qq.com|target:_blank” btn_clr=”#ffffff” btn_bg=”#0e76a8″ btn_radius=”50″]
0 Comments