Skip to content

feat: llm tags for reasoning #40

@TobiasGleiter

Description

@TobiasGleiter

Summary

Add a ReActStep struct with llm tags and a typed ReActParser to the
agents/react package.

Changes

  • Add ReActStep struct with llm tags for reasoning, action, input and final answer
  • Add ReActParser as a typed instantiation of jsonout.NewParser[ReActStep]

Struct

type ReActStep struct {
Reasoning string json:"reasoning" llm:"reasoning,think"
Action string json:"action" llm:"action,required"
Input string json:"input" llm:"action_input,required"
Answer string json:"answer" llm:"final_answer,optional"
}

Depends On

  • jsonout must support the llm tag with think, required, and optional options

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions