惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

小众软件
小众软件
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
WordPress大学
WordPress大学
月光博客
月光博客
Hugging Face - Blog
Hugging Face - Blog
博客园 - 聂微东
博客园 - 【当耐特】
博客园_首页
The Cloudflare Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Apple Machine Learning Research
Apple Machine Learning Research
Last Week in AI
Last Week in AI
酷 壳 – CoolShell
酷 壳 – CoolShell
大猫的无限游戏
大猫的无限游戏
雷峰网
雷峰网
量子位
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
T
Tailwind CSS Blog
IT之家
IT之家
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
GbyAI
GbyAI
V
Visual Studio Blog
F
Fortinet All Blogs
Martin Fowler
Martin Fowler

Hacker News - Newest: "LLM"

GitHub - lechmazur/position_bias: A benchmark for testing whether LLM judges keep the same preference when two lightly edited versions of the same story are shown in opposite orders. Flex routing (EU and EFTA) Dark Factories: Retooling for LLM Velocity Ask HN: What would be the impact of a LLM output injection attack? GitHub - AronDaron/dataset-generator: No-code desktop app for generating high-quality synthetic datasets to fine-tune LLMs — plan-then-execute pipeline, LLM-as-judge, HuggingFace upload. GitHub - Oaklight/llm-rosetta: Production-ready LLM API translation layer for Python — bidirectional conversion between OpenAI, Anthropic & Google formats via hub-and-spoke IR. Optional API gateway. Streaming & non-streaming. Zero core deps. Contributions welcome! GitHub - browser-use/browser-harness: Self-healing browser harness that enables LLMs to complete any task. GitHub - moeen-mahmud/remen: Remen turns thoughts into something you can return to Analyzing 156 LLM Launch Posts on Hacker News ChatGPT vs Gemini vs Claude: The Best LLM Subscription You Should Buy GitHub - salaamalykum/quran-semantic-search: High-density RAG Semantic Search Engine & Quran Corpus (GEO/SEO Architecture) GitHub - NVIDIA/TensorRT-LLM: TensorRT LLM provides users with an easy-to-use Python API to define Large Language Models (LLMs) and supports state-of-the-art optimizations to perform inference efficiently on NVIDIA GPUs. TensorRT LLM also contains components to create Python and C++ runtimes that orchestrate the inference execution in a performant way. The State of LLM Bug Bounties in 2026 Operational Readiness Criteria for Tool-Using LLM Agents Meshcore: Architecture for a Decentralized P2P LLM Inference Network How an LLM becomes more coherent as we train it GitHub - seetrex-ai/laimark GitHub - Jossifresben/BibCrit: AI-assited biblical textual criticism GitHub - wastedcode/memex: File system based wiki, maintained by Claude 99helpers.com GitHub - cliver-project/AITrigram GitHub - unbody-io/adapt: A self-evolving memory layer for AI agents. GitHub - hb20007/awesome-gen-ai-fails: A list of incidents where reliance on generative AI and LLMs resulted in harm to companies, individuals, or society GitHub - nevenkordic/localmind: Run any local LLM with persistent memory and context. CLI agent over Ollama with SQLite-backed hybrid recall. No cloud. Ask HN: What are the machine requirements for a LLM like Llama-3.1-8B? Faster LLM Inference via Sequential Monte Carlo grpo explained: group relative policy optimization for llm finetuning - cgft Andrej Karpathy's LLM Wiki Is a Bad Idea GitHub - GG-QandV/mnemostroma: Offline RAM-first cognitive leer/coprocessor for AI agents and robotics. Solves "Context Abandonment" with 20-80ms latency using a dual-thread biomimetic memory architecture (ONNX + SQLite WAL). mempalace/agent at agent · skorotkiewicz/mempalace
Stop comparing price per million tokens: the hidden LLM A...
vrm · 2026-04-17 · via Hacker News - Newest: "LLM"

· Gabriel Bianconi

Most engineers know they need to evaluate models on their specific task because performance varies. But so does cost: the same input can cost several times more on one provider than another, even when their list prices look similar.

The typical metric for comparing LLM API costs is price per million tokens ($/MTok). Here’s what the major providers charge today:

Model$/MTok (input)
gemini-3.1-pro-preview$2.00
gpt-5.4$2.50
claude-sonnet-4-6$3.00
claude-opus-4-6$5.00
claude-opus-4-7$5.00

But not all tokens are equal! Different providers use different tokenizers, so the same input produces wildly different token counts.

What is a tokenizer?

A tokenizer splits text into smaller units (tokens) that the LLM processes. Different tokenizers split the same text differently, producing different token counts.

For example, gpt-5.4 uses the tokenization below:

We sent identical inputs through each provider’s official token counting API and normalized against OpenAI’s:

Grouped bar chart showing token counts normalized to OpenAI across content types
ModelTextYAMLJSONTools
gpt-5.41.00x1.00x1.00x1.00x
gemini-3.1-pro-preview1.06x1.18x1.11x1.82x
claude-sonnet-4-61.17x1.25x1.22x2.06x
claude-opus-4-61.17x1.25x1.22x2.06x
claude-opus-4-71.57x1.53x1.70x2.65x
Details about the input data

We used the following input data for this experiment:

TypeSource
TextThe Iliad
JSON & YAMLCloudflare’s OpenAI Spec (trimmed to 2 million characters)
Tools100 synthetically generated tools (name, description, schema)

Multiplying list price by tokenizer efficiency gives you what you actually pay to process the same input.

Grouped bar chart showing effective price per million input tokens adjusted for tokenizer differences
ModelTextYAMLJSONTools
gpt-5.4$2.50
(1.00x)
$2.50
(1.00x)
$2.50
(1.00x)
$2.50
(1.00x)
gemini-3.1-pro-preview$2.12
(0.85x)
$2.36
(0.94x)
$2.22
(0.89x)
$3.64
(1.46x)
claude-sonnet-4-6$3.51
(1.40x)
$3.75
(1.50x)
$3.66
(1.46x)
$6.18
(2.47x)
claude-opus-4-6$5.85
(2.34x)
$6.25
(2.50x)
$6.10
(2.44x)
$10.30
(4.12x)
claude-opus-4-7$7.85
(3.14x)
$7.65
(3.06x)
$8.50
(3.40x)
$13.25
(5.30x)

The differences are dramatic. On tool-heavy workloads, claude-opus-4-7 costs 5.3x more than gpt-5.4 even though their list prices are only 2x apart. The rankings also flip depending on what you’re sending: Gemini is the cheapest option for text and structured data, but becomes 46% more expensive than OpenAI on tool definitions.

This analysis only considers base input token prices. In practice, cost comparisons get even more complex when you factor in prompt caching discounts, long-context pricing tiers, output tokens, and thinking tokens.

When choosing the right model for your task, you should compare both performance and cost in a real setting. A model that looks cheaper on paper might cost several times more once you account for how it counts tokens.


The only way to know what you’re actually paying is to measure it.

Our 11.2Kopen-source LLM gateway tracks real-world token usage and cost across providers. You can configure multiple variants and track usage and costs side by side.