AgentRivet: an automated system for producing Rivet routines from journal publications
Summary
AgentRivet, an automated system using Large Language Models (LLMs), generates Rivet routines directly from particle physics journal publications. Rivet routines are essential for comparing theoretical models to experimental data, aiding Monte Carlo event generator development and searches for physics beyond the Standard Model. Currently, only 39% of measurements have publicly available Rivet routines. AgentRivet, a Python-based AI workflow, extracts physics analysis information, writes C++ Rivet routines, and incorporates intermediate code and physics reviews for quality control. The system was benchmarked using commercial LLMs (OpenAI's Gpt-5.5, Anthropic's Claude-Opus-4.6, and Google's Gemini-3.5-Flash) on two recent ATLAS and CMS measurements. AgentRivet produced competent routines with few syntax errors and reasonable physics fidelity, though some implementation issues arose from ambiguous definitions in publications or LLM struggles with complex observables. The cost per routine ranged from USD1.20 to USD2.20.
Key takeaway
For particle physicists or research scientists aiming to improve analysis preservation, AgentRivet offers a viable path to automate Rivet routine generation. You should consider integrating LLM-powered agent workflows to address the current 39% coverage gap. Be aware that ambiguous publication definitions can still lead to physics implementation issues, requiring careful human oversight or prompt refinement. Explore using multiple LLM providers for redundancy and cost-effectiveness.
Key insights
AgentRivet automates Rivet routine generation from physics papers using LLM-orchestrated agents, addressing a significant gap in analysis preservation.
Principles
- Modular LLM orchestration improves scientific analysis reinterpretation.
- Iterative review loops are critical for complex code generation.
- Ambiguous source definitions cause physics implementation issues.
Method
AgentRivet employs specialized agents (Analyst, Coder, Code Reviewer, Physics Reviewer) in a Python-based workflow. It extracts structured analysis info, generates C++ code, and refines it through an iterative review loop with shared state.
In practice
- Use Pydantic models for structured LLM outputs.
- Implement retry logic for commercial LLM API calls.
- Decompose review into code and physics concerns.
Topics
- AgentRivet
- Rivet Routines
- Large Language Models
- Particle Physics
- Analysis Preservation
- AI Agents
Code references
Best for: AI Scientist, Research Scientist, Machine Learning Engineer
Related on AIssential
Editorial summary, takeaway, and curation by AIssential. Original article published by cs.AI updates on arXiv.org.