eosphoros-ai / DB-GPT

AI Native Data App Development framework with AWEL(Agentic Workflow Expression Language) and Agents
http://docs.dbgpt.cn
MIT License
13.64k stars 1.83k forks source link

[Bug][ChatData]Using chat db, unable to engage in database conversation. #1106

Closed TaoPeiLing closed 4 months ago

TaoPeiLing commented 9 months ago

Search before asking

Operating system information

Linux

Python version information

=3.11

DB-GPT version

main

Related scenes

Installation Information

Device information

CnetOS7 ,mysql数据库

Models information

LLM =zhipu_proxyllm

What happened

创建数据库对话,正确连接上了远程mysql数据库,但是进行数据库对话,发现无法进行数据级别的对话。如图: Dingtalk_20240123181545 项目env配置如下:

***

DB-GPT METADATA DATABASE SETTINGS

***

SQLite database (Current default database)

LOCAL_DB_TYPE=sqlite

MYSQL database

LOCAL_DB_TYPE=mysql LOCAL_DB_USER=root LOCAL_DB_PASSWORD=root123 LOCAL_DB_HOST=192.168.110.45 LOCAL_DB_PORT=3306 LOCAL_DB_NAME=dbgpt

PG database

LOCAL_DB_TYPE=postgresql

LOCAL_DB_USER=postgres

LOCAL_DB_PASSWORD=111111

LOCAL_DB_HOST=192.168.32.245

LOCAL_DB_PORT=1922

LOCAL_DB_NAME=postgres

This option determines the storage location of conversation records. The default is not configured to the old version of duckdb. It can be optionally db or file (if the value is db, the database configured by LOCAL_DB will be used)

CHAT_HISTORY_STORE_TYPE=db

What you expected to happen

可以和数据库进行交流问询

How to reproduce

1、添加mysql数据库 2、连接成功 3、点击chatdb 4、进行问询“数据库中有哪些表”

Additional context

No response

Are you willing to submit PR?

allen781105 commented 9 months ago

你这个问题跟我那个貌似类似,我是sqlite库,报的也是一样的错,取不到表

TaoPeiLing commented 9 months ago

你这个问题与那个明显相似,我是sqlite库,报的也一样的错,取不到表

请问你的解决了吗

allen781105 commented 9 months ago

还没,准备今天debug一下看看

TaoPeiLing commented 9 months ago

嗯嗯,好的。如果有进展望告知下。十分感谢  

-_- @.***

 

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年1月24日(星期三) 上午9:59 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [eosphoros-ai/DB-GPT] 使用chat db,无法进行数据库对话 (Issue #1106)

还没,准备今天debug一下看看

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

yuehong136 commented 9 months ago

The problem I encountered is that he can retrieve tables, but the quantity is very inaccurate. For example, when I asked him how many tables he currently has in the database, he said two. After I added a new table and asked him again, he still said two, only knowing the first two tables. However, in fact, there was an issue with his backend SQL writing, which added restrictions and only searched for the first two tables

TaoPeiLing commented 9 months ago

 Thank you for your detailed response and answers. It seems I also need to learn to look at its source code. I later discovered that it creates some basic tables in my database without my knowledge, which makes me feel out of control. Also, regarding the accuracy you mentioned, I have indeed noticed it, but I haven't delved into its code yet. I hope to consult you again if I have any further questions in the future. Wishing you a pleasant life, and thank you again for your answers and the time you've spent.  

-_- @.***

 

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2024年1月26日(星期五) 下午2:08 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [eosphoros-ai/DB-GPT] 使用chat db,无法进行数据库对话 (Issue #1106)

The problem I encountered is that he can retrieve tables, but the quantity is very inaccurate. For example, when I asked him how many tables he currently has in the database, he said two. After I added a new table and asked him again, he still said two, only knowing the first two tables. However, in fact, there was an issue with his backend SQL writing, which added restrictions and only searched for the first two tables

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

neuwangmq commented 8 months ago

同样的问题 看log似乎在提示词里面就没有数据库里的表信息 图片

只有若干字段信息

github-actions[bot] commented 7 months ago

This issue has been marked as stale, because it has been over 30 days without any activity.

github-actions[bot] commented 4 months ago

This issue bas been closed, because it has been marked as stale and there has been no activity for over 7 days.

chuangzhidan commented 2 months ago

同样的问题 看log似乎在提示词里面就没有数据库里的表信息 图片

只有若干字段信息

截图不是有吗?