Lesson 4 of 4 Evaluating and Improving Multi-Agent Solutions

Running Continuous Improvement Loops

This lesson describes the continuous improvement loop, which turns production signals into measured changes, and two of its engines, semantic optimization and user feedback.

Learning outcomes

After completing this lesson, you will be able to:

  • Describe the five steps of the improvement loop.
  • Automate prompt improvement with a semantic optimization loop.
  • Collect explicit and implicit user feedback.

The improvement loop

The loop has five steps. Observe production through traces, continuous evaluation and feedback. Analyze failures and group them by cause (misunderstood intent, wrong tool, missing knowledge, guardrail block, model error). Propose changes to prompts, tools, retrieval, routing or models. Evaluate each change on the regression dataset with the same evaluators. Release the improvement through the normal pipeline and return to observing. Each confirmed failure becomes a new regression case so that it cannot silently return.

The following diagram shows the five steps as a loop.

The continuous improvement loop. Observe production through traces, continuous evaluation and feedback. Analyze failures and group them by cause. Propose changes to prompts, tools, retrieval, routing or models. Evaluate each change on the regression dataset with the same evaluators. Release through the normal pipeline and observe again. Each confirmed failure becomes a new regression case.
Each turn of the loop makes the regression dataset stronger.
Put in order

The improvement loop

Exam skills 3.2.3

Arrange the steps of the continuous improvement loop.

Log in to try this activity Interactive activities are free with an account.

Semantic optimization loops

A semantic optimization loop automates the propose and evaluate steps. A model reads failing cases and the current prompt (or tool descriptions) and proposes revised versions; each candidate is evaluated on a training split of the dataset; the best candidate is confirmed on a held-out split to avoid overfitting; and a person reviews the change before release. The loop optimizes meaning-level artefacts such as instructions, examples and descriptions, rather than model weights.

best, best_score = current_prompt, evaluate(current_prompt, train_set)
for round in range(5):
    failures = failing_cases(best, train_set)
    for candidate in propose_revisions(best, failures, n=4):          # model-generated rewrites
        score = evaluate(candidate, train_set)
        if score > best_score:
            best, best_score = candidate, score
holdout_gain = evaluate(best, holdout_set) - evaluate(current_prompt, holdout_set)   # confirm before review
Spot the bug

An optimization loop that fools itself

Exam skills 3.2.3

Find the lines that make this semantic optimization loop unreliable.

Log in to try this activity Interactive activities are free with an account.

User feedback loops

User feedback loops collect explicit signals (ratings, thumbs, comments) and implicit ones (rephrased questions, abandoned conversations, escalations, overrides by staff). Feedback is attached to traces so each signal links to the exact run. Negative feedback is triaged, confirmed failures are added to the regression set, and trends are monitored by intent and agent. Because explicit feedback is sparse and biased towards strong reactions, it is combined with sampled evaluations rather than used alone.

The following table summarizes the sources of improvement signals.

SignalSourceTypical use
Evaluator scoresContinuous evaluationDetect regressions and trends
Explicit feedbackRatings, thumbs, commentsFind failures users notice
Implicit feedbackRephrasing, abandonment, escalations, overridesFind silent failures
Synthetic testsSimulators, red teamingCover rare and adversarial cases
Sort into groups

Explicit or implicit feedback?

Exam skills 3.2.3

Classify each user signal.

Log in to try this activity Interactive activities are free with an account.
Worked example

Closing the loop

A support solution receives 2% thumbs-down feedback. The team has fixed several reported problems, but some recur after later releases.

Recurring problems mean fixes are not protected by tests. Each confirmed thumbs-down case should be added, with the expected behaviour, to the regression dataset that gates every release. Analysis should also group feedback by cause and agent to prioritize systemic fixes over individual patches.

Check yourself

What should happen to every confirmed failure?

Show answer

It becomes a regression case, so the same failure is caught automatically in future evaluations.

Exam Tips

Remember for the exam

  • Observe, analyze, propose, evaluate, release; every confirmed failure becomes a regression case.
  • Semantic optimization: model-proposed prompt revisions confirmed on a held-out set and reviewed.
  • Combine sparse explicit feedback with implicit signals and sampled evaluation.