It’s hard to deny the sweeping impact LLMs have had on the technology world recently, so I’ve been playing around with it all in an effort to better understand what is and isn’t possible. One of the most interesting things have been agents.
The core idea of agents is to use an LLM to choose a sequence of actions to take. In chains, a sequence of actions is hardcoded (in code). In agents, a language model is used as a reasoning engine to determine which actions to take and in which order.
Tools are the functions that an agent calls. My idea was to create a couple of custom tools that would allow the agent to answer queries about data powered by the SBLive Connect API. I haven’t done much more than debug Python code since around 2014, so that’s a little rusty, but I ended up with something like:
From there, it’s really as simple as just plugging the right bits and pieces into setting up and running the agent. Once you’ve got it all hooked together, the results are seriously just neat as heck.