chapter five
5 Setting Up VS Code and Your Python Development Environment
This chapter covers
- What VS Code is and why developers use it
- Installing VS Code 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---a chatbot with a graphical interface that calls the model programmatically---you need to write Python code. Do not worry if you have never written code before; this chapter walks you through setting up the tools, and subsequent chapters will teach you the code one step at a time.
TIP
From this chapter onward, basic Python fundamentals will be helpful. If terms such as variable, function, string, or parameter feel unfamiliar, take a little time to review them before the project code becomes more involved.