top | item 45842892 (no title) spenczar5 | 3 months ago Its JSON schema, well standardized, and predates LLMs: https://json-schema.org/ discuss order hn newest zahlman|3 months ago Ah, so I can specify how I want it to describe the tool request? And it's been trained to just accommodate that? simonw|3 months ago Most LLMs have tool patterns trained into them now, which are then managed for you by the API that the developers run on top of the models.But... you don't have to use that at all. You can use pure prompting with ANY good LLM to get your own custom version of tool calling: Any time you want to run a calculation, reply with: {{CALCULATOR: 3 + 5 + 6}} Then STOP. I will reply with the result. Before LLMs had tool calling we called this the ReAct pattern - I wrote up an example of implementing that in March 2023 here: https://til.simonwillison.net/llms/python-react-pattern
zahlman|3 months ago Ah, so I can specify how I want it to describe the tool request? And it's been trained to just accommodate that? simonw|3 months ago Most LLMs have tool patterns trained into them now, which are then managed for you by the API that the developers run on top of the models.But... you don't have to use that at all. You can use pure prompting with ANY good LLM to get your own custom version of tool calling: Any time you want to run a calculation, reply with: {{CALCULATOR: 3 + 5 + 6}} Then STOP. I will reply with the result. Before LLMs had tool calling we called this the ReAct pattern - I wrote up an example of implementing that in March 2023 here: https://til.simonwillison.net/llms/python-react-pattern
simonw|3 months ago Most LLMs have tool patterns trained into them now, which are then managed for you by the API that the developers run on top of the models.But... you don't have to use that at all. You can use pure prompting with ANY good LLM to get your own custom version of tool calling: Any time you want to run a calculation, reply with: {{CALCULATOR: 3 + 5 + 6}} Then STOP. I will reply with the result. Before LLMs had tool calling we called this the ReAct pattern - I wrote up an example of implementing that in March 2023 here: https://til.simonwillison.net/llms/python-react-pattern
zahlman|3 months ago
simonw|3 months ago
But... you don't have to use that at all. You can use pure prompting with ANY good LLM to get your own custom version of tool calling:
Before LLMs had tool calling we called this the ReAct pattern - I wrote up an example of implementing that in March 2023 here: https://til.simonwillison.net/llms/python-react-pattern