Connecting an LLM API Doesn't Make an AI Agent
Many people, when building their first AI assistant, have a very natural thought:
I've already connected the large model API, and it can answer questions in the command line. So, does this count as an AI Agent?
The answer is:
Not yet.
Because there's a whole layer of capability missing between "being able to chat" and "being able to act."
This article won't discuss complex frameworks or large blocks of code. We'll use 8 diagrams to first clarify this question.
01 | I've connected the API, and it can already answer questions
The user inputs a question, Node.js sends the question to the large model API, and then prints the model's answer to the terminal.
Seeing this, many people think:
"Isn't this an AI Agent?"
But in reality, it's currently just an AI program that can chat.
02 | What can it actually do right now?
After connecting the API, the model can already understand questions, generate answers, perform basic reasoning, and output content according to prompts.
But it still cannot read your project files, modify code, run commands, or check execution results.
Essentially, it's still:
The user asks a question, the model gives an answer.
It has a "brain," but no real "hands" or "feet."
03 | Why isn't it an Agent yet?
Suppose you say to it:
Help me fix the login bug.
The model might know where to start troubleshooting, but it can't see login.ts, auth.ts, or user.ts, much less directly modify the project or run tests.
So, being smart doesn't mean being able to act.
It knows "what should be done," but it can't yet "actually do it."
04 | What extra layer does a real Agent have?
A real Agent doesn't just have a large model; it also needs a layer called Harness:
- The large model is responsible for understanding tasks, reasoning, and deciding the next step.
- The Harness is responsible for providing tools, executing operations, managing context, and constraining behavior.
You can first remember this core formula:
AI Agent ≈ Large Model (Brain) + Harness (Control System)
That is: The large model decides what to do, and the Harness is responsible for making it happen.
05 | What exactly does the Harness do?
For example, if the model decides the next step is to read the README, it doesn't open the file itself; instead, it initiates a Tool Call.
After the Harness receives the request, it calls the corresponding tool:
read_file: Read a fileedit_file: Modify codebash: Execute a command
These operations ultimately land in the real project and runtime environment.
The model is responsible for thinking, and the Harness is responsible for calling tools and executing.
06 | Why does the first article still start with "connecting the API"?
Because all the subsequent complex capabilities are built upon this minimal link:
User Input →
main.ts→chat.ts→ Large Model → Terminal Output
Where:
config.tsis responsible for reading the model configurationchat.tsis responsible for requesting the large modelmain.tsis responsible for receiving user input
Although this step isn't a complete Agent yet, it is the foundation of the entire system. Tools, the Agent Loop, memory, and Plan Mode will all gradually grow from here.
07 | So what is this thing more like right now?
The current program is more like a CLI Chatbot:
User asks → Large model answers
A real Agent would also interact with the project and environment through a tool system, and continuously complete:
Observe → Act → Check Result → Continue Executing
So a more accurate statement isn't:
"I've already finished building an Agent."
But rather:
"I've built a minimally viable AI command-line assistant."
08 | What should you really remember from this article?
You only need to remember three points from this article:
- Connecting the API does not mean you've built an Agent.
- The large model is responsible for thinking, and the Harness is responsible for acting.
- The first step is to make it able to speak; the next step is to make it able to act.
If you only remember one sentence, let it be this:
A model program that can only answer questions is not yet a complete AI Agent.
A real Agent needs to start interacting with a real environment and completing tasks through tools.
Next Article
Illustrated AI Agent ②: How exactly does a model read a file?
The model doesn't open the README by itself; it just applies to call a tool:
read_file
This illustrated article helps you first build an overall understanding of AI Agents.
In the next one, we'll attach the first "hand" to this "brain," letting it truly see your project files for the first time.
If you want to continue building these capabilities with real code, you can follow the "Hand-Building AI Agents Without Frameworks" series. We will start from connecting the model API and gradually implement file reading, an Agent Loop, a tool system, memory, and Plan Mode.
The illustrated series is responsible for helping you understand, and the hands-on series is responsible for guiding you to build it.