Introduction: Understanding the New AI Agent Paradigm
he field of artificial intelligence is shifting from a mere competition of large model capabilities to the practical application of AI Agents. A complete AI Agent can be understood as a combination of a “framework” and a “large language model” (LLM). The framework acts as the Agent’s “body,” responsible for executing tasks, planning workflows, and interacting with external tools, while the LLM serves as the “brain,” providing core reasoning, understanding, and generation abilities.
Among the many Agent frameworks, such as OpenClaw and Hermes, Claude Code, launched by Anthropic, has become one of the most prominent solutions, focusing on local operations, code development, and knowledge management scenarios. This article aims to provide a detailed technical guide to help developers set up and use Claude Code from scratch.
Step 1: Install the Claude Code Core Program on macOS

The installation process for Claude Code is primarily done through the command-line terminal. Before starting, ensure your system has access to the internet. Here is the standard installation procedure on macOS:
Execute the installation script: Open the “Terminal” application, then type and execute the following command:
bash
curl -fsSL https://claude.ai/install.sh | bash
This command downloads and executes the installation script from the official address. Upon successful installation, the terminal will display “Claude Code installed successfully!”
Verify the installation: To confirm that the program has been installed and configured correctly, run the version check command in the terminal:
bash
claude –version
If it successfully returns a version number, the installation is complete. If you see a “command not found” error, it usually means the environment variable was not configured correctly. In this case, you can copy and execute the command starting with echo that was suggested by the terminal at the end of the installation, then restart the terminal to resolve the issue.
Start the service: Simply type the claude command in the terminal to start the Claude Code service. On the first launch, the program will ask if you want to continue; select “YES” and press Enter. Once the service starts successfully, you can proceed to the next step of configuring the model.
Step 2: Configure Third-Party Large Language Models with CC Switch
As a framework, Claude Code does not include a language model itself; users need to configure a “brain” for it. Although pairing it with Anthropic’s official Claude series models theoretically yields the best results, connecting to alternative large language models like Kimi K2.6, GLM 5.1, or Minimax M2.7 is a reliable option, considering network and account stability.
To simplify the process of managing and switching models, we recommend using an open-source model management tool called “CC Switch.” This tool supports visual model configuration for multiple Agent frameworks, including Claude Code and OpenClaw.
Install CC Switch: Visit its GitHub releases page (https://github.com/farion1231/cc-switch/releases), download the appropriate installer for your operating system (e.g., the .dmg file for macOS), and complete the installation.
Add a Model Configuration:
- Open the CC Switch application and select the “Claude Code” tab on the main interface.
- Click the “Add New” button to go to the model provider selection page.
- Choose the model you plan to use from the provider list, such as “Kimi.”
- On the configuration page, the most critical step is to enter the API Key obtained from the model’s official open platform. Other parameters can be left at their default values.
- Click “Add” to complete the configuration.
Test and Enable:
- After adding the model, find the newly configured Kimi model in the list and click the “test tube” icon to perform a connectivity test. A green success message indicates that the API Key is valid and the network is connected.
- Finally, click the blue “Enable” button to activate the model.
Verify in Claude Code: Return to the terminal window where Claude Code is running and enter the /model command. The Kimi K2.6 model you just configured via CC Switch should now appear in the list. After selecting it, you can start interacting with it via the command line.
It is worth noting that, according to recent reports, the usage cost of Claude Code has recently doubled. Users should take this cost factor into account when selecting models and planning their usage frequency.
Step 3: Integrate with Visual Studio Code for a Visual Interface
For users from non-technical backgrounds or developers who prefer a graphical interface, a purely command-line operation might not be intuitive enough. Integrating Claude Code with the popular code editor Visual Studio Code (VS Code) can provide a more efficient and user-friendly experience.
Install VS Code: Go to the official Visual Studio Code website (https://code.visualstudio.com/) to download and install the latest version.
Install the Claude Code Extension:
- Open VS Code and click the “Extensions” icon in the left sidebar.
- Type “Claude Code” into the search bar, find the official extension, and click “Install.”
Use the Integrated Interface: After the extension is successfully installed, a dedicated Claude Code session window will appear in the VS Code interface. Users can directly interact with the configured AI large model in this window to request code generation, explanation, or refactoring, with all interactions presented visually.
Summary: Building an Efficient AI-Assisted Development Workflow
At this point, a complete local development environment for Claude Code has been set up. This environment consists of four core components:
- Claude Code Framework: The core executor of the Agent.
- AI Large Language Model: The intelligent core of the Agent (e.g., Kimi K2.6).
- CC Switch: A flexible tool for managing and switching models.
- VS Code Extension: Provides a graphical user interface and deeply integrates into the development process.
In practice, the best approach is to place different projects in separate folders and open the corresponding folder as a workspace in VS Code. This helps Claude Code better understand the project context. Ultimately, an effective AI application depends not only on a powerful framework and model but also on how the user integrates it into their existing workflow, creating a high-performance model of “Agent = Framework + Model + Methodology”.