Modern AI Fundamentals: From Models to Agentic Systems

Modern AI is more than a powerful model. This article presents a seven-layer mental model—from tokens, transformers and foundation models to context, knowledge, tools and agents—showing how these capabilities come together to create AI systems that can reason, act, learn…

From Tokens and Transformers to Agents, Decisions and Continuous Improvement

A seven-layer mental model for understanding how tokens, transformers, context, knowledge, tools and agents come together to turn AI intelligence into decisions and actions.

The vocabulary around AI has expanded rapidly. We started with Machine Learning and Deep Learning, then Transformers, Foundation Models and LLMs. Today, conversations increasingly include RAG, context engineering, reasoning models, tool calling, MCP, memory, AI agents, multi-agent systems, evaluation, observability and agentic workflows.

Individually, most of these concepts are understandable. The harder part is seeing how they fit together. Where does a Transformer fit relative to an LLM? Is RAG part of the model or the application around it? What is the difference between context, memory and state? Does giving an LLM a tool make it an agent? Where does MCP fit? And what changes when AI moves from generating an answer to pursuing a goal and taking action?

A useful way to make sense of this landscape is to stop treating modern AI as a collection of disconnected terms and instead build a layered mental model. The framework in this article has seven layers: Data & Representation; Model; Context & Knowledge; Capabilities; Agentic; Evaluation, Observability & Control; and Decisions & Actions. The layers are not a rigid technology stack. They are a way to understand what each concept contributes and how increasingly capable AI systems are assembled.

The model provides intelligence. The system around it makes that intelligence useful, controlled and trustworthy.

Layer 1 — Data & Representation

Modern AI can work with text, images, audio, video and code, but models ultimately process numerical representations. This first layer explains how real-world information is converted into a form the model can work with. For language, the journey begins with tokenization; embeddings then provide a richer numerical representation of meaning.

1. Tokens and Tokenization

A token is a small unit of text processed by a language model. Depending on the tokenizer, it may be a complete word, part of a word, punctuation or another symbol. Tokenization breaks text into these units and maps them to numerical IDs. Conceptually: Text → Tokens → Numeric IDs → Model. Tokens also matter at the application level because instructions, retrieved evidence, conversation history and tool results all consume context capacity.

2. Embeddings

An embedding represents information as a vector — a collection of numbers that captures useful aspects of meaning. The important idea is not the individual numbers but their relationships. Semantically related words, sentences or document passages can often be represented closer together mathematically. This makes embeddings important both inside models and in retrieval systems.

3. Vector Space

Embeddings exist in a high-dimensional vector space. A useful intuition is that similar meanings tend to occupy nearby regions. This enables semantic similarity: a question can be compared with thousands of passages and the system can retrieve information that is close in meaning even when the exact wording is different.

Layer 2 — Model

The Model Layer is where much of the intelligence associated with modern Generative AI is learned. Transformers process relationships among tokens, attention helps the model focus on relevant information, and foundation models provide broad capabilities that can be reused across many applications.

1. Transformer and Attention

The Transformer is the neural-network architecture behind most modern LLMs. One of its central mechanisms is attention, which helps the model weigh relationships among different parts of the input. At a simplified level: Input Tokens → Attention Layers → Internal Representations → Next-Token Prediction. Repeated across many layers and trained at large scale, this allows the model to learn complex patterns in language and other modalities.

2. Foundation Model

A foundation model is trained broadly and can support many downstream tasks rather than being designed for one narrow problem. One broadly trained model may summarize, extract, classify, answer questions, generate code or support reasoning. This is an important shift from one model for one task toward reusable intelligence that applications can adapt through context, tools and surrounding software.

3. LLMs and Multimodal Models

A Large Language Model, or LLM, is a large-scale foundation model primarily oriented around language. A multimodal model can work across multiple forms of information such as text, images, audio and video. These terms describe related capabilities, but the important mental-model point is that the model provides general intelligence; it does not by itself know the current business situation, the latest enterprise data or what action is permitted.

