# Building AI Agents with Sofuu and Kaze

Sofuu is an open-source runtime for AI agents and applications. One of its goals is to give developers a way to define agent routines, work with tools and memory, and package those routines for execution.

In this post, I’ll show a small example using **Kaze**, Sofuu’s agent language.

## An agent is more than a prompt

An AI agent may need to work through several steps: interpret a task, use a tool, retain useful information, and produce a result.

Sofuu brings together capabilities for these kinds of workflows, including model integrations, tools, MCP, and local memory. Kaze provides a way to describe routines and declare the capabilities they use.

## A small Kaze example

Create a file named `agent.kaze`:

```kaze
needs: ai, tool, memory, log

action main():
    let plan = ai.prompt("Plan a response for this task.")
    let result = tool.call("search", "Sofuu AI agents")
    remember result as "search_result"
    log.info(plan)
    return result
```

The `needs` line declares the capabilities used by the routine. The routine then requests an AI response, calls a tool, records the tool result, and logs the plan.

## Run it in simulation

Check the file and run it with simulated AI and tool capabilities:

```bash
sofuu script check agent.kaze
sofuu script run agent.kaze --cap ai=sim --cap tool=sim
```

Sofuu prints a trace of the actions performed by the routine.

**This example uses simulated responses.** It does not call a real model or perform a real search. It is a way to explore the routine and its trace before connecting real services.

## Compile the routine

Sofuu can also package the Kaze file into an executable:

```bash
sofuu compile agent.kaze -o my-agent
./my-agent
```

In the configuration used for this example, the compiled routine also uses simulated responses. A real agent workflow requires a supported model and tool backend to be configured for the execution path being used.

## Where Sofuu is today

Sofuu is in beta. Its broader agent capabilities include model integrations, MCP, tools, and memory, while the built-in local inference engine remains experimental.

My focus is on making the experience of building AI agents more reliable and understandable: clear capability boundaries, useful traces, and better explanations when something goes wrong.

You can explore the project here:

- [Sofuu website](https://sofuu.xyz)
- [Sofuu on GitHub](https://github.com/sofuu-runtime/sofuu)

I’d welcome feedback on the agent experience and the kinds of workflows you would like to build.
