projectankraj / ccpa_knowledge.py
ankushka's picture
Upload 8 files
7e09b15 verified
# Pre-extracted CCPA knowledge base - key sections for RAG
CCPA_SECTIONS = {
"Section 1798.100": """General Duties of Businesses that Collect Personal Information.
A business must inform consumers at or before point of collection about:
- Categories of personal information collected and purposes
- Whether information is sold or shared
- If collecting sensitive personal information, categories and purposes
- Length of time business intends to retain each category
A business shall not collect additional categories or use for incompatible purposes without notice.
Collection, use, retention, and sharing must be reasonably necessary and proportionate to disclosed purposes.
Violation: Collecting data without disclosure, collecting undisclosed categories, using data for undisclosed purposes, not disclosing retention period, collecting sensitive data (browsing history, geolocation, biometric data) without mentioning it in privacy policy.""",
"Section 1798.105": """Consumers' Right to Delete Personal Information.
A consumer has the right to request deletion of their personal information.
A business that receives a verifiable consumer request to delete must:
- Delete the consumer's personal information from its records
- Notify service providers and contractors to delete
- Notify third parties to delete
Exceptions to deletion: completing a transaction, security, debugging, free speech, legal compliance, scientific research, internal uses compatible with context.
Violation: Ignoring or refusing deletion requests, keeping records after verified deletion request, not notifying service providers to delete.""",
"Section 1798.106": """Consumers' Right to Correct Inaccurate Personal Information.
A consumer has the right to request correction of inaccurate personal information.
A business must use commercially reasonable efforts to correct inaccurate information.
Violation: Refusing to correct inaccurate personal information after verified request.""",
"Section 1798.110": """Consumers' Right to Know What Personal Information is Being Collected.
A consumer has the right to request disclosure of:
- Categories of personal information collected
- Categories of sources
- Business or commercial purpose for collecting/selling/sharing
- Categories of third parties to whom information is disclosed
- Specific pieces of personal information collected
Violation: Refusing to disclose what personal information is collected, failing to respond to access requests.""",
"Section 1798.115": """Consumers' Right to Know What Personal Information is Sold or Shared.
A consumer has the right to know:
- Categories of personal information sold or shared and to whom
- Categories of personal information disclosed for business purposes
Third parties shall not re-sell personal information without consumer notice and opt-out opportunity.
Violation: Not disclosing to whom personal information is sold or shared, third party re-selling without notice.""",
"Section 1798.120": """Consumers' Right to Opt Out of Sale or Sharing of Personal Information.
A consumer has the right at any time to direct a business not to sell or share their personal information (right to opt-out).
Business must provide notice that information may be sold/shared and consumers have right to opt out.
SPECIAL RULE FOR MINORS: A business shall NOT sell or share personal information of consumers it knows are under 16 years of age unless:
- Consumer aged 13-15 has affirmatively authorized the sale/sharing, OR
- Parent/guardian of consumer under 13 has authorized it
Selling data of minors (under 16) without proper consent is a violation.
Violation: Selling/sharing personal information without opt-out mechanism, not providing opt-out notice, selling/sharing data of users under 16 without consent, selling data of users under 13 without parental consent, ignoring opt-out requests.""",
"Section 1798.121": """Consumers' Right to Limit Use and Disclosure of Sensitive Personal Information.
A consumer has the right to direct a business to limit use of sensitive personal information to necessary purposes.
Sensitive personal information includes: Social Security numbers, financial account info, precise geolocation, racial/ethnic origin, religious beliefs, union membership, contents of mail/email/texts, genetic data, biometric data for identification, health information, sex life or sexual orientation.
A business using sensitive data for non-essential purposes must provide notice and honor limitation requests.
Violation: Using sensitive personal information beyond necessary service delivery without consumer opt-out option, not honoring limitation requests for sensitive data.""",
"Section 1798.125": """Consumers' Right of No Retaliation Following Opt Out or Exercise of Other Rights.
A business shall not discriminate against a consumer for exercising CCPA rights, including:
- Denying goods or services
- Charging different prices or rates (higher prices to consumers who opt out)
- Providing different level or quality of goods or services
- Suggesting consumer will receive different price/rate/quality
Exception: A business may offer financial incentives for collection/sale/sharing of data if:
- Not unjust, unreasonable, coercive, or usurious
- Consumers are notified and opt-in voluntarily
Violation: Charging higher prices to consumers who opt out of data selling, offering lower quality service, denying service, any discriminatory treatment for exercising privacy rights.""",
"Section 1798.130": """Notice, Disclosure, Correction, and Deletion Requirements.
Businesses must:
- Provide two or more designated methods for submitting consumer requests (including toll-free number)
- Respond to verifiable consumer requests within 45 days (extendable to 90 days with notice)
- Not require account creation to make a request
- Provide privacy policy disclosing consumer rights
- Disclose categories of personal information collected in the past 12 months
Violation: Not responding within 45 days, requiring account creation to exercise rights, not providing adequate request mechanisms.""",
"Section 1798.135": """Methods of Limiting Sale, Sharing, and Use of Personal Information.
A business that sells/shares personal information or uses sensitive personal information must:
- Provide a clear and conspicuous link titled 'Do Not Sell or Share My Personal Information' on homepage
- Provide link to limit use of sensitive personal information
- Honor opt-out signals including Global Privacy Control
- Not require consumer to create account to opt out
- Not use dark patterns that subvert opt-out choices
Violation: Not having 'Do Not Sell My Personal Information' link, ignoring Global Privacy Control signals, using dark patterns to prevent opt-out, requiring account creation to opt out.""",
}
# Map common violation patterns to sections
VIOLATION_PATTERNS = {
"selling personal information without opt-out": ["Section 1798.120", "Section 1798.135"],
"selling data without notice": ["Section 1798.120", "Section 1798.100"],
"ignoring deletion request": ["Section 1798.105"],
"refusing to delete": ["Section 1798.105"],
"undisclosed data collection": ["Section 1798.100"],
"collecting without disclosure": ["Section 1798.100"],
"discriminatory pricing": ["Section 1798.125"],
"higher price for opt-out": ["Section 1798.125"],
"minor data without consent": ["Section 1798.120"],
"children data without parental consent": ["Section 1798.120"],
"sensitive data without limitation option": ["Section 1798.121"],
"biometric data without disclosure": ["Section 1798.100", "Section 1798.121"],
"geolocation without disclosure": ["Section 1798.100", "Section 1798.121"],
"no do not sell link": ["Section 1798.135"],
"ignoring opt-out": ["Section 1798.120", "Section 1798.135"],
"refusing access request": ["Section 1798.110"],
"not disclosing third parties": ["Section 1798.115"],
"third party reselling without notice": ["Section 1798.115"],
"not responding to requests": ["Section 1798.130"],
"denying service for opt-out": ["Section 1798.125"],
}