16 of 174 subtitles documented + 1 independent supplementary unit(s) · Writing progress, not your learning progress · Videos not visually reviewed
What is an agent? From fixed flow to tool selection
Objective and entry check
Distinguish a predetermined workflow from model-selected actions, and separate retrieved evidence from generated claims in a job-search project.
If an application always searches first and summarizes second, does having both search and a model automatically make it an agent?
Entry answer
Not under this lesson's definition. The programmer fixed that sequence. A model choosing a next step or tool introduces agentic behavior; hybrid workflows are possible.
Why connect a model to tools?
A base model generates responses from its input and learned weights. Knowing language or a website's name does not establish live access to that site or a database. Today's job listings require relevant current data supplied through the application.
In a simple chain, we specify when search happens. An agent can delegate part of deciding whether and how to search to the model, while application infrastructure still performs the action. “Agent” has different meanings across fields; this lesson follows the course's language-application usage.
Historical context: ReAct
The 2022 ReAct paper investigated interleaving reasoning and action. The important idea here is that an action's result informs the next decision, rather than producing only one isolated response. Original paper
Understanding this architecture does not require exposing every private reasoning step. Tool requests, validated inputs, observations, and final results let us inspect the operational path. ReAct here names an agent architecture, distinct from the React user-interface library.
Follow the loop
- The user states a goal.
- The model produces an answer or a tool request.
- The application validates the tool name and arguments and executes an allowed tool.
- A result correlated to the call ID enters the message history.
- The model answers or requests another step; application limits also constrain execution.
A request from the model does not grant unlimited action capabilities. Available operations depend on tools the application actually exposes and executes. A search tool does not itself submit job applications.
The instructor's job-search project
Lecture 018 demonstrates finding three AI engineering positions involving LangChain in the Bay Area and emphasizes source links. Those listings and the demonstrated interface belong to that example. These notes do not treat them as active today or as directly inspected by us.
A verifiable result benefits from a title, company, location, source link, and verification time. If a source does not establish a skill or location, preserve “unknown” rather than filling gaps to complete a table. A URL alone does not prove a claim; its source text must support that particular assertion.
In our fictional exercise, only two records exist: one mentions LangChain and another Python. Finding one match does not justify inventing two additional records to reach three. A requested count is a search target, not permission to fabricate evidence.
An executable simulation
tool_loop.py uses real AIMessage and ToolMessage objects with scripted model replies. Its tool filters a local fictional list. It does not search the internet or implement an agent with actual LLM decision-making.
python tool_loop.py
Run from examples in the configured environment. The observed path was:
tool-request → tool-result → final-answer
The example exposes call/result correlation, argument validation, and loop termination. Changing scripted replies illustrates the mechanism; it does not evaluate a real model's ability to select tools.
Common misconceptions
- Tool availability does not require calling a tool for every request.
- A
tool_callgenerally requests an operation; generating it does not establish successful execution. - Search and RAG can occur inside agents; these terms are not synonyms.
- Reaching a turn limit stops execution without necessarily solving the task.
Independent practice
- Only one trustworthy source matches a request for three positions. What should the answer do?
- Why must
search_jobsnot automatically execute asend_applicationrequest? - A tool-call message exists without a recorded result. What remains unknown?
- What does the current simulator check, and what does it not check?
Answer 1
Report the one supported match and coverage limits. Further permitted search may find more; do not fabricate records.
Answer 2
Submitting applications is a different capability absent from this tool. An unknown name must be handled or rejected, not converted to arbitrary execution.
Answer 3
Whether execution happened, failed, or remains pending. Inspect execution events and the correlated result.
Answer 4
It checks call/result linkage, filtering, invalid requests, and termination limits. It does not test intelligent tool choice, live search, or current listing accuracy.
Recall and continuation
Draw the loop without the text and distinguish a request from its execution. If you can explain fixed and agentic flows using two examples, continue to agent implementation evolution. Otherwise, compare direct-answer and tool-using simulator paths.
Course basis: complete lecture 017 and 018 subtitles. The diagram, fictional records, code, and exercises are supplementary. Simulator checks used core 1.5.2; videos and the instructor's demonstrated listings were not directly inspected. Historical reference checked on 2026-10-16.