# ChartGPT **Repository Path**: vax52/chart-gpt ## Basic Information - **Project Name**: ChartGPT - **Description**: 基于gpt的数据可视化agent - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2023-09-08 - **Last Updated**: 2025-01-13 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # ChartGPT ChartGPT allows data lake visualization as a graph through dialogue. This project borrows some code from the [Viusal ChatGPT]( https://github.com/microsoft/TaskMatrix.git) project ## Effect Display ### 柱状图 ![柱状图](./assets/bar.jpg) ### 折线图 ![折线图](./assets/line.jpg) ### 饼图 ![饼图](./assets/pie.png) ### 散点图 ![饼图](./assets/scatter.png) ## 示例输入 ```markdown 例一: 将[2,4,5,6,10,20,100]可视化为柱状图 例二: 将[2,4,5,6,10,100,120,200,135,50,10]可视化为折线图 例三: 将下面的数据可视化为饼图 ['A', 'B', 'C', 'D', 'E'] [25, 20, 15, 10, 30] 例四 Visualize [2,4,5,6,10,100,120,200,135,50,10] as a line chart 例五: 将下面的数据可视化为散点图 x = [1, 2, 3, 4, 5] y = [5, 4, 3, 2, 1] ``` ## Quick Start ```shell # clone the repo git clone https://github.com/vax521/ChartGPT.git # Go to directory cd chart_gpt # create a new environment conda create -n chartgpt python=3.8 # activate the new environment conda activate chartgpt # prepare the basic environments pip install -r requirements.txt # prepare your private OpenAI key (for Linux) export OPENAI_API_KEY={Your_Private_Openai_Key} # prepare your private OpenAI key (for Windows) set OPENAI_API_KEY={Your_Private_Openai_Key} # start! python chart_gpt.py ``` ## Acknowledgement We appreciate the open source of the following projects: [TaskMatrix]( https://github.com/microsoft/TaskMatrix.git)   [LangChain](https://github.com/hwchase17/langchain)