#There is the messages array being sent
1 messages · Page 1 of 1 (latest)
this looks correct. It is calling a function and you're responding with the result and you're giving it the result with the right tool id
{
"role": "tool",
"name": "writefile", // This is extra
"tool_call_id": "call_xyz...",
"content": "result string"
}
the "name" field is extra
also try setting parallel_tool_calls to false
okay I'll try without "name". I'll think about parallel tools...
I would also just clarify to the model when it should be calling those functions. Your actual code isn't wrong, but the model is calling write file again., so it's probably just confused. Ask it why it called it again, and in the response from writefile say "Content successfully written to {}"
I use: "content": ""Content written to file './page-01.json'""
let me get the name out
I would also give an example of the steps and ideal workflow
Without name still does the same...
I think I'll try to add a next step after writting file, maybe that will break it out of loop
added " - only write json file once " to rules... go no...
Okay, got it.....
Added:
**IMPORTANT**
After writting json file, Tell user that JSON was written!!!
To end of system prompt....
that got it...
Meaning it is definitely an o1 training error?
<cudo point>100</cudo points>
Been working on this for many hours, and I forgot to use Prompt programming and not Procedural programming... AGAIN
Is it good now?