---
title: "De-identifying text at scale: How Airbnb protects personal data in AI training"
description: "Airbnb de-identifies messages, reviews and support chats before ML training using Presidio, an open-source PII framework, shipped as an in-process Python library and a shared pipeline step whose de-identified dataset tag gates model deployment."
url: "https://swe.quest/articles/de-identifying-text-at-scale-how-airbnb-protects-personal-data-in-ai-training-8f0e89339f2f4724"
canonical: "https://medium.com/airbnb-engineering/de-identifying-text-at-scale-how-airbnb-protects-personal-data-in-ai-training-32f3ff8ff7d0"
source: "Airbnb Engineering"
published: "2026-11-17"
difficulty: "medium"
kind: "Case study"
reading_minutes: 13
tags: ["privacy","machine-learning","ml-platform","python"]
---

# De-identifying text at scale: How Airbnb protects personal data in AI training

A post on [Airbnb Engineering](https://swe.quest/sources/airbnb.md), published 2026-11-17, 13 min read, Case study. Original: [https://medium.com/airbnb-engineering/de-identifying-text-at-scale-how-airbnb-protects-personal-data-in-ai-training-32f3ff8ff7d0](https://medium.com/airbnb-engineering/de-identifying-text-at-scale-how-airbnb-protects-personal-data-in-ai-training-32f3ff8ff7d0)

## Summary

Airbnb de-identifies messages, reviews and support chats before ML training using Presidio, an open-source PII framework, shipped as an in-process Python library and a shared pipeline step whose de-identified dataset tag gates model deployment. The team added Airbnb-specific pattern recognizers with multi-word phrase context scoring, replaced spaCy with the zero-shot GLiNER model for names and street addresses, and resolves overlapping detections in the Anonymizer. Replacement uses realistic custom Faker values seeded from the real value plus a per-run secret, so fakes stay consistent within a run but unlinkable across runs. Structured fields get salted hashing, coordinate truncation and format-preserving encryption for 64-bit IDs. Quality is tracked on recall, precision and throughput per entity and language, with recall prioritized.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Privacy](https://swe.quest/tags/privacy.md) (Security)
- [Machine learning](https://swe.quest/tags/machine-learning.md) (AI & ML)
- [ML platforms](https://swe.quest/tags/ml-platform.md) (AI & ML)
- [Python](https://swe.quest/tags/python.md) (Languages)

## Prerequisites

- named entity recognition basics
- PII concepts
- ML training pipelines ([easy posts on Machine learning](https://swe.quest/tags/machine-learning.md?difficulty=easy))

## Keywords

Presidio, GLiNER, spaCy, Faker, format-preserving encryption, Airbnb

## Related posts

- [Project Lighthouse — Part 3: Introducing project-lighthouse-anonymize](https://swe.quest/articles/project-lighthouse-part-3-introducing-project-lighthouse-anonymize-df592a142a535f24.md): Airbnb Engineering · 2026-08-25 · Easy · 4 min read · Privacy, Python, Open source, Algorithms
  Airbnb has open-sourced project-lighthouse-anonymize, the Python library behind Project Lighthouse's anonymization of perceived race data, alongside two new arXiv papers.
- [Privacy-Aware Infrastructure in the AI-Native Era: An Asset Classification Case Study](https://swe.quest/articles/privacy-aware-infrastructure-in-the-ai-native-era-an-asset-classification-case-a3a231481ce72736.md): Meta Engineering · 2026-06-25 · Medium · 23 min read · Privacy, LLMs, System design, Evaluation, Data pipelines
  Meta classifies data assets for privacy enforcement with a hybrid pipeline: it builds structured evidence briefs from code resolution, lineage, ownership and annotations, uses LLMs only for novel or ambiguous assets, and distills stable patterns into versioned, human-reviewed deterministic rules.
- [How to build scalable web apps with OpenAI's Privacy Filter](https://swe.quest/articles/how-to-build-scalable-web-apps-with-openai-s-privacy-filter-e26f0bd30942aaf6.md): Hugging Face · 2026-04-27 · Medium · 6 min read · Privacy, Python, Machine learning, Frontend
  OpenAI's open-source Privacy Filter (1.5B params, 50M active, Apache 2.0) detects PII across eight categories in a single forward pass over 128k tokens.
- [Scaling Privacy Infrastructure for GenAI Product Innovation](https://swe.quest/articles/scaling-privacy-infrastructure-for-genai-product-innovation-98d3311fada3a633.md): Meta Engineering · 2025-10-23 · Easy · 9 min read · Privacy, Data pipelines, LLMs, Observability
  Meta scales its Privacy Aware Infrastructure (PAI) to cover GenAI products such as its AI glasses, using cross-stack data lineage as the foundation for automated privacy enforcement.
- [How to Handle PII in Staging Databases Without Losing Realistic Data](https://swe.quest/articles/how-to-handle-pii-in-staging-databases-without-losing-realistic-data-41c0818c53e7c05e.md): Neon · 2025-11-17 · Medium · 11 min read · Privacy, PostgreSQL, Testing, Databases
  Four common ways to get realistic but PII-safe staging data are compared, with code for each: manual CSV export plus Python anonymization scripts, Faker-based masking libraries with deterministic seeding to preserve referential integrity, fully synthetic data generators, and replication into staging with SQL masking views or the PostgreSQL Anonymizer extension (declarative security labels, dynamic masking, anonymized dumps, k-anonymity checks).

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
