You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Revise chapter3-1.md to improve clarity and structure in feedback mechanisms for RAG systems
- Enhanced formatting of notes, warnings, and examples for better readability and engagement.
- Clarified feedback collection strategies and their impact on user interaction.
- Improved consistency in presentation of feedback options and examples throughout the chapter.
Copy file name to clipboardExpand all lines: docs/workshops/chapter3-1.md
+31-17Lines changed: 31 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,19 +11,26 @@ author: Jason Liu
11
11
12
12
RAG systems improve most when they collect feedback effectively. Many implementations focus exclusively on the technical details of retrieval and generation while neglecting the infrastructure needed to collect and utilize user feedback.
13
13
14
-
!!! note "Building on Previous Chapters" - **[Chapter 1](chapter1.md)**: The evaluation framework you built provides the baseline - **[Chapter 2](chapter2.md)**: The fine-tuning techniques need feedback data to be effective
14
+
!!! note "Building on Previous Chapters"
15
+
- **[Chapter 1](chapter1.md)**: The evaluation framework you built provides the baseline
16
+
- **[Chapter 2](chapter2.md)**: The fine-tuning techniques need feedback data to be effective
15
17
16
18
This chapter shows you how to collect the data that powers continuous improvement.
17
19
18
20
In this chapter, we'll explore how to build effective feedback mechanisms that turn your RAG application from a static implementation into a continuously improving system. This approach creates a feedback loop where user interactions provide the data needed to make the system better.
19
21
20
22
!!! warning "The Invisible Feedback Problem"
21
-
Many RAG implementations hide feedback mechanisms in obscure UI locations or use generic "thumbs up/down" buttons that provide minimal insight. Users interact with these minimal feedback options less than 0.1% of the time, providing insufficient data for meaningful improvements.
23
+
Many RAG implementations hide feedback mechanisms in obscure UI locations or use generic "thumbs up/down" buttons that provide minimal insight. Users interact with these minimal feedback options less than 0.1% of the time, providing insufficient data for meaningful improvements.
22
24
23
25
In my consulting practice, I've seen that simply changing the copy from generic "How did we do?" to specific "Did we answer your question?" can increase feedback rates by **5x**. Well-designed feedback mechanisms don't just collect more data—they accelerate your entire improvement cycle, allowing you to fine-tune 5x faster and deploy with greater confidence.
24
26
25
27
!!! success "Effective Feedback Copy"
26
-
**5x Better Feedback Rates:** - ✅ "Did we answer your question?" - ✅ "Was this information helpful?" - ✅ "Did we take the correct actions?" (for action-oriented systems) - ❌ "How did we do?" - ❌ "Rate your experience"
28
+
**5x Better Feedback Rates:**
29
+
- ✅ "Did we answer your question?"
30
+
- ✅ "Was this information helpful?"
31
+
- ✅ "Did we take the correct actions?" (for action-oriented systems)
32
+
- ❌ "How did we do?"
33
+
- ❌ "Rate your experience"
27
34
28
35
**Context-Specific Examples:**
29
36
- For coding assistants: "Did this code solve your problem?"
@@ -46,7 +53,7 @@ This chapter focuses on the practical implementation of feedback mechanisms in R
46
53
The first principle of effective feedback collection is visibility. Your feedback mechanisms should be prominent and engaging, not hidden in dropdown menus or settings pages. Users should encounter feedback options naturally as part of their interaction flow.
47
54
48
55
!!! example "High-Visibility Feedback UI"
49
-
Consider the difference between these two approaches:
56
+
Consider the difference between these two approaches:
50
57
51
58
```
52
59
**Low Visibility:** A small thumbs up/down icon in the corner of the response
@@ -81,7 +88,7 @@ Here are several patterns for implementing high-visibility feedback mechanisms:
81
88
Each approach has advantages for different use cases. The key is to make feedback collection a natural part of the user experience rather than an afterthought.
82
89
83
90
!!! tip "Streaming and Perceived Performance"
84
-
**The Claude Progress Counter Effect:**
91
+
**The Claude Progress Counter Effect:**
85
92
86
93
Claude's implementation of progress counters during response generation serves multiple purposes:
87
94
- Shows "thinking" progress (e.g., "Analyzing document 3 of 5...")
@@ -116,7 +123,7 @@ For enterprise applications, especially when working with large customers who ha
116
123
This approach creates transparency and builds trust by showing customers that their feedback drives real improvements. This method typically increases feedback by 5x compared to traditional forms, while also improving customer retention.
117
124
118
125
!!! example "Enterprise Feedback Pattern"
119
-
**The Most Effective B2B Feedback Flow:**
126
+
**The Most Effective B2B Feedback Flow:**
120
127
121
128
1. **In-App Collection:**
122
129
- Binary feedback (thumbs up/down) for quick signals
@@ -142,14 +149,14 @@ This approach creates transparency and builds trust by showing customers that th
142
149
This pattern has helped teams achieve 30-40% feedback rates in enterprise settings.
143
150
144
151
!!! example "Slack Webhook Integration Code"
145
-

152
+

146
153
147
154
```
148
155
*This code integrates feedback collection with Slack, automatically posting negative feedback to a shared channel for immediate visibility and follow-up.*
149
156
```
150
157
151
158
!!! example "Feedback UI Implementation"
152
-

159
+

153
160
154
161
```
155
162
*This code renders a response with prominent feedback options, automatically showing a more detailed form if the user indicates the response wasn't fully helpful.*
@@ -160,7 +167,11 @@ This approach creates transparency and builds trust by showing customers that th
160
167
Generic feedback like thumbs up/down provides minimal insight for improvement. To make feedback truly actionable, segment it into specific aspects of your RAG pipeline.
161
168
162
169
!!! warning "The Problem with Generic Feedback"
163
-
A simple "thumbs down" could mean many things: - The retrieval system found irrelevant documents - The generation step produced inaccurate information - The answer was technically correct but poorly formatted - The answer was too brief or too verbose
170
+
A simple "thumbs down" could mean many things:
171
+
- The retrieval system found irrelevant documents
172
+
- The generation step produced inaccurate information
173
+
- The answer was technically correct but poorly formatted
174
+
- The answer was too brief or too verbose
164
175
165
176
```
166
177
Without knowing which aspect failed, you can't target improvements effectively.
By tracking these behaviors, you can identify patterns that indicate success or failure even when users don't provide explicit feedback.
203
214
204
215
!!! example "Implicit Feedback Collection"
205
-

216
+

206
217
207
218
```
208
219
*This code tracks key implicit feedback signals including query refinements, citation clicks, and engagement time, providing valuable data even when users don't explicitly rate responses.*
@@ -229,7 +240,7 @@ Consider these UI patterns specifically designed to help collect hard negative e
229
240
1.**Regeneration After Removal**: Allow users to remove citation sources and then regenerate the answer. Documents removed before regeneration become strong hard negative candidates for that query.
230
241
231
242
!!! example "Interactive Citations UI"
232
-