Layer 3 — Context & Knowledge

A capable model is only part of a useful AI application. The model also needs the right information for the task at the right time. This layer brings together the user request, instructions, history, current state, retrieved evidence and governed knowledge that shape what the model can do in a particular interaction.

1. Prompt

A prompt is the instruction or input given to the model. Prompt engineering focuses on expressing the task, constraints and expected response clearly. In a production application, however, the prompt is only one component of the model’s working information.

2. Context Window

The context window is the bounded amount of information available to the model in an interaction. It can include system instructions, the user request, retrieved evidence, conversation history, tool descriptions, tool results and current task state. More context is not automatically better: irrelevant or stale information can consume capacity and make important evidence harder to use.

3. Context Engineering

Context engineering is the deliberate selection and organization of what the model needs right now. Prompt engineering asks, “What should I ask the model?” Context engineering asks the broader question, “What should the model know at this point in the task?” In enterprise AI, this can include governed definitions, relevant documents, user or business context, current state and the tools available to the application.

4. RAG — Retrieval-Augmented Generation

RAG retrieves relevant information at runtime and supplies it to the model as evidence. A simple flow is Question → Retrieve Relevant Information → Add Evidence to Context → Generate Response. This is useful when knowledge changes frequently because the underlying source can be updated without retraining the model.

5. Vector Search

Vector search uses embeddings to find semantically similar information. Document passages and the user’s query are represented numerically and compared in vector space. This allows retrieval based on meaning rather than relying only on exact keyword matches.

6. Knowledge Graphs and Semantic Models

Not every knowledge problem is best solved by retrieving text. Knowledge graphs represent entities and their relationships explicitly, while semantic models encode governed business meaning such as measures, definitions and hierarchies. These approaches can complement one another: RAG retrieves evidence, vector search finds semantic similarity, knowledge graphs capture relationships and semantic models provide consistent business meaning.

Layer 4 — Capabilities

The model may understand and reason about information, but real work often requires capabilities outside the model. The system may need to query a database, search, execute code, read files, call an API, remember something for later or maintain progress across a workflow. The Capability Layer extends what the model knows into what the overall application can do.

1. Tools

A tool is an external capability available to the AI application. Examples include APIs, databases, search, files, calculators, code execution and enterprise systems. Tools let the system obtain fresh information or cause an external operation rather than relying only on what is already present in the model or context.

2. Tool Calling

The model typically does not execute an external system directly. It requests a tool and supplies structured arguments. The surrounding runtime or harness validates that request, checks permissions, executes the allowed operation and returns the result. The mental model is Model → Request → Harness → Tool → Result → Model. The model proposes; the surrounding software validates and executes.

3. MCP — Model Context Protocol

As applications connect to more tools and resources, custom point-to-point integrations become difficult to reuse. Model Context Protocol, or MCP, provides a standard interface through which AI applications can connect to tools and resources. MCP is therefore best understood as an interoperability mechanism. It can make capabilities easier to expose and reuse, but it does not by itself make a system agentic.

4. Context, Memory and State

These terms are related but should not be collapsed into one idea. Context is what the model can see now. Memory is information intentionally retained for later use. State records where the system currently is in a task or workflow. A useful shorthand is Now → Context; Later → Memory; Where → State. Durable state should live in application storage rather than treating the model’s context window as a database.

5. Fine-Tuning

Fine-tuning adapts model behavior through additional training. It solves a different problem from RAG: RAG changes the information available to the model at runtime, while fine-tuning changes learned model behavior. This distinction helps avoid using model adaptation when the actual need is simply fresh or domain-specific evidence.

6. Reasoning Models

Reasoning-oriented models are optimized for tasks that benefit from multi-step problem solving, such as decomposing a problem, connecting evidence, comparing alternatives or planning a next step. Reasoning can improve how a problem is worked through, but reasoning alone does not create agency. Agency also requires a system that can act, observe results, maintain state and decide whether to continue.

Layer 5 — Agentic

