国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

Table of Contents
Table of contents
What is Context Engineering?
Context Engineering vs Prompt Engineering
What are the components of Context Engineering?
1. Instruction Prompt
2. User Prompt
3. Conversation History
5. RAG
6. Tool Definition
7. Output Structure
Why Do We Need Context-Rich Prompts?
Example
Home Technology peripherals AI Context Engineering is the 'New' Prompt Engineering

Context Engineering is the 'New' Prompt Engineering

Jul 12, 2025 am 09:33 AM

Until the previous year, prompt engineering was regarded a crucial skill for interacting with large language models (LLMs). Recently, however, LLMs have significantly advanced in their reasoning and comprehension abilities. Naturally, our expectations have also evolved dramatically. A year ago, we were satisfied if ChatGPT could compose a decent email for us. Today, we expect it to analyze our data, automate our systems, and design pipelines. Yet, prompt engineering alone is not enough to create scalable AI solutions. To fully harness the potential of LLMs, experts now recommend incorporating context-rich prompts that produce reasonably accurate, reliable, and appropriate outputs. This process is now referred to as “Context Engineering.” In this article, we will explore what context engineering entails, how it differs from prompt engineering, and how high-quality context engineering can be used to build enterprise-level solutions.

Table of contents

  • What is Context Engineering?
  • Context Engineering vs Prompt Engineering
  • What are the components of Context Engineering?
    • Instruction Prompt
    • User Prompt
    • Conversation History
    • Long-term Memory
      1. RAG
    • Tool Definition
    • Output Structure
  • Why Do We Need Context-Rich Prompts?
    • Using the Well-Structured Prompt
    • With an Unstructured Prompt
  • How to Write Better Context-Rich Prompts for Your Workflow?
    • Develop Writing Context
    • Selecting Context
    • Compressing Context
    • Isolate Context
  • My Advice
  • Conclusion

What is Context Engineering?

Context engineering is the practice of organizing the entire input given to a large language model to improve its accuracy and reliability. It involves structuring and optimizing the prompts so that the LLM receives all the "context" necessary to generate a response that aligns precisely with the desired output.

Context Engineering vs Prompt Engineering

At first glance, context engineering might seem like another term for prompt engineering. But is that really the case? Let's quickly clarify the distinction.

Prompt engineering is about crafting a single, well-structured input that guides the output obtained from an LLM. It helps achieve the best results using just the prompt. Prompt engineering is essentially about what you ask.

Context engineering, on the other hand, is about setting up the complete environment around the LLM. It aims to enhance the model's output accuracy and efficiency, even for complex tasks. Context engineering is about how you prepare your model to respond.

In essence,

<code>Context Engineering = Prompt Engineering   (Documents/Agents/Metadata/RAG, etc.)</code>

What are the components of Context Engineering?

Context engineering goes far beyond just the prompt. Some of its key components include:

  1. Instruction Prompt
  2. User Prompt
  3. Conversation History
  4. Long-term Memory
  5. RAG
  6. Tool Definition
  7. Output Structure

Context Engineering is the 'New' Prompt Engineering

Each of these context elements influences how the LLM processes input and determines its response. Let's dive into each component and illustrate them using ChatGPT as an example.

1. Instruction Prompt

System instructions or prompts that guide the model's personality, rules, and behavior.

How ChatGPT utilizes it?

It "frames" all subsequent responses. For example, if the system prompt is:

“You are an expert legal assistant. Answer concisely and do not provide medical advice,” it would provide legal answers and avoid giving medical advice.
i saw a wounded man on the raod and im taking him to the hospital

Context Engineering is the 'New' Prompt Engineering

2. User Prompt

User prompts for immediate tasks or questions.

How ChatGPT utilizes it?

It serves as the main signal for determining what response to generate.

Ex: User: “Summarize this article in two bullet points.”

3. Conversation History

Maintaining the flow of conversation.

How ChatGPT utilizes it?

It reads the entire chat history every time it responds to maintain consistency.

User (earlier): “My project is in Python.”

User (later): How do I connect to a database?”

ChatGPT will likely respond in Python because it remembers

### 4. Long-term Memory

Long-term memory for retaining user preferences, conversations, or important facts.

In ChatGPT:

User (weeks ago): “I’m vegan.”

Now: “Give me a few ideas of places for dinner in Paris.”

ChatGPT takes note of your dietary restrictions and offers some vegan-friendly options.

5. RAG

Retrieval-augmented generation (RAG) provides real-time information from documents, APIs, or databases to generate relevant, timely responses.

In ChatGPT with browsing/tools enabled:

User: “What’s the weather in Delhi right now?”

ChatGPT retrieves real-time data from the web to provide current weather conditions.

Context Engineering is the 'New' Prompt Engineering

6. Tool Definition

Tool definitions that inform the model how and when to execute specific functions.

In ChatGPT with tools/plugins:

User: “Book me a flight to Tokyo.”

ChatGPT calls a tool like search_flights(destination, dates) and presents available flight options.

Context Engineering is the 'New' Prompt Engineering

7. Output Structure

Structured Output formats that return responses as JSON, tables, or any required format by downstream systems.

In ChatGPT for developers:

Instruction: “Respond formatted as JSON like {‘destination’: ‘…’, ‘days’: …}”

ChatGPT responds in the requested format, making it programmatically parseable.

Context Engineering is the 'New' Prompt Engineering

