We know about the human learning process and reasoning capabilities for making decisions and completing tasks, but what does LLM training look like?

Can I say?

  1. Firstly, pre-training of LLM: In this step, you help the model learn patterns, such as grammar, sentence structure, and even relationships between words and concepts.
  2. Instruction-tuning (or Fine-Tuning): To fine-tune the model, a curated dataset containing examples of instructions and desired responses is used.
  3. Reinforcement Learning with Human Feedback (RLHF): Human evaluators rank model responses, which is used further to improve the model’s alignment with user expectations.

That makes sense, right? But what if we build an agentic workflow to make the model learn and give the output while doing all the checks independently? It would be like having your own assistant who can do all the work without any human intervention. Further, in this article we will talk about the 4 Agentic AI Design Patterns for Architecting AI Systems.

image.png

Overview

What is Agentic Design Patterns?

The agentic design pattern is introduced as a solution for making LLMs more autonomous. Instead of just giving the model one prompt and expecting a final answer (like writing an essay in one go), an agent-like approach involves prompting the LLM multiple times, step by step. Each step refines the task, with the model improving its output iteratively.

To understand this better, let’s look at it like this:

When we prompt an LLM in zero-shot mode, it’s like asking someone to write a story in one go without revising. LLMs do well at this, but they can do even better. By using an agent-like workflow, we can prompt the LLM multiple times in steps. Each step builds on the previous one, refining the response. Think of it like asking the LLM to go over the essay multiple times, improving it with each pass.

By each step, I meant:

Let’s take the example of writing a code using Agentic workflow:

  1. Plan an outline for the code: Break down the task into smaller modules or functions.
  2. Gather information and content: Research libraries, algorithms, or existing solutions. Do web searches or check the documentation if needed.
  3. Write the first draft of the code: Implement the basic functionality, focusing on structure over perfection.