To build an AI utility function, start by deciding what “better” means for the choice at hand. For a restaurant recommendation, that might mean finding a quick, affordable meal that also fits a diner’s dietary needs and is worth the trip. The function makes those human priorities explicit so a system can compare options against them.
What the restaurant exercise is asking you to do
The exercise, presented in a 2024 document hosted by the Government of Peru, asks participants to build a utility function for recommending where to eat. It frames the goal as a meal that is quick, cheap, and “good enough,” then offers possible criteria such as value, price, dietary needs, promotions, location, employee treatment, family-friendliness, accessibility, parking, noise, reviews, service, cuisine, ambiance, food quality, freshness, and hygiene. The presentation is the closest located match to the exercise title; it does not establish that the exact title is a separate published article or course.
Why one measure is not enough
A recommendation based only on the lowest price might fail someone with a dietary restriction. One based only on travel time might overlook accessibility, cleanliness, or food quality. The “best” choice therefore depends on the person’s goals and the trade-offs they are willing to accept.
Bill Schmarzo describes an AI utility function as a deliberate, weighted definition of what counts as better across the dimensions of value a person cares about. In that framing, a human defines the objective and AI optimizes against it. His route-choice example illustrates the point: someone may prefer a safer, calmer drive over the fastest arrival. Schmarzo’s explanation of AI utility functions provides related context.
#1 Best Overall
How to build a utility function for the restaurant choice
- Define the decision. State the choice clearly: for example, select a restaurant for a quick, affordable meal.
- Choose relevant criteria. Use only factors that matter to the diners. Possible prompts include price or value, dietary fit, distance, accessibility, food quality and freshness, cleanliness, service, and ambiance or noise.
- Discuss conflicts. Ask what the group would trade off. Is a farther restaurant acceptable if it better meets dietary needs? Would diners pay more for better accessibility or food quality?
- Set relative importance. Assign weights to indicate how much each criterion should matter. A weight is a human priority expressed in a form an optimization process can use; it is not an objective fact about the restaurant.
- Compare options and inspect the result. Apply the chosen criteria and weights to the available choices, then check whether the resulting recommendation reflects the group’s actual priorities.
The exercise’s criteria are prompts for discussion, not a calibrated scoring rubric. The presentation does not supply measurement methods, fixed weights, or a tested formula, so a group must decide how it will score each factor before treating any total as meaningful.
What a weighted score can—and cannot—tell you
Weighting makes chosen priorities computable, but it does not show that the priorities are complete, fair, or appropriate. A score can appear precise while leaving out an important concern, or while hiding a trade-off participants have not agreed to. Review the criteria and weights as human decisions, not as proof that the highest-scoring restaurant is universally best.
Rank #2
Schmarzo’s wider framing moves from prediction, to defining what matters, to making those values computable through weights. He says he introduced the AI Utility Function concept in his book The AI-Human Edge. His LinkedIn post on the series summarizes that progression.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.What Part 1 establishes
The located presentation provides a restaurant scenario and a broad set of candidate criteria. It does not provide validated weights, a prescribed formula, or measured outcomes showing that one scoring method performs better than another. Treat the exercise as a way to make priorities and trade-offs explicit before building or using an optimization system.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Quick Recap
Best Value
Rank #4
Rank #3
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

