HyperAIHyperAI

Command Palette

Search for a command to run...

6 days ago
Agent
LLM

NVIDIA-labs OO Agents Native Python Object-Oriented Agents

Abstract

Traditional agent development is split across prompt templates, tool schemas, callback code, and workflow graphs. We present NVIDIA Object-Oriented Agents (NOOA or NVIDIA double-O Agents), a modelagnostic Python framework for building reliable AI agents. NOOA takes a simpler approach: an agent is a Python object. Its methods are the actions the model can take, fields are its state, docstrings are its prompts, and its type annotations are contracts. A method with code body consisting of ... is completed at runtime by an LLM-driven agent loop, while methods with normal bodies remain standard deterministic Python. This gives developers and agents the same interface, so agent behavior can be tested, traced, refactored, and improved just like other software This paper makes three contributions. (1) We present the agent-as-a-Python-object programming model and the design principles behind it. Where Python has existing abstractions, we adopt them directly: agents are classes, capabilities are methods, type annotations are contracts, asynchronous work is asyncio , and tools and orchestration are normal Python code. Agent-specific capabilities – context, events, state rendering, long-term memory, and validated LLM loops – are exposed through simple Pythonic APIs, so both developers and agents share one familiar programming model. (2) We identify six model-facing ideas that NOOA is, to our knowledge, the first to combine on a single surface: typed input/output, pass-by-reference over live objects, code as action, programmable loop engineering, explicit object state, and model-callable harness APIs for context and events. Surveying fourteen agent frameworks and harnesses, we find the community already converging on several of these ideas – often as experimental or partial features – and we present the comparison to encourage further adoption. (3) We demonstrate that current models use this interface efectively, both in targeted capability tests and on SWE-bench Verified and Terminal-Bench 2.0; on the ARC-AGI-3 interactive-reasoning benchmark, the interface compresses a multi-agent world-model system into a single agent with a one-page skill while advancing the benchmark’s score–cost Pareto frontier.

One-sentence Summary

NVIDIA presents NOOA (NVIDIA Object-Oriented Agents), a model-agnostic Python framework that treats agents as Python objects whose methods with an ellipsis body are completed at runtime by an LLM-driven agent loop, and that for the first time combines typed I/O, pass-by-reference over live objects, code as action, programmable loop engineering, explicit object state, and model-callable harness APIs into a single Pythonic surface, demonstrating its effectiveness on SWE-bench Verified, Terminal-Bench 2.0, and the ARC-AGI-3 interactive-reasoning benchmark where it advances the score–cost Pareto frontier.

Key Contributions

  • Introduces an agent-as-a-Python-object programming model where an agent is a Python class, with methods as actions, fields as state, docstrings as prompts, and type annotations as contracts, directly adopting existing Python abstractions.
  • Identifies six model-facing design principles (typed input/output, pass-by-reference over live objects, code as action, programmable loop engineering, explicit object state, and model-callable harness APIs) that NOOA is the first to combine on a single surface, and surveys fourteen agent frameworks to show emerging convergence on these ideas.
  • Demonstrates that current models effectively use this interface, achieving strong results on SWE-bench Verified and Terminal-Bench 2.0, and on ARC-AGI-3 compresses a multi-agent world-model system into a single agent with a one-page skill while advancing the score-cost Pareto frontier.

Introduction

The proliferation of AI agent development kits has introduced a wide range of custom abstractions for tools, memory, workflows, and state, but these frameworks often force developers to relearn concepts that already have mature equivalents in ordinary programming languages, such as typed interfaces, variable scoping, and control flow. Agent source code becomes fragmented across prompt templates, schemas, configuration files, and orchestration logic, increasing complexity and the learning curve. The authors present NVIDIA Object-Oriented Agents (NOOA), a harness that treats an agent as a single Python class. By using Python’s native constructs for actions, state, and control flow, and by exposing agent-specific features (like context construction and event history) through simple Pythonic APIs, NOOA eliminates the need for separate workflow languages or serialization-heavy interfaces. This design turns prompt engineering into a software engineering discipline, making agentic software ordinary software that both humans and coding agents can read, test, and improve.

Method

The authors leverage standard Python abstractions to construct the NOOA framework, reframing agentic loops as typed method calls rather than unstructured text exchanges. By moving deterministic work out of the agentic loop and allowing models to write normal Python code, the system draws on the model's existing programming knowledge.

Agent Loop and Strategies A NOOA agent is a Python object exposing model-callable behavior through typed methods. Control flow remains ordinary Python until execution reaches an agentic method, indicated by an ellipsis body. At this point, the harness implements the method as an agent loop. The authors implement these agentic methods through strategies, which are declared as decorators to control execution, context rendering, and output validation.

Two primary strategies are provided. The PredictStrategy is a single-shot approach for classification or extraction, validating the output against the Python return type. The CodeActStrategy generalizes this into an iterative Python Read-Eval-Print Loop (REPL). In this mode, the model can call execute_python to compute, inspect state, or invoke helpers, repeating until it calls return_result with a type-validated value.

As shown in the figure below:

The harness first renders context, calls the LLM, executes Python actions if chosen, and updates events and state. Once a successful value is recorded, it is returned to the caller.

Context Rendering and Management The first step in a CodeAct turn is rendering the live Python execution state into model context. The authors separate context into three regions: static context blocks computed once, event history recording the execution trace, and dynamic context blocks re-evaluated before each model call.

As shown in the figure below:

The ContextManager and EventManager populate these regions. Static blocks hold stable information like system prompts. The event history is an append-only sequence of typed events. Dynamic blocks hold changing information, such as a TODO list. This layout maximizes KV-cache reuse across turns.

