# 3. Strategy

The **Strategy** section defines how an AI agent approaches problem-solving. &#x20;

You can think of it as the agent's **way of working** — how it breaks down a task, reasons through the steps, chooses when to use tools, and how to react when something fails or when it encounters unexpected situations.

### **Currently Available Strategies**

#### **1. Basic Strategy**

This is the simplest mode of operation. It answers user prompts or runs tools as instructed — with no breakdown, and no internal reasoning.&#x20;

**Example:**\
\
Agent with skill `get_fear_and_greed_latest`:\
User asks, _“What’s today’s crypto fear and greed index?”_ → The agent directly calls the tool and answers: _“The current Fear and Greed Index is 39 (Fear).”_

This strategy is ideal for **lightweight tasks** like fetching current prices, generating images, or reading weather data. The benefit of this strategy is that it is **faster** compared to other two strategies.&#x20;

#### **2. ReAct Strategy**

ReAct stands for **Reasoning + Acting**.&#x20;

Instead of jumping straight to an answer or tool, the agent _**thinks first.**_&#x20;

In other words, it decides: "Do I need to use a skill? If yes, which one? Or should I answer directly instead?"

It works through a structured loop:

* **Thought:** “I need to do answer users query by...”
* **Action:** If required, the agent invokes a skill.
* **Observation:** Tool output is analyzed.
* **Answer:** The final response is generated.

**Example:**

Agent with 3 skills: `convert_price`, `get_cryptocurrency_info`, `get_cryptocurrency_quotes_latest`.

User: _“How much is 1 BTC in ETH, and what is BTC’s market cap today?”_

The ReAct agent breaks it down:

* **Thought:** “I need to get both the current price of BTC and convert it to ETH.”
* **Action:** `get_cryptocurrency_quotes_latest` with symbol = BTC
* **Observation:** Output includes price and market cap
* **Action:** `convert_price` from BTC to ETH
* **Observation:** BTC = 15.2 ETH
* **Thought:** Now I can generate final response.
* **Answer:** _“1 BTC is approximately 15.2 ETH. The current market cap of BTC is $925B.”_

This strategy is useful when the task involves deciding _whether_ to use a tool, and _which_ one to choose.

**3. Conversational ReAct**

In this, the system interleaves dialogue (conversation) with reasoning and decision-making steps.&#x20;

Instead of producing a final answer all at once, the agent explains its thought process step by step, asks clarification questions if needed, and uses skills to gather more information.

For example, if a user asks a complex query, the agent may first break it down, reason through sub-parts, and perform actions like web searches or code execution mid-conversation before arriving at a final answer.&#x20;

The goal of this strategy is to mimic how a thoughtful human would tackle a problem: by thinking out loud, asking questions when needed, and using tools to assist with incomplete knowledge or data retrieval.

#### **4. Planning Strategy**

The Planning Strategy is the most advanced one, involving a three-model system that breaks down complex tasks into sequential subtasks, reasons through each one, and dynamically adapts if a tool fails or an output is unclear.

This makes it suitable for users who expect more than basic answers — they want agents that can actually think, adapt, and execute with accuracy.

This strategy is powered by GPT-o3-mini-high.

It uses **multiple models** to handle different roles:

* LLM 1: Breaks the goal into subtasks (like a project manager)
* LLM 2: Executes each subtask using tools (like a problem-solver)
* LLM 3: Writes the final answer for the user&#x20;

#### **How Planning Strategy Works?**&#x20;

<figure><img src="https://3620906879-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft1TLw2CAY3Yjr54moPYE%2Fuploads%2FeuJFLMG6Q0QBKJvEbSwA%2FPlanning_Strategy_Diagram.png?alt=media&#x26;token=b27cbed6-13fc-4b01-894b-c90ca2399e90" alt=""><figcaption><p>Planning Strategy</p></figcaption></figure>

→ **Step 1:** User Query

User start by asking the AI a question or giving it a task.

