OmAgent
[EMNLP-2024] Build multimodal language agents for fast prototype and production
Install / Use
/learn @om-ai-lab/OmAgentREADME
📖 Introduction
OmAgent is python library for building multimodal language agents with ease. We try to keep the library simple without too much overhead like other agent framework.
- We wrap the complex engineering (worker orchestration, task queue, node optimization, etc.) behind the scene and only leave you with a super-easy-to-use interface to define your agent.
- We further enable useful abstractions for reusable agent components, so you can build complex agents aggregating from those basic components.
- We also provides features required for multimodal agents, such as native support for VLM models, video processing, and mobile device connection to make it easy for developers and researchers building agents that can reason over not only text, but image, video and audio inputs.
🔑 Key Features
- A flexible agent architecture that provides graph-based workflow orchestration engine and various memory type enabling contextual reasoning.
- Native multimodal interaction support include VLM models, real-time API, computer vision models, mobile connection and etc.
- A suite of state-of-the-art unimodal and multimodal agent algorithms that goes beyond simple LLM reasoning, e.g. ReAct, CoT, SC-Cot etc.
- Supports local deployment of models. You can deploy your own models locally by using OllamaOllama or LocalAI.
- Fully distributed architecture, supports custom scaling. Also supports Lite mode, eliminating the need for middleware deployment.
🛠️ How To Install
- python >= 3.10
- Install omagent_core
Use pip to install omagent_core latest release.
Or install the latest version from the source code like below.pip install omagent-corepip install -e omagent-core
🚀 Quick Start
Configuration
The container.yaml file is a configuration file that manages dependencies and settings for different components of the system. To set up your configuration:
-
Generate the container.yaml file:
cd examples/step1_simpleVQA python compile_container.pyThis will create a container.yaml file with default settings under
examples/step1_simpleVQA. For more information about the container.yaml configuration, please refer to the container module -
Configure your LLM settings in
configs/llms/gpt.yml:- Set your OpenAI API key or compatible endpoint through environment variable or by directly modifying the yml file
export custom_openai_key="your_openai_api_key" export custom_openai_endpoint="your_openai_endpoint"You can use a locally deployed Ollama to call your own language model. The tutorial is here.
Run the demo
-
Run the simple VQA demo with webpage GUI:
For WebpageClient usage: Input and output are in the webpage
cd examples/step1_simpleVQA python run_webpage.pyOpen the webpage at
http://127.0.0.1:7860, you will see the following interface:
<img src="docs/images/simpleVQA_webpage.png" width="400"/>
🤖 Example Projects
1. Video QA Agents
Build a system that can answer any questions about uploaded videos with video understanding agents. we provide a gradio based application, see details here.
<p > <img src="docs/images/video_understanding_gradio.png" width="500"/> </p>More about the video understanding agent can be found in paper.
<p > <img src="docs/images/OmAgent.png" width="500"/> </p>2. Mobile Personal Assistant
Build your personal mulitmodal assistant just like Google Astral in 2 minutes. See Details here.
<p > <img src="docs/images/readme_app.png" width="200"/> </p>3. Agentic Operators
We define reusable agentic workflows, e.g. CoT, ReAct, and etc as agent operators. This project compares various recently proposed reasoning agent operators with the same LLM choice and test datasets. How do they perform? See details here.
| Algorithm | LLM | Average | gsm8k-score | gsm8k-cost($) | AQuA-score | AQuA-cost($) | | :-----------------: | :------------: | :-------------: | :---------------: | :-------------------: | :------------------------------------: | :---: | | SC-COT | gpt-3.5-turbo | 73.69 | 80.06 | 5.0227 | 67.32 | 0.6491 | | COT | gpt-3.5-turbo | 69.86 | 78.70 | 0.6788 | 61.02 | 0.0957 | | ReAct-Pro | gpt-3.5-turbo | 69.74 | 74.91 | 3.4633 | 64.57 | 0.4928 | | POT | gpt-3.5-turbo | 64.42 | 76.88 | 0.6902 | 51.97 | 0.1557 | | IO* | gpt-3.5-turbo | 38.40 | 37.83 | 0.3328 | 38.98 | 0.0380 |
*IO: Input-Output Direct Prompting (Baseline)
More Details in our new repo open-agent-leaderboard and Hugging Face space
💻 Documentation
More detailed documentation is available here.
🤝 Contributing
For more information on how to contribute, see here.
We value and appreciate the contributions of our community. Special thanks to our contributors for helping us improve OmAgent.
🔔 Follow us
You can follow us on X, Discord and WeChat group for more updates and discussions.
<p > <img src="docs/images/readme_qr_code.png" width="200"/> </p>🔗 Related works
If you are intrigued by multimodal large language models, and agent technologies, we invite you to delve deeper into our research endeavors:
🔆 How to Evaluate the Generalization of Detection? A Benchmark for Comprehensive Open-Vocabulary Detection (AAAI24)
🏠 GitHub Repository
🔆 OmDet: Large-scale vision-language multi-dataset pre-training with multimodal detection network (IET Computer Vision)
🏠 Github Repository
⭐️ Citation
If you find our repository beneficial, please cite our paper:
@article{zhang2024omagent,
title={OmAgent: A Multi-modal Agent Framework for Complex Video Understanding with Task Divide-and-Conquer},
author={Zhang, Lu and Zhao, Tiancheng and Ying, Heting and Ma, Yibo and Lee, Kyusong},
journal={arXiv preprint arXiv:2406.16620},
year={2024}
}
Related Skills
claude-opus-4-5-migration
83.9kMigrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5
async-pr-review
99.3kTrigger this skill when the user wants to start an asynchronous PR review, run background checks on a PR, or check the status of a previously started async PR review.
ci
99.3kCI Replicate & Status This skill enables the agent to efficiently monitor GitHub Actions, triage failures, and bridge remote CI errors to local development. It defaults to automatic replication
code-reviewer
99.3kCode Reviewer This skill guides the agent in conducting professional and thorough code reviews for both local development and remote Pull Requests. Workflow 1. Determine Review Target
