AI-native Visual Analytics framework build for agents.
AVA ( Visual Analytics) is a technology framework designed for more convenient visual analytics. The first A has multiple meanings: AI native, Automated, Augmented, and VA stands for Visual Analytics. It can assist users in unstructured data loading, data processing and analysis, as well as visualization code generation.
AVA is a fundamental shift from rule-based analytics to AI-native capabilities:
AVA by npmnpm install @antv/ava
pnpm install @antv/ava
yarn add @antv/ava…Create an AVA instance:
new AVA(options): initialize runtime and LLM configuration.llm: required model config, e.g. { model, apiKey, baseURL }sqlThreshold?: optional size threshold (bytes) to switch from in-memory analysis to SQLite/IndexedDB (default: 10KB)Core APIs in AVA:
loadCSV(filePathOrContent): load CSV (Node.js: file path; Browser: CSV content string).loadObject(data) / loadURL(url, transform?) / loadText(text): load data into AVA.suggest(count?): generate recommended analysis questions.analysis(query): run data analysis and return { query, text, data, code?, sql? } (code for in-memory JS analysis, sql for SQLite analysis).visualize(analysisResult): generate chart output from analysis result, returns { chartType, syntax, html } | null (null when no visualization intent or no usable data).dispose(): release SQLite / IndexedDB and in-memory resources.Minimal usage:
const ava = new AVA({ llm: { model, apiKey, baseURL } });
await ava.loadObject([{ city: 'Hangzhou', gdp: 18753 }]);
const analysis = await ava.analysis('Show GDP by city');
console.log(analysis.text);
const viz = await ava.visualize(analysis);
if (viz) {
console.log(viz.chartType);
console.log(viz.html);
}
ava.dispose();AVA uses a modular pipeline architecture that processes user queries through distinct stages. Data is loaded from multiple sources (CSV, JSON, URL, or text), analyzed intelligently based on size (JavaScript for small datasets, SQLite for large ones), results are summarized using LLM into natural language responses, and optionally visualized with chart recommendations.
…AVA v4 is designed to run seamlessly in both browser and Node.js environments:
AVA automatically detects the runtime environment and adapts:
This is an experimental branch. Contributions are welcome! Please ensure:
VizLinter - Chen, Q., Sun, F., Xu, X., Chen, Z., Wang, J. and Cao, N., 2021. VizLinter: A Linter and Fixer Framework for Data Visualization. IEEE transactions on visualization and computer graphics, 28(1), pp.206-216.
《数据可视化设计的类型学实践》(Exploring the Typology of Visualization Design) - 蓝星宇, 王嘉喆. 数据可视化设计的类型学实践, 《美术大观》, 2022(3), 149-152.
MIT
No open issues yet, or sync has not completed.