SJTU Professors Open-Source Agent Tutorial: A Four-Stage Path from Zero to AI Engineer

SJTU's open-source 4-stage Agent tutorial offers a systematic path from beginner to AI engineer.
A team of Shanghai Jiao Tong University professors has published a comprehensive Agent learning tutorial on GitHub, covering four progressive stages: core Agent modules (LLM, planning, memory, tool calling), the ReAct paradigm, multi-agent collaboration and prompt tuning, and hands-on projects like RAG-based knowledge bases. The resource aims to lower the barrier for developers entering AI application engineering.
A Tutorial Taking the AI Learning Community by Storm
Recently, the AI tech community has been buzzing about an Agent learning tutorial released by a team of professors from Shanghai Jiao Tong University. Published on GitHub, the tutorial quickly captured attention from developers worldwide and has been widely praised as a "hand-holding" beginner's guide to intelligent agents.
Its viral success isn't surprising. For a long time, Agents have been perceived as an "advanced" area of AI — something only PhD students and senior researchers could tackle. This tutorial dramatically lowers that barrier through a systematic, practical learning path. According to a Bilibili content creator who covered it, with about three months of consistent effort, developers with no prior background can realistically grow into AI engineers with real-world project experience.
What Is an Agent (Intelligent Agent)? An Agent is an AI system capable of autonomously perceiving its environment, making decisions, and taking actions to achieve specific goals. Unlike traditional question-answering language models, Agents have "autonomy" — they don't just answer questions; they proactively plan steps, call tools, process feedback, and iterate until a task is complete. The concept originated from the "rational agent" theory in reinforcement learning and cognitive science, and only became practically deployable in recent years as large models like GPT-4 and Claude reached new capability thresholds.

Unlike the many tutorials that stay at the conceptual level and "explain principles without covering implementation," this tutorial emphasizes complete training from underlying mechanisms to end-to-end project delivery. Its focus on engineering and real-world applicability is the key reason it stands out among the crowded landscape of AI learning resources.
Stage 1: Master the Four Core Modules of an Agent
Building any engineering capability starts with a solid foundation. The first stage focuses on the four core components of an Agent system — the prerequisite for everything that follows.
LLM Backbone, Planning Module, Memory Mechanism, and Tool Calling
A complete Agent system typically consists of four key parts:
- LLM Backbone: The "brain" of the agent, responsible for understanding and reasoning — the central driving force of the entire system. Large Language Models (LLMs) acquire general language understanding through pretraining on massive text corpora, serving as the "central nervous system" within an Agent. All planning and decision-making ultimately flows through it.
- Planning Module: Determines how the Agent breaks down goals and formulates execution steps — the critical bridge from "knowing how to talk" to "knowing how to act." Planning modules typically combine Task Decomposition and priority-ranking algorithms to translate vague high-level objectives into sequences of executable subtasks.
- Memory Mechanism: Enables the Agent to retain context, interaction history, and long-term knowledge, preventing it from "forgetting" everything between sessions. Memory is generally categorized into three layers: short-term memory (current conversation context window), long-term memory (historical information stored in vector databases), and episodic memory (execution experience from specific tasks).
- Tool Calling: Empowers the Agent to invoke external APIs, search engines, databases, and more — breaking through the limitations of a pure language model. Tool calling is essentially teaching an LLM "when to use which tool," implemented via Function Calling interfaces or plugin mechanisms to interact with the external world.

These four modules work in concert, forming a complete capability framework for an Agent to autonomously perceive, reason, and act. Understanding how they work individually and collaborate together is both the first hurdle to entering Agent development and the critical differentiator between those who can build usable products and those who can't.
Stage 2: Master Classic Paradigms Like ReAct
With the fundamentals in place, Stage 2 moves to methodology — focusing on mastering industry-recognized paradigms, particularly ReAct (Reasoning + Acting).
The core of the ReAct paradigm is a continuous loop between "reasoning" and "acting": the model first thinks about what to do next, then executes the corresponding action (such as calling a tool), and continues reasoning based on the feedback. This pattern gives Agents the ability to autonomously decompose complex tasks — faced with an ambiguous high-level goal, they can independently plan out a series of executable steps.
The Academic Roots of ReAct ReAct (Reasoning + Acting) was proposed by a Google Research team in 2022 and published in the paper "ReAct: Synergizing Reasoning and Acting in Language Models." Its core innovation lies in alternating Chain-of-Thought (CoT) reasoning with external tool calls, forming a closed loop of "think → act → observe → think again." Compared to pure reasoning, ReAct significantly reduces hallucinations; compared to pure action-taking, it adds interpretability and error-correction capabilities. Mainstream Agent frameworks like LangChain and AutoGPT both incorporate ReAct or its variants as core execution engines.
The value of this stage is that it assembles the "parts" from the previous stage into a running "engine." Learning to let an Agent autonomously decompose tasks means developers no longer need to manually orchestrate every step — the agent makes decisions within the framework on its own. This is precisely what distinguishes Agents from traditional automation scripts.
Stage 3: Multi-Agent Collaboration and Prompt Tuning
After mastering a single Agent, Stage 3 advances into two key areas: multi-agent collaboration and prompt/parameter tuning.
Getting Multiple Agents to Work Together
Complex tasks often exceed the capacity of a single agent. The Multi-Agent approach assigns specialized Agents to collaborate — for example, one handling information retrieval, another writing code, and a third reviewing results. This division of roles improves the overall system's stability and raises its capability ceiling.
The Technical Architecture of Multi-Agent Systems Multi-Agent Systems (MAS) have theoretical roots in distributed AI research dating back to the 1980s. In modern LLM applications, multi-agent collaboration is typically implemented via an "Orchestrator-Executor" pattern: a primary Agent handles task decomposition and scheduling, while multiple specialized Agents process subtasks in parallel or in series. Microsoft's open-source AutoGen framework, Stanford's Generative Agents experiments, and Andrew Ng's concept of Agentic Workflows are all landmark examples in this space. Research shows that multi-agent collaboration significantly outperforms single large models on complex tasks such as code generation and scientific reasoning.

