Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

🤖 GPT Vision, Open Source Vision components for GPTs, generative AI, and LLM projects. Not only UI Components.

License

NotificationsYou must be signed in to change notification settings

antvis/GPT-Vis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

74 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

English |简体中文 |日本語

GPT-Vis

Components for GPTs, generative AI, and LLM projects.Not only UI Components.

DocumentKnowledgeAgent Demo

agent.mov

✨ Features

  • 🤖LLM Protocol: A visual protocol for LLM Agent cards, designed for LLM conversational interaction and service serialized output, to facilitate rapid integration into AI applications.
  • 🍡LLM Component: Developed components for LLM applications, with 20+ commonly used VIS components built-in, providing convenient expansion mechanism and architecture design for customized UI requirements.
  • 📈LLM access: Chart knowledge base and chart recommendation model for seamless access to LLM, directly output visual cards for LLM, and provide knowledge base and recommended model solutions for Agent.

📦 Installation

$ npm i @antv/gpt-vis --save

🔨 Usage

import{GPTVis}from'@antv/gpt-vis';constmarkdownContent=`# GPT-VIS \n\nComponents for GPTs, generative AI, and LLM projects. Not only UI Components.Here’s a visualization of Haidilao's food delivery revenue from 2013 to 2022. You can see a steady increase over the years, with notable *growth* particularly in recent years.\`\`\`vis-chart{  "type": "line",  "data": [    { "time":2013,"value":59.3 },    { "time":2014,"value":64.4 },    { "time":2015,"value":68.9 },    { "time":2016,"value":74.4 },    { "time":2017,"value":82.7 },    { "time":2018,"value":91.9 },    { "time":2019,"value":99.1 },    { "time":2020,"value":101.6 },    { "time":2021,"value":114.4 },    { "time":2022,"value":121 }  ]}\`\`\``;exportdefault()=>{return<GPTVis>{markdownContent}</GPTVis>;};
🛠 Custom renderer UI
import{GPTVisLite,withChartCode,ChartType,Pie}from'@antv/gpt-vis';constmarkdownContent=`\`\`\`my-uimy data\`\`\`\`\`\`vis-chart{  "type": "pie",  "data": [    { "category": "category 1", "value": 27 },    { "category": "category 2", "value": 25 },    { "category": "category 3", "value": 18 },    { "category": "other", "value": 5 }  ]}\`\`\``;constcustomRenderers={'my-ui':({ children})=><div>{children}</div>};constcomponents={code:withChartCode({languageRenderers:customRenderers,// register custom block renderercomponents:{[ChartType.Pie]:Pie},// register a pie chart}),};exportdefault()=>{return<GPTVisLitecomponents={components}>{markdownContent}</GPTVisLite>;};

🐍 Streamlit

importstreamlitasstfromstreamlit_gpt_visimportset_gpt_viscontent='''Here’s a visualization of Haidilao's food delivery revenue from 2013 to 2022. You can see a steady increase over the years, with notable *growth* particularly in recent years.\`\`\`vis-chart{"type": "line","data": [{"time":2013,"value":59.3},{"time":2014,"value":64.4},{"time":2015,"value":68.9},{"time":2016,"value":74.4},{"time":2017,"value":82.7},{"time":2018,"value":91.9},{"time":2019,"value":99.1},{"time":2020,"value":101.6},{"time":2021,"value":114.4},{"time":2022,"value":121}]}\`\`\`'''set_gpt_vis(content)

Learn more 👉streamlit-gpt-vis

Visual Knowledge

The purpose of theVisual Knowledge Base is to provide a comprehensive and systematic resource to help Agents understand, select, create various data visualization charts. Below are the metrics for generating accurate chart protocols based on theevaluation dataset through the RAG.

Line(Multi)Column(Grouped/Stacked)PieArea(Stacked)Bar(Grouped/Stacked)Scatter(Bubble)Heatmap
40/4025/2713/1418/1818/2010/109/10
HistogramTree MapWord CloudRadarDual AxisRich Text NTVPin Map
15/1613/1511/1223/2313/147.3/1010/11
Network GraphMind MapOrganizational ChartFlow DiagramFishbone Diagram
8/1012/1410/1210/1110/12

Note: The numbers in the format of X/Y represent the metrics of the respective chart types when evaluated against the dataset.

🤖 Chart Recommendation Dataset

The chart recommendation dataset is designed to evaluate or fine-tune large language models on their ability to recommend chart types based on given data. The dataset currently encompasses 16 types of charts, with 1-3 different data scenarios per chart type, and more than 15 chart data instances for each scenario. The dataset is continuously updated, and we welcome contributions of chart data collected from your own use cases. For more detailed information about the dataset, please visitevaluations/recommend.

💻 Development

# install dependencies$ pnpm install# develop library by docs demo$ pnpm dev# build library source code$ pnpm build

License

MIT

About

🤖 GPT Vision, Open Source Vision components for GPTs, generative AI, and LLM projects. Not only UI Components.

Topics

Resources

License

Stars

Watchers

Forks


[8]ページ先頭

©2009-2025 Movatter.jp