Skip to content
Deep Agents

Task Automation Agent with Deep Agents

Build a task automation agent that creates, assigns, and tracks tasks across your project management workflow — using Deep Agents.

automationproject managementtasksworkflow

Working Code

Deep Agents
from deepagents import create_deep_agent
from langchain_core.tools import tool
@tool
def create_task(title: str, description: str, assignee: str = "") -> str:
"""Create a new task in the project."""
task_id = project.create_task(title=title, description=description, assignee=assignee)
return f"Task created: #{task_id} - {title}"
@tool
def list_tasks(status: str = "open") -> str:
"""List tasks filtered by status (open, in_progress, done)."""
tasks = project.list_tasks(status=status)
return "\n".join(f"#{t.id} [{t.status}] {t.title} -> {t.assignee}" for t in tasks)
@tool
def update_task(task_id: int, status: str) -> str:
"""Update task status."""
project.update_task(task_id, status=status)
return f"Task #{task_id} updated to {status}"
agent = create_deep_agent(
model="anthropic:claude-sonnet-4-5-20250929",
tools=[create_task, list_tasks, update_task],
system_prompt="You are a project management assistant. Help organize tasks: create new ones, track progress, and update statuses. Be proactive about suggesting task breakdowns.",
)
result = agent.invoke({
"messages": [("user", "Break down 'Launch new website' into subtasks and assign them to the team")]
})
print(result["messages"][-1].content)

Step by Step

1

Install dependencies

Install Deep Agents and the required tools for this use case.

2

Define your tools

Create the domain-specific tool functions your agent will use to interact with external services.

3

Create the agent and run

Initialize the Deep Agents agent with your tools, set the system prompt, and execute a query.

Ready to build with Deep Agents?

Generate a production-ready project with Deep Agents pre-configured — FastAPI + Next.js, auth, streaming, and more.

Get Started

Ready to build your first production AI agent?

Open-source tools, battle-tested patterns, zero boilerplate. Configure your stack and ship in minutes — not months.