The Agentic Layer marks the transition from systems that primarily generate responses to systems that can pursue goals across multiple steps. The architectural change is not simply a more powerful model. It is the combination of a model with context, tools, state and an iterative execution loop.

1. Agent

An AI agent, in the course framing, is a language-model-based system in which the model selects steps toward a goal while surrounding software executes permitted tools and returns their results. The system also uses task state — information retained about the task and its progress — to decide what to do next. The amount of decision-making delegated to the model can vary substantially. A useful mental model is therefore not simply “LLM + tools,” but Model + Context + Tools + Task State + Harness + Iterative Execution.

2. Agentic Loop

The course defines the agentic loop through five functions: Perceive → Reason → Act → Observe → Verify, repeating relevant steps when work remains. Perceive receives the goal and relevant task state. Reason chooses the next step. Act occurs when the harness executes a permitted tool request. Observe receives the tool result. Verify compares the available evidence with the acceptance criteria. If work remains, the loop repeats; otherwise the system reports the result or the reason for stopping. In the infographic, “Iterate” makes this repetition explicit. Importantly, repeated actions do not prove success — verification requires evidence against defined acceptance criteria.

3. Agency Levels

Agency is better understood as a spectrum of delegated control. The course uses four teaching categories: None — a fixed prompt and one model call without tools or branching; Augmented Interaction (Level 1) — retrieval, tools or other capabilities inside a bounded procedure; Workflow (Level 2) — an engineer-defined coordination scheme combining model calls and tools while delegating selected decisions; and Autonomous Agent (Level 3) — the model selects successive steps and tools at runtime within the harness’s permissions and limits. The infographic uses “L0 Fixed model call” as a compact visual shorthand for the course’s “None” category. The key design question remains: Who decides what happens next?

4. Agentic Workflow

An agentic workflow combines model calls, tools and delegated decisions inside a coordination structure largely defined by the engineer. This can provide useful flexibility while keeping the process bounded, testable and easier to govern. For many enterprise use cases, this can be preferable to maximizing autonomy.

5. Autonomous Agent

An autonomous agent selects steps and tools dynamically at runtime. Autonomy does not mean unrestricted freedom: permissions, tool boundaries, budgets, verification rules and stopping conditions still belong to the surrounding system. More autonomy is useful only when the task benefits from it and the additional decisions can be evaluated.

6. Harness

The agentic harness is the software around the model that supplies context and tools, executes permitted requests, and manages continuation or stopping. It can also retain task state between model calls. In practical systems, the harness is therefore the control boundary between model proposals and real execution: the model proposes steps; the harness enforces the available execution rules. This is why the same underlying model can behave very differently depending on the harness in which it operates.

7. Multi-Agent Systems

A multi-agent system uses several agents and distributes work or autonomy across them. Coordination may follow fixed rules or allow dynamic decisions; importantly, agent count is a separate design choice from the level of autonomy. The value may come from specialization, isolation, parallelism or independent review. More agents do not automatically make a system better: tightly coupled agents sharing changing state can increase coordination problems. Multi-agent design is therefore a decomposition and coordination choice, not a maturity badge.

Layer 6 — Evaluation, Observability & Control

Once AI systems use tools and pursue goals, evaluating only the final answer is no longer enough. We need evidence of what happened during execution, explicit criteria for judging behavior, a way to diagnose failures, regression tests for agreed behavior and monitoring after deployment. Week 5 of the IISc course frames this as a continuous engineering loop rather than a final quality gate.

1. Traces and Spans — What Happened?

A trace is the end-to-end record of one request through the system; spans represent individual steps within that trace. Together they can show model calls, tool requests, tool results, routing decisions, latency, validation outcomes and errors. This makes the system observable at the process level rather than judging only the final response.

2. Evaluation — How Well Did It Work?

Evaluation converts desired behavior into explicit criteria and checks. Some criteria are deterministic and can be evaluated in code; others require semantic judgement. For agentic systems, evaluation should consider both output quality and process quality: whether the right tools were used, arguments were appropriate, permissions were respected and the claimed result was actually achieved.

