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

推荐订阅源

B
Blog RSS Feed
Spread Privacy
Spread Privacy
T
Threatpost
C
Cisco Blogs
P
Palo Alto Networks Blog
AI
AI
Cyberwarzone
Cyberwarzone
NISL@THU
NISL@THU
P
Privacy & Cybersecurity Law Blog
G
GRAHAM CLULEY
Simon Willison's Weblog
Simon Willison's Weblog
T
Tor Project blog
Latest news
Latest news
AWS News Blog
AWS News Blog
D
Docker
S
SegmentFault 最新的问题
博客园 - 聂微东
WordPress大学
WordPress大学
Vercel News
Vercel News
S
Securelist
爱范儿
爱范儿
J
Java Code Geeks
Know Your Adversary
Know Your Adversary
S
Schneier on Security
Hugging Face - Blog
Hugging Face - Blog
F
Fortinet All Blogs
Last Week in AI
Last Week in AI
D
DataBreaches.Net
宝玉的分享
宝玉的分享
D
Darknet – Hacking Tools, Hacker News & Cyber Security
MongoDB | Blog
MongoDB | Blog
Engineering at Meta
Engineering at Meta
K
Kaspersky official blog
美团技术团队
博客园 - 叶小钗
阮一峰的网络日志
阮一峰的网络日志
量子位
博客园_首页
Attack and Defense Labs
Attack and Defense Labs
S
Secure Thoughts
Google Online Security Blog
Google Online Security Blog
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
腾讯CDC
T
Threat Research - Cisco Blogs
雷峰网
雷峰网
有赞技术团队
有赞技术团队
www.infosecurity-magazine.com
www.infosecurity-magazine.com
P
Privacy International News Feed
S
Security Affairs

Redis

Real-Time Fraud Detection: Latency, Features & Scale Context window in AI: why every token is a budget decision Redis Data Integration in Redis Cloud is now GA in AWS | Redis Why AI Misses Business Context & How Teams Fix It AI Reasoning Explained: Why Context Matters Semantic Layer vs Context Layer: Key Differences Redis array data type: How it works and when to use it Context Graphs vs. Vector Search: When RAG Falls Short What’s new in two – May 2026 edition Redis 8.8 performance improvements: Faster string, hash, streams, SCAN & more Redis 8.8: New array data structure & open source features How Conflict-free Replicated Data Types power active-active database replication Context Orchestration: What It Is & How It Works Context Compaction for AI Agents: A Complete Guide Prompt Bloat: Causes, Costs & Fixes for LLM Apps Agentic Retrieval Techniques: A Complete Guide Single-shot reliable consumers with XREADGROUP CLAIM in Redis 8.4 | Redis Long-Horizon AI Agents: Memory & State Infrastructure What is a context engine? What Is a Context Layer? AI Agent Infrastructure Context Retrieval for AI Agents: What It Is & Why It Matters Context Poisoning: How Bad Data Breaks Agent Reasoning Context is all you need: Introducing Redis Iris | Redis Context Engineering for AI: What It Is & How to Build It Dynamic endpoints: Migrate databases without changing your endpoint | Redis AI Shopping Assistants: How They Work & What to Build Endless Aisle Retail: Infrastructure & Real-Time Data LLM Speed Benchmarks: Metrics & Infrastructure Guide Context Pruning: Cut LLM Tokens Without Losing Quality What’s new in two – April 2026 edition Agentic AI Architecture: 5 Patterns Explained AI Agent vs Chatbot: Key Differences Explained Advantages of Building a Vector Search Solution API Latency in LLM Apps: Causes & How to Fix It Security advisory: [CVE‑2026‑23479] [CVE‑2026‑25243] [CVE-2026-25588] [CVE‑2026‑25589] [CVE-2026-23631] | Redis Edge Computing Latency: Causes & How to Reduce It AI Agents vs Workflows: When to Use Each Streaming LLM Responses: Make Your AI App Feel Fast Active-Active vs Active-Passive Database Architecture Prefill vs Decode: LLM Inference Phases Explained Long-Term Memory Architectures for AI Agents Time to First Byte Test: Tools, Causes & Fixes Speculative decoding: how it works & when to use it P95 Latency: What It Is & Why It Matters Why Multi-Agent LLM Systems Fail & How to Fix Them AI Human in the Loop: Production Oversight Patterns Native OpenTelemetry metrics for Redis client libraries | Redis Client-side geographic failover for Redis Active-Active | Redis Use Redis with SQL | Redis Introducing Redis Feature Form Build Google ADK Agents with persistent, real-time memory on Redis | Redis Startup Spotlight: Neuron Systems API Throttling: Algorithms, Patterns & Mistakes Agentic AI Examples Across 6 Industries Best Chunking Strategies for RAG Pipelines Agentic AI Guardrails: Controls That Work Redis joins AWS at GDC to support the next generation of gaming | Redis Designing a semantic routing system: From static rules to dynamic intelligence with Redis and Java | Redis Real-Time Dispatch System: A Complete Guide P99 Latency: What It Means & How to Fix It Tokenization in LLMs: What AI App Devs Need to Know TTFT Meaning: What is Time to First Token? Atomic slot migration with Redis 8.4 Hybrid search benefits: Why your RAG system needs both keyword & vector search What’s new in two: March 2026 edition Vector embedding generators: How they work & how to use them Throughput-optimizing Redis for L2 KV Cache Reuse What is a data pipeline? Building AI agent pipelines that don't forget, fail, or fall apart Redis achieves Google Cloud Ready, Distributed Cloud status ahead of Google Cloud Next ‘26 | Redis Real-time network monitoring: what your data platform needs to keep up AI agent API: How agents connect to the real world What is multicloud infrastructure? A guide for 2026 What is a transaction monitoring system & how does it work? Why your AI agent fails in production & how tracing helps AI agent benchmarks: Where they fall short & why your infrastructure matters What is a JSON database (and when should you use one)? Introducing the Redis Partner Network: A new foundation for real-time innovation How real-time customer segmentation works in retail Payment orchestration & vault architecture in retail Agentic systems vs. GenAI: when generation isn't enough What is fuzzy matching? Semantic caching & routing: two powerful patterns for vector classification Redis alternatives: Why there are no exact substitutes Connect to Azure Managed Redis with Redis Insight 3.2.0 How to tame the thundering herd problem Redis to Manage Storage Replication | Redis How hierarchical navigable small world (HNSW) algorithms can improve search | Redis How leading financial institutions use Redis to drive growth | Redis What’s new in two: May 2025 | Redis Introducing Model Context Protocol (MCP) for Redis | Redis Redis vs. Elasticsearch: What’s faster for GenAI & vector search? | Redis Build fast, production-worthy AI apps with Spring AI and Redis | Redis Azure Managed Redis is GA today | Redis Redis then & now: Adapting with developers through every era | Redis Supercharge Your AI with OpenShift AI and Redis: Unleash speed and scalability | Redis What’s new in two: April 2025 | Redis Redis 8 is now GA, loaded with new features and more than 30 performance improvements | Redis What is a data strategy? 6 key components explained Data replication explained: types, examples & use cases
Context engineering vs prompt engineering: the difference
Redis · 2026-06-23 · via Redis