243
+

233
244
234
245
```
235
246
*This UI allows users to mark specific citations as relevant or irrelevant and regenerate answers, creating valuable training data for improving retrieval quality.*
@@ -261,7 +272,7 @@ There are several approaches to implementing citations in your RAG interface:
261
272
1.**Visual PDF overlays**: For document-based applications, highlighting the exact location in a PDF
262
273
263
274
!!! example "Markdown-based Citation Implementation"
264
-

275
+

265
276
266
277
```
267
278
*This code formats responses with clickable citations and builds a reference list that includes feedback options for each source, helping collect document-level relevance signals.*
@@ -281,12 +292,12 @@ This approach is particularly valuable for PDF-heavy domains like legal, medical
281
292
### Citation Implementation Patterns
282
293
283
294
!!! quote "Preventing Hallucinations"
284
-
Skylar Payne emphasizes that hallucination remains a critical challenge, especially in sensitive domains. His most effective approach: "Force the LLM to provide inline citations, validate that each citation exists in the retrieved documents, and semantically validate that each citation actually supports the claimed content."
295
+
Skylar Payne emphasizes that hallucination remains a critical challenge, especially in sensitive domains. His most effective approach: "Force the LLM to provide inline citations, validate that each citation exists in the retrieved documents, and semantically validate that each citation actually supports the claimed content."
285
296
286
297
This is particularly critical for healthcare, legal, and financial applications. [See more anti-patterns to avoid →](../talks/rag-antipatterns-skylar-payne.md)
287
298
288
299
!!! info "XML-Based Citation Pattern"
289
-
**The Most Robust Approach:**
300
+
**The Most Robust Approach:**
290
301
291
302
Instead of relying on markdown links or footnotes, use XML tags with start/end word anchoring:
292
303
@@ -312,7 +323,7 @@ Skylar Payne emphasizes that hallucination remains a critical challenge, especia
312
323
The ultimate goal of feedback collection is to guide your improvement roadmap. Rather than making enhancement decisions based on intuition or technical interest, you can prioritize based on user needs revealed through feedback.
313
324
314
325
!!! info "Production Monitoring: Beyond Basic Feedback"
315
-
Ben Hylak and Sidhant Bendre highlight a critical insight: "There's no exception being thrown when something goes wrong - the model simply produces an inadequate response." Their approach combines implicit signals (user frustration, task failures) with explicit signals (ratings, regenerations) to identify issues that traditional monitoring misses. The Trellis framework they present helps organize the "infinite chaos" of AI outputs into controllable segments. [Learn about production monitoring strategies →](../talks/online-evals-production-monitoring-ben-sidhant.md)
326
+
Ben Hylak and Sidhant Bendre highlight a critical insight: "There's no exception being thrown when something goes wrong - the model simply produces an inadequate response." Their approach combines implicit signals (user frustration, task failures) with explicit signals (ratings, regenerations) to identify issues that traditional monitoring misses. The Trellis framework they present helps organize the "infinite chaos" of AI outputs into controllable segments. [Learn about production monitoring strategies →](../talks/online-evals-production-monitoring-ben-sidhant.md)
316
327
317
328
A feedback-driven roadmap:
318
329
@@ -341,7 +352,10 @@ Remember that small UX changes can make enormous differences in feedback collect
341
352
342
353
In the next chapter, we'll explore how to reduce perceived latency through streaming and progressive responses, building on the feedback foundation to create a more engaging user experience.
343
354
344
-
!!! info "How This Chapter Connects Forward" - **[Chapter 4](chapter4-2.md)**: The feedback you collect enables query segmentation and analysis - **[Chapter 5](chapter5-1.md)**: User behavior patterns reveal which specialized retrievers to build - **[Chapter 6](chapter6-2.md)**: Feedback on router decisions improves tool selection
355
+
!!! info "How This Chapter Connects Forward"
356
+
- **[Chapter 4](chapter4-2.md)**: The feedback you collect enables query segmentation and analysis
357
+
- **[Chapter 5](chapter5-1.md)**: User behavior patterns reveal which specialized retrievers to build
358
+
- **[Chapter 6](chapter6-2.md)**: Feedback on router decisions improves tool selection
345
359
346
360
## Reflection Questions
347
361
@@ -374,7 +388,7 @@ Effective feedback collection is essential for systematic improvement of RAG sys
374
388
1.**Start Small**: Begin with simple, high-visibility feedback mechanisms and gradually add sophistication as you learn what works for your specific users and use cases.
375
389
376
390
!!! success "Quick Implementation Wins"
377
-
**Start with these patterns:**
391
+
**Start with these patterns:**
378
392
379
393
1. **Change your feedback copy** to "Did we answer your question?" (immediate 5x improvement)
380
394
2. **Add streaming progress indicators** to reduce perceived latency by 45%
0 commit comments