Company
Zillow
Title
Building Fair Housing Guardrails for Real Estate LLMs: Zillow's Multi-Strategy Approach to Preventing Discrimination
Industry
Other
Year
2024
Summary (short)
Zillow developed a comprehensive Fair Housing compliance system for LLMs in real estate applications, combining three distinct strategies to prevent discriminatory responses: prompt engineering, stop lists, and a custom classifier model. The system addresses critical Fair Housing Act requirements by detecting and preventing responses that could enable steering or discrimination based on protected characteristics. Using a BERT-based classifier trained on carefully curated and augmented datasets, combined with explicit stop lists and prompt engineering, Zillow created a dual-layer protection system that validates both user inputs and model outputs. The approach achieved high recall in detecting non-compliant content while maintaining reasonable precision, demonstrating how domain-specific guardrails can be successfully implemented for LLMs in regulated industries.
# Notes on Zillow's Fair Housing LLM Implementation ## Challenge Overview - Need to ensure LLM compliance with Fair Housing Act - Prevent discriminatory responses in real estate context - Balance between compliance and user experience - Address complex legal requirements at scale ## Legal Context ### Protected Classes Include - Race/color - National origin - Sex (including orientation and gender identity) - Familial status - Religion - Disability - Age - Marital status - Source of income - Criminal background - Military status ### Key Legal Considerations - Fair Housing Act (FHA) - Equal Credit Opportunity Act (ECOA) - State and local anti-discrimination laws - Steering prevention requirements ## Technical Implementation ### Three-Pronged Approach ### 1. Prompt Engineering - Advantages: - Limitations: ### 2. Stop List - Advantages: - Limitations: ### 3. Classifier Model - Architecture: BERT-based - Features: - Training Data: ### Dataset Development - Sources: - Augmentation Methods: ## Implementation Results ### System Architecture - Pre-processing validation - Post-processing checks - Combined approach benefits: ### Performance Considerations - Speed requirements - Precision vs recall trade-offs - Error handling strategies - Feedback incorporation ## Future Directions ### Model Improvements - Enhanced feature engineering - Expanded training data - Advanced architectures - Context handling ### Open Source Plans - Classifier release - Supporting data sharing - Community collaboration - Industry standardization ## Key Learnings ### Success Factors - Multi-layered approach - Domain expertise integration - Balanced precision/recall - Continuous improvement process ### Implementation Insights - Importance of legal compliance - Value of multiple strategies - Need for context awareness - Feedback loop importance ## Business Impact - Enhanced compliance assurance - Reduced discrimination risk - Improved user experience - Scalable solution framework

Start your new ML Project today with ZenML Pro

Join 1,000s of members already deploying models with ZenML.