Context Compression for Production AI Agents: From Message Trimming and Tool-Result Cleanup to Hermes Agent's Layered Compaction

This article systematically explains context-compression methods for production AI agents, distinguishing message trimming, tool-result cleanup, artifact externalization, structured summaries, and native compaction. Using Hermes Agent, LangChain v1, and LangGraph v1, it presents a layered implementation and evaluation approach.

July 26, 2026 · 17 min · 3452 words · Andy SI
Read more

What Did Tencent AI Leader Shunyu Yao Discuss in This Podcast?

Drawing on Latent Space’s interview with Shunyu Yao, this article reviews ReAct, Reflexion, Tree of Thoughts, memory, benchmarks, ACI, and Agent UX, and summarizes the importance of tools, environments, evaluation, and interface design when putting AI agents into practice.

May 24, 2026 · 15 min · 2983 words · Andy SI
Read more

When an LLM's Inner State and Its Words Diverge: A Master Key to Understanding LLM Behavior

Using the bandwidth gap between hidden states and tokens, this article offers one explanation for LLM engineering phenomena such as Chain of Thought, prompt length, few-shot learning, personality drift, and hallucinations.

May 2, 2026 · 16 min · 3265 words · Andy SI
Read more

Entropy in LLMs: A Unifying Language from Training to Inference and Products

This article connects cross-entropy, perplexity, temperature, conditional entropy, hallucination detection, and prompt constraints into one line of reasoning, showing how entropy provides a unified language for understanding LLM training, inference, and product design. It also explains entropy’s practical value in RAG and engineering governance.

March 27, 2026 · 6 min · 1263 words · Andy SI
Read more

The Complete Best-Practices Guide to Prompt Engineering

A long-form Prompt Engineering guide for AI application engineers, covering foundational principles, context design, task chains, injection defenses, agent prompt design, and evaluation-driven development.

March 11, 2026 · 19 min · 4045 words · Andy SI
Read more

The Complete Guide to LLM Chain-of-Thought (CoT)

Understand what LLM Chain-of-Thought (CoT) is and how prompt engineering can elicit Chain-of-Thought (CoT) from an LLM.

March 4, 2026 · 12 min · 2430 words · Andy SI
Read more

Prompt Engineering: From Principles to Practice

Prompt engineering? It may not be as simple as you think.

March 3, 2026 · 20 min · 4215 words · Andy SI
Read more

Prompt Injection

Understand LLM prompt injection and several fundamental defensive measures.

March 3, 2026 · 11 min · 2278 words · Andy SI
Read more