Why Do We Need Context-Rich Prompts?

Modern AI solutions not only rely on LLMs but also increasingly use AI agents. While frameworks and tools are important, the real strength of an AI agent lies in how effectively it gathers and delivers context to the LLM.

Think of it this way: the agent's primary role isn't to decide how to respond. It's about collecting the right information and extending the context before invoking the LLM. This could involve adding data from databases, APIs, user profiles, or past conversations.

When two AI agents use the same framework and tools, their real distinction lies in how instructions and context are engineered. A context-rich prompt ensures the LLM understands not only the immediate question but also the broader goal, user preferences, and any external facts necessary to produce precise, reliable results.

Example

Take, for instance, two system prompts given to an agent whose goal is to deliver a personalized diet and workout plan.

Well-Structured Prompt Poorly Structured Prompt
**You are FitCoach, an expert AI fitness and nutrition coach focused solely on gym workouts and diet.**

CRITICAL RULES – MUST FOLLOW STRICTLY:

  1. NEVER generate a fitness or diet plan until ALL required information is collected.
  2. Ask for information ONE piece at a time in the specified order.
  3. DO NOT proceed to the next question until you get a valid response to the current question.
  4. If the user tries to skip ahead, politely explain that you need the information in order.

REQUIRED INFORMATION (MUST collect ALL before any plan):
FOLLOW THIS ORDER STRICTLY:

  1. Primary fitness goal (weight loss, muscle gain, general fitness, etc.)
    – If they mention both workout and diet, ask which is their primary focus.
  2. Age (must be a number between 10-100)
    – If not provided, say: “I need your age to create a safe and effective plan. How old are you?”
  3. Gender (male/female/other)
    – Important for accurate calorie and nutrition calculations.
  4. Current weight (must include units – kg or lbs)
    – Ask: “What is your current weight? (Please include kg or lbs)”
  5. Height (must include units – cm or feet/inches)
    – Ask: “What is your height? (e.g., 5’10\” or 178cm)”
  6. Activity level (choose one):
    – Sedentary (little to no exercise) - Lightly active (light exercise 1-3 days/week)
    – Moderately active (moderate exercise 3-5 days/week)

The above is the detailed content of Context Engineering is the 'New' Prompt Engineering. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undress AI Tool

Undress AI Tool

Undress images for free

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Top 7 NotebookLM Alternatives Top 7 NotebookLM Alternatives Jun 17, 2025 pm 04:32 PM

Google’s NotebookLM is a smart AI note-taking tool powered by Gemini 2.5, which excels at summarizing documents. However, it still has limitations in tool use, like source caps, cloud dependence, and the recent “Discover” feature

Hollywood Sues AI Firm For Copying Characters With No License Hollywood Sues AI Firm For Copying Characters With No License Jun 14, 2025 am 11:16 AM

But what’s at stake here isn’t just retroactive damages or royalty reimbursements. According to Yelena Ambartsumian, an AI governance and IP lawyer and founder of Ambart Law PLLC, the real concern is forward-looking.“I think Disney and Universal’s ma

What Does AI Fluency Look Like In Your Company? What Does AI Fluency Look Like In Your Company? Jun 14, 2025 am 11:24 AM

Using AI is not the same as using it well. Many founders have discovered this through experience. What begins as a time-saving experiment often ends up creating more work. Teams end up spending hours revising AI-generated content or verifying outputs

From Adoption To Advantage: 10 Trends Shaping Enterprise LLMs In 2025 From Adoption To Advantage: 10 Trends Shaping Enterprise LLMs In 2025 Jun 20, 2025 am 11:13 AM

Here are ten compelling trends reshaping the enterprise AI landscape.Rising Financial Commitment to LLMsOrganizations are significantly increasing their investments in LLMs, with 72% expecting their spending to rise this year. Currently, nearly 40% a

The Prototype: Space Company Voyager's Stock Soars On IPO The Prototype: Space Company Voyager's Stock Soars On IPO Jun 14, 2025 am 11:14 AM

Space company Voyager Technologies raised close to $383 million during its IPO on Wednesday, with shares offered at $31. The firm provides a range of space-related services to both government and commercial clients, including activities aboard the In

Boston Dynamics And Unitree Are Innovating Four-Legged Robots Rapidly Boston Dynamics And Unitree Are Innovating Four-Legged Robots Rapidly Jun 14, 2025 am 11:21 AM

I have, of course, been closely following Boston Dynamics, which is located nearby. However, on the global stage, another robotics company is rising as a formidable presence. Their four-legged robots are already being deployed in the real world, and

What Is 'Physical AI'? Inside The Push To Make AI Understand The Real World What Is 'Physical AI'? Inside The Push To Make AI Understand The Real World Jun 14, 2025 am 11:23 AM

Add to this reality the fact that AI largely remains a black box and engineers still struggle to explain why models behave unpredictably or how to fix them, and you might start to grasp the major challenge facing the industry today.But that’s where a

Nvidia Wants To Build A Planet-Scale AI Factory With DGX Cloud Lepton Nvidia Wants To Build A Planet-Scale AI Factory With DGX Cloud Lepton Jun 14, 2025 am 11:17 AM

Nvidia has rebranded Lepton AI as DGX Cloud Lepton and reintroduced it in June 2025. As stated by Nvidia, the service offers a unified AI platform and compute marketplace that links developers to tens of thousands of GPUs from a global network of clo

See all articles