An AI workspace in CodeFusion Studio is a fully configured development project built around a specific AI model and target device. Unlike a standard workspace created from a code template, an AI workspace automatically integrates your model file, runs a compatibility check against the chosen SoC and core, generates the initial inference C/C++ source files, and opens the AI Hardware Profiling view ready for deployment. This workflow is optimized for ML engineers who want to move from a trained model to a running embedded application with minimal embedded systems knowledge required.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/analogdevicesinc/codefusion-studio/llms.txt
Use this file to discover all available pages before exploring further.
What gets created
When you create a workspace from an AI model, CodeFusion Studio produces a complete project structure that includes:- A
.cfsconfigfile recording the model configuration (backend, target SoC, core, and extension properties) - Generated C/C++ source and header files for the inference runtime
- A
.cfs/ai.cfsaiproffile that opens the AI Hardware Profiling view - An application source file that loads the model, runs inferences (using provided sample data or random input), and emits Zephelin profiling trace data over UART
(sizeof(dataset) / sizeof(model_input)) iterations if sample data is provided, or 10 inferences on random input data if no sample data is given.
Create a workspace from the GUI
Open the Workspace Creation Wizard
Click the CodeFusion Studio icon in the VS Code activity bar to open the CFS Home Page, then click New Workspace from AI model.
Configure the Files section
In the Files section, provide the following:
- Model File (required): Click Browse and select your trained model file. For example,
hello_world_f32.tflite. Supported formats include.tflitefor TFLM and.pth.tarfor MAX78002 PyTorch CNN models. - Sample Data (optional): Click Browse to select a binary input dataset file (
.bin). Example data files are available in thecfs-ai/examples/directory of the CodeFusion Studio repository — for example, usehello_world_f32.binwithhello_world_f32.tflite. - Workspace Name (optional): Enter a custom name, or leave blank to auto-generate a name based on the SoC and package selection (for example,
MAX32690-TQFN).
Select a target SoC
In the SoCs section, use the search box to filter available devices and select the SoC that matches your hardware — for example, MAX32690, MAX78002, or an ADSP-SC5xx part. Compatibility checking runs automatically when you select a model file. Compatible SoCs display a Compatible badge.
Only SoCs with AI profiling support appear in this list. The catalog is filtered automatically to show compatible hardware.
Select a board
After selecting an SoC, choose your specific development board from the Board dropdown.
Select target cores
In the Cores section, enable the Run model on core toggle for each processor core you want to target. Supported cores show the toggle; unsupported cores display an Unsupported badge and cannot be selected.
Wizard field reference
| Field | Required | Description |
|---|---|---|
| Model File | Yes | The AI model to deploy. Supported formats include .tflite (TFLM) and .pth.tar (PyTorch/izer). |
| Sample Data | No | Binary input dataset file (.bin) matching the model’s input format. Example files are in cfs-ai/examples/. |
| Workspace Name | No | Custom workspace directory name. If omitted, auto-generates as {SoC}-{Package} (e.g. MAX32690-TQFN). |
| SoC | Yes | Target microcontroller. Only SoCs with AI plugin support are shown. |
| Board | Yes | Specific development board variant. Options depend on the selected SoC. |
| Run model on core | No | Toggle to target a specific processor core for model deployment. |
Create a workspace from the CLI
Usecfsutil ai workspace create to generate a complete AI workspace from the terminal. This command runs a compatibility check, creates the project structure, integrates the model, and performs an initial build automatically.
Required flags
| Flag | Description |
|---|---|
--output / -o | Output directory path. The workspace is created as a subdirectory inside this path. |
--name | Name for the new workspace. |
--soc | Target SoC (e.g. MAX32690, MAX78002, ADSP-SC835). |
--board | Board name (e.g. EvKit_V1). |
--core | Target core (e.g. CM4, CM33, FX). |
--model / -m | Path or URL to the model file. |
Example: create a workspace for MAX32690
Example: create a workspace using a remote model
The--model and --dataset flags accept raw remote URLs in addition to local file paths. Remote files are cached for offline reuse and refreshed after one hour.
Skip the compatibility check
By default,cfsutil ai workspace create runs cfsutil ai compat before generating the workspace. Use --skip-compat (-f) to bypass this step.
What happens during workspace creation
Compatibility check
cfsutil ai compat is run to verify the model is compatible with the target hardware. Use --skip-compat to bypass this step.Workspace generation
A new workspace is created at the specified location using the appropriate template for the target SoC and board.
Model integration
The model is added to the workspace configuration using
cfsutil ai model update, writing an entry to the AIModels array in the .cfsconfig file.The .cfsconfig AI section
Model configurations are stored in the AIModels array inside the workspace .cfsconfig file. Each entry describes the backend, target, and backend-specific properties. An example TFLM model entry looks like this:
Managing models in an existing workspace
Once a workspace exists, use thecfsutil ai model subcommands to add, inspect, update, or remove model configurations without re-running the full workspace wizard.
- Add a model
- List models
- Update a model
- Remove a model
A model with the same name cannot be added twice. The name is derived from the model filename (without extension). If
--acc CNN is omitted, the model is treated as a TFLM model and --network-config is silently ignored.End-to-end CLI workflow example
The following sequence shows a complete embedded AI workflow from the command line — adding a model, checking compatibility, generating code, and listing configured models.Next steps
Check Compatibility
Validate operator support, memory constraints, and data types before generating code.
Profile Resources
Estimate inference latency, memory usage, and per-layer performance before deployment.