Publication:

Towards Memory Augmented Coding Agents

datacite.rightsrestricted
dc.contributor.advisorNarasimhan, Karthik
dc.contributor.authorShi, Quan
dc.date.accessioned2024-07-17T14:28:17Z
dc.date.accessioned2026-09-29T21:54:02Z
dc.date.available2024-07-17T14:28:17Z
dc.date.available2026-09-29T21:54:02Z
dc.date.created2024-04-27
dc.date.issued2024-07-17
dc.description.abstractTraditional language agents, built upon large language models, suffer from limited context windows and inefficiency in utilizing long contexts, thereby hindering long-term knowledge retention and utility. To address these challenges, we propose the augmentation of language agents with a read-write memory store that filters task-relevant information in both the writing and retrieval phases. We focus our scope on coding agents, specifically for competitive programming, developing and employing a challenging new benchmark (USACO) consisting of 307 problems from the USA Computing Olympiad. Standard models like GPT-4 exhibit modest performance on this benchmark, only achieving a 8.7% pass@1 score. Our memory-augmented coding agents demonstrate significant performance improvements, well over doubling the baseline solve rates, from a pass@1 rate of 8.7% to 20.2%. Further analysis reveals that the quality and the type of the stored content are crucial, with practical examples of code combined with reasoning being particularly impactful. Retrieved memories serve to ground models in snippet of verified code + reasoning, greatly improving performance and underscoring the advantage of memory stores that prioritize operational knowledge over theoretical content. In sum, we hope to not only establish the feasibility and efficacy of external memory stores for language agents in coding applications, but also sets a precedent for future explorations into memory-augmented cognitive models for a range of tasks, potentially transforming how agents learn and interact with information over long durations. A complete codebase can be found at https://github.com/princeton-nlp/USACO.en_US
dc.format.mimetypeapplication/pdf
dc.identifier.urihttp://arks.princeton.edu/ark:/88435/dsp01pg15bj25c
dc.identifier.urihttps://theses-dissertations.princeton.edu/handle/88435/dsp01pg15bj25c
dc.language.isoenen_US
dc.titleTowards Memory Augmented Coding Agentsen_US
dc.typePrinceton University Senior Theses
dspace.entity.typePublication
pu.contributor.authorid920246078
pu.date.classyear2024en_US
pu.departmentComputer Scienceen_US
pu.mudd.walkinNoen_US
pu.pdf.coverpageSeniorThesisCoverPage

Files

Original bundle

Now showing 1 - 1 of 1
Loading...
Thumbnail Image
Name:
SHI-QUAN-THESIS.pdf
Size:
4.26 MB
Format:
Adobe Portable Document Format
Download

License bundle

Now showing 1 - 1 of 1
Loading...
Thumbnail Image
Name:
LICENSE.txt
Size:
245 B
Format:
Plain Text
Description:
Download