Agents#
Overview#
An agent is the quickest way to get started with Gen AI Builder. Agents take in Tools and run(prompt_input)
directly, which the agent uses to add a Prompt Task .
You can access the final output of the Agent by using the Structured Output attribute.
Agent Tools#
from griptape.structures import Agent
from griptape.tools import CalculatorTool
agent = Agent(input="Calculate the following: {{ args[0] }}", tools=[CalculatorTool()])
agent.run("whats 13^7?")
print("Answer:", agent.output)
Agent Input#
from griptape.structures import Agent
agent = Agent(
input="Write me a {{ args[0] }} about {{ args[1] }} and {{ args[2] }}",
)
agent.run("Haiku", "Skateboards", "Programming")
- Configs
- Conversation Memory
- Observability
- Pipelines
- Rulesets
- Task Memory and Off Prompt
- Tasks
- Workflows