5 Expanding GenAI capabilities with tools and agents
In this chapter
- Understand what agents are, how they reason, and how they behave.
- Learn how to equip agents with the right set of tools for expanding their capabilities.
- Design and build an app leveraging agents and tools in Langflow.
The seemingly magical text generation capacity of LLMs is impressive. But if you think about it... that’s all they do.
They take in text. They apply some reasoning to that text. They output text. That’s it.
Their action is confined within strings of text, and in many cases, that’s enough. For example, this would work if we want to build an app to summarize a document, translate a message, or answer questions based on a given knowledge base. For many applications, the LLM’s text-in, text-out behavior is sufficient. But in real-world applications, this is often inadequate.
A fully loaded GenAI application is usually supposed to do stuff, not just generate text. Said differently, we need actions, not just words.
Beyond Words: When GenAI Needs to Act
Let’s explore three sample cases.
Fetching live data
Sometimes we need a GenAI app to fetch live data to respond to a user query. When we prompt an LLM with a question like, “What’s the weather like in Rome right now?” we’re asking something that requires a live connection to reality. There’s no point in retrieving this from a static vector database full of pre-loaded facts. No PDF will contain this live information, which is inherently ephemeral.