AWS Builder Center

GLM-5.2 Self-hosting Customer Advisor

Collection of AI Coding assistant tools as AI-powered advisors for self-hosting GLM-5.2 LLM as a bring-your-own-cloud (BYOC) deployment on AWS.

GLM-5.2 Self-Hosting Advisor

AI-powered advisor for self-hosting GLM-5.2 as a bring-your-own-cloud (BYOC) deployment on AWS. Packaged for three AI coding assistants so your team can get expert guidance in whichever tool they use.
GLM-5.2 is an open-weights mixture-of-experts (MoE) model with ~744B total parameters (~40B active per token). Self-hosting keeps all inference traffic, session state, and proprietary content inside the customer's AWS account boundary.

Try it

or just
git clone git@ssh.gitlab.aws.dev:alexmedx/glm-self-hosting-advisor.git
Start with the README.md in the repository, and reach me out if any difficulties in setting this up.

What it covers

Domain
Key questions it answers
Architecture
Trust boundary, control plane vs data plane, EKS/EC2 topology, BYOC model
Marketplace pathways
AMI, container, CloudFormation, SageMaker, SaaS, private offers — which to pick
Deployment pipeline
How a private endpoint reaches ready in minutes (not tens of minutes)
Scaling strategy
Why scale on KV cache occupancy, not GPU utilization
Capacity planning
First-principles memory math, concurrency formulas, worked 8x H200 example

Repository structure

glm-self-hosting/
├── kiro-power/ # Kiro IDE Power
│ ├── POWER.md # Main knowledge base + decision frameworks
│ ├── README.md
│ └── steering/
│ ├── architecture.md
│ ├── capacity-planning.md
│ ├── deployment-pipeline.md
│ ├── marketplace-pathways.md
│ └── scaling-strategy.md
├── claude-skill/ # Claude Code Skill (slash command)
│ ├── glm-advisor.md # Self-contained skill file
│ └── README.md
└── glm-selfhosting-advisor-mcp/ # MCP Server (plugin)
└── mcp-server/
├── package.json
└── src/
├── index.js # Server with 2 tools
└── knowledge.js # Embedded reference material



Quick Start

1. Kiro Power

For teams using  Kiro IDE .
Install:
  1. Open the Kiro Powers panel
  1. Click Add Custom Power > Local Directory
  1. Point to the  kiro-power/  directory in this repo
Usage:
Ask Kiro naturally — the power activates on keywords like  glm-5.2 ,  self-hosting ,  byoc ,  aws-marketplace ,  kv-cache ,  capacity-planning :
"Which AWS Marketplace pathway should a Kubernetes-standardized customer use for GLM-5.2?"
Kiro loads  POWER.md  for the frameworks and pulls in steering files on demand for deeper detail.



2. Claude Code Skill

For teams using  Claude Code .
Install (knowledge base, no dependencies required):
# User-level — available in all projects
cp claude-skill/glm-advisor.md ~/.claude/skills/glm-advisor.md

# Or project-level — scoped to one repo
mkdir -p .claude/skills
cp claude-skill/glm-advisor.md .claude/skills/glm-advisor.md
Usage:
/glm-advisor
Then ask your question. The skill embeds all reference material directly — no external reads needed.
Update: replace the file with the latest version from this repo.



3. MCP Server

For teams wanting tool-based interaction or the capacity calculator. Works with Claude Code, Claude Desktop, VS Code, Cursor, or any MCP-compatible client.
Install:
cd glm-selfhosting-advisor-mcp/mcp-server
npm install
Add to Claude Code:
claude mcp add glm-advisor -- node /absolute/path/to/glm-selfhosting-advisor-mcp/mcp-server/src/index.js
Add to Claude Desktop / other MCP clients ( claude_desktop_config.json ):
{
"mcpServers": {
"glm-advisor": {
"command": "node",
"args": ["/absolute/path/to/glm-selfhosting-advisor-mcp/mcp-server/src/index.js"]
}
}
}
Available tools:
Tool
Purpose
 glm_advisor 
Returns reference material for a topic:  overview ,  architecture ,  marketplace ,  deployment ,  scaling ,  capacity 
 glm_capacity_calculator 
Calculates max concurrency for any GPU config (count, memory, context length, quantization)
Usage examples:
"Explain the marketplace pathways for GLM-5.2"
"Calculate capacity for 4x H100 80GB GPUs at 131K context"
"What's the max concurrency on 8x H200 at 1M tokens?"



Which should I use?

If you...
Use
Use Kiro IDE
Kiro Power — activates automatically on relevant questions
Use Claude Code and want the simplest install
Claude Code Skill — one file,  /glm-advisor  slash command
Want the capacity calculator or use Claude Desktop
MCP Server — structured tools, works across MCP clients
Want maximum coverage
Install all three — they don't conflict



Key numbers (provisional reference)

Metric
Value
Total parameters
~744B (sparse MoE)
Active per token
~40B
Weight memory (FP8)
~744 GB
KV cache per token (MLA)
~44 KB
KV at 32K context
~1.4 GB/request
KV at 1M context
~46 GB/request
8x H200 node — available for KV
~344 GB
Max concurrency at 32K
~245 requests
Max concurrency at 1M
~7 sessions



Caveats

  • KV cache architectural values (KV-LoRA compression rank, RoPE dimension, layer count) are from the closest available GLM-5 family disclosures — not confirmed against the primary released configuration
  • Every capacity figure scales linearly with the per-token KV cost — re-derive once primary-source config is available before final hardware procurement
  • This is a practical reference for initial production rollout; revisit as production traffic data becomes available
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article