3. Diagnose — Why Did It Fail?

The Week 5 material introduces three useful gulfs for diagnosis. The comprehension gulf is the gap between the developer and the data or real behavior. The specification gulf is the gap between the intended behavior and what was actually specified. The generalization gulf is the gap between tested examples and the broader range of real requests. This framing helps teams locate the source of failure before deciding that the model itself needs to change.

4. Evaluators and Human Judgement

Human judgement is often where evaluation criteria begin. Experts review real traces, identify acceptable and unacceptable behavior, and turn those observations into explicit checks. Deterministic checks should be used where code can decide reliably. LLM-as-a-Judge becomes useful for semantic criteria that cannot be captured easily in code, but the judge itself should be validated against expert-reviewed examples before it is trusted at scale.

5. Improve — Fix the Responsible Layer

Once a failure is understood, improvement should target the responsible layer. The right fix may be a clearer specification, better context, a different prompt, stronger retrieval, improved tool definitions, application logic, permissions, data or model choice. Treating every failure as a prompt problem or model problem can hide the real architectural cause.

6. Golden Sets and Regression Testing

A golden set is a curated collection of approved cases with expected behavior. It should include core functionality, important edge cases and past failures that must not return. Golden sets are valuable regression alarms, but a high pass rate does not prove quality across every user or production situation. They protect known behavior; they do not eliminate unknown failure modes.

7. Monitor in Production and Improve Continuously

Evaluation continues after deployment. Production traces, user feedback and new failure patterns provide fresh evidence that can update criteria, evaluators and the golden set. The lifecycle therefore becomes Traces → Evaluate → Diagnose → Improve → Regression Test → Monitor → New Evidence → Improve Again. This is the feedback loop that turns evaluation into continuous system improvement.

8. Guardrails and Human Oversight

Guardrails and human oversight span the entire lifecycle rather than appearing as one final step. Permissions, validation, budgets, approval gates, rollback strategies and escalation paths constrain what the system may do. Human review becomes increasingly important for consequential or difficult-to-reverse actions. The level of control should reflect the consequence of the action, not simply the technical capability of the model.

Layer 7 — Decisions & Actions

The final layer connects AI to real-world outcomes. In enterprise settings, the goal is rarely to generate more content for its own sake. The value comes from turning analysis and evidence into better decisions, appropriate actions and measurable outcomes — and then feeding what happened back into the system.

1. Evidence

Evidence is the information on which a decision is based. It may come from model analysis, retrieved facts, enterprise data, analytical models or tool results. Grounding decisions in evidence improves explainability and creates something that can be reviewed or verified.

2. Decision

A decision converts evidence into a choice. It may be a recommendation, an automated selection, a human approval or a combination of these. The important point is that the decision should be connected to the evidence and to the level of authority the AI system has been given.

3. Action

An action changes something in the real world or another system: updating a record, triggering a workflow, sending a notification, creating a ticket or executing another permitted operation. This is where tool-enabled and agentic systems move beyond content generation.

4. Outcome

An outcome is the measurable result of the decision and action. Depending on the use case, it could be faster resolution, better decision quality, improved customer experience, reduced cost, higher revenue or lower risk. Outcomes also provide new evidence for evaluation, closing the feedback loop.

Putting the Seven Layers Together

Once the layers are connected, the terminology becomes easier to place. Tokens and embeddings explain representation. Transformers, attention and foundation models provide the core intelligence. Context engineering, RAG, vector search, knowledge graphs and semantic models bring the right knowledge into the interaction. Tools, MCP, memory, state and reasoning extend what the application can do. Agentic loops, workflows, harnesses and multi-agent systems allow the system to pursue goals. Evaluation, observability, guardrails and human oversight make that behavior measurable and controlled. Decisions, actions and outcomes connect the technology to the real world.

