---
title: "Speeding up language models for travel applications"
description: "Travel platforms like Booking.com use LLMs for AI Trip Planner, Smart Filters, and accommodation description generation, but models with tens of billions of parameters introduce latency and cost challenges at scale. The authors combined knowledge distillation (KD) with Medusa: KD trains a 1.1-billion-parameter TinyLlama student to mimic a 70-billion-parameter Llama-3.1 teacher, closing over 90% of the quality gap, while Medusa adds prediction heads for parallel token decoding, yielding a 2-3.6x speedup. The unified pipeline produced a model matching the teacher’s quality while running 10-20 times faster and costing less than one-third. For Smart Filters, 99% of queries responded 15 times faster; AI Trip Planner saw 2.9% more engagement than GPT-3.5; and accommodation descriptions got 1.4% more helpful ratings. The approach was presented at ACL and won the Industry Track best-paper award."
---

# Speeding up language models for travel applications

[AWS](https://yomu.fyi/company/aws) · Daniel Zagyva, Laurens van der Maas · Oct 29, 2026

**Type:** Problem & solution

## Summary

Travel platforms like Booking.com use LLMs for AI Trip Planner, Smart Filters, and accommodation description generation, but models with tens of billions of parameters introduce latency and cost challenges at scale. The authors combined knowledge distillation (KD) with Medusa: KD trains a 1.1-billion-parameter TinyLlama student to mimic a 70-billion-parameter Llama-3.1 teacher, closing over 90% of the quality gap, while Medusa adds prediction heads for parallel token decoding, yielding a 2-3.6x speedup. The unified pipeline produced a model matching the teacher’s quality while running 10-20 times faster and costing less than one-third. For Smart Filters, 99% of queries responded 15 times faster; AI Trip Planner saw 2.9% more engagement than GPT-3.5; and accommodation descriptions got 1.4% more helpful ratings. The approach was presented at ACL and won the Industry Track best-paper award.

## Context

Large language models used in travel applications provide contextually relevant advice but suffer from high computational cost and latency, where even 100 ms delay can lose customers and revenue.

## Approach / What changed

Combine knowledge distillation (KD) with the Medusa framework: use a 70B parameter Llama-3.1 teacher to train a 1.1B TinyLlama student via KD, and add Medusa heads to the student for parallel token prediction. Medusa-2 trains the base model and heads in a single stage.

## Takeaways

- Combining knowledge distillation and Medusa matched the quality of a 70B-parameter teacher (Llama-3.1) while running 10-20 times faster and costing less than one-third of the large model.
- Medusa accelerates inference by predicting multiple tokens in parallel using additional prediction heads, achieving 2-4x speedup without compromising generation quality.
- Domain-specific fine-tuning of a compact model (TinyLlama) significantly improves accuracy over few-shot GPT-4o, but still falls short; knowledge distillation closes over 90% of the quality gap to a larger teacher.

## FAQ

### How does Medusa speed up LLM inference?

Medusa adds prediction heads to the base LLM, one for each additional token decoded in parallel, allowing the model to predict multiple tokens simultaneously. This leverages GPU parallelism to achieve 2-4x speedup without reducing generation quality.

### What is the benefit of combining knowledge distillation with Medusa?

Knowledge distillation transfers knowledge from a large teacher to a small student, closing over 90% of the quality gap and providing 6x baseline speedup; adding Medusa heads to the student gives an additional 2-3.6x speedup, yielding 10-20x total speedup at less than one-third the cost.

### What was the result for the Smart Filters feature?

After applying KD and Medusa, Smart Filters responded 15 times faster for 99% of queries compared to the original large model.

**Tags:** [Distillation](https://yomu.fyi/topic/distillation), [LLMs](https://yomu.fyi/topic/llm), [Medusa](https://yomu.fyi/topic/medusa)

- Source: [AWS](https://www.amazon.science/blog/speeding-up-language-models-for-travel-applications)
- Source URL: https://www.amazon.science/blog/speeding-up-language-models-for-travel-applications
- Ingested by Yomu: 2026-10-29T18:01:06.656Z

[Read original post](https://www.amazon.science/blog/speeding-up-language-models-for-travel-applications)
