KatInterview

Designing a Grounded LLM Assistant for Seller Policy Questions

Machine LearningModel answer
MediumModel answerMachine Learninggenerative-airagllm-evaluation

Last updated

Decide whether an LLM fits a seller-compliance help desk, choose an architecture, define offline and online accuracy measures, and design a safe improvement loop.

Context

An online marketplace wants an internal assistant that answers third-party sellers' questions about selling policies and catalog compliance. Sellers send thousands of such questions each day, and human agents currently need hours to resolve each one. The policy library is large, and a meaningful share of it is revised every week.

Assume roughly these figures when you reason about trade-offs, and state any others you add:

  • about 5,000 questions per day
  • about 2,000 policy documents, with about 50 changing weekly
  • a goal of 95% factual correctness on the questions the system chooses to answer
  • no more than 0.5% wrong answers on high-severity topics such as prohibited or restricted items

What to cover

  1. Is an LLM the right tool? Lay out the criteria for choosing between a generative approach, plain search, a rule engine, or a traditional classifier. State where each is appropriate for this problem.
  2. Architecture. Propose a design (prompting only, retrieval-augmented generation, fine-tuning, or a mix) and justify it using policy freshness, hallucination risk, and latency.
  3. Evaluation. Define offline and online metrics for factual accuracy and policy adherence. Explain how you would detect and quantify hallucinations, and why overlap metrics such as ROUGE or BLEU are poor accuracy measures here.
  4. Continuous improvement. Describe an operating loop that detects drift, captures weak answers, and ships updates safely.

Expectations

  • Name concrete metrics (for example faithfulness, answer relevance, context recall, citation quality, abstention quality) and say how each is computed.
  • Include human audit sampling in your plan.
  • Explain precisely how you would stop an invented or misread policy from reaching a seller.

Hints

Hint 1

Start by splitting the traffic: which questions are binary lookups that a rules table can answer exactly, and which need synthesis across several documents? Also decide who is allowed to take enforcement actions.

Hint 2

Compare how retrieval and fine-tuning each handle weekly policy changes, source attribution, and rollback. Then think about which layers of checking (retrieval filters, citation checks, abstention) sit between the model and the seller.

Hint 3

Evaluate retrieval and generation separately, using a labeled golden set that includes unanswerable and adversarial questions. Validate any LLM judge against human labels, and weight errors by severity rather than counting them equally.

Hint 4

For the improvement loop, think about what signals reveal a bad answer after launch (re-asks, escalations, downstream violations), and how you would gate a change with regression tests, shadow traffic, and a staged rollout.