Abstract
Text-based Reinforcement Learning (RL) agents often suffer from extreme sample inefficiency due to the vast action spaces of natural language environments. This paper investigates the integration of external commonsense knowledge from ConceptNet to guide agent decision-making. By combining a dynamic local belief graph with a task-relevant global commonsense graph, the proposed architecture enables agents to prune illogical actions and focus on meaningful goals. Results on the TextWorld "Kitchen Cleanup" and "Cooking Recipe" tasks demonstrate that "just-in-time" delivery of commonsense information significantly accelerates learning and improves move efficiency, while also highlighting the risks of information overload from irrelevant external data.
Introduction
Reinforcement Learning agents in text-based environments, such as TextWorld, face a daunting challenge: they must navigate complex worlds and solve puzzles using only text commands. Unlike humans, who bring a lifetime of prior knowledge to a task, standard RL agents start as a tabula rasa. For instance, a human knows instinctively that a plate belongs in a cabinet or an apple in a refrigerator. An RL agent, however, must fail thousands of times to discover these basic relationships through trial and error.
This paper addresses the problem of "sample inefficiency" by bridging the gap between raw RL and human-like reasoning. By integrating structured external knowledge from ConceptNet, the researchers aim to provide agents with a symbolic guide that helps them focus on logical actions and ignore the vast sea of irrelevant possibilities.
Methodology
The proposed system builds upon the Graph Aided Transformer Agent (GATA) framework. The core innovation lies in representing the agent's state through two distinct but complementary graph structures:
- Local Belief Graph: This is a symbolic representation constructed dynamically by the agent based on its immediate observations (e.g., "I am in the kitchen," "I see a table"). It tracks what the agent currently knows about its environment.
- Global Commonsense Graph: This is a subgraph extracted from ConceptNet, containing entities and relationships relevant to the objects identified in the environment (e.g.,
Apple$\xrightarrow{AtLocation}$Refrigerator).
Model Architecture
As illustrated in the architecture diagram below, the agent processes text observations and available actions through dedicated input encoders using GloVe embeddings and Gated Recurrent Units (GRUs). The local belief and global commonsense graphs are then integrated using Graph Convolutional Networks (GCNs). This integration involves graph aggregation and embedding (using Numberbatch) to create a unified state representation.
The final decision-making process utilizes an Advantage Actor-Critic (A2C) framework. An attention layer weighs the integrated knowledge against the encoded actions, and a softmax layer selects the most promising command.
Experimental Setup
The researchers evaluated the model using TextWorld, a sandbox for generating text-based games, focusing on two primary tasks:
- Kitchen Cleanup Task: A custom environment where the agent must tidy a room by placing 10 specific objects in their logical locations while ignoring 5 distractor objects.
- Cooking Recipe Task: A benchmark dataset requiring the agent to gather specific ingredients to follow a recipe.
Results and Discussion
The experimental results highlight the significant impact of structured knowledge on agent performance. In the Kitchen Cleanup Task, the knowledge-aware agents outperformed all baselines in both speed of learning and operational efficiency.
The Importance of Evolving Knowledge
A critical discovery was the "Information Overload" trap. Providing the agent with the entire commonsense graph at the start of the game introduced too much noise, actually hindering performance. The most effective strategy was KG_Evolve, where the agent only receives commonsense facts about objects it has already encountered. This "just-in-time" delivery keeps the agent focused on relevant information.
As shown in the performance plots, the KG_Evolve agent reached the maximum score of 10 much faster than the "Simple" text-only agent. Furthermore, it reduced the average number of moves required to complete the task from 48 to approximately 27, demonstrating a much higher level of intentionality.
Task Alignment and Limitations
In the Cooking Recipe Task, the benefits were more modest. Because these recipes often involved randomized ingredients that did not strictly follow real-world logic, the external commonsense knowledge was sometimes less relevant. This suggests that the utility of external knowledge is highly dependent on how well the task logic aligns with real-world priors.
Conclusion
Integrating commonsense knowledge graphs into RL agents provides a powerful heuristic for navigating complex text-based environments. By filtering this knowledge to match the agent's current experience (KG_Evolve), researchers can significantly mitigate sample inefficiency. Future work will explore more sophisticated filtering mechanisms to ensure that agents are guided by relevant hints without being overwhelmed by the scale of global knowledge bases.
Summary updated