Learning to Wait: Synchronizing Agents with the Physical World
Yifei She, Ping Zhang, He Liu, Yanmin Jia, Yang Jing, Zijun Liu, Peng Sun, Xiangbin Li, and Xiaohe Hu

TL;DR
This paper introduces an agent-side method enabling large language models to synchronize with real-world timing by predicting wait durations, improving efficiency and temporal coordination in asynchronous environments.
Contribution
It extends the Code-as-Action paradigm to the temporal domain, allowing LLMs to predict precise waiting times without environment-side modifications.
Findings
Agents accurately predict wait durations to synchronize with environment
Method reduces query overhead and execution latency
Temporal awareness is shown to be a learnable skill for LLMs
Abstract
Real-world agentic tasks, unlike synchronous Markov Decision Processes (MDPs), often involve non-blocking actions with variable latencies, creating a fundamental \textit{Temporal Gap} between action initiation and completion. Existing environment-side solutions, such as blocking wrappers or frequent polling, either limit scalability or dilute the agent's context window with redundant observations. In this work, we propose an \textbf{Agent-side Approach} that empowers Large Language Models (LLMs) to actively align their \textit{Cognitive Timeline} with the physical world. By extending the Code-as-Action paradigm to the temporal domain, agents utilize semantic priors and In-Context Learning (ICL) to predict precise waiting durations (\texttt{time.sleep(t)}), effectively synchronizing with asynchronous environment without exhaustive checking. Experiments in a simulated Kubernetes cluster…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsEmbodied and Extended Cognition · Multimodal Machine Learning Applications · Language and cultural evolution
