---
title: "OpenRouter 1M-Context Cost Index: Ergo vs GLM-5.3-Flash vs MiniMax M4"
slug: "openrouter-1m-context-cost-index-ergo-glm-5-3-flash-minimax-m4"
description: "Systems architecture analysis of Amazon Ergo, GLM-5.3-Flash, and MiniMax M4 on OpenRouter: 1M-token context pricing, KV-cache memory footprint, and runtime"
author: "Hamdi Soudani"
category: "ai-llms"
archetype: "architecture-analysis"
published_at: "2026-12-03T16:05:09.294+00:00"
updated_at: "2026-12-03T16:05:09.377535+00:00"
canonical_url: "https://pyvren.com/blog/openrouter-1m-context-cost-index-ergo-glm-5-3-flash-minimax-m4"
reading_time_minutes: 5
word_count: 894
quality_score: 93
tags: ["openrouter","slm","llm-pricing","kv-cache","context-window"]
keywords: ["openrouter slm pricing","amazon ergo kv cache","glm-5-3-flash context window","1m token context pricing","openrouter provider routing fallback"]
sources: ["https://openrouter.ai/amazon/ergo-1.0","https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix","https://benchlm.ai/compare/amazon-ergo-vs-glm-realtime-flash","https://openrouter.ai/models"]
---

# OpenRouter 1M-Context Cost Index: Ergo vs GLM-5.3-Flash vs MiniMax M4

> **TL;DR:** Amazon Ergo costs $1.00/M input and $3.00/M output on OpenRouter with no documented cache-read rate, while GLM-5.3-Flash costs $0.075/M input, $0.250/M output, and $0.015/M cache reads plus a 5.5% platform fee; MiniMax M4 pricing remains unpublished as of 2026-12-03.

## Key Facts

