Create and Explain formulas with Copilot (AI) in Power Platform

Introduction

As we know, Power Fx formulas in Power Platform are very powerful; however, sometimes, it’s tricky and difficult to understand these complex formulas. So, we want someone who can create and explain these formulas to us. Copilot is here to help! This article dives into how you can use Copilot to generate formulas and get explanations of existing ones within the Power Platform.

Copilot will help us build Power Platform solutions faster and more efficiently. With the help of Copilot in formula creation and explanation, we can focus on the bigger picture of app development.

Implementation


Create formula

With the new “Create Formula” feature, we can now generate Power Fx formulas directly using natural language.

Write the formula in a simple natural language, and AI Copilot will suggest the appropriate formula and append it wherever the cursor was located when the request was made after you click apply.

Step 1. Select the formula bar and click on Copilot. You will get a preview option called “Create a formula”, as shown below.

Create formula

Step 2. Write the query in natural language, as shown below.

Natural language

Result: The Copilot will generate the formula based on your input.

Copilot

Point to remember

Create formula is still a Preview feature and is not enabled by default. To use this feature in your app, turn on the “Copilot for formulas” flag in Canvas App Settings > Updates > Preview (as shown below):

Setting

Explain formula

In addition to creating the formulas, Copilot can explain the existing written formulas or logic. In addition, partial formulas can also be explained if the formula is very big. By selecting a formula, you will get an option in Copilot to “Explain this selection” and get a plain language explanation of what the selected portion of the formula does. This is particularly useful for understanding long or complex formulas.

Selection

As shown in the below image, Copilot has explained the selected formula.

Formula

Conclusion

Start using these new and exciting AI features in Power Platform (Power App), which will help create and modify Power Fx formulas quickly and overall will help in Power App development.

Learn more: https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/ai-formulas-formulabar.

Up Next
    Ebook Download
    View all
    Learn
    View all