Context management is integrated into the object-oriented API, allowing both developers and the agent to interact with context through Pythonic primitives.

As shown in the figure below:

A key feature is pass by reference. Arguments are passed as live Python objects. The model sees a bounded preview of the argument, including its type and length, but operates on the full object in the execution environment. This allows the agent to process data bounded by the execution environment rather than the context window.

Execution and State Updates When the model chooses a Python action, NOOA executes the code in a restricted session. Method arguments and the live agent are injected as locals. Dangerous APIs are rejected, and outputs are captured as structured results. After every response or execution, the harness appends typed events to the event manager. State updates follow standard Python scoping rules, with REPL locals persisting only within the method call.

Long-Term Memory To address transfer across tasks, the authors introduce an optional long-term memory subsystem. The agent authors its own memory through deliberate actions using model-callable tools like remember, recall, and search.

As shown in the figure below:

Memory reaches the model through deliberate queries and a BeforeTurn hook that injects associated memories into a dynamic context block. Retrieval ranks candidates by relevance, recency, and importance. Asynchronous reflection runs outside the agent loop to merge duplicates, reconcile conflicts, and prune decayed memories. The entire store resides in a single SQLite file, with vector indexes derived from it.

Experiment

The evaluation includes targeted capability tests that confirm models fluently use the NOOA interface, while stress tests reveal remaining challenges in multi-step batching, error recovery, and decomposition. End-to-end benchmarks on software engineering, terminal interaction, cybersecurity, and interactive reasoning show that NOOA agents outperform comparable open harnesses and often match or exceed specialized closed systems, with typed termination preventing premature completions and in-memory object state reducing token usage. On ARC-AGI-3, a single agent with a world-model skill achieves a large margin over the raw model, demonstrating a strong harness effect. Overall, these results show that expressing agentic constructs as native software abstractions removes interface friction and enables efficient, competitive agents.

Current-generation models show strong fluency in the interface, with an overall pass rate of 97.9% across 4,400 test records. Frontier models nearly saturate the suite, while small models still exceed 91%, but the gap widens sharply on stress tests that require agentic bookkeeping and error recovery. Large/frontier models pass 99.2% of all records, with GPT-5.5 achieving a perfect score. On stress tests resembling agentic work, the pass rate drops to 84.7% overall, and the scale gap grows from 3.2 to 23 percentage points.

Stress tests that require agentic behaviors like batch bookkeeping, error recovery, and iterative exploration reveal a widening capability gap between small and large models. While overall interface pass rates are high for both groups, the stress subset drops substantially for small models while large models remain robust, with perfect scores on refinement, task decomposition, and REPL exploration. Large models pass 93.9% of stress records while small models pass only 70.8%, widening the scale gap from 3.2 points overall to 23 points on this subset. Sentiment batch is the hardest stress test for both groups, with small models passing only 40% and large models reaching 76.7%. Large models achieve perfect pass rates on refinement, task decomposition, and REPL exploration, whereas small models range from 55% to 90% on these same tests. Error recovery is the only stress test where small models nearly match large models, passing 95% versus 96.7%.

NOOA achieves the highest pass rates among the compared open harnesses on SWE-bench Verified across every evaluated model and reasoning-effort configuration. With GPT-5.5 at maximum reasoning effort, it reaches 82.2%, exceeding the prior published leaderboard state-of-the-art of 79.2% that used a specialized agent. With Opus 4.6, NOOA attains 79.8%, while OpenCode and PI both score roughly 75–76%. NOOA consistently outperforms OpenCode and PI across all configurations, with the largest absolute gaps at the lowest reasoning effort (e.g., 67.2% vs 59.2–60.8% on GPT-5.5 off). The highest NOOA score (82.2% with GPT-5.5 xhigh) exceeds the prior specialized-agent SOTA of 79.2%.

NOOA achieves the highest Terminal-Bench 2.0 pass rates among open harnesses across all tested model and reasoning configurations. With GPT-5.5 at xhigh reasoning effort, NOOA reaches 73.0%, outperforming OpenCode and PI, and it also leads with Opus 4.6 at both standard and high settings. NOOA with GPT-5.5 reaches 73.0% pass rate at both high and xhigh reasoning effort, exceeding OpenCode by over 12 percentage points at high effort. With Opus 4.6, NOOA achieves 65.2% at high reasoning effort, compared to 43.8% for OpenCode and 58.4% for PI. At the lowest GPT-5.5 reasoning effort, NOOA attains 46.1%, while OpenCode and PI reach 34.8% and 37.1% respectively.

On the CyberGym L1 vulnerability discovery benchmark, the NOOA agent achieved a solve rate of 86.8%, making it the highest-scoring open-source solution. It outperformed the majority of closed-source agents, with only two proprietary systems reaching higher scores. The architecture's deconstruction and simplification contributed to this strong validation-stage performance. NOOA is the top open-source agent, surpassing most closed-source alternatives including Anthropic Glasswing and OpenAI Daybreak. The agent's solve rate significantly exceeds the baseline OpenAI Codex agent and its submission-skill variant, demonstrating the benefit of its architectural approach.

The evaluation first measures model pass rates on a broad interface suite and on stress tests requiring agentic bookkeeping and error recovery, finding that while both small and large models handle basic interface tasks well, the performance gap widens sharply on agentic stress tasks where large models remain robust and small models struggle. The NOOA open harness is then validated across SWE-bench Verified, Terminal-Bench 2.0, and the CyberGym L1 vulnerability discovery benchmark, consistently achieving the highest scores among open harnesses and often surpassing prior state-of-the-art specialized agents and many closed-source systems.


Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing

HyperAI Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp