1 Exploring DeepSeek R1's Agentic Capabilities Through Code Actions
katrinaspargo edited this page 1 year ago


I ran a fast experiment examining how DeepSeek-R1 carries out on agentic tasks, regardless of not supporting tool use natively, and I was rather amazed by initial results. This experiment runs DeepSeek-R1 in a single-agent setup, where the model not only prepares the actions however likewise formulates the actions as executable Python code. On a subset1 of the GAIA recognition split, DeepSeek-R1 surpasses Claude 3.5 Sonnet by 12.5% absolute, from 53.1% to 65.6% appropriate, and other designs by an even bigger margin:

The experiment followed design use standards from the DeepSeek-R1 paper and the model card: Don't use few-shot examples, prevent adding a system timely, and wiki.vst.hs-furtwangen.de set the temperature to 0.5 - 0.7 (0.6 was utilized). You can discover more examination details here.

Approach

DeepSeek-R1's strong coding abilities allow it to act as a representative without being clearly trained for tool usage. By enabling the design to produce actions as Python code, it can flexibly interact with environments through code execution.

Tools are executed as Python code that is included straight in the timely. This can be a simple function definition or a module of a bigger plan - any legitimate Python code. The model then produces code actions that call these tools.

Arise from executing these actions feed back to the model as follow-up messages, complexityzoo.net driving the next actions till a final answer is reached. The representative structure is a simple iterative coding loop that moderates the conversation between the design and its environment.

Conversations

DeepSeek-R1 is used as chat design in my experiment, where the design autonomously pulls extra context from its environment by utilizing tools e.g. by utilizing a search engine or lespoetesbizarres.free.fr bring data from websites. This drives the conversation with the environment that continues up until a last response is reached.

In contrast, o1 designs are understood to carry out badly when utilized as chat models i.e. they do not try to pull context throughout a discussion. According to the connected post, o1 designs carry out best when they have the complete context available, engel-und-waisen.de with clear guidelines on what to do with it.

Initially, I likewise tried a full context in a single timely method at each step (with arise from previous steps included), but this caused substantially lower ratings on the GAIA subset. to the conversational approach explained above, I had the ability to reach the reported 65.6% performance.

This raises a fascinating concern about the claim that o1 isn't a chat model - perhaps this observation was more pertinent to older o1 designs that did not have tool use capabilities? After all, isn't tool usage support an important system for making it possible for photorum.eclat-mauve.fr designs to pull additional context from their environment? This conversational technique certainly seems effective for qoocle.com DeepSeek-R1, though I still require to conduct comparable try outs o1 models.

Generalization

Although DeepSeek-R1 was mainly trained with RL on mathematics and coding tasks, it is exceptional that generalization to agentic tasks with tool usage via code actions works so well. This capability to generalize to agentic jobs reminds of current research by DeepMind that reveals that RL generalizes whereas SFT remembers, although generalization to tool usage wasn't investigated because work.

Despite its capability to generalize to tool usage, DeepSeek-R1 frequently produces really long reasoning traces at each action, compared to other designs in my experiments, restricting the effectiveness of this model in a single-agent setup. Even easier jobs sometimes take a very long time to complete. Further RL on agentic tool use, be it via code actions or not, could be one option to improve efficiency.

Underthinking

I also observed the underthinking phenomon with DeepSeek-R1. This is when a thinking model regularly changes in between different thinking ideas without sufficiently exploring appealing courses to reach an appropriate service. This was a major factor for overly long thinking traces produced by DeepSeek-R1. This can be seen in the recorded traces that are available for download.

Future experiments

Another common application of thinking models is to utilize them for preparing just, while utilizing other models for creating code actions. This could be a prospective brand-new function of freeact, if this separation of functions proves helpful for more complex jobs.

I'm likewise curious about how reasoning designs that currently support tool usage (like o1, o3, ...) perform in a single-agent setup, with and championsleage.review without generating code actions. Recent developments like OpenAI's Deep Research or Hugging Face's open-source Deep Research, which likewise utilizes code actions, look fascinating.