[KongchangAI]
Tutorials· 2 min read· 1,158 words

Complete Guide for Beginners: Setting Up an AI Programming Environment from Scratch (2025 Latest)

Complete Guide for Beginners: Setting Up an AI Programming Environment from Scratch (2025 Latest)

Beginners guide to setting up Claude Code + MiniMax for AI programming with an IBE encryption project

This article guides complete beginners through setting up an AI-assisted programming environment: installing the Claude Code command-line tool, VS Code editor with plugins, purchasing MiniMax LLM API access (29 RMB/month), and configuring the connection via CCSwitch. It concludes with a hands-on project implementing the IBE identity-based encryption algorithm, demonstrating how to use natural language conversation to have AI generate complete Java code and debug it to completion.

Introduction

For programming beginners, the emergence of AI programming tools has dramatically lowered the barrier to learning to code. Through natural language conversations, even without any programming background, you can have AI write complex algorithm code for you.

This article will guide you step by step from scratch to set up a complete AI programming environment, using the IBE (Identity-Based Encryption) algorithm from cryptography as an example to complete your first AI-assisted programming project.

The entire process involves three core tools: Claude Code (AI programming assistant), VS Code (code editor), MiniMax (LLM API), plus a helper configuration tool called CCSwitch.

Environment Preparation & Tool Installation

Step 1: Install Claude Code

Claude Code is a command-line AI programming assistant released by Anthropic, powered by the Claude series of large language models. Unlike IDE-integrated tools such as Cursor and GitHub Copilot, Claude Code uses an agentic architecture that can autonomously read/write files, execute terminal commands, and call external tools to complete multi-step complex programming tasks — not just code completion. This design makes it closer to an "automated programming agent" rather than a traditional code suggestion plugin.

Installation steps:

  1. Visit the Claude Code official website (consider using a Chinese mirror site to avoid network issues)
  2. Open PowerShell or CMD and execute the official installation command
  3. The installation process will automatically detect and install Node.js dependencies

Important notes:

  • On Windows, PowerShell may encounter permission issues — it's recommended to switch to CMD for the installation command
  • Claude Code on Windows also requires Git — simply download it from the official website and install with default settings

Configure this model for Claude Code

Step 2: Install VS Code and AI Plugins

Claude Code itself has a command-line interface, which isn't very beginner-friendly. Pairing it with VS Code makes the experience much better:

  1. Download the installer from the VS Code official website and install with default settings
  2. Open VS Code and click the Extensions icon on the left sidebar
  3. Search for "Claude Code" and install the official Anthropic plugin
  4. If you need to write Java code, additionally install the Java Extension Pack and JDK

Step 3: Purchase LLM Tokens

Claude Code needs to work with a large language model. Before understanding your options, it's important to understand the billing logic of LLM APIs: The billing unit is the Token, which is the basic unit for model text processing. Typically, one English word equals approximately 1-2 Tokens, and one Chinese character equals approximately 1-2 Tokens. API call count and Token consumption are two different dimensions — call count refers to the number of requests made to the API, while the number of Tokens consumed per request depends on the sum of input prompt length and output code length.

After comparing multiple providers, MiniMax offers excellent value for money. MiniMax is a leading Chinese LLM company whose M2 model has strong capabilities in code generation tasks and offers developer subscription plans that are more suitable for learning scenarios compared to pay-per-use pricing:

  • Search "MiniMax Token PlanAd" to access the subscription page
  • The Starter tier costs only 29 RMB per month (approximately $4 USD)
  • It provides 600 calls every 5 hours, which is more than enough for learning
  • After purchase, obtain your API Key from account management (keep it confidential — never share it with others)

Configuring the Model Connection

One-Click Configuration with CCSwitch

CCSwitch is a helper tool that configures LLM APIs for Claude Code, saving you the hassle of manually editing configuration files:

  1. Download the appropriate system version of CCSwitch from GitHub
  2. After installation, open it and select Claude Code as the target tool
  3. Choose MiniMax from the model list
  4. Enter the API Key you received after purchase
  5. Keep other parameters at default values and click Add

After configuration is complete, type claude in CMD to launch Claude Code, and ask "What model are you?" to verify the connection. If it responds with "I am the MiniMax M2 model," the configuration is working correctly.

I use CMD instead of PowerShell

Set Permission Mode for Better Efficiency

In the Claude Code plugin settings within VS Code, it's recommended to change the permission mode to Bypass Permission. This way, the AI doesn't need manual confirmation every time it creates files or executes commands, significantly improving interaction efficiency.

AI Programming in Practice: Implementing IBE Encryption from Scratch

About the IBE Algorithm: Why Choose It as a Starter Project?

IBE (Identity-Based Encryption) is a public-key encryption system proposed by cryptographer Adi Shamir in 1984 and formally implemented by Dan Boneh and Matthew Franklin in 2001 based on Bilinear Pairing. Its core idea is that a user's identity information (such as email address or phone number) directly serves as the public key, eliminating the cumbersome certificate application and management processes in traditional PKI systems. Private keys are distributed by a trusted PKG (Private Key Generator) based on user identity.

Compared to traditional RSA encryption, IBE's advantage is that the sender doesn't need to obtain the recipient's certificate in advance — they only need to know the recipient's identity identifier to encrypt. This offers significant advantages in scenarios like enterprise internal communications and IoT device authentication. JPBC (Java Pairing-Based Cryptography) is the mainstream Java library for implementing bilinear pairing operations, widely used in academic research and prototype verification, and is the core dependency for this project.

IBE was chosen as a starter project because its implementation structure is clear (four standard steps), it has high academic value, and it's complex enough to fully demonstrate the value of AI-assisted programming.

Writing Code with Natural Language

Once the environment is set up, programming becomes a conversation with AI:

  1. Create a new folder on your desktop (e.g., "IBE") and place the necessary dependency libraries in it
  2. Open the folder with VS Code
  3. Enter a prompt in the Claude Code dialog:

"Help me write an Identity-Based Encryption (IBE) implementation based on the JPBC library. Keep it simple and clear."

The AI will automatically generate complete Java code, including:

  • Setup (system parameter generation)
  • Extract (private key extraction)
  • Encrypt (encryption)
  • Decrypt (decryption)
  • Complete test cases and output printing

I've actually already used it this afternoon

Running Code & AI-Assisted Debugging

If you encounter environment issues during execution (such as missing JDK), Claude Code will automatically detect and suggest solutions. The entire debugging process is simply ongoing conversation with AI: error → AI fix → run again, until the program works.

In practice, the IBE code ran successfully after a few rounds of fixes, outputting the complete encryption and decryption workflow.

Have AI Generate a Demo Webpage

Besides writing code, you can also have AI create presentation materials. For example:

"I want to introduce the IBE algorithm to others. Help me create an HTML presentation page."

#Claude Code setup#AI programming for beginners#MiniMax API#IBE encryption algorithm#AI coding environment 2025#VS Code AI plugins#identity-based encryption tutorial
Share:

Related articles