LatteReview 🤖☕
🚨 NEW in v1.3.0: Screen with decision models such as TypeSafe's Jev: probabilities instead of generated text, in about 0.2 seconds per article, next to your LLM reviewers in the same workflow. See What's New and Jev vs LLM reviewers.
LatteReview is a powerful Python package designed to automate academic literature review processes through AI-powered agents. Just like enjoying a cup of latte ☕, reviewing numerous research articles should be a pleasant, efficient experience that doesn't consume your entire day!
🆕 What's New in v1.3.0
- Decision reviewers with Jev: LatteReview can now review with System One decision models such as TypeSafe's Jev, which answer typed questions with probabilities instead of generating text.
DecisionTitleAbstractReviewer,DecisionScoringReviewerand the genericDecisionReviewerwork in anyReviewWorkflow, next to LLM reviewers. - One provider, any backend:
SystemOneProviderworks with TypeSafe and OpenRouter, and with any other/v1/systemoneserver viabase_url, including a self-hosted OpenJev model on your own machine. - Evaluated at full scale: on all 11,793 articles of LatteReview's evaluation datasets, Jev ranked articles better than the v1 LLM reviewers on every dataset (mean AUC 0.88 vs 0.83), for about $0.06 per 1,000 articles. See the evaluation, including where Jev falls short.
- Thresholds for a target recall:
suggest_thresholdfits a probability cutoff on labeled data. - Hybrid workflows: let Jev screen everything and send only uncertain articles to an LLM (tutorial).
A Jev + LLM pipeline in a few lines: Jev screens every article, and only the articles it is unsure about go to an LLM (set TYPESAFE_API_KEY and OPENAI_API_KEY):
import asyncio
import pandas as pd
from lattereview.providers import SystemOneProvider, OpenAIProvider
from lattereview.agents import DecisionTitleAbstractReviewer, TitleAbstractReviewer
from lattereview.workflows import ReviewWorkflow
inclusion = {1: "The study must involve CT scans.", 2: "The study must use deep learning."}
exclusion = {1: "The study must not include PET scans."}
jev = DecisionTitleAbstractReviewer(
provider=SystemOneProvider(), # TypeSafe's jev-latest; or SystemOneProvider(backend="openrouter")
name="Jev", inclusion_criteria=inclusion, exclusion_criteria=exclusion,
)
llm = TitleAbstractReviewer(
provider=OpenAIProvider(model="gpt-6-luna"),
name="LLM", inclusion_criteria=str(inclusion), exclusion_criteria=str(exclusion),
)
workflow = ReviewWorkflow(workflow_schema=[
{"round": "A", "reviewers": [jev], "text_inputs": ["title", "abstract"]},
{"round": "B", "reviewers": [llm], "text_inputs": ["title", "abstract"],
"filter": lambda row: 0.1 <= row["round-A_Jev_include_probability"] < 0.9}, # only uncertain articles
])
results = asyncio.run(workflow(pd.read_csv("articles.csv"))) # columns: title, abstract
Try it in the notebooks: Screening, scoring and extraction with Jev · Hybrid Jev + LLM review with measurements · Decision Models docs.
Nothing changes for existing LLM reviewers. See the CHANGELOG for the full list.
What Was New in v1.2.0
- Current models: tested with OpenAI GPT-6 (
gpt-6-astra,gpt-6-sol,gpt-6-luna) and GPT-5.x, Anthropic Claude Opus 5.5, Sonnet 5, Haiku 4.5 and Fable 5.1, and Google Gemini 3.x (gemini-3.8-flash,gemini-3.5-flash-lite). Older models such asgpt-4o-miniandgemini-2.5-flashkeep working. - No more rejected-parameter errors: if a model rejects a setting in
model_args(e.g.,temperatureon GPT-6 or Claude 5, ormax_tokenson OpenAI reasoning models), LatteReview drops or renames it with a one-time warning and retries. If a reasoning model runs out of tokens before finishing its answer, the call is retried without the limit. - New default models:
OpenAIProviderandLiteLLMProviderdefault togpt-6-luna,GoogleProvidertogemini-3.8-flash, andOllamaProvidertoqwen3.8:27b. Passmodel=to choose another. - Better local models:
OllamaProviderconstrains answers to the reviewer's JSON schema, mapsreasoning_effortto Ollama'sthinksetting, passes othermodel_args(e.g.,top_p) as model options instead of failing, andclose()works again. Tested withqwen3.8:27bon a 32 GB Apple Silicon Mac. - More accurate costs: computed from the token usage each API reports, including hidden reasoning tokens.
- Python 3.10 or later is now required. On Python 3.9,
pipinstalls 1.1.1.
🎯 Key Features
- Multi-agent review system with customizable roles and expertise levels for each reviewer
- Support for multiple review rounds with hierarchical decision-making workflows
- Review diverse content types including article titles, abstracts, custom texts, and even images using LLM-powered reviewer agents
- Define reviewer agents with specialized backgrounds and distinct evaluation capabilities (e.g., scoring or concept abstraction or custom reviewers of your own preferance)
- Create flexible review workflows where multiple agents operate in parallel or sequential arrangements
- Enable reviewer agents to analyze peer feedback, cast votes, and propose corrections to other reviewers' assessments
- Enhance reviews with item-specific context integration, supporting use cases like Retrieval Augmented Generation (RAG)
- Broad compatibility with LLM providers through LiteLLM, including OpenAI and Ollama
- Model-agnostic integration supporting OpenAI, Gemini, Claude, Groq, DeepSeek, OpenRouter, and local models via Ollama
- NEW: Decision-model reviewers (TypeSafe's Jev, or a self-hosted OpenJev) that return probabilities for fast, cheap screening
- High-performance asynchronous processing for efficient batch reviews
- Standardized output format featuring detailed scoring metrics and reasoning transparency
- Robust cost tracking and memory management systems
- Extensible architecture supporting custom review workflow implementation
- NEW: Support for RIS (Research Information Systems) file format for academic literature review
💾Installation
pip install lattereview
LatteReview requires Python 3.10 or later. Please refer to the installation guide for detailed instructions.
🚀 Quick Start and Documentation
LatteReview enables you to create custom literature review workflows with multiple AI reviewers. Each reviewer can use different models and providers based on your needs. Below is a working example of how you can use LatteReview for doing a quick title/abstract review with two junior and one senior reviewers (all AI agents)! And this is just the beginning! Beyond study screening, LatteReview can handle data abstraction, customized pipelines, image analysis, and much more. Explore the Tutorials for more examples!
Please refer to the Quick Start page and Documentation page for detailed instructions.
The example below is fully self-contained: set your API keys, install the package, and run it as-is. It uses one OpenAI and one Gemini model, so it needs OPENAI_API_KEY and GEMINI_API_KEY (in a .env file or exported in your shell). You can swap in any LiteLLM-supported model — see Model Support.
from lattereview.providers import LiteLLMProvider
from lattereview.agents import TitleAbstractReviewer
from lattereview.workflows import ReviewWorkflow
import pandas as pd
import asyncio
from dotenv import load_dotenv
# Load environment variables (e.g., OPENAI_API_KEY, GEMINI_API_KEY) from a .env file
load_dotenv()
# First Reviewer: Conservative approach
reviewer1 = TitleAbstractReviewer(
provider=LiteLLMProvider(model="gpt-6-luna"),
name="Alice",
backstory="a radiologist with expertise in systematic reviews",
inclusion_criteria="The study must focus on applications of artificial intelligence in radiology.",
exclusion_criteria="Exclude studies that are not peer-reviewed or not written in English.",
model_args={"reasoning_effort": "low"},
)
# Second Reviewer: More exploratory approach
reviewer2 = TitleAbstractReviewer(
provider=LiteLLMProvider(model="gemini/gemini-3.8-flash"),
name="Bob",
backstory="a computer scientist specializing in medical AI",
inclusion_criteria="The study must focus on applications of artificial intelligence in radiology.",
exclusion_criteria="Exclude studies that are not peer-reviewed or not written in English.",
model_args={"reasoning_effort": "low"},
)
# Expert Reviewer: Resolves disagreements
expert = TitleAbstractReviewer(
provider=LiteLLMProvider(model="gpt-6-sol"),
name="Carol",
backstory="a professor of AI in medical imaging",
inclusion_criteria="The study must focus on applications of artificial intelligence in radiology.",
exclusion_criteria="Exclude studies that are not peer-reviewed or not written in English.",
model_args={"reasoning_effort": "high"},
additional_context="Alice and Bob disagree with each other on whether or not to include this article. You can find their reasonings above.",
)
# Define workflow
workflow = ReviewWorkflow(
workflow_schema=[
{
"round": 'A', # First round: Initial review by both reviewers
"reviewers": [reviewer1, reviewer2],
"text_inputs": ["title", "abstract"]
},
{
"round": 'B', # Second round: Expert reviews only disagreements
"reviewers": [expert],
"text_inputs": ["title", "abstract", "round-A_Alice_output", "round-A_Bob_output"],
"filter": lambda row: row["round-A_Alice_evaluation"] != row["round-A_Bob_evaluation"]
}
]
)
# Prepare your data: a DataFrame (or .csv/.xlsx/.ris file path) with 'title' and 'abstract' columns
data = pd.DataFrame(
{
"title": [
"Deep learning for automated detection of pneumonia on chest radiographs",
"Effects of mindfulness meditation on stress levels in college students",
],
"abstract": [
"We developed a convolutional neural network to detect pneumonia on chest X-rays.",
"A randomized trial of mindfulness training in 200 undergraduates reduced stress.",
],
}
)
# Or load from a file: data = pd.read_excel("articles.xlsx")
results = asyncio.run(workflow(data)) # Returns a pandas DataFrame with all original and output columns
# Save results
results.to_csv("review_results.csv", index=False)
🎯 Decision Models (Jev)
Decision reviewers use a System One decision model instead of an LLM. Set TYPESAFE_API_KEY (or use SystemOneProvider(backend="openrouter") with OPENROUTER_API_KEY):
from lattereview.providers import SystemOneProvider
from lattereview.agents import DecisionTitleAbstractReviewer
jev = DecisionTitleAbstractReviewer(
provider=SystemOneProvider(), # TypeSafe's jev-latest
name="Jev",
inclusion_criteria={1: "The study must involve CT scans.", 2: "The study must use deep learning."},
exclusion_criteria={1: "The study must not include PET scans."},
)
# Use it in a ReviewWorkflow like any reviewer. Columns: evaluation (1-5), include_probability,
# confidence, criteria (per-criterion probabilities) and reasoning (generated from the probabilities).
Jev vs LLM reviewers. An LLM reviewer writes its answer and a reasoning; Jev writes nothing and returns a probability for every allowed answer, so its answers are always on-schema and can be thresholded for a target recall. It is fast (about 0.2 s per article) and cheap (about $0.06 per 1,000 abstracts), and in our evaluation it ranked articles better than the v1 LLM reviewers. But it reads text only, has no written reasoning, does not do multi-step reasoning, and its default 0.5 cutoff is too strict for long, multi-part criteria: rank by include_probability or fit a cutoff with suggest_threshold. A good pattern is to let Jev screen everything and send only uncertain articles to an LLM. Read Decision Models for how it works, backends, self-hosting and the full evaluation.
🔌 Model Support
LatteReview offers flexible model integration through multiple providers:
- LiteLLMProvider (Recommended): Supports OpenAI, Anthropic (Claude), Gemini, Groq, DeepSeek, OpenRouter, and more
- OpenAIProvider: Direct integration with OpenAI and Gemini APIs
- GoogleProvider: Direct integration with Gemini through Google's
google-genaiSDK - OllamaProvider: Optimized for local models via Ollama
- SystemOneProvider (new): System One decision models such as Jev, via TypeSafe, OpenRouter, or any
/v1/systemoneserver (e.g., a self-hosted OpenJev)
If you don't pass a model, OpenAIProvider and LiteLLMProvider use gpt-6-luna, GoogleProvider uses gemini-3.8-flash, and OllamaProvider uses qwen3.8:27b (run ollama pull qwen3.8:27b first). For Claude, pass e.g. LiteLLMProvider(model="anthropic/claude-sonnet-5") or "anthropic/claude-haiku-4-5" for a cheaper option.
Note: Models should support async operations and structured JSON outputs for optimal performance.
Model compatibility
Newer reasoning models reject some request parameters that older models accept. OpenAI's GPT-5/GPT-6 families and o-series models reject max_tokens (they use max_completion_tokens) and non-default temperature/top_p. Anthropic's Claude Opus 4.7+, Claude 5 and Fable models reject temperature, top_p and top_k. LatteReview handles this for you. If a model rejects a parameter in model_args, it is dropped (or max_tokens is sent as max_completion_tokens) with a one-time warning. If a reasoning model runs out of tokens before finishing its answer, the call is retried without the token limit. Models that accept these parameters are called exactly as before, so existing code keeps working.
For reasoning models, we recommend leaving out max_tokens and temperature and using reasoning_effort (e.g., "low" for screening, "high" for an expert reviewer) instead. See Model compatibility in the docs for details.
📖 Documentation
Full documentation and API reference are available at: https://pouriarouzrokh.github.io/LatteReview
🎓 Tutorials
✅ TitleAbstractReviewer:
🔸1. A simple task of abstract screening based on 1-5 scoring + inclusion and exclusion criteria
✅ AbstractionReviewer:
🔸1. Data abstraction from abstracts/manuscripts
✅ ScoringReviewer:
🔸1. A simple task of abstract screening based on custom scoring by multiple agents
🔸2. Question answering with RAG (Retrieval Augmented Generation)
🔸3. Image analysis by LatteReview
✅ Custom Reviewer:
🔸1. How to Customize the AbstractReviewer Agent for Your Needs
🔸2. Chat with the agents and other base functionalities
🔸3.: Combination of differnet agents for a comprehensive literature review
✅ Decision Reviewers (Jev):
🔸1. Screening, scoring and categorical extraction with Jev
🔸2. Hybrid review: Jev screens everything, an LLM handles the uncertain articles
🛣️ Roadmap for Future Features
- Implementing LiteLLM to add support for additional model providers
- Draft the package full documentation
- Enable agents to return a percentage of certainty
- Enable agents to be grounded in static references (text provided by the user)
- Enable agents to be grounded in dynamic references (i.e., recieve a function that outputs a text based on the input text. This function could, e.g., be a RAG function.)
- Support for image-based inputs and multimodal analysis
- Development of
AbstractionReviewerclass for automated paper summarization - Showcase how
AbstractionReviewerclass could be used to analyse the literature around a certain topic. - Adding a tutorial example and also a section to the docs on how to create custom reviewer agents.
- Adding a
TitleAbstractRevieweragent and adding a tutorial for it. - Evaluating LatteReview.
- Writing the white paper for the package and public launch
- Addign support for
RISfiles. - Adding support for models without structured-output (json_schema) capability via an automatic JSON-mode fallback (e.g., DeepSeek).
- Supporting the newest reasoning models (GPT-6, Claude 5, Gemini 3.x) with automatic handling of parameters they reject.
- Supporting System One decision models (Jev) for fast, probability-based screening, including hybrid Jev + LLM workflows.
- Development of a no-code web application
- (for v>) Adding conformal prediction tool for calibrating agents on their certainty scores
- (for v>2.0.0) Adding a dialogue tool for enabling agents to seek external help (from helper agents or parallel reviewer agents) during review.
- (for v>2.0.0) Adding a memory component to the agents for saving their own insights or insightful feedback they receive from the helper agents.
👨💻 Author
|
|
Pouria Rouzrokh, MD, MPH, MHPE Medical Practitioner and Machine Learning Engineer Incoming Radiology Resident @Yale University Former Data Scientist @Mayo Clinic AI Lab |
❤️ Support LatteReview
If you find LatteReview helpful in your research or work, consider supporting its continued development. Since we're already sharing a virtual coffee break while reviewing papers, maybe you'd like to treat me to a real one? ☕ 😊
Ways to Support:
- Become my sponsor on GitHub
- Treat me to a cup of coffee on Ko-fi ☕
- Star the repository to help others discover the project
- Submit bug reports, feature requests, or contribute code
- Share your experience using LatteReview in your research
📜 License
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License (see the LICENSE file). To view a copy of this license, visit creativecommons.org/licenses/by-nc-nd/4.0.
🤝 Contributing
I welcome contributions! Please feel free to submit a Pull Request.
Acknowledgement
I would like to express my heartfelt gratitude to Moein Shariatnia for his invaluable support and contributions to this project.
📚 Citation
If you use LatteReview in your research, please cite our paper:
@misc{rouzrokh2025lattereview,
title={LatteReview: A Multi-Agent Framework for Systematic Review Automation Using Large Language Models},
author={Pouria Rouzrokh and Moein Shariatnia},
year={2025},
eprint={2501.05468},
archivePrefix={arXiv},
primaryClass={cs.CL}
}
Metadata
Release files for lattereview 1.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| lattereview-1.3.0.tar.gz | 64.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| lattereview-1.3.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 124.5 kB
Release files / lattereview-1.3.0.tar.gz
| Download URL | lattereview-1.3.0.tar.gz |
|---|---|
| Size | 64.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e3904f679d3fdf54a21c23f721b673230c99d7f0a4fa9addfd6fabbe5c680c78
|
|
BLAKE2b-256 checksum How to use checksums |
61dd24235dc789f04f1dd5940d280d1d6398ad17e1a094bc6c8098aa70ba91e6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / lattereview-1.3.0-py3-none-any.whl
| Download URL | lattereview-1.3.0-py3-none-any.whl |
|---|---|
| Size | 59.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
09201f79439cbd8117c481e924039d029d27f1e671b088eb808c8ea10ec08485
|
|
BLAKE2b-256 checksum How to use checksums |
3886e43d3ff02a4382b9702c77d5a23092c70d8837cd7cc3ad71860c63bf0bc1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|