Skip to content

Run code with the code interpreter

Have Python run server-side and get the output plus generated files back — for example, to compute, analyze data, or generate a plot. You need this when the answer requires actual execution, not just generation.

  1. Describe the task in plain language:

    Plot sin(x) over one period and give me the PNG.

    mistral_code_interpreter takes a prompt — what to compute, analyze or generate; the code itself is written server-side.

  2. Read the result — the executed code, captured output and generated files arrive as download links.

See Tools · Configuration keys