AI Coffee Expert Case Study: How Anas Saleh Coffee Designs Custom Blends from Customers' Words
How the AI coffee expert on Anas Saleh Coffee turns taste words into custom blends: beans and ratios, a roast chosen per bean, spice limits, server validation, live pricing and a blend editor.

The coffee expert on the Anas Saleh Coffee store is an AI assistant that turns a customer's own words, such as «تقيلة ووشها كتير ومش مُرّة، بطعم شوكولاتة», into a professional custom blend: which beans, in what ratio, at which roast for each bean, with how much cardamom. The server checks and prices every blend before the customer sees it, and the customer can adjust it in a blend editor and order it like any product when every part of it has a price.
This case study explains how we built it for Anas Saleh Coffee, a Cairo roastery, and which design choices keep it accurate. It is one of two examples in our guide to AI shopping assistants for online stores.
Key takeaways
- The assistant understands taste words in Egyptian Arabic, Franco and English, including negation such as «مش مُرّة».
- Blends are built from a knowledge base of 38 coffee origins at three roasts, blending rules and Egyptian spice mixes.
- The roastery, not the customer, decides the roast: each bean gets the level that suits it and the brewing method, with the reason shown.
- Every blend is validated and priced by the server from the shop's own prices; the model cannot type a price onto the card.
- The blend card is honest about gaps and trade-offs, and a blend editor lets the customer adjust it with the price updating live.
The problem: special mixes ordered by phone
Before the store, customers who wanted a special mix called the roastery and described it, and the roaster translated the description into beans and percentages one call at a time. The roastery wanted customers to design that mix online, see its taste and price, and order it, while the roaster receives an exact recipe instead of a phone note.
From taste words to a blend
Customers do not say "medium body, low acidity". They say «تقيلة», «ريحتها تملى البيت», «زي القهاوي» or «mesh 7amda». A taste lexicon maps 476 phrasings onto 35 taste concepts across Egyptian colloquial, Saidi, Franco, English and formal Arabic. Negation and intensity are handled, so «مش مُرّة ولا حامضة» negates both, and «تقيلة أوي» raises the target one step.
The assistant also detects the brewing method from everyday words: «كنكة» means Turkish, «المكنة» or «شوت» means espresso, «المكبس» means French press. When the request is ambiguous, it asks one question. In a real conversation the customer asked for a heavy, foamy, not-bitter spiced Turkish blend with a chocolate taste, and the assistant asked whether "heavy" meant taste and body or more caffeine before designing anything.
Beans, ratios and roast per bean
The design code tries bases and supporting beans at different ratios and scores each candidate against the customer's targets. Four rules shape the result:
- The base bean usually carries 40–70% of the blend so its identity stays stable.
- Robusta stays at 30% or less, because beyond that its earthy bitterness covers the other flavours.
- Each bean is roasted separately to its own best level and blended after roasting, so a medium Santos and a darker robusta in one bag is normal.
- The roast is the roastery's decision. A customer's roast word is honoured only where the research rates it suitable for that bean and brew; otherwise the assistant keeps the right roast and explains why.
For the request above, the assistant proposed 70% Brazilian Santos, 20% Indian robusta and 10% Indonesian robusta, all at medium roast, with 10% cardamom, and estimated about 84 mg of caffeine per Turkish cup.
Spices and flavours with safe limits
Egyptian Turkish coffee is often «محوّج». The assistant understands cardamom, clove, nutmeg, mastic and cinnamon in their common spellings, and spice levels such as light, normal and heavy. Safety ceilings always apply, for example nutmeg at 0.5% of the bag at most, and ground spices are offered only for Turkish, moka and French press. For espresso and filter the assistant explains why spices do not belong in the beans and suggests adding cardamom to the cup or the milk instead.
Server validation and pricing
The model never writes the final blend by itself. It must send every blend to a server tool that checks robusta caps, spice ceilings, unsuitable roasts and poor pairings, predicts the taste profile, and prices the blend from the 1 kg prices in the shop's catalogue. The card the customer sees, with its prices and add-to-cart button, is built from that server result, not from text the model typed. Checkout prices the recipe again on the server.
If any bean in the blend has no price, or a spiced blend uses a bean with no spiced price, the blend is not orderable online. That happened in the real conversation above: the card said the spiced versions of those beans were not priced yet and offered ordering on WhatsApp,.
The blend card and the roaster's analysis
Each blend card shows the grind, each bean with its share and the reason for its roast, the spice in grams per kilo, the expected taste and a brewing recipe. A collapsible section, «ليه التوليفة دي؟», explains the role of each bean, the ratio logic and the honest trade-offs. In the real example it showed that body and foam came out at 3.6 against a requested 4, and bitterness at 2.6 against a requested maximum of 2, with a fix for each.
| Step | What happens | Decided by |
|---|---|---|
| Understand the request | Taste words, brew method, spice level | Lexicon rules plus the AI model |
| Clarify | At most one or two questions when something is ambiguous | AI model |
| Design | Beans and ratios scored against the targets | Blend search in code |
| Roast | One roast per bean for the brew method, with the reason | Roast rules in code |
| Validate and price | Caps, ceilings, pairings, price per weight | Server, from shop prices |
| Adjust and order | Blend editor with live price, then cart or WhatsApp | Customer |
The blend editor
From any blend card, the customer can open «عدّل التوليفة»: change the name, brewing method and grind, add or remove beans (up to five), move ratio sliders, and add spices or flavours within their limits. Every change is re-quoted by the server, so the profile, warnings and price per weight update as they edit. A blend in the cart can be opened and edited again. When the order is placed, the roastery sees the full recipe and prep notes on the order page.
What changed for the roastery
The store has 98 products online with a fixed delivery fee for each of Egypt's 27 governorates. Customers who used to call for a special mix can now design it with the coffee expert, see its taste and price, and order it online when every component is priced, while the roaster gets the exact recipe with each order. The safeguards that keep prices and personal data safe are described in keeping a store chatbot honest, with the wider risks covered in AI chatbot security.
How Nilex helps
Nilex builds the AI business chatbot around your own product knowledge: the rules your experts follow are written into code, the assistant recommends from your live catalogue, and the server checks every price. If your product is configured to taste or need, like coffee blends or the appliance sizing in our appliance advisor case study, talk to us about what your assistant should know.
Frequently asked questions
Can every custom blend be ordered online?
No. A blend is orderable online only when every bean and addition in it has a price in the shop. Otherwise the card says why and offers ordering on WhatsApp, or the customer can swap the bean in the editor.
Can the customer choose the roast?
The roastery decides the roast per bean for the brewing method. A customer's preference is honoured when it suits the bean; otherwise the assistant explains its choice.
How accurate is the predicted taste?
It is a weighted average of published cupping data for each origin and roast, shown with a confidence level. It is a professional starting point, and the roaster tastes the blend before preparing it.
Which languages does it understand?
Egyptian Arabic in several regional varieties, Franco, English and formal Arabic, including typos and mixed messages.
Does this only work for coffee?
No. The pattern fits any product built to a customer's taste or need: expert rules in code, server checks and live pricing.
AI Book Assistant Case Study: Recommending Legal Books From a Reader's Case11 October 2026 · 8 min
How We Built Our Own AI Sales Assistant: A Consultant That Recommends Systems Without Making Things Up11 October 2026 · 8 min
AI Business Chatbots From Nilex: What They Do, What We Connect Them To and the Limits We Set11 October 2026 · 9 min
