A 94.2% Score from a 180B Model You Have Never Heard Of

3 min read

According to a recent Dev.to article, a 180B model achieved a 94.2% accuracy score on a specific task. This caught my attention, and I decided to investigate further.

The idea of giving AI agents the freedom to choose their own tools is an interesting one. By allowing agents to select their own tools, we can create more flexible and adaptable systems. For example, a model might choose to use a combination of a large language model and a rule-based system to generate product descriptions.

So, how do we give AI agents the ability to choose their own tools? The answer lies in the concept of "tool choice" or "tool selection". This is a process where the AI agent is given the ability to select from a range of tools or algorithms to complete a task. For instance, if the task is to generate a product description, the agent might choose to use a large language model to generate the description, or a rule-based system to ensure that the description is accurate and consistent.

One way to implement tool choice is by using a simple algorithm that selects a tool randomly from a list of available tools. Here's an example of how this can be implemented using Python:

python
import random

def tool_choice():
    tools = ["Tool A", "Tool B", "Tool C"]
    return random.choice(tools)

In this example, the tool_choice function returns a random tool from the list of available tools.

But how do we check the answers against the source? This is an important step in ensuring that the AI agent is providing accurate results. One way to do this is to use a "ground truth" dataset, which is a dataset that contains the correct answers for a particular task. A ground truth dataset is like a gold standard for AI agents - it's a benchmark against which we can measure the accuracy of the agent's responses.

Here's an example of how this can be implemented using Python:

python
import pandas as pd

def check_answers(answers, ground_truth):
    df = pd.read_csv(ground_truth)
    for i, answer in enumerate(answers):
        if answer == df.iloc[i]:
            print("Answer {} is correct".format(i))
        else:
            print("Answer {} is incorrect".format(i))

In this example, the check_answers function takes in the answers provided by the AI agent and the ground truth dataset. It then compares the answers to the ground truth and prints out whether each answer is correct or incorrect.

Try this

To try out the concept of giving AI agents the ability to choose their own tools, you can use the following code:

bash
pip install random

This will install the random library, which is used to select the tool randomly.

To check the answers against the source, you can use the following code:

bash
pip install pandas

This will install the pandas library, which is used to load and manipulate the ground truth dataset.

Sources

  • "Give Tool Choice to a Small Router, and Check Answers Against the Source" by aahyouoos on Dev.to
  • "Tool Choice" by Wikipedia
  • "Ground Truth Dataset" by Wikipedia