Trajectory-Oriented Resource Modeling for AI Agents in Online Learning Services
DOI:
https://doi.org/10.18372/2073-4751.87.21679Keywords:
online learning, resource optimization, distributed systems, inference serving, QoS/SLA, autoscaling, observability, token costAbstract
AI agents based on Large Language Models are increasingly being integrated into online learning services, where interaction is session-based, multi-step, and extended through the use of external tools. In such systems, resource consumption cannot be described by a traditional unit of control. Instead, a single user request generates an internal workload trajectory that may include several inference calls, tool-related I/O operations, memory operations, and observability overhead. At the same time, the GPU workload profile is shaped by the token structure and the two-phase nature of inference, namely prefill and decode, while long contexts have a critical impact on the tail of the latency distribution. This paper proposes a trajectory-oriented model of resource consumption by AI agents in high-load educational platforms. The agent trajectory is formalized as the primary object of resource accounting. The paper introduces notation that links trajectory parameters with GPU, CPU, memory, and network costs, and defines QoS/SLA constraints through latency quantiles and error-rate limits aligned with the interactive requirements of tutoring. The model takes into account the architectural separation between the inference and orchestration layers, as well as the role of tool calls and memory operations as components of the critical latency path. The paper also formalizes the distinction between observability as part of a control loop and observability as post-factum diagnostics.
References
1. Yao S., Zhao J., Yu D., Du N., Shafran I., Narasimhan K., Cao Y. ReAct: Synergizing Reasoning and Acting in Language Models. arXiv preprint. 2022. arXiv:2210.03629. DOI: 10.48550/arXiv.2210.03629.
2. Schick T., Dwivedi-Yu J., Dessì R., Raileanu R., Lomeli M., Zettlemoyer L., Cancedda N., Scialom T. Toolformer: Language Models Can Teach Themselves to Use Tools. arXiv preprint. 2023. arXiv:2302.04761. DOI: 10.48550/arXiv.2302.04761.
3. Park J. S., O’Brien J. C., Cai C. J., Morris M. R., Liang P., Bernstein M. S. Generative Agents: Interactive Simulacra of Human Behavior. arXiv preprint. 2023. arXiv:2304.03442. DOI: 10.48550/arXiv.2304.03442.
4. Wu Q., Bansal G., Zhang J., Wu Y., Li B., Zhu E., Jiang L., Zhang X., Zhang S., Liu J., Awadallah A. H., White R. W., Burger D., Wang C. AutoGen: Enabling Next-Gen LLM Applications via Multi-Agent Conversation. arXiv preprint. 2023. arXiv:2308.08155. DOI: 10.48550/arXiv.2308.08155.
5. Kwon W., Li Z., Zhuang S., Sheng Y., Zheng L., Yu C. H., Gonzalez J. E., Zhang H., Stoica I. Efficient Memory Management for Large Language Model Serving with PagedAttention. Proceedings of the 29th ACM Symposium on Operating Systems Principles (SOSP ’23). New York, NY: ACM, 2023. P. 611–626. DOI: 10.1145/3600006.3613165.
6. Moritz P., Nishihara R., Wang S., Tumanov A., Liaw R., Liang E., Elibol M., Yang Z., Paul W., Jordan M. I., Stoica I. Ray: A Distributed Framework for Emerging AI Applications. Proceedings of the 13th USENIX Symposium on Operating Systems Design and Implementation (OSDI ’18). Carlsbad, CA: USENIX Association, 2018. P. 561–577.
7. Schroeder C., et al. Comparison of Autoscaling Frameworks for Containerised Machine-Learning-Applications in a Local and Cloud Environment. arXiv preprint. 2023. arXiv:2311.18659. DOI: 10.48550/arXiv.2311.18659.
8. Wang G., Xie Y., Jiang Y., Mandlekar A., Xiao C., Zhu Y., Fan L., Anandkumar A. Voyager: An Open-Ended Embodied Agent with Large Language Models. arXiv preprint. 2023. arXiv:2305.16291. DOI: 10.48550/arXiv.2305.16291.
9. Ilyushkin A., Ali-Eldin A., Ghit B., Iosup A., Epema D. A Workload Forecasting Model for Private Clouds. IEEE Transactions on Cloud Computing. 2017. Vol. 7, No. 4. P. 949–963.
10. KEDA Project. Kubernetes Event-Driven Autoscaling (KEDA): Documentation. URL: https://keda.sh/docs/
11. OpenTelemetry Project. Observability Primer: Documentation. URL: https://opentelemetry.io/docs/concepts/observability-primer/
12. Luo J., Zhang W., Yuan Y., Zhao Y., Yang J., Gu Y., Wu B., Chen B., Qiao Z., Long Q., et al. Large Language Model Agent: A Survey on Methodology, Applications and Challenges. arXiv preprint. 2025. arXiv:2503.21460. DOI: 10.48550/arXiv.2503.21460.
13. Xu W., Huang C., Gao S., Shang S. LLM-Based Agents for Tool Learning: A Survey. Data Science and Engineering. 2025. Vol. 10. P. 533–563. DOI: 10.1007/s41019-025-00296-9.
14. Zhong Y., Liu S., Chen J., Hu J., Zhu Y., Liu X., Jin X., Zhang H. DistServe: Disaggregating Prefill and Decoding for Goodput-Optimized Large Language Model Serving. Proceedings of the 18th USENIX Symposium on Operating Systems Design and Implementation (OSDI ’24). USENIX Association, 2024.
15. Agrawal A., Kedia N., Panwar A., Mohan J., Kwatra N., Gulavani B. S., Tumanov A., Ramjee R. Taming Throughput–Latency Tradeoff in LLM Inference with Sarathi-Serve. Proceedings of the 18th USENIX Symposium on Operating Systems Design and Implementation (OSDI ’24). USENIX Association, 2024. P. 117–134.
16. Sheng Y., Cao S., Li D., Hooper C., Lee N., Yang S., Chou C., Zhu B., Zheng L., Keutzer K., Gonzalez J. E., Stoica I. Fairness in Serving Large Language Models. Proceedings of the 18th USENIX Symposium on Operating Systems Design and Implementation (OSDI ’24). USENIX Association, 2024.
17. Khan R. I. S., Jain K., Shen H., Mallick A., Parayil A., Kulkarni A., Kofsky S., Choudhary P., St. Amant R., Wang R., Cheng Y., Butt A. R., Rühle V., Bansal C., Rajmohan S. Ensuring Fair LLM Serving Amid Diverse Applications. arXiv preprint. 2024. arXiv:2411.15997.
18. Gao B., He Z., Sharma P., Kang Q., Jevdjic D., Deng J., Yang X., Yu Z., Zuo P. Cost-Efficient Large Language Model Serving for Multi-Turn Conversations with CachedAttention. arXiv preprint. 2024. arXiv:2403.19708.
19. OpenTelemetry. GenAI Semantic Conventions. URL: https://github.com/open-telemetry/semantic-conventions-genai
Downloads
Published
How to Cite
Issue
Section
License

This work is licensed under a Creative Commons Attribution 4.0 International License.
The scientific journal adheres to the principles of Open Access and provides free, immediate, and permanent access to all published materials without financial, technical, or legal barriers for readers.
All articles are published in Open Access under the Creative Commons Attribution 4.0 International (CC BY 4.0) license.
Copyright
Authors who publish their works in the journal:
-
retain the copyright to their publications;
-
grant the journal the right of first publication of the article;
-
agree to the distribution of their materials under the CC BY 4.0 license;
-
have the right to reuse, archive, and distribute their works (including in institutional and subject repositories), provided that proper reference is made to the original publication in the journal.



