I was recently involved in a customer meeting, doing a data governance speak. I was having fun and had a good story with practical use cases and an eye-catching demo. After my set was finished, a colleague started his presentation on augmenting data preparation with AI. I was a bit skeptical, as I felt it’s still just hot air and a lot of promises. Little did I know, as I had not realized how far we have come with GenAI as coder’s aid.
In his demo my colleague was using the SAS Viya Copilot Extension for Visual Studio Code and started his demo by telling GenAI what kind of data manipulation he would like to accomplish. It was a simple data preparation task - to split a source table into separate result tables as output based of the content of a specific column. GenAI replied with a first version of the code, and he let it run in Visual Studio Code. Code ran with no errors and output was as expected. However, the next two things were the part that literally blew my mind!
He asked GenAI to insert comments to the code. We checked them together and they were as good as anyone of us typically writes. I felt that was very cool for all of us who are lazy to write comments. But the coolest thing was when he asked AI to modify the code to into re-usable format. GenAI went on to create a SAS macro that takes the table name and names of the columns to be processed as macro inputs. And the result was a working SAS macro. We also tested that with necessary variables and results were good!
This was the part that convinced me that AI can be especially useful in shaping the rough version of the code and letting the developer to fine tune it with either more detailed requirements for the GenAI or editing manually. These capabilities in my opinion earn the moniker ‘Copilot’ as that is exactly what is does. One thing has not changed though. While Copilot provides good advice, comments and a solution to given problem, the developer still needs to know which problem is being solved to define the requirements for the code. In this transportation analogy, the developer would be the pilot who directs the GenAI by formulating the requirements and estimates the validity of the results. It’s good to remember that the developer in pilot role is ultimately responsible also for the copilot’s possible logic mistakes. As in any software development process, human review of the results adds necessary governance to the process.
Many organizations have already defined or are in the process of defining their policy regarding the application of GenAI and use of results obtained from the use of it. Use of GenAI often raises questions related to intellectual property risks so having a clear policy makes it more straightforward for the developer to start using these tools in good confidence. Obviously training plays a key role in the adoption of secure GenAI practices. In modern integrated development environments, it’s all too easy to drop private information into the editor.
If you’re already developing in SAS Viya, then you can give it a try with the SAS Viya Copilot Extension for Visual Studio Code. It’s flexible tool to enhance productivity and time to results as you program in SAS. SAS Viya Copilot uses GenAI to add comments to a block of SAS code, write an explanation of a block of SAS code, and generate SAS code based on a block of comments in a SAS program. All of these available directly from the developer-friendly menus, as in the image below (source: https://github.com/sassoftware/sas-copilot)
Looking at these examples it’s very easy to get hyped with all the possibilities that GenAI can offer. That happened to me, and if you’re feeling the same way, have a look yourself. A good place to start is the blog 3 ways you can use a copilot in SAS® which explains how SAS Viya Copilot can speed-up your SAS coding right now.
I'm certainly going to use the Copilot services 🙂 Thanks for sharing your experience @jarno !
The rapid growth of AI technologies is driving an AI skills gap and demand for AI talent. Ready to grow your AI literacy? SAS offers free ways to get started for beginners, business leaders, and analytics professionals of all skill levels. Your future self will thank you.