Agents fail to call each other (and where to edit the system prompt)

In the log, I see GPT 4o-mini is trying to call other agents like this:

{“task”: {“description”: “Please review and enhance the content … and style enhancements.”, “type”: “str”}, “context”: {“description”: “This article outlines … and community growth.”, “type”: “str”}, “coworker”: “Content Quality Editor”}

Apparently, it is misguided by the stringified Pydantic schema and needs extra instructions on how to interpret it.

What is the standard way to fix the framework prompts? Is it to replace the system prompt per every agent? Or is it possible to supply it per project?


Additionally, the docs are cryptic. Here’s an example from there:

custom_agent = Agent(
    role="Customer Service Representative",
    goal="Assist customers with their inquiries",
    backstory="Experienced in customer support with a focus on satisfaction",
    system_template="""<|start_header_id|>system<|end_header_id|>
                        {{ .System }}<|eot_id|>""",
    prompt_template="""<|start_header_id|>user<|end_header_id|>
                        {{ .Prompt }}<|eot_id|>""",
    response_template="""<|start_header_id|>assistant<|end_header_id|>
                        {{ .Response }}<|eot_id|>""",
)
  • Which part of the template in this example is custom? Or is it a copy of a default value?
  • Where does the {{ .System }} value come from in vivo?
  • What happens to the <|xxx|> parts in vivo?
  • Where should I add my additional instructions - to the system_template string here or to the {{ .System }} value somewhere else?