Code-first Python framework from Google for building, evaluating, and deploying AI agents, optimized for Gemini but model-agnostic.
dwzhu-pku/PaperBanana
A multi-agent framework that turns method text and figure captions into publication-style academic diagrams and plots using LLMs and image generation.
- Stars
- 7,332
- Forks
- 553
- Open issues
- 1
- Last commit
- yesterday
What is it?
PaperBanana is a reference-driven multi-agent system for generating academic illustrations. Given a method section and a figure caption, it runs a pipeline of Retriever, Planner, Stylist, Visualizer and Critic agents. The Retriever pulls relevant examples from the PaperBananaBench dataset, the Planner writes a detailed figure description, the Stylist adjusts it to academic aesthetic conventions, the Visualizer produces the image, and the Critic reviews it so the Visualizer can iterate.
The project ships several ways to run it: a Gradio web app, a Streamlit demo that supports generating many candidates in parallel and refining images to 2K or 4K, and a command-line interface with selectable experiment modes from a vanilla single-call run to the full pipeline. It works with Google Gemini directly or with OpenRouter, which provides access to models from several providers.
The repository is a fork of Google Research's PaperVizAgent and is licensed under Apache-2.0. The current scope focuses on computer science diagrams and matplotlib-style plots, and statistical plot generation is still listed as a TODO.
Key features
- 01Five-agent pipeline covering retrieval, planning, styling, image generation and critique.
- 02Retrieves few-shot reference examples from the PaperBananaBench dataset.
- 03Multi-round Critic-Visualizer loop for iterative refinement.
- 04Streamlit UI generates up to 20 candidates in parallel and upscales images to 2K or 4K.
- 05Supports Google Gemini and OpenRouter as model providers.
- 06Command-line interface with selectable experiment modes.
Use cases
- Drafting architecture or method diagrams for a paper from its text and caption.
- Generating several candidate figures and choosing the best one for a submission.
- Upscaling or editing an existing generated diagram to high resolution.
- Benchmarking diagram generation pipelines against the PaperBananaBench dataset.
Quick start
- 1
Clone the repository
git clone https://github.com/dwzhu-pku/PaperBanana.git - 2
Create a virtual environment with uv
uv venv - 3
Install the required packages
uv pip install -r requirements.txt - 4
Set an API key in configs/model_config.yaml, then launch the Gradio web app
python app.py
Things to know
- Requires an API key from OpenRouter or Google Gemini, so usage depends on external paid model services.
- Generation reliability is still limited, and the README says there is a long way to go for more reliable and diverse results.
- Generating many candidates at once needs an API key that supports high concurrency.
Topics
FAQ
- What is PaperBanana?
- A multi-agent framework that turns method text and figure captions into publication-style academic diagrams and plots using LLMs and image generation. PaperBanana is a reference-driven multi-agent system for generating academic illustrations. Given a method section and a figure caption, it runs a pipeline of Retriever, Planner, Stylist, Visualizer and Critic agents. The Retriever pulls relevant examples from the PaperBananaBench dataset, the Planner writes a detailed figure description, the Stylist adjusts it to academic aesthetic conventions, the Visualizer produces the image, and the Critic reviews it so the Visualizer can iterate.
- Is PaperBanana free to use? What license does it have?
- PaperBanana is open source under the Apache-2.0 license. Check the license terms before using it in commercial products.
- Is PaperBanana still maintained?
- Actively maintained. The last commit to PaperBanana was on Oct 19, 2026.
- What can I use PaperBanana for?
- Drafting architecture or method diagrams for a paper from its text and caption. Generating several candidate figures and choosing the best one for a submission. Upscaling or editing an existing generated diagram to high resolution. Benchmarking diagram generation pipelines against the PaperBananaBench dataset.
- How do I install PaperBanana?
- Clone the repository: git clone https://github.com/dwzhu-pku/PaperBanana.git Create a virtual environment with uv: uv venv Install the required packages: uv pip install -r requirements.txt Set an API key in configs/model_config.yaml, then launch the Gradio web app: python app.py
- Where can I get PaperBanana?
- The source code and installation instructions are on GitHub: https://github.com/dwzhu-pku/PaperBanana
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
Open-source, cross-platform AI chat client for Web, desktop and mobile that connects to OpenAI, Claude, Gemini, DeepSeek and self-hosted models.
A free, open-source desktop app for running large language models locally, with a chat UI and an OpenAI/Anthropic-compatible API.
A minimal Python library for building AI agents that write and run their actions as Python code.
An SDK for building AI agents and multi-agent systems in Python, .NET and Java, with model, plugin and vector database integrations.
Agentic video generation framework that turns a story idea, screenplay, or novel into a multi-shot video by coordinating script, storyboard, character, and video generation agents.