Skip to content
ai agents

Microsoft's New Fix for Broken AI

AI agents are brilliant at code but terrible at visuals, leading to broken charts and wasted tokens. A new Microsoft project reveals the problem isn't the model's intelligence, but the language we're forcing it to speak.

Sol Aguirre
Microsoft's New Fix for Broken AI

The Geometry Problem AI Can't Solve

Large Language Models (LLMs) often stumble where precision matters most. Agents can orchestrate complex backend systems, yet struggle with a seemingly simple request: generating a single data visualization. The common failure mode involves an LLM producing hundreds of lines of Vega-Lite code for a waterfall chart, only for it to render a blank page or a broken, unusable graphic.

This common breakdown highlights a fundamental dichotomy: meaning versus geometry. LLMs excel at semantic understanding, recognizing "this column is month" or "that one's revenue." They grasp the what of the data. However, they consistently falter with the precise geometric decisions required for a functional chart, like setting axis step sizes, defining scale domains, or configuring label spacing and color ramps.

For user-facing products, this isn't a minor glitch; it's a critical flaw. Microsoft's own analytics agent, for example, achieved only an 80% success rate for well-rendered charts. While 80% might sound acceptable in some contexts, for end-users, a one-in-five failure rate erodes trust and necessitates constant manual intervention. This unacceptable success rate makes the problem a business-critical challenge for AI adoption.

How Flint Splits the Job

Flint rearchitects chart generation, splitting the problem into two distinct jobs. First, the LLM constructs a compact, ~10-line semantic spec, focusing solely on meaning. It leverages Flint's library of over 70 semantic types—like 'quarter', 'price', or 'percentageChange'—to describe data attributes, not visual layout.

Second, a deterministic compiler takes this semantic spec and assumes full responsibility for all geometric decisions. This layer precisely dictates elements such as axis step sizes, scale domains, and label spacing, outputting a complete and correct specification for Vega-Lite, ECharts, or Chart.js. The LLM handles meaning; the compiler handles the math.

Witnessing the system in action reveals its elegance. Changing a single word in the semantic spec—for example, switching a column tag from 'quantity' to 'percentageChange'—instantly triggers a cascade of intelligent design choices. The compiler automatically selects a diverging color palette, re-formats numerical values, and rescales the axis, ensuring a visually appropriate and accurate chart without further LLM intervention.

The Real Blueprint for Future Agents

Flint transcends being merely a new charting language. It acts as a profound case study for a powerful, emerging pattern crucial for building reliable agentic systems. This architecture prioritizes validation and predictability, moving beyond the inherent fragility of monolithic AI generation. It’s a blueprint for how AI can consistently deliver rather than merely suggest.

At its core, the pattern is elegantly simple yet profoundly impactful: an LLM generates a small, validatable Intermediate Representation (IR). This concise IR, often a mere 10 lines of JSON describing semantic meaning, then feeds into a Deterministic Execution Layer. This layer, entirely separate from the LLM, handles all geometric decisions and precise rendering, effectively insulating the final output from model hallucinations.

This separation of concerns offers a critical advantage in reliability. One can easily validate 10 lines of Flint's JSON IR, checking its adherence to specific semantic types (e.g., 'quarter', 'price'). Such a quick, programmatic check ensures the LLM's intent is correctly captured before any rendering occurs. This contrasts sharply with the near-impossible task of reliably validating 100+ lines of raw, generated D3 or Vega-Lite code, where a single misplaced bracket can break the entire visualization.

This architecture — LLM for intent, deterministic system for execution — represents a significant evolution in AI tooling. It's the pragmatic path to agents we can trust, not just marvel at. For deeper insights into this design philosophy, explore the Flint: A visualization language for the AI era - Microsoft Research Blog. This approach promises to unlock far more robust and verifiable AI applications across diverse domains.

Enjoying this? Get one like it in your inbox each morning.

one email a day · unsubscribe in two clicks · no third-party tracking

Reality Check: Promises vs. Production

Flint remains an early research project, currently at v0.2 with known bugs where specs render inconsistently across backends. It lacks a Python package for eager developers and is missing critical features:

  • maps
  • 3D
  • network graphs
  • layering

Accessibility, a fundamental concern, is an empty GitHub issue.

Power users leveraging frontier models can often one-shot simple charts, making Flint seem redundant for their needs. Its true value emerges with smaller, cheaper models, or when tackling complex charts like waterfalls and sunbursts. For products requiring 99%+ reliability, where 80% success isn't enough for end-users, Flint's deterministic approach is indispensable.

Despite its nascent stage, Flint shows significant momentum. Over 5,000 weekly NPM downloads underscore developer interest. Crucially, it already powers Microsoft's internal Data Formulator tool, signaling strong internal backing and validation. This project exemplifies the emerging pattern in agents: LLMs generate a small, validatable intermediate representation, then a deterministic layer handles the complex, precise execution.

Frequently Asked Questions

What is Microsoft Flint?

Flint is a new charting language where an AI agent defines the 'meaning' of data in a simple spec, and a deterministic compiler handles the complex 'geometry' to reliably generate charts for backends like Vega-Lite or ECharts.

How is Flint different from Vega-Lite?

Flint isn't a replacement for Vega-Lite; it compiles to it. It acts as a higher-level abstraction that allows an LLM to describe 'what' the data is, while the Flint compiler handles the verbose geometric code that LLMs often get wrong.

What is the main advantage of Flint's approach?

Its main advantage is reliability. By separating meaning from geometry and using a small, validatable spec, it dramatically increases the success rate of AI-generated charts, aiming to solve the problem where 1 in 5 charts generated directly by LLMs are broken.

Is Flint ready for production use?

Flint is an early-stage (v0.2) research project. While it powers Microsoft's Data Formulator tool, it currently lacks a Python package and advanced features like maps or 3D graphs, making it best for specific use cases where chart reliability is critical.

Found this useful? Share it.

For builders

Want Stork to write one of these about your product?

Send us a URL. We use the product, form a view, and publish what we actually think — in 8 languages, labeled Sponsored, with no copy approval on your side. That last part is what makes it worth quoting.

See how it works$500 · AI tools & software only