This chapter covers
- What VS Code is and why developers use it
- Installing VS Code and Python with Homebrew
- Installing the Python extension for syntax highlighting and error detection
- Using the integrated terminal to run commands without leaving the editor
- Creating a project folder and running your first Python script
So far, you have been using the terminal to run Ollama commands and chat with AI models. That works well for quick interactions, but to build a real application, such as a chatbot with a graphical interface that calls the model programmatically, you need to write Python code. Knowing basic Python fundamentals will be helpful from this point forward, especially concepts like functions, variables, files, and packages. Do not worry if those terms are new to you; this chapter will walk you through setting up the tools, and subsequent chapters will teach you the code one step at a time.
TIP When you see programming terms such as function, variable, file, package, or parameter, treat them as vocabulary to learn gradually. You do not need to master Python before continuing, but looking at an introduction to Python [1, 2] will make the next several chapters more comfortable.