Robots Can Multitask Too: Integrating a Memory Architecture and LLMs for Enhanced Cross-Task Robot Action Generation

Hassan Ali, Philipp Allgeuer, Carlo Mazzola, Giulia Belgiovine, Burak Can Kaplan, Lukás Gajdosech, Stefan Wermter

Introduction

Large Language Models (LLMs) have provided robots with sophisticated reasoning capabilities, yet they often falter in dynamic, multi-task environments. The primary constraint is the "memory gap"—the inability of standard LLMs to maintain long-term context beyond a fixed token window. In scenarios where a robot is interrupted or must switch between complex tasks, this limitation leads to "forgetting" states, causing redundant actions or total failure. This paper introduces a dual-layered memory architecture designed to bridge this gap by mimicking human cognitive memory structures.

A Hierarchical Memory Architecture

Inspired by human cognitive functions, the proposed system separates high-level reasoning from low-level memory management through a dual-layered approach:

  1. The Coordinator LLM (Level 1): Acts as the central reasoning engine. It processes environmental data and high-level goals, deciding which memory cues are necessary for the current step. By offloading state-tracking, the Coordinator's prompt remains clean and focused, preventing "reasoning instability."
  2. The Worker LLM (Level 0): Functions as a specialized "librarian." It is an instruction-based model dedicated to creating and maintaining memory logs. It parses the environment and supplies the Coordinator with structured, foundational information.

This architecture utilizes three distinct memory types to maintain context:

  • Procedural Memory: Stores the "how-to"—the base prompts and action specifications for various tasks.
  • Working Memory: A compact representation of the current task, including "Task Reminders" (goals) and "Task State" (what has been completed so far). This implements a form of selective attention, filtering out irrelevant environmental data.
  • Declarative Memory: A persistent log of interaction history, allowing the robot to recall facts about past actions even after a task has been interrupted or completed.

Experimental Methodology

The system was implemented on the NICOL robot, a semi-humanoid platform, using ViLD for open-vocabulary object detection. The researchers utilized both GPT-3.5 and Llama 3 as the LLM backbones to test the architecture's versatility across different model scales.

The researchers evaluated the system using a benchmark of five diverse robotic tasks involving YCB objects and colored cubes: Separating (sorting items), Arrangement (placing items in a bowl), Pointing (color-coded sequences), Recipe (gathering ingredients), and Tower (stacking cubes). These were tested across three operational modes:

  • Standalone: One task at a time.
  • Consecutive: Tasks performed back-to-back.
  • Intervened: Tasks interrupted at 50% completion to switch to another task before returning to the original.

Performance and Key Insights

The integration of the memory architecture led to dramatic performance gains, particularly in multi-tasking and interrupted scenarios:

  • Consecutive Tasks: In the "Arrangement" task, GPT-3.5’s success rate increased from 14% (without memory) to 100% (with memory). Llama 3 saw a similar boost from 50% to 100%.
  • Intervened Tasks: This was the most challenging mode. For the "Separating" task, Llama 3’s success rate plummeted to 19% when interrupted without memory. With the memory architecture, it recovered to 96%.
  • Retention: The system maintained near-perfect "Task Retention" (remembering what is in which container) and "Environment Retention" (knowing what is still on the table), whereas models without memory frequently lost track of the world state after a few turns.

The study highlights that external memory architectures are essential for smaller, open-weight models like Llama 3 (70B) to compete in long-term deployments, as they are more susceptible to context window limitations than larger models like GPT-3.5.

Limitations and Future Work

While the architecture significantly improves multi-tasking, the authors identified several areas for growth. Currently, the environment is limited to six objects; as object density increases, the complexity of memory logs may challenge the Worker LLM's parsing abilities. Additionally, the models still occasionally generate redundant actions, suggesting a need for improved self-correction loops. Future work will focus on multi-party interactions, where the robot must manage different goals for multiple humans simultaneously, further testing the limits of this hierarchical memory model.

Summary updated

BibTeX
@inproceedings{ali2024robots,
  author = {Hassan Ali and Philipp Allgeuer and Carlo Mazzola and Giulia Belgiovine and Burak Can Kaplan and Lukás Gajdosech and Stefan Wermter},
  title = {{Robots Can Multitask Too: Integrating a Memory Architecture and LLMs for Enhanced Cross-Task Robot Action Generation}},
  booktitle = {Humanoids},
  year = {2024},
  url = {https://openreview.net/forum?id=adXLRfcvvO},
}
Figure