This "team-based" approach is a major direction for industrial-grade Agent applications and a necessary step in moving from demos to production environments.
Tuning for Stable, Reliable Output
Beyond architectural collaboration, output quality and consistency are equally critical. Through careful tuning of prompts and related parameters, developers can make Agent outputs more stable and precise, effectively reducing hallucinations and unpredictable behavior.
Core Techniques in Prompt Engineering and Parameter Tuning Prompt Engineering refers to the practice of carefully designing input text to guide a large model toward desired outputs. In Agent scenarios, commonly used techniques include few-shot prompting, Chain-of-Thought (CoT), and role prompting. On the parameter side, Temperature controls output randomness while Top-P affects vocabulary diversity — lowering both helps stabilize Agent outputs on deterministic tasks. For engineers prioritizing production reliability, enforcing structured output (e.g., JSON format constraints) and self-verification loops are also common strategies for ensuring consistency.
For developers aiming to build reliable products, tuning capabilities often determine whether an application can truly ship.
Stage 4: Real-World Closure — Running Complete Projects End-to-End
The goal of learning is application. Stage 4 emphasizes "real-world closure" — personally completing two to three full small projects to consolidate everything learned.
The tutorial recommends practical directions such as intelligent customer service and personal knowledge bases as typical scenarios. Though modest in scale, these projects cover the complete workflow from requirements analysis and module construction to tool integration and deployment, helping learners genuinely develop engineering-oriented thinking.
The Core Technology Behind Personal Knowledge Bases: RAG Personal knowledge base applications are typically powered by RAG (Retrieval-Augmented Generation). The RAG workflow: split and vectorize private documents, store them in a vector database (e.g., Chroma, Pinecone, Milvus), retrieve relevant document chunks when a user asks a question, and inject them as context into the LLM for answering. This architecture effectively addresses two major pain points of large models — knowledge cutoff dates and the inability to train on private data — making it one of the most mature paths for enterprise AI deployment. The relevant toolchain includes LangChain, LlamaIndex, and others, with a well-established open-source ecosystem.

According to the tutorial, mastering these practical skills equips learners to handle roughly 90% of AI application engineering roles. While this claim may be somewhat optimistic, it does reflect a real market dynamic: enterprise demand for Agent application developers is strong, and engineers with end-to-end project experience are especially scarce.
The Lowered Barrier: Opportunity and Realistic Expectations
The viral success of SJTU's tutorial signals that Agent technology is moving from "research halls" into "mainstream engineering." The four-stage progressive learning path, systematic coverage of underlying mechanisms, and emphasis on end-to-end project experience genuinely offer developers interested in AI engineering a relatively efficient entry route.
That said, it's worth keeping realistic expectations: the promise of becoming an "AI engineer" in three months is an idealized time estimate. Actual outcomes depend heavily on each learner's existing background and level of commitment. The tutorial provides a clear learning map — but real engineering capability is still built through repeated practice.
Regardless, the open-sourcing and democratization of high-quality learning resources is a net positive for the entire AI ecosystem. When Agent development is no longer the exclusive domain of a select few, more innovative applications can emerge from a much broader pool of developers.
Key Takeaways
Related articles

What to Do When AI Won't Listen? Understanding Why Models Go Off-Track and Practical Fixes
AI keeps giving irrelevant answers? This article explains the technical reasons behind AI "misbehavior" and provides practical tips including prompt optimization, system constraints, and conversation resets.

1,741 "Informed Consents" with One Click? GDPR Complaint Exposes the Cookie Consent Chaos
One click on "Accept All Cookies" triggers 1,741 informed consent authorizations. A deep analysis of how this GDPR complaint exposes RTB ad system compliance failures and their impact on privacy.

What to Do When AI Won't Listen? Understanding Why Models Go Off-Track and Practical Fixes
AI responses keep missing the mark? This article explains why AI models go off-track from a technical perspective and provides practical correction techniques including prompt optimization, system constraints, and conversation resets.