Domain-Adapted LLMs Through Continued Pretraining on E-commerce Data

ebay · E-commerce · 2025 · source Agentic: no · promotional bias: med · source-backed · extracted with prompt 0.5.6 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: E-commerce domain-adapted LLMs

eBay needed domain-specific LLMs for marketplace-scale e-commerce tasks while avoiding the cost, security, and customization limits of third-party frontier models.

Constraints:

Architecture

eBay continued-pretrained Meta Llama 3.1 8B and 70B models on e-commerce and general-domain data to create e-Llama. The training mixture used replay/general examples and 10% non-English general data to preserve base capability, while Megatron-LM distributed training ran across 60 nodes and 480 H100 GPUs. The models were trained on 1 trillion tokens and evaluated against e-commerce and general-domain benchmarks.

Diagram confidence: explicit (topology described by the source).

flowchart LR
  ebay-e-commerce-data["eBay e-commerce data"] --> balanced-training-mixture["Balanced training mixture"]
  general-domain-replay-data["General-domain replay data"] --> balanced-training-mixture["Balanced training mixture"]
  balanced-training-mixture --> llama-3-1-base-models["Llama 3.1 base models"]
  llama-3-1-base-models --> megatron-lm-training-framework["Megatron-LM training framework"]
  h100-compute-platform["H100 compute platform"] --> megatron-lm-training-framework["Megatron-LM training framework"]
  megatron-lm-training-framework --> e-llama-models["e-Llama models"]
  e-llama-models --> benchmark-evaluation["Benchmark evaluation"]
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
eBay e-commerce data Marketplace-domain corpus carrying product/listing/seller knowledge. Balanced training mixture
General-domain replay data Curated public/general and non-English examples used to retain pretrained capabilities. Balanced training mixture
Balanced training mixture General-to-e-commerce continued-pretraining data with replay. Llama 3.1 base models
Llama 3.1 base models 8B and 70B open models adapted toward the e-commerce domain. Megatron-LM training framework
Megatron-LM training framework Distributed 3D-parallel training stack. H100 compute platform, e-Llama models
H100 compute platform eBay training cluster with 60 nodes and 480 H100 GPUs. Megatron-LM training framework
e-Llama models Domain-adapted 8B and 70B models. Benchmark evaluation
Benchmark evaluation E-commerce-specific, non-English, and general-domain NLU benchmark checks. e-Llama models

Data flow

eBay marketplace data and curated general-domain data are combined into a balanced training mixture. Llama 3.1 base models undergo continued pretraining with Megatron-LM on the eBay compute platform. e-Llama models are then evaluated for e-commerce gains, non-English gains, and general-domain degradation before powering company AI initiatives.

“we continue training the Llama base models on a large amount of e-commerce data in order to infuse domain specific knowledge into the model.”article, stated
“The final e-Llama models demonstrate approximately 25% improvement in e-commerce-specific benchmarks for English and about 30% improvement for non-English”article, stated

Why this architecture

Continued pretraining let eBay reuse open Llama models rather than train every model from scratch, while keeping more control and lower cost than third-party APIs. Replay/general data balanced the domain gains against catastrophic forgetting.

“This allows us to move faster and unlock more value, as we do not have to develop the models completely from scratch.”article, stated
“This "replay" has been shown to help a model retain previously learned information.”article, stated

Models used: Llama 3.1 8B · Llama 3.1 70B · e-Llama · LiLiuM · Megatron-LM · GPT-4 · Claude

Scale

Alternatives considered (roads not taken)

Use GPT-4 or Claude services for scaled e-commerce tasks

Rejected because: They are costly, less controllable, and create proprietary-data/security concerns.

“Additionally, relying on third-party models introduces data security risks and limits fine-tuning capabilities based on proprietary data.”article, stated

Train every model from scratch

Rejected because: The article calls scratch training time- and resource-intensive.

“Training a large-scale LLM from scratch is a very time- and resource-intensive process.”article, stated