A customer asks your support agent whether their refund went through. The agent checks, says yes, and cites a confirmation number. The refund actually bounced back twenty minutes ago, but the lookup the agent ran hit a store that only syncs overnight. You tighten the system prompt: "always confirm the latest transaction status before answering." Next ticket, same failure, because the prompt was never the problem. The data the agent reached for was already stale.

This is the trap that catches most teams shipping agents. When the output is wrong, the reflex is to rewrite the prompt, but the prompt is rarely where the failure lives. It lives in everything around the prompt: the data and history the agent draws on at the moment it answers.

Prompt engineering earned its reputation on single-turn, bounded tasks, where everything the model needed fit in one well-worded request. Production AI agents broke that assumption. This guide covers what context engineering and prompt engineering mean, why better prompts stopped moving the needle on production agents, and why stale or fragmented context is an infrastructure problem that prompt changes alone usually won't fix.

Prompt engineering is the craft of writing what you hand a model: the system message, examples, and formatting cues that steer its behavior. Done well, it reliably improves output, and it's still worth doing. The catch is scope. A prompt steers a single model call, but an agent strings many calls together.

Context engineering is broader. It's the set of strategies for curating and maintaining tokens during LLM inference, covering everything in the context window outside the prompt: retrieved documents, memory, tool outputs, and user state. The line is clean: prompt engineering is about how you instruct the model; context engineering is about what the model knows when it answers. The prompt is one input among many, which makes prompt engineering a piece of context engineering, not the reverse.

Redis Iris

Redis Iris serves agent context in milliseconds

Redis Iris connects memory, live data, and retrieval in one place.

Why prompt engineering stops scaling for production AI agents

Prompting was great when tasks were single-turn and everything the model needed fit in one prompt. Multi-step agents blew right past that. An agent orchestrates many LLM calls and tool invocations, and when something goes wrong, you're not tuning a sentence anymore. You're debugging how the whole system behaved across steps.

A prompt is also written once, at build time, but the agent runs against inputs you never saw when you wrote it. You can tune the instructions perfectly for the phrasings in your test set, yet real users won't phrase things that way. The same underlying request arrives a hundred different ways, and models can be sensitive to superficial paraphrasing, so an agent that handles "I want to cancel my subscription" can still stumble on "please end my plan." No fixed wording anticipates every variant. The same goes for what the prompt depends on: schemas and tool interfaces change, so an agent that breaks when a database query returns columns in a different order has a structural weakness, not a wording one. And prompts drift as models get updated, so tuning work rarely survives the next version bump.

The failures that show up most often in production aren't ones a better prompt can touch. They live in the machinery around it:

  • Bloated tool sets: Hand an agent too many tools and it often picks the wrong one because the decision surface is too wide.
  • Missing memory: For agents that converse or act over multiple steps, prompt engineering alone falls short, because the model doesn't remember anything beyond its context window.
  • Broken retrieval: Even a perfect prompt can't compensate for a broken retrieval system or an incomplete information pipeline.

