Building and customizing solutions using Microsoft 365 Copilot APIs and tools
For Copilot Studio agents, CSV analysis is tied to file-processing behavior and code execution capabilities.
- Yes, CSV analysis can require Code interpreter for analytical tasks such as calculations, summarization based on structured data processing, table operations, forecasting, and chart generation. Code interpreter is the feature that generates and runs Python against structured files like CSV and Excel.
- With only File uploads enabled, users can upload supported files and the agent can use them in responses, but structured-data analysis is a separate capability documented under Code interpreter.
To improve the experience in Copilot Studio:
- In Copilot Studio > Settings > Generative AI, turn on File uploads.
- In the same area, turn on Code interpreter.
- Select Save.
- In the test pane, attach the CSV and submit a prompt that clearly asks for the analysis needed.
If the CSV is coming from SharePoint as a knowledge source:
- Add the SharePoint file as a knowledge source.
- Go to Settings > Generative AI and turn on Code interpreter.
- Under Search, select Turn on Work IQ.
- Select Save.
- Publish the agent.
Important limitations that affect the experience:
- Multiple uploaded files in one prompt aren’t supported for code interpreter.
- Asking questions about an uploaded file over multiple turns isn’t supported.
- The agent must use user authentication. For example, Direct Line with No authentication doesn’t work for code interpreter scenarios.
- If the agent is published to a SharePoint channel, users can’t upload files.
- In a customer managed key enabled environment, files can be uploaded but the agent doesn’t process them.
For troubleshooting slow or failing analysis:
- Verify Code interpreter is enabled.
- Verify the agent is configured to use user authentication.
- Check error logs in Copilot Studio or the associated Power Platform environment.
- If using SharePoint knowledge files, publish the agent after adding the file.
For file handling limits in Copilot Studio:
- CSV is a supported upload type.
- Individual file size limit is 15 MB.
- With code interpreter, there’s no character limit for the file-processing scenario described.