# How to Write an Agent

DevFeed: [How to Write an Agent](<https://devfeed.tech/articles/how-to-write-an-agent-41271.md>)

Original publisher: [Read original article](<https://www.evilsocket.net/2025/03/13/How-To-Write-An-Agent/>)

Author: Simone Margaritelli

Published: 2025-03-13T01:36:08Z

Content type: tutorial

Language: en

Sources: [evilsocket](<https://devfeed.tech/sources/evilsocket.md>)

Topics: [AI Development](<https://devfeed.tech/topics/ai-development.md>), [function calling](<https://devfeed.tech/topics/function-calling.md>), [LLMs](<https://devfeed.tech/topics/llms.md>)

Tags: [adk](<https://devfeed.tech/tags/adk.md>), [agent](<https://devfeed.tech/tags/agent.md>), [agent-development-kit](<https://devfeed.tech/tags/agent-development-kit.md>), [agent-evals](<https://devfeed.tech/tags/agent-evals.md>), [ai](<https://devfeed.tech/tags/ai.md>), [autonomous-agents](<https://devfeed.tech/tags/autonomous-agents.md>), [blog](<https://devfeed.tech/tags/blog.md>), [cybersecurity](<https://devfeed.tech/tags/cybersecurity.md>), [evals](<https://devfeed.tech/tags/evals.md>), [evaluations](<https://devfeed.tech/tags/evaluations.md>), [function-calling](<https://devfeed.tech/tags/function-calling.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [howto](<https://devfeed.tech/tags/howto.md>), [llm](<https://devfeed.tech/tags/llm.md>), [nerve](<https://devfeed.tech/tags/nerve.md>), [nerve-adk](<https://devfeed.tech/tags/nerve-adk.md>), [project-release](<https://devfeed.tech/tags/project-release.md>), [tool-use](<https://devfeed.tech/tags/tool-use.md>)

## AI overview

This tutorial explains how software agents use models to select tools in a loop, and how function calling lets language models invoke tools. It introduces Nerve as a project intended to simplify implementing an agent and discusses executing tool calls and returning their outputs to the model.

## Source excerpt

Hello friends. This blog post was supposed to be the second part of this re