TaskWeaver (6,178 Stars) 2026: Microsoft's Code-First Agent Framework for Data Analysis

๐Ÿ“˜ Tutorials 2026-08-06 2 min read

TaskWeaver (6,178 stars) is Microsoft's code-first agent framework that turns natural language into Python for data analysis. Here is how to build your first analysis agent.

💡 What You Will Learn

TaskWeaver (6,178 stars) is Microsoft's code-first agent framework that turns natural language into Python for data analysis. Here is how to build your first analysis agent.

📜 Table of Contents

The short answer

microsoft/TaskWeaver (6,178 stars, Python) is a code-first agent framework from Microsoft. Instead of letting an LLM answer directly, TaskWeaver converts user requests into Python code, executes it in a sandbox, and returns the results - a design that makes it excellent for data analysis, plotting, and file processing tasks.

Why code-first agents win for data

Quick start

pip install taskweaver
# Generate the config and workspace
taskweaver --gen_project
cd project
# Edit taskweaver_config.json to add your OpenAI/other API key

Start the console and ask a data question:

taskweaver -p project
>>> Load sales.csv and show monthly revenue as a bar chart

TaskWeaver writes the Python, runs it, shows you the chart and the code.

Building custom plugins

Add a Python file in plugins/ with a documented function - TaskWeaver exposes it to the LLM automatically:

def compute_growth(series):
    """Compute month-over-month growth of a series."""
    return series.pct_change()

Practical tips

FAQ

Is it only for data analysis? It is optimized for it, but the code-first pattern works for any task expressible as code.

Which LLMs does it support? OpenAI, Azure OpenAI, and custom endpoints via configuration.

Is it free? Yes - MIT licensed open source.

❓ FAQ

Is it only for data analysis?

It is optimized for it, but the code-first pattern works for any task expressible as code.

Which LLMs does it support?

OpenAI, Azure OpenAI, and custom endpoints via configuration.

Is it free?

Yes - MIT licensed open source.

Related Articles
2026-07-19
Open WebUI Complete Guide: The Best Looking Local AI Chat Interface
2026-08-01
LangChain Agent Tools in 2026: Every Built-in Tool and How to Use It
2026-07-16
AI Agent User Feedback Loop 2026

Written by our editorial team; tools listed here are tested or verified against public sources. Links point to official sites or GitHub repos for reference only โ€” no paid placements.

๐Ÿ’ฌ Comments (0)

No comments yet. Be the first!

Login to comment