Fix GLM chicken-and-egg problem in Master Prompt workflow

BREAKING CHANGES to workflow:
- Add 'BEFORE YOU BEGIN' section to MASTER-PROMPT.md
- GLM users MUST configure GLM FIRST before using Claude Code
- Add clear GLM pre-configuration steps at top of file
- Add clear copy boundaries (✂️ COPY FROM HERE / ✂️ COPY ENDS HERE)
- Add visual separator lines for copy-paste section

README.md updates:
- Add prominent GLM warning at top of Installation Options
- Add quick GLM setup commands
- Clarify Master Prompt workflow with step-by-step
- Emphasize GLM pre-configuration requirement

This fixes the issue where GLM users couldn't use Claude Code
to paste the master prompt without first configuring GLM.
This commit is contained in:
uroma
2026-01-15 15:02:37 +00:00
Unverified
parent 3ec540288b
commit 775c5c65e7
2 changed files with 159 additions and 121 deletions

View File

@@ -1,35 +1,91 @@
# 🚀 Claude Code & GLM Suite - Master Integration Prompt
> **Copy and paste this entire prompt into Claude Code to automatically install the complete customization suite.**
> **Quick installation by copy-pasting a prompt into Claude Code**
---
## 📋 Master Integration Prompt
## ⚠️ BEFORE YOU BEGIN - Read This First!
**Copy everything below this line and paste into Claude Code:**
### **If Using Z.AI / GLM Coding Plan (90% cheaper):**
```
I want to install the Ultimate Claude Code & GLM Customization Suite with 40+ agents, MCP tools, and auto-triggering automation. Please perform the following integration:
## Prerequisites: Install Claude Code
**Before installing agents and tools, ensure Claude Code is installed:**
**You MUST configure GLM FIRST before using Claude Code!**
```bash
# Install Claude Code (requires Node.js 18+)
# Step 1: Get your API key
# Visit: https://z.ai/
# Sign up for GLM Coding Plan and copy your API key
# Step 2: Create Claude Code settings
mkdir -p ~/.claude
cat > ~/.claude/settings.json << 'EOF'
{
"env": {
"ANTHROPIC_AUTH_TOKEN": "YOUR_ZAI_API_KEY_HERE",
"ANTHROPIC_BASE_URL": "https://api.z.ai/api/anthropic",
"API_TIMEOUT_MS": "3000000",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "glm-4.5-air",
"ANTHROPIC_DEFAULT_SONNET_MODEL": "glm-4.7",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "glm-4.7"
}
}
EOF
# Step 3: Install Claude Code (if not installed)
npm install -g @anthropic-ai/claude-code
# Verify installation (recommended: 2.0.14+)
claude --version
# Step 4: Verify installation
claude --version # Should be 2.0.14 or higher
# If needed, upgrade to latest
claude update
# Step 5: Start Claude Code
claude
# Step 6: When prompted, enter /status to verify GLM is working
/status
```
**Reference:** https://docs.anthropic.com/en/docs/claude-code/overview
**📖 Official GLM Documentation:** https://docs.z.ai/devpack/tool/claude
---
### **If Using Anthropic Claude (Official API):**
```bash
# Step 1: Get your API key
# Visit: https://console.anthropic.com/
# Step 2: Create Claude Code settings
mkdir -p ~/.claude
cat > ~/.claude/settings.json << 'EOF'
{
"env": {
"ANTHROPIC_AUTH_TOKEN": "sk-ant-your-api-key-here",
"ANTHROPIC_BASE_URL": "https://api.anthropic.com"
}
}
EOF
# Step 3: Install Claude Code (if not installed)
npm install -g @anthropic-ai/claude-code
# Step 4: Start Claude Code
claude
```
---
## 📋 HOW TO USE THE MASTER PROMPT
**Once Claude Code is running and configured:**
### **Option 1: Copy From This File**
**✂️ COPY FROM HERE:**
```text
═══════════════════════════════════════════════════════════════════════════════
I want to install the Ultimate Claude Code & GLM Customization Suite with 40+ agents, MCP tools, and auto-triggering automation. Please perform the following integration:
## Step 1: Install Contains Studio Agents (37 agents with PROACTIVELY auto-triggering)
Clone the contains-studio/agents repository:
@@ -67,83 +123,19 @@ This provides 15+ MCP tools including:
- Web search and page reading
- GitHub repository reading
## Step 3: Configure Model (Choose ONE)
### Option A: Anthropic Claude (Official API)
**Best for:** Production, highest quality, official support
1. Get your API key: https://console.anthropic.com/
2. Create ~/.claude/settings.json:
```json
{
"env": {
"ANTHROPIC_AUTH_TOKEN": "sk-ant-your-actual-api-key-here",
"ANTHROPIC_BASE_URL": "https://api.anthropic.com"
}
}
```
3. Verify installation: `claude --version`
### Option B: Z.AI / GLM Coding Plan (90% cheaper, Official Integration)
**Best for:** Development, testing, cost-sensitive projects
**Follow official Z.AI documentation:** https://docs.z.ai/devpack/tool/claude
1. **Get your GLM Coding Plan API key:**
- Visit: https://z.ai/
- Sign up for GLM Coding Plan
- Copy your API key
2. **Configure Claude Code for GLM:**
Create ~/.claude/settings.json with:
```json
{
"env": {
"ANTHROPIC_AUTH_TOKEN": "your-zai-api-key-here",
"ANTHROPIC_BASE_URL": "https://api.z.ai/api/anthropic",
"API_TIMEOUT_MS": "3000000",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "glm-4.5-air",
"ANTHROPIC_DEFAULT_SONNET_MODEL": "glm-4.7",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "glm-4.7"
}
}
```
3. **Verify and test:**
```bash
# Check Claude Code version (recommended: 2.0.14+)
claude --version
# Start Claude Code
claude
# Check model status (enter /status when prompted)
/status
```
4. **Troubleshooting (if configuration doesn't take effect):**
- Close all Claude Code windows
- Open new terminal and run `claude` again
- Or delete ~/.claude/settings.json and reconfigure
- Verify JSON format is correct (no missing/extra commas)
**GLM Models Available:**
- `glm-4.5-air` - Fast, efficient (Haiku equivalent)
- `glm-4.7` - High quality (Sonnet/Opus equivalent)
## Step 4: Configure Hooks-Based Auto-Triggering (Optional)
## Step 3: Configure Hooks-Based Auto-Triggering (Optional)
Create ~/.claude/hooks.json for additional auto-triggering:
cat > ~/.claude/hooks.json << 'EOF'
{
"userPromptSubmitHook": "test-writer-fixer@agent",
"toolOutputHook": "whimsy-injector@agent"
}
EOF
Note: PROACTIVELY agents (studio-coach, experiment-tracker) work automatically without hooks.
## Step 5: Verify Installation
## Step 4: Verify Installation
Run these checks:
1. List agents: ls -la ~/.claude/agents/
@@ -185,43 +177,17 @@ Expected results:
2. Hooks-Based (our implementation) - Event-driven, explicit control
Please execute this integration step by step and confirm when complete.
═══════════════════════════════════════════════════════════════════════════════
```
---
## 🎯 How to Use
1. **Copy** the entire prompt above (including the code block)
2. **Paste** into Claude Code
3. **Follow** the step-by-step installation
4. **Verify** your installation
**✂️ COPY ENDS HERE**
---
## 📚 Source Repositories
## 📖 Detailed Installation Guide
This integration pulls from multiple open-source projects:
### Core Agents
- **[contains-studio/agents](https://github.com/contains-studio/agents)** - 37 agents with PROACTIVELY auto-triggering
- **[claude-codex-settings](https://github.com/fcakyon/claude-codex-settings)** - MCP configuration patterns
### Design Inspiration
- **[ui-ux-pro-max-skill](https://github.com/nextlevelbuilder/ui-ux-pro-max-skill)** - UI/UX design patterns
### Coordination Framework
- **[Ralph](https://github.com/iannuttall/ralph)** - Multi-agent coordination patterns
### MCP Tools
- **[@z_ai/mcp-server](https://github.com/zai-ai/mcp-server)** - Vision and analysis tools
- **[Model Context Protocol](https://github.com/modelcontextprotocol)** - Open standard for AI tools
### Official Tools
- **[Claude Code](https://github.com/anthropics/claude-code)** - Official Claude Code CLI
---
## 🔧 What Gets Installed
### What Gets Installed:
| Component | Source | Count |
|-----------|--------|-------|
@@ -234,9 +200,9 @@ This integration pulls from multiple open-source projects:
---
## ✅ After Installation
## 🎯 Quick Reference
Test your setup:
**After Installation, Test With:**
```bash
# Start Claude Code
@@ -267,11 +233,48 @@ claude
---
## 📖 Documentation
## 📚 Source Repositories
- **[Integration Guide](https://github.rommark.dev/admin/claude-code-glm-suite/src/main/INTEGRATION-GUIDE.md)** - Technical details
- **[Contains Studio Integration](https://github.rommark.dev/admin/claude-code-glm-suite/src/main/CONTAINS-STUDIO-INTEGRATION.md)** - PROACTIVELY mechanism
- **[README](https://github.rommark.dev/admin/claude-code-glm-suite)** - Complete documentation
This integration pulls from multiple open-source projects:
### Core Agents
- **[contains-studio/agents](https://github.com/contains-studio/agents)** - 37 agents with PROACTIVELY auto-triggering
- **[claude-codex-settings](https://github.com/fcakyon/claude-codex-settings)** - MCP configuration patterns
### Design Inspiration
- **[ui-ux-pro-max-skill](https://github.com/nextlevelbuilder/ui-ux-pro-max-skill)** - UI/UX design patterns
### Coordination Framework
- **[Ralph](https://github.com/iannuttall/ralph)** - Multi-agent coordination patterns
### MCP Tools
- **[@z_ai/mcp-server](https://github.com/zai-ai/mcp-server)** - Vision and analysis tools
- **[Model Context Protocol](https://github.com/modelcontextprotocol)** - Open standard for AI tools
### Official Tools
- **[Claude Code](https://github.com/anthropics/claude-code)** - Official Claude Code CLI
- **[Z.AI GLM Documentation](https://docs.z.ai/devpack/tool/claude)** - Official GLM integration guide
---
## ✅ After Installation
Test your setup:
```bash
# 1. Verify agents are installed
ls ~/.claude/agents/
find ~/.claude/agents -name "*.md" | wc -l
# 2. Start Claude Code
claude
# 3. Check status (enter /status when prompted)
/status
# 4. Try an agent
> Use the studio-coach agent to help me plan a complex project
```
---