Get to know the Microsoft AI Code model

Completed

Tip

See the Text and images tab for more details!

The MAI-Code model is specialized for software engineering. The full model name, such as MAI-Code-1.1-Flash identifies the family, version, and variant:

  • MAI-Code identifies a model trained and optimized for coding tasks.
  • A number such as 1.1 identifies a model version.
  • A suffix such as Flash identifies a variant optimized for fast, efficient operation.

Model names and available variants can change as the family evolves. In this module, MAI-Code model refers to the appropriate available model in the MAI-Code family.

Understand the capabilities

An MAI-Code model can support work throughout the software development lifecycle, including:

  • Exploring a repository and explaining existing code.
  • Turning requirements into an implementation plan.
  • Generating functions, components, tests, scripts, and configuration.
  • Modifying multiple files to implement a feature.
  • Diagnosing a defect and proposing a correction.
  • Refactoring code while preserving its intended behavior.
  • Interpreting a screenshot or design when the coding tool supports image input.
  • Using tools to search files, edit code, run commands, and respond to test results in an agentic workflow.

MAI-Code models can work with many common languages and ecosystems, including Python, C++, HTML, CSS, .NET, Java, JavaScript, and TypeScript. This breadth is useful for applications that combine frontend, backend, data, testing, and infrastructure code.

Use a coding model as a collaborator

A coding model can generate an entire implementation, but it doesn't replace engineering judgment. It doesn't automatically know the unwritten requirements of your project, and a plausible response isn't proof that the code is correct.

Use the model iteratively:

  1. Give it a well-defined objective and relevant project context.
  2. Ask it to inspect existing patterns before making changes.
  3. Review its plan and generated code.
  4. Run tests, linters, type checks, and security checks.
  5. Provide the results and ask it to correct any problems.

This cycle combines the speed of AI-assisted generation with human oversight and measurable validation.

Tip

Review the MAI-Code-1.1-Flash model card for detailed information about that model's capabilities, evaluation, limitations, and intended uses.