→ **Step 2:** Plan Generation

The first AI model (LLM 1) creates a plan by breaking your query into multiple smaller tasks.

→ **Step 3:** Sub-Tasks

LLM 2 picks up each sub-task and decides:

* What tool to use (e.g., web search, calculator, database, etc.)
* How to use it

This part runs in a loop, where it tries tools, checks results, and repeats if needed.

Soon, this layer will be powered by **our own fine-tuned GPT-4o Mini** — a model specifically trained for advanced tool usage. It has already outperformed the base GPT-4o in internal benchmarks, with faster execution, better context retention, and higher accuracy when handling tool-based tasks.

<figure><img src="https://3620906879-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft1TLw2CAY3Yjr54moPYE%2Fuploads%2FbGdlsB4s56yBOf8kxHOn%2FPerformance_Comparison.png?alt=media&#x26;token=ac2b6a32-cafc-4abc-9d43-c913024afef4" alt=""><figcaption><p>Performace Comparison between GPT-4o vs our Fine-tuned GPT-4o-mini</p></figcaption></figure>

→ **Step 4:** Output Evaluation

Now the system checks: Was the tool's result good enough?

If yes → the sub-task is marked complete.\
If no → it decides what to do next:

→ **Step 5:** What If the Tool Output Fails?

There are 3 options:

1. Try Another Tool – If another tool is available, use it.
2. Retry or Refine – Try again with the same tool but improve the input.
3. Change the Plan – If nothing works, go back and update the task or plan using either:

* LLM 2 (refine sub-task)
* LLM 1 (completely re-plan)

→ **Step 6:** Repeat

This loop continues until every small task is successfully completed.

→ **Step 7:**  Final Output

Once all sub-tasks are done, LLM 3 combines all the results and creates a final, polished answer for the user.

**Why Planning is Different?**\
\
Unlike ReAct, which handles a few tools linearly, Planning Strategy:

* Breaks a big query into smaller, manageable subtasks
* Dynamically picks the right tools for each
* Checks every tool output to ensure it's correct
* If anything fails or looks wrong, it **retries or replans**
* Merges all results into one clean, context-aware response

In nuthsell, the Planning Strategy runs a built-in feedback loop. After every tool execution, the system checks: _Is this result correct? Is it complete? Does it move the task forward?_ If not, it loops back — either re-executing the tool with new input or calling the Planner to rework the strategy.&#x20;

This makes the system highly self-correcting and capable of handling real-world complexity without getting stuck or silently failing.

### 💡Difference between Skills and Strategy

Skills and Strategy are two separate but connected parts of how an AI agent functions.&#x20;

Skills are the tools that let the agent perform specific actions — like converting crypto prices, scraping websites, or checking the stock market. For example, the `convert_price` skill allows an agent to convert the value of 1 Bitcoin to USD or ETH.&#x20;

But just having this skill doesn’t mean the agent knows when or how to use it — that’s where strategy comes in.

Strategy controls the thinking process. It tells the agent how to break down a task, whether or not to use a skill, which skill to choose, and what to do with the result.&#x20;

So, **if skills are what the agent can&#x20;**_**do**_**, then strategy is how the agent&#x20;**_**decides**_**&#x20;what to do.**

Let’s take an example. Suppose a user asks:\
&#xNAN;_"Tell me how much 1 BTC is worth in ETH, and give me the top 3 gainers in the stock market today."_

The **skills** needed here might include `convert_price` and `get_current_gainer_stocks`.\
The **strategy** will determine how the agent handles this. It will:

1. Understand that the user’s request involves two different tasks.
2. Use the `convert_price` skill to convert BTC to ETH.
3. Then use `get_current_gainer_stocks` to fetch stock gainers.
4. Finally, combine the results into one complete answer.

Without strategy, the agent wouldn't know how to split the request, run each tool in the right order, or merge the answers meaningfully. **Skills do the execution. Strategy decides the steps**. Both are necessary — but they play very different roles.