- **Amazon Ergo input price (OpenRouter):** $1.00 per million input tokens ([source](https://openrouter.ai/amazon/ergo-1.0))
- **Amazon Ergo output price (OpenRouter):** $3.00 per million output tokens ([source](https://openrouter.ai/amazon/ergo-1.0))
- **Amazon Ergo context window:** 1M tokens ([source](https://benchlm.ai/compare/amazon-ergo-vs-glm-realtime-flash))
- **GLM-5.3-Flash input price (OpenRouter Z.ai route):** $0.075 per million input tokens ([source](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix))
- **GLM-5.3-Flash output price (OpenRouter Z.ai route):** $0.25 per million output tokens ([source](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix))
- **GLM-5.3-Flash cache read price:** $0.015 per million cached input tokens ([source](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix))
- **OpenRouter platform fee:** 5.5% platform fee on pay-as-you-go accounts ([source](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix))
- **GLM-5.3-Flash context window:** roughly one million tokens ([source](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix))

This architecture analysis compares three SLMs served through OpenRouter: Amazon Ergo, GLM-5.3-Flash, and MiniMax M4. All three advertise roughly 1M-token context windows, but the economics of serving that context diverge sharply once you account for KV-cache read pricing, platform fees, and runtime memory pressure.

## Benchmark Verdict & Cost Math

Amazon Ergo lists at $1.00 per million input tokens and $3.00 per million output tokens on OpenRouter, with no documented cache-read discount in the provider excerpt. GLM-5.3-Flash, the documented GLM-family analog on OpenRouter, lists at $0.075 per million input tokens and $0.25 per million output tokens, with cache reads at $0.015 per million tokens. OpenRouter adds a 5.5% platform fee on pay-as-you-go accounts, bringing effective GLM-5.3-Flash costs to roughly $0.0791/M input, $0.2638/M output, and $0.0158/M cache read when fees are allocated proportionally.

The gap is structural. At a 50% cache ratio on a 1M-token context, GLM-5.3-Flash effectively bills about half its input volume at cache-read rates. Amazon Ergo has no published cache-read rate in the OpenRouter model page excerpt, which means long-context agents reusing system prompts pay full input price on every turn. That difference compounds quickly in multi-turn coding agents where conversation history and code context repeat across requests.

MiniMax M4 pricing was not present in the provided primary sources, so I cannot state its OpenRouter input, output, or cache-read rates. Any cost model that includes MiniMax M4 must treat those figures as unavailable until OpenRouter publishes them.

## Model / Runtime Quantitative Comparison Table

| Model | Creator | Context Window | Input / 1M Tokens | Output / 1M Tokens | Cache Read / 1M Tokens | Platform Fee | EU In-Region | Shared Benchmarks |
|---|---|---|---|---|---|---|---|---|
| Amazon Ergo | Amazon | 1M tokens | $1.00 | $3.00 | Not documented | 5.5% | No | 5 covered |
| GLM-5.3-Flash (Z.ai route) | Zhipu AI | ~1M tokens | $0.075 | $0.250 | $0.015 | 5.5% | Not documented | 0 shared with Ergo |
| MiniMax M4 | MiniMax | Not documented | Not documented | Not documented | Not documented | Not documented | Not documented | Not documented |

BenchLM reports zero shared sourced benchmark rows between Amazon Ergo and GLM Realtime Flash, so there is no score-level head-to-head winner. Amazon Ergo independently reports Terminal-Bench 4.0 at 46.20%, Terminal-Bench-Science 0.1 at 21.3%, DeepSWE at 74.2%, FrontierSWE v2 at 31.5%, and ProgramBench at 23.5%. GLM-family models show no public-lane scores in the provided comparison.

## Context Window & Memory Bottlenecks

A 1M-token context window does not come free. At FP8 quantization, a 1M-token KV cache for a 70B-parameter model occupies roughly 140 GB of VRAM before activation memory, optimizer states, or batch overhead. At Q4_K_M, the footprint drops but attention computation still scales quadratically with sequence length in naive implementations, and linear attention variants trade memory for approximation error.

KV-cache OOM is the dominant failure mode here. When the cache exceeds device memory, the runtime must either evict entries (causing context rot and lost instructions), spill to host memory (adding PCIe transfer latency), or reject the request. Context poisoning appears when irrelevant or adversarial tokens in the prefix distract the model from later instructions, a known failure mode in long-context reasoning that gets worse as the cache fills.

OpenRouter acts as a routing layer, not a runtime. The actual KV-cache memory lives on the provider's inference stack—vLLM, SGLang, or llama.cpp depending on the provider. That means cache eviction policy, prefix caching behavior, and prefill chunking are provider-specific, not OpenRouter settings. You cannot tune KV-cache quantization from the OpenRouter API.

## Reproducible Inference / Routing Config

The OpenRouter Chat Completions endpoint accepts standard sampling parameters for Amazon Ergo, including temperature, top_p, max_tokens, frequency_penalty, presence_penalty, repetition_penalty, seed, stop, logprobs, top_logprobs, logit_bias, min_p, top_k, response_format, tool_choice, tools, parallel_tool_calls, reasoning, and seed. The endpoint is POST https://openrouter.ai/api/v1/chat/completions with Authorization: Bearer $OPENROUTER_API_KEY.

```bash
curl https://openrouter.ai/api/v1/chat/completions \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "amazon/ergo-1.0",
    "messages": [{"role": "user", "content": "Summarize the attached codebase."}],
    "max_tokens": 4096,
    "temperature": 0.2,
    "top_p": 0.9,
    "stream": true
  }'
```

For cached-context workloads, set stream to false when you need deterministic cache-hit measurement, and monitor the usage object in the response to distinguish input tokens from cache-read tokens. OpenRouter does not expose a cache-ratio knob; cache behavior depends on the provider's implementation of automatic context caching.

For provider routing with fallback behavior, use a JSON object like this:

```json
{
  "model": "amazon/ergo-1.0",
  "provider": {
    "order": ["Amazon Bedrock", "Chutes", "inference.net"],
    "allow_fallbacks": true,
    "require_parameters": true
  },
  "max_tokens": 4096,
  "temperature": 0.2
}
```

Capture TTFT by timing the first token arrival with curl -w "%{time_starttransfer}" and verify cache hits by inspecting usage.prompt_tokens_details.cached_tokens in the response body.

## Selection Rubric by Workload

Choose Amazon Ergo only when you need its documented reasoning benchmarks (Terminal-Bench, DeepSWE, FrontierSWE, ProgramBench) and can absorb the $1.00/$3.00 pricing without cache-read discounts. It suits agentic workloads where benchmark coverage matters more than per-token cost, and where EU in-region routing is not required.

Choose GLM-family models on OpenRouter when cached-context economics dominate. The $0.075/$0.250 base rates with $0.015 cache reads make repeated system prompts and multi-turn coding sessions substantially cheaper than Ergo, provided the 5.5% platform fee fits your budget. The lack of shared benchmark rows with Ergo means you should run your own evals before committing.

MiniMax M4 cannot be recommended or ruled out on cost grounds from the available data. Treat it as an unknown until OpenRouter publishes its pricing table.

When NOT to use this architecture: do not route 1M-context requests through OpenRouter if you need deterministic KV-cache residency, sub-50ms TTFT at full context, or EU data residency. OpenRouter is a broker, not a runtime, and provider-side cache eviction can evict your prefix mid-session. For latency-sensitive long-context workloads, deploy vLLM or SGLang directly on dedicated GPU infrastructure and manage the KV cache yourself.

![GLM-5.3-Flash pricing comparison showing OpenRouter's 5.5% platform fee and cache-ratio cost examples](https://aihubmix.com/blog-media/images/2026/09/e82b375fbcc67572.png)

Primary sources: [OpenRouter Amazon Ergo model page](https://openrouter.ai/amazon/ergo-1.0), [AIHubMix GLM-5.3-Flash pricing comparison](https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix), [BenchLM Amazon Ergo vs GLM Realtime Flash](https://benchlm.ai/compare/amazon-ergo-vs-glm-realtime-flash).

## Frequently Asked Questions

### Does OpenRouter mark up provider prices for Amazon Ergo?

No. OpenRouter states it does not mark up provider prices shown in its model catalog; the listed inference price remains $1.00/M input and $3.00/M output, though a 5.5% platform fee applies to pay-as-you-go accounts.

### Can Amazon Ergo and GLM Realtime Flash be compared on BenchLM yet?

Not fully yet. BenchLM reports no shared sourced benchmark row between Amazon Ergo and GLM Realtime Flash, so there is no score-level head-to-head winner.

### Is Amazon Ergo available through EU in-region routing on OpenRouter?

No. Amazon Ergo is not currently available through EU in-region routing on OpenRouter.

## Primary Sources

- https://openrouter.ai/amazon/ergo-1.0
- https://aihubmix.com/blog/glm-5-3-flash-pricing-compared-openrouter-z-ai-and-aihubmix
- https://benchlm.ai/compare/amazon-ergo-vs-glm-realtime-flash
- https://openrouter.ai/models