Use only domain/e-commerce data

Rejected because: The model would risk forgetting general pretrained knowledge.

“without the models forgetting information they have learned in their original pretraining (an effect sometimes called "catastrophic forgetting").”article, stated

Patterns

fine-tuning-adaptation (model-ops)

eBay used continued pretraining to adapt Llama 3.1 base models to e-commerce.

“This technique is known as "continued pretraining"”article, stated

data-quality-loop (data)

The training mixture includes replay/general data and non-English data to retain general and multilingual behavior.

“We also include 10% non-English language general domain data to further enhance the model’s multilingual capabilities.”article, stated

cost-aware-routing (strategy)

The domain-adapted model path reduces dependence on costly third-party services at eBay marketplace scale.

“these services come with considerable costs, making them impractical for businesses like eBay”article, stated

privacy-preserving-processing (security)

In-house model capability reduces the need to send proprietary marketplace information to third-party models.

“relying on third-party models introduces data security risks and limits fine-tuning capabilities based on proprietary data.”article, stated

Tradeoffs

Adopt a hybrid LLM strategy

Chose Scratch-built LiLiuM plus adapted Llama/e-Llama over Only third-party models or only scratch-built models.

Rationale: The hybrid approach balances control, speed, cost, and domain customization.

“because of the depth and breadth of our data, we have taken a hybrid approach to LLMs.”article, stated

Continue-pretrain open models

Chose Llama 3.1 domain adaptation over Training from scratch for this model family.

Rationale: Using existing pretrained models moves faster while domain data infuses e-commerce knowledge.

“In order to move fast, one could use existing pretrained models, such as Llama 3.1, for their use cases.”article, stated

Preserve general-domain ability

Chose Replay/general and 10% non-English data over All e-commerce-domain data.

Rationale: The model needed e-commerce gains without excessive degradation on general tasks.

“We also include 10% non-English language general domain data to further enhance the model’s multilingual capabilities.”article, stated

Gotchas (what bit them)

Continued pretraining can erase general capability.

Root cause: Overweighting domain data can cause catastrophic forgetting.

Resolution: Use replay/general-domain data and balance the data ratio.

“the training setup has to be carefully balanced to make the model learn about the new domain while preventing the model from degrading too much in performance on general domain tasks.”article, stated

Third-party LLMs become impractical at e-commerce scale.

Root cause: Cost, proprietary-data exposure, and limited fine-tuning all compound at high volume.

Resolution: Build a hybrid in-house/open-model strategy.

“we build e-commerce LLMs completely from scratch (including our LiLiuM family of LLMs)”article, stated

Large-scale training needs distributed optimization.

Root cause: States must be distributed across GPUs/nodes for 70B-scale continued pretraining.

Resolution: Use Megatron-LM 3D parallelism, distributed optimizer states, and flash-attention optimizations.

“Model training at this scale requires an efficient distribution of model and optimizer states across several GPUs and sometimes even across nodes.”article, stated

Evaluation

eBay evaluated e-Llama on English/non-English e-commerce-specific benchmarks and general-domain NLU benchmarks to measure both improvement and forgetting.

Metrics: 25% English e-commerce benchmark improvement · 30% non-English e-commerce benchmark improvement · 1% degradation on general-domain NLU benchmarks · Training efficiency: 1 trillion tokens, about one month, about 340k GPU-hours

“approximately 25% improvement in e-commerce-specific benchmarks for English and about 30% improvement for non-English”article, stated
“only 1% degradation on general domain NLU benchmarks for the large e-Llama 70B model.”article, stated

Outcomes

This duplicate eBay source describes marketplace-scale domain adaptation with billions of listings, millions of sellers, 190 markets, 480 H100 GPUs, and 1 trillion training tokens.

“the model training is enabling eBay to leverage proprietary and open LLMs to drive new AI initiatives across the company.”article, stated
“Training the 70 billion model on 1 trillion tokens took around one month, or about 340k GPU-hours.”article, stated