The important architectural idea is that these layers interact. An agent can fail because retrieval supplied the wrong evidence, because a tool contract was ambiguous, because state was lost, because the specification was incomplete or because the model made a poor decision. Continuous evaluation provides the evidence needed to improve the correct layer rather than simply changing the model.

A System View: From Intelligence to Controlled Action

The seven layers can also be compressed into four architectural bands. This is an explanatory synthesis used in this article — not a separate IISc course taxonomy — and it helps show why agentic AI is a system architecture rather than simply a new model category.

1. Intelligence

Tokens → Embeddings → Transformers → Foundation Models. This is where information is represented and general model capability is learned.

2. Grounding & Augmentation

Prompt + Context + Retrieved Knowledge + Reasoning + Tools/MCP. This gives the model task-specific evidence and external capabilities.

3. Agency & Orchestration

Harness + Task State + Memory + Agentic Loop + Workflow/Agent Coordination. This determines how permitted work continues across steps and who controls what happens next.

4. Trusted Decisions & Actions

Evaluation + Observability + Guardrails + Human Oversight → Evidence → Decision → Action → Outcome. This connects AI behavior to controlled execution and measurable results.

A Simpler Capability Progression

The seven-layer model explains the architecture. A second, simpler view helps explain how AI capabilities build on one another:

  • Generative AI — Model + Prompt → generates content such as answers, plans or analyses.
  • Grounded AI — Generative AI + Context + Retrieved Knowledge → uses relevant evidence.
  • Augmented AI — Grounded AI + Tools → reaches external capabilities and systems.
  • Agentic AI — Augmented AI + Harness + Task State + Iterative Loop → pursues goals through controlled, multi-step execution.
  • Governed Agentic AI — Agentic AI + Evaluation + Guardrails + Human Oversight → controlled and trustworthy execution.
  • Decision Systems — Evidence → Decision → Action → Outcome, with feedback flowing back into every layer.

Generative AI creates. Grounded AI uses knowledge. Augmented AI reaches tools. Agentic AI pursues goals. Governed Agentic AI adds control. Decision systems connect all of this to outcomes.

From Intelligence to Continuous Improvement

The evolution of modern AI is often described mainly through more capable models. That is only part of the story. The larger architectural change is happening around the model. We give models context, connect them to knowledge and tools, maintain memory and durable task state, place the model inside a harness that controls execution, and use iterative loops to pursue goals. We then surround those loops with evaluation, observability, permissions, guardrails and human oversight.

The addition of real-world outcomes changes the picture again. Once an AI system takes action, the result of that action becomes new evidence. Production traces, user feedback, exceptions and business outcomes can flow back into evaluation. Evaluation can refine criteria, expose new failure categories, expand the golden set and guide improvements to prompts, context, tools, data, orchestration or models.

Data → Representation → Model → Context & Knowledge → Capabilities → Agentic → Evaluation, Observability & Control → Decisions & Actions → Outcomes → Continuous Improvement

This is why modern AI is no longer only about what a model can generate. It is about how intelligence is represented, grounded, extended, orchestrated, evaluated and connected to action — and how evidence from those actions is used to make the system better over time.

The model provides intelligence. The system around it makes that intelligence useful, controlled and trustworthy.

About the author

Amit is a digital, data and AI transformation leader with more than two decades of experience building analytics products, enterprise platforms and AI-enabled decision systems. AmitNotes is where he writes about Design Thinking, Decision Intelligence and Generative AI & Agentic AI.

Previous post
Next post

2 responses to “Modern AI Fundamentals: From Models to Agentic Systems”

  1. […] earlier blog post, Modern AI Fundamentals: From Models to Agentic Systems, introduced the broader AI building blocks. This blog post focuses on the engineering environment […]

  2. […] blog post is the third in a series. Modern AI Fundamentals explained what an agent is and where it sits among the layers of a modern AI system. Beyond the […]

Leave a Reply

Stay Connected

New ideas, frameworks and perspectives.

Occasional writing on Human-Centered AI, Decision Intelligence, enterprise technology and transformation.

No noise. Just new thinking when there is something worth sharing.