AgentKit enables developers to compose simple single-agent systems or entire
*systems of agents* in which multiple agents can work together.
**[Agents](/concepts/agents)** are combined into
**[Networks](concepts/networks)** which include a
**[Router](concepts/routers)** to determine which Agent should be called.
Their system's memory is recorded as Network **[State](concepts/state)** which
can be used by the Router, Agents or **[Tools](concepts/tools)** to
collaborate on tasks.

The entire system is orchestration-aware and allows for customization at runtime for dynamic, powerful AI workflows and agentic systems. Here is what a simple Network looks like in code:
```ts
import {
createNetwork,
createAgent,
openai,
anthropic,
} from "@inngest/agent-kit";
import { searchWebTool } from "./tools";
const navigator = createAgent({
name: "Navigator",
system: "You are a navigator...",
tools: [searchWebTool],
});
const classifier = createAgent({
name: "Classifier",
system: "You are a classifier...",
model: openai("gpt-3.5-turbo"),
});
const summarizer = createAgent({
model: anthropic("claude-3-5-haiku-latest"),
name: "Summarizer",
system: "You are a summarizer...",
});
const network = createNetwork({
agents: [navigator, classifier, summarizer],
defaultModel: openai({ model: "gpt-4o" }),
});
const input = `Classify then summarize the latest 10 blog posts
on https://www.deeplearning.ai/blog/`;
const result = await network.run(input, ({ network }) => {
return defaultRoutingAgent;
});
```
## `llms.txt`
You can access the entire AgentKit docs in markdown format at [agentkit.inngest.com/llms-full.txt](https://agentkit.inngest.com/llms-full.txt). This is useful for passing the entire docs to an LLM, AI-enabled IDE, or similar tool to answer questions about AgentKit.
If your context window is too small to pass the entire docs, you can use the shorter [agentkit.inngest.com/llms.txt](https://agentkit.inngest.com/llms.txt) file which offers a table of contents for LLMs or other developer tools to index the docs more easily.
# createAgent
Source: https://agentkit.inngest.com/reference/create-agent
Define an agent
Agents are defined using the `createAgent` function.
```ts
import { createAgent, agenticOpenai as openai } from '@inngest/agent-kit';
const agent = createAgent({
name: 'Code writer',
system:
'You are an expert TypeScript programmer. Given a set of asks, you think step-by-step to plan clean, ' +
'idiomatic TypeScript code, with comments and tests as necessary.' +
'Do not respond with anything else other than the following XML tags:' +
'- If you would like to write code, add all code within the following tags (replace $filename and $contents appropriately):' +
"