The throughline: when a production agent breaks, the cause usually sits in the context around the prompt, not the model.

The three parts of an agent's context window

Context is more than the documents you retrieve. It breaks into three buckets, each filling the window for a different reason:

  • Instructions: Prompts, system messages, few-shot examples, and tool descriptions, the standing rules that shape how the agent behaves.
  • Knowledge: Facts and retrieved information the model wasn't trained on, including retrieval-augmented generation (RAG) results.
  • Tools: Definitions of the external functions, APIs, and Model Context Protocol (MCP) servers the agent can call.

Together these three are everything the model has to reason with on a given call. It knows nothing else: not the request it handled a minute ago, not the record that changed since the window was built. So where does all of it come from?

Context is assembled at runtime, not written at design time

Context comes from code that runs just before the model does. On every call, that code assembles the window fresh: it retrieves the relevant documents, loads the right slice of memory, attaches the tools the agent might need, and trims whatever won't fit. A prompt is fixed the moment you write it, so it can't do any of this on its own. The assembly step is what reaches live sources, like vector databases, APIs, and memory stores, and turns them into the window the model actually reasons over. Done well, it's as much about what you leave out as what you include, and doing it fast enough to stay inside an agent's latency budget is its own infrastructure problem.

Redis Vector Database

Build agents that remember, not agents that guess

Redis Iris gives every agent fresh context and long-term memory.

Stale & fragmented context is an infrastructure problem

Assembling good context is harder than it sounds, because the data an agent needs is rarely fresh, fast, or in one place. The failures look like this: agents make confident, coherent-sounding decisions based on data that's three days old, or rerun expensive workflows they already completed. These are data problems, and they show up in two ways.

The first is freshness. Most data stacks were built for human consumers: batch analytics, periodic dashboards, daily refreshes. Agents need fresher data than that. In an observe-decide-act loop, when the second observation returns outdated state, the agent re-plans and burns tokens. An agent making a purchasing decision on stale inventory data is an expensive business risk.

The second is fragmentation. Customer records, policies, and product details each live in a different system, and fast-changing operational data is spread across APIs, databases, and software-as-a-service (SaaS) tools. Pulling all of it into one coherent window, fast enough and for thousands of concurrent users at once, is a concurrency, consistency, and durability problem. None of that is solved at the prompt or the model. It's solved in the layer that does the assembling.

What a context engine does for AI agents

A context engine is the infrastructure layer that does the assembly. Production agent performance depends as much on it as on the model itself, spanning retrieval, memory, caching, and freshness. The pattern looks like User → Context Engine → Agents → Tools, with the engine on the hook for memory management across sessions and agents, task routing, tool boundary enforcement, token budget management with automatic pruning, and consistency, so a decision made by one agent is visible to all the others. Redis Iris is built for exactly this, bringing Context Retriever, Agent Memory, LangCache, Redis Data Integration, and Redis Search together as one runtime for agent context.

A few capabilities matter most. In a semantic retrieval flow, the app embeds the query, uses vector search to pull the most similar chunks, and passes those chunks to the model as context, the job Context Retriever handles. LangCache adds semantic caching: it matches incoming queries against previous ones using vector embedding similarity instead of exact string matching, so a sufficiently similar query returns a cached response without another LLM call, which lowers cost and tail latency. One evaluation reported that semantic caching cut API calls by up to 68.8% across tested query categories. Agent Memory handles the short-term and long-term split, with consolidation rules deciding what gets promoted.

The consolidation argument is what makes this an engine rather than a checklist. Memory and retrieval depend on each other, and keeping them on one layer avoids the dual-write problem and the drift that creeps in when two stores fall out of step. It also addresses a failure no prompt can reach: an agent that remembers your name but fabricates account balances.

Context, not prompts, is the bottleneck in production AI

The practitioner workflow has shifted. Teams stopped asking "how do I phrase this better?" and started asking "what does this model need to know at every step to behave the way I want?" A new role has emerged, the context engineer, whose work spans retrieval pipelines, memory systems, tool design, and evaluation, closer to systems engineering than to prompt writing. The reliability gains tend to follow from that architecture work rather than from sharper phrasing.

Prompt engineering still matters as one input, but in production agents, most of what breaks happens outside the prompt, in retrieval, memory, tool selection, and data freshness. Fixing those means working on the infrastructure that assembles context, not the wording fed in.

Redis Iris is built as a real-time context engine for fast context assembly across vector search, semantic caching, agent memory, and fresh operational data. Instead of stitching together a separate vector database, memory service, cache, and data-pipeline glue, Iris brings those pieces into one platform, which cuts the synchronization failures of coordinating separate stores and helps your agents stay coherent across sessions.

If your agent works in the demo but falls apart in production, the next thing to fix probably isn't the prompt. Try Redis Iris to build on a real-time context layer, or talk to our team about consolidating your AI infrastructure.

Redis Cloud

Fresh context, every call

Redis Iris keeps agent data current so answers stay accurate.