Gofer - Your Friendly AI Search Agent
Building your own AI search agent is easy
Want to interact with LLMs (Large Language Models) but perplexed on how to go about it and where to find good ones? You can of course interact with LLMs via search engines, but what if you want to build your own interaction agent? I got you covered in this article.
Nothing is as convenient as having a good LLM provider and a good AI agent to have your conversations. With the power of Tkinter, Openrouter, PydanticAI and YAML, you can create a simple, yet elegant AI agent. Here comes Gofer - your friendly AI agent that makes use of all of them.
LLMs don’t come free out of the box, they come on a subscription, but you do get some free ones. Openrouter is a platform that provides an interface to interact with multiple LLMs and it gives you access to some free LLMs as well. You can prompt a decent number of prompts for a day till you reach a limit.
Tkinter is Python’s standard GUI toolkit. It is a simple yet versatile interface for creating your minimalistic GUIs. PydanticAI and its dependencies are also used to create Openrouter LLM agents.
Getting started
First, you have to get started with an Openrouter account. Generate an Openrouter API key after you login. This key helps in your interaction with LLMs. After that, download the main program and the YAML file. Make sure that you have the required dependencies installed and then proceed with running your program.
What do you get out of Gofer?
With Gofer you get a no-frills LLM interface. It is a simple and appealing interface that helps you do the main interactions through a few button clicks rather than writing lengthy programs.
Error handling
You might sometimes encounter a message saying ‘No endpoints found that support model usage’. This might mean that the model is no longer supported. Try finding a new free LLM model from the Openrouter website as a substitute by mentioning and calling it from the YAML file.
Hacking suggestions
You can use this as a ‘starter’ program to build a more sophisticated interaction agent. You could give it a REST interface.
Conclusion
We generally run after proprietary models thinking they are more capable.
This leaves some of the potential of the free models untapped. Thanks to Gofer
and Openrouter – free model usage seems to be more approachable.
Gofer shows you how.