Skip to content

Conversation

yoshitafiddler
Copy link

Comprehensive Quickstart Notebook Created!

I've created a well-structured Jupyter notebook (sensitive_information_guardrail_quickstart.ipynb) that demonstrates how to use the sensitive information guardrail with all the new entity configuration features.

What's Included:

🔧 Core Features:

  • ✅ Complete API setup with guardrail credentials
  • ✅ Configurable entity detection function with PII/PHI/Custom support
  • ✅ Pretty-print results with entity grouping and confidence scores
  • ✅ Error handling and robust API calls

Examples Covered:

  • PII Detection (Default) - Personal, financial, and digital identifiers
  • PHI Detection - Healthcare-specific entities (medications, conditions, insurance)
  • Combined PII + PHI - Comprehensive healthcare compliance scanning
  • Custom Entities - Enterprise-specific sensitive data detection
  • Batch Processing - Efficient processing of multiple texts with performance metrics

Configuration Templates:

  • Financial screening (PII only)
  • Healthcare compliance (PII + PHI)
  • Enterprise security (PII + Custom)
  • Comprehensive audit (All entity types)

🚀 Key Benefits:

  • ✅ Ready to Run: Just execute the cells to see live examples
  • ✅ Production Ready: Includes error handling, retries, and batch processing
  • ✅ Flexible: Easy to adapt for your specific entity categories
  • ✅ Educational: Clear explanations and best practices
  • ✅ Comprehensive: Covers all new entity configuration features

🎯 Usage Examples:
The notebook is structured for both learning and production use.

# Basic PII detection
response, latency = get_sensitive_information_response(text)

# Healthcare compliance (PII + PHI)
response, latency = get_sensitive_information_response(
    text, entity_categories=['PII', 'PHI']
)

# Custom enterprise entities
response, latency = get_sensitive_information_response(
    text, 
    entity_categories='Custom Entities',
    custom_entities=['employee id', 'api key', 'project code']
)

# Batch processing for datasets
results_df = process_dataset_batch(
    text_list, entity_categories=['PII', 'PHI'], max_records=100
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant