Skip to Main Content

AI and Academic Use

Introduction to Generative AI in Coding

Coding is one area in which AI assistance has been making great strides, and has been met with both enthusiasm and skepticism. From "vibe coders" to AI cynics, there is spectrum of opinions about using these tools in coding. While these tools can be used to help with review, automation, auto-completion, debugging, translation, documentation, vulnerability detection, and code generation, we recommend certain practices to ensure responsible AI-assisted programming. 

In general, these tools should be used to aid and empower human coders, but the process can be challenging as you acquire the experience necessary to make the tools work for you. As with AI tools in general, LLMs used for coding are often over-confident and prone to hallucinations, and will require patience to iterate and improve the results. The work produced by AI tools, like all work, should always be reviewed, validated, and verified.

As Wills et al. note: 

[T]he integration of generative AI tools such as ChatGPT holds immense promise for advancing academic research(e.g. in ecological and evolutionary fields), revolutionising coding education and practices, promoting inclusivity, and facilitating knowledge dissemination. However, researchers must navigate the ethical and methodological challenges inherent in harnessing AI technologies, prioritising transparency, validation, and critical inquiry to ensure the integrity and credibility of research initiatives. (2191)

As with any AI tool, proceed with caution and understand the the potential risks of sharing original work with AI tools and with accepting the work of GenAI without adequate review. Read Terms of Service agreements carefully and understand how your data is being used or processed.

Please reviewing the guidance on Academic Integrity before using any tools.

For Coding Novices

Generative AI tools can be helpful for beginners learning how to code. Chat tools in particular allow researchers to ask LLM chatbots coding-related questions. Your results will depend on the effectiveness of your questions. 

We recommend additional research and guidance about working with LLMs to write code. Several guides are shared below under "Resources."

Below are a few common tools for AI-assisted coding that our library experts consider well-suited for beginners (includes both proprietary and open source tools):

When choosing a tool, remember that these are meant to assist you in your coding. As with other research practices, you, as the researcher and the programmer, need to be able to read the code and ensure that you understand how it works and can explain it to others. 

Consider too, that cloud-hosted LLM services can pose security and privacy concerns for researchers. In those cases, self-hosting LLMs for research purposes, could address the data privacy issues. 

*UCSB users can upgrade their GitHUb account to "Copilot Pro" for free if they want to test out Copilot. More information on that can be found below:

For Advanced Coders

For experienced programmers, there is a shift away from using chatbots via conversational modes to using AI coding tools that are integrated in the Integrated Developer Environments (IDE). 

  • VS Code (Visual Studio Code) is a free IDE popular among programmers that offers AI-powered extensions like GitHub Copilot and Cline
  • Cursor, a more proprietary freemium alternative to VS Code, offers built-in AI integrations and is also popular among software engineers. 
  • Jetstream2’s LLM Inference Service provides access to Llama and DeepSeek. It can also be integrated into IDEs using the Cline extension. This is available to researchers with NSF ACCESS accounts.
  • ellmer is a recent R package that aims at integrating LLM coding tools into R users' workflow. For more information: Read the ehttps://posit.co/blog/announcing-ellmer/https://posit.co/blog/announcing-ellmer/.

For additional assistance with Generative AI and coding applications, please reach out to experts at the DREAM Lab.

Additional Resources for AI and Coding