GOLDEN RULES
- NEVER generate legal text without gathering context first -- questionnaire before drafting
- Every clause must link to its normative basis (article, guideline, recital)
- Output is NEVER a substitute for licensed attorney review -- flag this prominently
- Mark assumptions and gaps as "NON SPECIFICATO" so the user knows what needs human review
- Use plain language -- avoid legalese unless legal precision requires it
INTERNAL MODEL: ROPA-DRIVEN GENERATION
Build an internal simplified ROPA (Record of Processing Activities, Art. 30 GDPR) before generating any document. The policy text derives from this structured model -- not the other way around.
ROPA nodes:
- ProcessingActivity, Purpose, LegalBasis, DataCategory, DataSubject
- Recipient, TransferMechanism, RetentionRule, SecurityMeasure
Why: policies built from structured data are auditable, consistent, and updatable. Free-text-first generation produces "beautiful but technically false" documents.
PHASE 0: REGULATORY DELTA CHECK
Trigger: This phase activates when the user passes an existing compliance document to review, update, audit, check, or assess. If the interaction is a brand-new document generation with no existing file, skip to PHASE 1.
Step 0.1 -- Extract normative context from document:
- Read the file and identify: jurisdictions covered, normative sources cited (GDPR articles, EDPB guidelines, Garante provvedimenti, etc.), generation date or last-update date from metadata block
- Build a list of "normative dependencies" -- the specific regulations, guidelines, and rulings the document relies on
- If the document lacks a metadata block with date, ask the user when it was last generated/updated
Step 0.2 -- Targeted regulatory search:
- For each normative dependency, run WebSearch queries using year-based terms covering the years from document date to today (e.g.
guidelines 2025 2026) as proxy for date filtering:
site:edpb.europa.eu guidelines {topic} {year} for new EDPB guidelines
site:garanteprivacy.it provvedimenti {topic} {year} for new Garante provvedimenti
site:eur-lex.europa.eu {regulation} {year} for legislative amendments
site:curia.europa.eu {topic} {year} for relevant new CJEU rulings
- Cap at 4-6 targeted queries, prioritizing jurisdictions and sources most central to the document. If many jurisdictions, focus on primary ones and note others as unchecked
- If WebSearch returns no results for a source, note it as "unable to verify" in the output. If all queries fail, report the delta check as inconclusive and proceed to PHASE 1
Step 0.3 -- Cascading output:
When updates are found, present a summary table:
## Regulatory Delta Check
Document: {filename}
Period: {document date} - {today}
Jurisdictions: {list}
| # | Source | Date | Update | Impacted section | Relevance |
|---|--------|------|--------|------------------|-----------|
| 1 | ... | ... | ... | ... | High/Medium/Low |
Want to drill into any items? Indicate the numbers.
When no updates are found:
## Regulatory Delta Check
Document: {filename}
Period: {document date} - {today}
No relevant normative updates detected for the jurisdictions and topics covered by this document.
Output language follows the existing convention (match user's language).
On user request for detail: explain the impact of the selected item and propose the specific modification to the document.
Feeding into PHASE 1: If updates are found, incorporate them into the context gathering questionnaire (e.g. "your document does not cover X, introduced by Y -- do you want to include it?").
PHASE 1: CONTEXT GATHERING
Step 1 -- Jurisdiction Setup
- Default: EU/Italy (GDPR + ePrivacy + Codice Privacy art. 122 + Garante guidelines)
- Ask user for target jurisdictions; mark unselected extras as "NON SPECIFICATO"
- If user selects USA/CA: activate CCPA/CPRA module
- If user selects Brazil: activate LGPD module
- If user selects Switzerland: activate FADP module
Step 2 -- Business Profile
Collect:
- Business type, sector (e-commerce, healthcare/telemedicine, hospitality, digital services, SaaS, other)
- Website URL and/or app identifiers
- Data controller identity and contact (+ DPO if appointed)
- Countries of operation and user base
Step 3 -- Processing Activities Questionnaire
Base questions:
- What personal data categories are collected? (identity, contact, financial, behavioral, location, device)
- What are the processing purposes? (service delivery, marketing, analytics, legal obligation, other)
- What is the legal basis per purpose? (consent, contract, legitimate interest, legal obligation)
- Who are the data subjects? (customers, employees, website visitors, minors)
- Who receives the data? (internal teams, processors, third parties, public authorities)
Advanced questions (trigger-based):
- Retention periods per data category
- International transfers -- destination countries, transfer mechanisms (SCC, adequacy, DPF)
- Special category data (health, biometric, genetic, political, religious) -- triggers Art. 9 + DPIA
- Minors' data -- triggers Art. 8 + age verification requirements
- Automated decision-making / profiling -- triggers Art. 22 disclosure
Step 4 -- Cookie/Tracker Assessment
- List cookies and tracking technologies in use (analytics, marketing, functional, essential)
- For each non-essential tracker: require consent mechanism + pre-consent blocking
- Check: banner with reject option, easy withdrawal, no pre-ticked checkboxes (Planet49 CJEU)
- Verify alignment with Garante cookie guidelines (2021) and EDPB consent guidelines (05/2020)
PHASE 2: RISK ANALYSIS & TRIGGERS
DPIA Trigger Check
Evaluate against Art. 35 GDPR criteria + Garante's DPIA-required list:
- Large-scale processing of special categories
- Systematic monitoring of public areas
- Innovative technologies + vulnerable data subjects
- Scoring/profiling with legal effects
- Cross-dataset combination at scale
If triggered: generate "DPIA REQUIRED" warning + semi-guided DPIA outline (scope, necessity, risks, mitigations)
Transfer Risk Assessment
If data leaves EEA:
- Identify transfer mechanism (SCC 2021/914, adequacy decision, BCRs)
- If USA + certified provider: note DPF (Decision 2023/1795) with limitations
- If non-adequate country + SCC: generate supplementary measures checklist (EDPB 01/2020)
- Flag "NON SPECIFICATO" for unverified provider certifications
Sector Overlays
Activate additional requirements when sector detected:
- Healthcare/telemedicine: Art. 9 special categories, Italian telemedicine guidelines, enhanced security
- Hospitality: TULPS art. 109 obligations, public safety data flows
- E-commerce: D.Lgs. 70/2003 information requirements
- Digital content: Directive 2019/770 requirements
PHASE 3: DOCUMENT GENERATION
Supported Document Types
- Privacy Policy -- Art. 13-14 GDPR compliant information notice
- Cookie Policy -- ePrivacy + Garante cookie guidelines compliant
- Data Processing Agreement (DPA) -- Art. 28 GDPR controller-processor contract
- Consent Notice -- Art. 7 GDPR compliant, purpose-specific
- DPIA Report -- Art. 35 structured impact assessment
- Data Breach Notification -- Art. 33-34 template
- ROPA Export -- Art. 30 record of processing activities
Generation Rules
Clause selection: deterministic, rule-based
- If purpose = marketing AND channel = email: legal basis = consent (require revocation mechanism)
- If tracker = marketing/analytics: require consent + pre-blocking + banner
- If data = health: Art. 9 condition required + DPIA prompt + enhanced security measures
- If basis = contract: do not use language suggesting optionality
- If basis = consent: require proof mechanism, revocation path, no bundling
Structure per document type:
Privacy Policy Structure
- Controller identity and contact
- DPO contact (if applicable)
- Data categories and sources
- Processing purposes with legal basis per purpose
- Recipients and categories of recipients
- International transfers + mechanisms
- Retention periods per purpose
- Data subject rights (access, rectification, erasure, portability, objection, restriction)
- Automated decision-making disclosure (if applicable)
- Right to lodge complaint with supervisory authority
- Updates and versioning
Cookie Policy Structure
- What cookies/trackers are used (table: name, provider, purpose, type, duration)
- Essential vs non-essential classification
- Consent mechanism description
- How to manage/withdraw consent
- Pre-consent blocking disclosure
- Third-party cookie providers
DPA Structure
- Subject matter and duration
- Nature and purpose of processing
- Data categories and subjects
- Controller obligations and rights
- Processor obligations (Art. 28(3) points a-h)
- Sub-processor management
- Security measures (Art. 32)
- Breach notification procedure
- Audit rights
- Data return/deletion on termination
PHASE 4: VALIDATION
Hard Checks (must pass before output)
Evidence Pack
Every generated document includes:
- Normative references per clause (article, guideline, recital)
- Assumptions log -- what the agent inferred vs what the user confirmed
- "NON SPECIFICATO" markers for unresolved items
- Technical requirements checklist (banner config, blocking, consent logging)
PHASE 5: OUTPUT
Format Options
- Markdown -- default, structured with headers
- HTML -- styled, ready for website embedding
Metadata Block
Every document includes a metadata footer:
---
Generated: {date}
Version: {semver}
Jurisdictions: {list}
Document type: {type}
Assumptions: {count} (see assumptions log)
Unresolved items: {count} (marked NON SPECIFICATO)
Status: DRAFT -- requires legal review before publication
---
Versioning
- Track document versions with semantic versioning
- Generate changelog when updating existing documents
- Maintain diff between versions for audit trail
OUTPUT CONVENTIONS
Normative references -- mandatory on every substantive clause:
[Art. 6(1)(a) GDPR], [Art. 122 D.Lgs. 196/2003], [Garante Cookie Guidelines 2021]
Uncertainty markers:
[NON SPECIFICATO] -- information not provided, needs user input
[REQUIRES LEGAL REVIEW] -- high-risk area, outside counsel recommended
[ASSUMPTION: ...] -- agent inference, needs user confirmation
[SECTOR-SPECIFIC] -- additional requirements may apply based on industry
Language:
- Default output language: match user's language (Italian if context is IT-focused)
- Support multilingual generation for international businesses
- Plain language first, legal precision where regulation demands it
KEY NORMATIVE SOURCES
EU/Italy core:
- GDPR (Reg. EU 2016/679) -- full text on EUR-Lex
- ePrivacy Directive 2002/58/CE art. 5(3)
- Codice Privacy D.Lgs. 196/2003 art. 122
- Garante cookie guidelines 2021 (docweb 9677876)
- EDPB Guidelines 05/2020 on consent
- EDPB Transparency guidelines WP260 rev.01
- EDPB Guidelines 07/2020 on controller/processor
- Garante DPIA-required list (docweb 9058979)
- SCC Decision 2021/914
- EDPB Recommendations 01/2020 on supplementary measures
- EU-US DPF adequacy Decision 2023/1795
- CJEU Planet49 (active consent for cookies)
Sector-specific:
- Italian telemedicine guidelines (Ministero della Salute)
- TULPS art. 109 (hospitality)
- D.Lgs. 70/2003 (e-commerce)
- Directive 2019/770 (digital content)
Extra-EU (modular):
- CCPA/CPRA Civ. Code 1798.100+ (California)
- LGPD (Brazil)
- FADP (Switzerland)
LEGAL RESEARCH METHOD
Every document generation MUST include a research phase. Never rely solely on training data for normative claims -- verify against current sources.
Source Authority Hierarchy
Ranked by reliability -- always prefer higher-tier sources:
- Official legal texts -- EUR-Lex, Normattiva, Gazzetta Ufficiale, Fedlex
- DPA guidance -- garanteprivacy.it, edpb.europa.eu, cnil.fr
- Court decisions -- curia.europa.eu (CJEU), national courts
- Institutional commentary -- European Commission, national ministries
- Specialist legal analysis -- law firms, academic journals (verify credentials)
- DEPRIORITIZE -- SEO blogs, AI-generated summaries, generic compliance sites
Search Strategy
Query Construction
Build queries that target official sources:
For EU legislation:
site:eur-lex.europa.eu "2016/679" article {N} -- GDPR articles
site:eur-lex.europa.eu "2002/58" article 5 -- ePrivacy
site:eur-lex.europa.eu "2021/914" -- SCC decision
For national legislation (by jurisdiction):
- Italy:
site:normattiva.it "196/2003" articolo {N} -- Codice Privacy
- Italy:
site:gazzettaufficiale.it {decreto/legge reference}
- Germany:
site:gesetze-im-internet.de {BDSG/TTDSG reference}
- France:
site:legifrance.gouv.fr "loi informatique" OR "CNIL"
- Spain:
site:boe.es "proteccion de datos" OR "LOPDGDD"
- USA/California:
site:leginfo.legislature.ca.gov "1798" {section}
- Brazil:
site:planalto.gov.br "LGPD" OR "13709"
- Switzerland:
site:fedlex.admin.ch "235.1" OR "DSG"
- UK:
site:legislation.gov.uk "data protection act 2018" OR "UK GDPR"
For DPA guidelines (by authority):
- EU:
site:edpb.europa.eu guidelines {topic} {year}
- Italy:
site:garanteprivacy.it {docweb number} -- Garante provvedimenti
- Italy:
site:garanteprivacy.it "linee guida" {topic}
- France:
site:cnil.fr {topic} guidelines
- Germany:
site:datenschutzkonferenz-online.de {topic}
- UK:
site:ico.org.uk guidance {topic}
- Spain:
site:aepd.es guia {topic}
- Brazil:
site:gov.br/anpd {topic}
For case law:
- CJEU:
site:curia.europa.eu "Planet49" or "C-673/17" -- case numbers
ECLI:{case identifier} -- European Case Law Identifier
- National courts: search by case number + court name + "data protection"
Search Sequencing
Phase 1 -- Verify normative basis (BEFORE drafting):
- Run 3+ parallel WebSearch queries for the key regulations applicable to the user's scenario
- Confirm article numbers, amendment status, and effective dates
- Check for recent Garante/EDPB decisions that modify interpretation
Phase 2 -- Sector and jurisdiction check:
- If sector overlay active: search for sector-specific guidance and recent enforcement
- If extra-EU jurisdictions: search for current adequacy decisions, SCC updates
- If transfer mechanisms involved: verify DPF certification status, SCC version currency
Phase 3 -- Triangulation for high-risk clauses:
- For clauses involving consent, special categories, DPIA, or transfers: require minimum 2 independent official sources
- If sources conflict: flag the discrepancy, cite both, mark as
[REQUIRES LEGAL REVIEW]
- For cookie/tracker clauses: cross-check ePrivacy text + Garante guidelines + CJEU jurisprudence
WebFetch for Source Extraction
When WebSearch finds a relevant official source:
- WebFetch the specific page -- request only the relevant section (article, recital, guideline paragraph)
- Extract: exact text, article/paragraph number, publication date, amendment history
- Store as evidence for the clause metadata
Recency Validation
Before generating any document:
- Check if cited guidelines have been updated or superseded
- Search
site:edpb.europa.eu and site:garanteprivacy.it for the current year to catch new guidance
- If a key source is older than 2 years: actively search for updates or confirmations
- Note the "last verified" date in the evidence pack
Research Output
For each document, produce an internal research log (included in evidence pack):
## Research Log
- Queries executed: {count}
- Official sources verified: {list with URLs}
- High confidence: {clauses with 2+ official sources}
- Medium confidence: {clauses with 1 official source}
- Needs verification: {clauses relying on training data only}
- Source recency: {oldest source date} to {newest source date}
1---2name: business-privacy-doc-generator3description: Draft and audit data-protection documents from a ROPA-driven model. TRIGGER WHEN: the user needs a Privacy Policy, Cookie Policy, DPA, consent notice, or DPIA under GDPR, ePrivacy, Codice Privacy, CCPA, LGPD, or FADP. DO NOT TRIGGER WHEN: general legal, contract, NDA, or IP questions (use legal-advisor); cookie banners, Consent Mode v2, or GTM (use digital-marketing:ga4-implementation-expert); business planning (use business-planner).4---56<!-- Generated by the Daodan compiler for pi. Edit the kernel, never this file. -->78# GOLDEN RULES910- NEVER generate legal text without gathering context first -- questionnaire before drafting11- Every clause must link to its normative basis (article, guideline, recital)12- Output is NEVER a substitute for licensed attorney review -- flag this prominently13- Mark assumptions and gaps as "NON SPECIFICATO" so the user knows what needs human review14- Use plain language -- avoid legalese unless legal precision requires it1516---1718# INTERNAL MODEL: ROPA-DRIVEN GENERATION1920Build an internal simplified ROPA (Record of Processing Activities, Art. 30 GDPR) before generating any document. The policy text derives from this structured model -- not the other way around.2122**ROPA nodes:**23- ProcessingActivity, Purpose, LegalBasis, DataCategory, DataSubject24- Recipient, TransferMechanism, RetentionRule, SecurityMeasure2526**Why:** policies built from structured data are auditable, consistent, and updatable. Free-text-first generation produces "beautiful but technically false" documents.2728---2930# PHASE 0: REGULATORY DELTA CHECK3132**Trigger:** This phase activates when the user passes an existing compliance document to review, update, audit, check, or assess. If the interaction is a brand-new document generation with no existing file, skip to PHASE 1.3334**Step 0.1 -- Extract normative context from document:**35- Read the file and identify: jurisdictions covered, normative sources cited (GDPR articles, EDPB guidelines, Garante provvedimenti, etc.), generation date or last-update date from metadata block36- Build a list of "normative dependencies" -- the specific regulations, guidelines, and rulings the document relies on37- If the document lacks a metadata block with date, ask the user when it was last generated/updated3839**Step 0.2 -- Targeted regulatory search:**40- For each normative dependency, run WebSearch queries using year-based terms covering the years from document date to today (e.g. `guidelines 2025 2026`) as proxy for date filtering:41 - `site:edpb.europa.eu guidelines {topic} {year}` for new EDPB guidelines42 - `site:garanteprivacy.it provvedimenti {topic} {year}` for new Garante provvedimenti43 - `site:eur-lex.europa.eu {regulation} {year}` for legislative amendments44 - `site:curia.europa.eu {topic} {year}` for relevant new CJEU rulings45- Cap at 4-6 targeted queries, prioritizing jurisdictions and sources most central to the document. If many jurisdictions, focus on primary ones and note others as unchecked46- If WebSearch returns no results for a source, note it as "unable to verify" in the output. If all queries fail, report the delta check as inconclusive and proceed to PHASE 14748**Step 0.3 -- Cascading output:**4950When updates are found, present a summary table:5152```53## Regulatory Delta Check54Document: {filename}55Period: {document date} - {today}56Jurisdictions: {list}5758| # | Source | Date | Update | Impacted section | Relevance |59|---|--------|------|--------|------------------|-----------|60| 1 | ... | ... | ... | ... | High/Medium/Low |6162Want to drill into any items? Indicate the numbers.63```6465When no updates are found:6667```68## Regulatory Delta Check69Document: {filename}70Period: {document date} - {today}7172No relevant normative updates detected for the jurisdictions and topics covered by this document.73```7475Output language follows the existing convention (match user's language).7677On user request for detail: explain the impact of the selected item and propose the specific modification to the document.7879**Feeding into PHASE 1:** If updates are found, incorporate them into the context gathering questionnaire (e.g. "your document does not cover X, introduced by Y -- do you want to include it?").8081---8283# PHASE 1: CONTEXT GATHERING8485## Step 1 -- Jurisdiction Setup8687- Default: EU/Italy (GDPR + ePrivacy + Codice Privacy art. 122 + Garante guidelines)88- Ask user for target jurisdictions; mark unselected extras as "NON SPECIFICATO"89- If user selects USA/CA: activate CCPA/CPRA module90- If user selects Brazil: activate LGPD module91- If user selects Switzerland: activate FADP module9293## Step 2 -- Business Profile9495Collect:96- Business type, sector (e-commerce, healthcare/telemedicine, hospitality, digital services, SaaS, other)97- Website URL and/or app identifiers98- Data controller identity and contact (+ DPO if appointed)99- Countries of operation and user base100101## Step 3 -- Processing Activities Questionnaire102103**Base questions:**104- What personal data categories are collected? (identity, contact, financial, behavioral, location, device)105- What are the processing purposes? (service delivery, marketing, analytics, legal obligation, other)106- What is the legal basis per purpose? (consent, contract, legitimate interest, legal obligation)107- Who are the data subjects? (customers, employees, website visitors, minors)108- Who receives the data? (internal teams, processors, third parties, public authorities)109110**Advanced questions (trigger-based):**111- Retention periods per data category112- International transfers -- destination countries, transfer mechanisms (SCC, adequacy, DPF)113- Special category data (health, biometric, genetic, political, religious) -- triggers Art. 9 + DPIA114- Minors' data -- triggers Art. 8 + age verification requirements115- Automated decision-making / profiling -- triggers Art. 22 disclosure116117## Step 4 -- Cookie/Tracker Assessment118119- List cookies and tracking technologies in use (analytics, marketing, functional, essential)120- For each non-essential tracker: require consent mechanism + pre-consent blocking121- Check: banner with reject option, easy withdrawal, no pre-ticked checkboxes (Planet49 CJEU)122- Verify alignment with Garante cookie guidelines (2021) and EDPB consent guidelines (05/2020)123124---125126# PHASE 2: RISK ANALYSIS & TRIGGERS127128## DPIA Trigger Check129130Evaluate against Art. 35 GDPR criteria + Garante's DPIA-required list:131- Large-scale processing of special categories132- Systematic monitoring of public areas133- Innovative technologies + vulnerable data subjects134- Scoring/profiling with legal effects135- Cross-dataset combination at scale136137If triggered: generate "DPIA REQUIRED" warning + semi-guided DPIA outline (scope, necessity, risks, mitigations)138139## Transfer Risk Assessment140141If data leaves EEA:142- Identify transfer mechanism (SCC 2021/914, adequacy decision, BCRs)143- If USA + certified provider: note DPF (Decision 2023/1795) with limitations144- If non-adequate country + SCC: generate supplementary measures checklist (EDPB 01/2020)145- Flag "NON SPECIFICATO" for unverified provider certifications146147## Sector Overlays148149Activate additional requirements when sector detected:150- **Healthcare/telemedicine:** Art. 9 special categories, Italian telemedicine guidelines, enhanced security151- **Hospitality:** TULPS art. 109 obligations, public safety data flows152- **E-commerce:** D.Lgs. 70/2003 information requirements153- **Digital content:** Directive 2019/770 requirements154155---156157# PHASE 3: DOCUMENT GENERATION158159## Supported Document Types1601611. **Privacy Policy** -- Art. 13-14 GDPR compliant information notice1622. **Cookie Policy** -- ePrivacy + Garante cookie guidelines compliant1633. **Data Processing Agreement (DPA)** -- Art. 28 GDPR controller-processor contract1644. **Consent Notice** -- Art. 7 GDPR compliant, purpose-specific1655. **DPIA Report** -- Art. 35 structured impact assessment1666. **Data Breach Notification** -- Art. 33-34 template1677. **ROPA Export** -- Art. 30 record of processing activities168169## Generation Rules170171**Clause selection:** deterministic, rule-based172- If purpose = marketing AND channel = email: legal basis = consent (require revocation mechanism)173- If tracker = marketing/analytics: require consent + pre-blocking + banner174- If data = health: Art. 9 condition required + DPIA prompt + enhanced security measures175- If basis = contract: do not use language suggesting optionality176- If basis = consent: require proof mechanism, revocation path, no bundling177178**Structure per document type:**179180### Privacy Policy Structure1811. Controller identity and contact1822. DPO contact (if applicable)1833. Data categories and sources1844. Processing purposes with legal basis per purpose1855. Recipients and categories of recipients1866. International transfers + mechanisms1877. Retention periods per purpose1888. Data subject rights (access, rectification, erasure, portability, objection, restriction)1899. Automated decision-making disclosure (if applicable)19010. Right to lodge complaint with supervisory authority19111. Updates and versioning192193### Cookie Policy Structure1941. What cookies/trackers are used (table: name, provider, purpose, type, duration)1952. Essential vs non-essential classification1963. Consent mechanism description1974. How to manage/withdraw consent1985. Pre-consent blocking disclosure1996. Third-party cookie providers200201### DPA Structure2021. Subject matter and duration2032. Nature and purpose of processing2043. Data categories and subjects2054. Controller obligations and rights2065. Processor obligations (Art. 28(3) points a-h)2076. Sub-processor management2087. Security measures (Art. 32)2098. Breach notification procedure2109. Audit rights21110. Data return/deletion on termination212213---214215# PHASE 4: VALIDATION216217## Hard Checks (must pass before output)218219- [ ] Purpose-basis coherence: every purpose has an explicit legal basis220- [ ] Consent mechanisms: if basis = consent, revocation + proof mechanisms documented221- [ ] Cookie compliance: no non-essential trackers without consent, reject option present222- [ ] Special categories: Art. 9 condition specified if health/biometric/genetic data223- [ ] DPIA: flagged if criteria met, not suppressed224- [ ] Transfers: mechanism specified for every extra-EEA transfer225- [ ] Roles: processors identified, Art. 28 contract referenced226- [ ] Art. 13-14 completeness: all required information fields present227- [ ] No pre-ticked consent checkboxes or equivalent dark patterns228229## Evidence Pack230231Every generated document includes:232- Normative references per clause (article, guideline, recital)233- Assumptions log -- what the agent inferred vs what the user confirmed234- "NON SPECIFICATO" markers for unresolved items235- Technical requirements checklist (banner config, blocking, consent logging)236237---238239# PHASE 5: OUTPUT240241## Format Options242243- **Markdown** -- default, structured with headers244- **HTML** -- styled, ready for website embedding245246## Metadata Block247248Every document includes a metadata footer:249250```251---252Generated: {date}253Version: {semver}254Jurisdictions: {list}255Document type: {type}256Assumptions: {count} (see assumptions log)257Unresolved items: {count} (marked NON SPECIFICATO)258Status: DRAFT -- requires legal review before publication259---260```261262## Versioning263264- Track document versions with semantic versioning265- Generate changelog when updating existing documents266- Maintain diff between versions for audit trail267268---269270# OUTPUT CONVENTIONS271272**Normative references** -- mandatory on every substantive clause:273- `[Art. 6(1)(a) GDPR]`, `[Art. 122 D.Lgs. 196/2003]`, `[Garante Cookie Guidelines 2021]`274275**Uncertainty markers:**276- `[NON SPECIFICATO]` -- information not provided, needs user input277- `[REQUIRES LEGAL REVIEW]` -- high-risk area, outside counsel recommended278- `[ASSUMPTION: ...]` -- agent inference, needs user confirmation279- `[SECTOR-SPECIFIC]` -- additional requirements may apply based on industry280281**Language:**282- Default output language: match user's language (Italian if context is IT-focused)283- Support multilingual generation for international businesses284- Plain language first, legal precision where regulation demands it285286---287288# KEY NORMATIVE SOURCES289290EU/Italy core:291- GDPR (Reg. EU 2016/679) -- full text on EUR-Lex292- ePrivacy Directive 2002/58/CE art. 5(3)293- Codice Privacy D.Lgs. 196/2003 art. 122294- Garante cookie guidelines 2021 (docweb 9677876)295- EDPB Guidelines 05/2020 on consent296- EDPB Transparency guidelines WP260 rev.01297- EDPB Guidelines 07/2020 on controller/processor298- Garante DPIA-required list (docweb 9058979)299- SCC Decision 2021/914300- EDPB Recommendations 01/2020 on supplementary measures301- EU-US DPF adequacy Decision 2023/1795302- CJEU Planet49 (active consent for cookies)303304Sector-specific:305- Italian telemedicine guidelines (Ministero della Salute)306- TULPS art. 109 (hospitality)307- D.Lgs. 70/2003 (e-commerce)308- Directive 2019/770 (digital content)309310Extra-EU (modular):311- CCPA/CPRA Civ. Code 1798.100+ (California)312- LGPD (Brazil)313- FADP (Switzerland)314315---316317# LEGAL RESEARCH METHOD318319Every document generation MUST include a research phase. Never rely solely on training data for normative claims -- verify against current sources.320321## Source Authority Hierarchy322323Ranked by reliability -- always prefer higher-tier sources:3243251. **Official legal texts** -- EUR-Lex, Normattiva, Gazzetta Ufficiale, Fedlex3262. **DPA guidance** -- garanteprivacy.it, edpb.europa.eu, cnil.fr3273. **Court decisions** -- curia.europa.eu (CJEU), national courts3284. **Institutional commentary** -- European Commission, national ministries3295. **Specialist legal analysis** -- law firms, academic journals (verify credentials)3306. **DEPRIORITIZE** -- SEO blogs, AI-generated summaries, generic compliance sites331332## Search Strategy333334### Query Construction335336Build queries that target official sources:337338**For EU legislation:**339- `site:eur-lex.europa.eu "2016/679" article {N}` -- GDPR articles340- `site:eur-lex.europa.eu "2002/58" article 5` -- ePrivacy341- `site:eur-lex.europa.eu "2021/914"` -- SCC decision342343**For national legislation (by jurisdiction):**344- Italy: `site:normattiva.it "196/2003" articolo {N}` -- Codice Privacy345- Italy: `site:gazzettaufficiale.it {decreto/legge reference}`346- Germany: `site:gesetze-im-internet.de {BDSG/TTDSG reference}`347- France: `site:legifrance.gouv.fr "loi informatique" OR "CNIL"`348- Spain: `site:boe.es "proteccion de datos" OR "LOPDGDD"`349- USA/California: `site:leginfo.legislature.ca.gov "1798" {section}`350- Brazil: `site:planalto.gov.br "LGPD" OR "13709"`351- Switzerland: `site:fedlex.admin.ch "235.1" OR "DSG"`352- UK: `site:legislation.gov.uk "data protection act 2018" OR "UK GDPR"`353354**For DPA guidelines (by authority):**355- EU: `site:edpb.europa.eu guidelines {topic} {year}`356- Italy: `site:garanteprivacy.it {docweb number}` -- Garante provvedimenti357- Italy: `site:garanteprivacy.it "linee guida" {topic}`358- France: `site:cnil.fr {topic} guidelines`359- Germany: `site:datenschutzkonferenz-online.de {topic}`360- UK: `site:ico.org.uk guidance {topic}`361- Spain: `site:aepd.es guia {topic}`362- Brazil: `site:gov.br/anpd {topic}`363364**For case law:**365- CJEU: `site:curia.europa.eu "Planet49"` or `"C-673/17"` -- case numbers366- `ECLI:{case identifier}` -- European Case Law Identifier367- National courts: search by case number + court name + "data protection"368369### Search Sequencing370371**Phase 1 -- Verify normative basis (BEFORE drafting):**372- Run 3+ parallel WebSearch queries for the key regulations applicable to the user's scenario373- Confirm article numbers, amendment status, and effective dates374- Check for recent Garante/EDPB decisions that modify interpretation375376**Phase 2 -- Sector and jurisdiction check:**377- If sector overlay active: search for sector-specific guidance and recent enforcement378- If extra-EU jurisdictions: search for current adequacy decisions, SCC updates379- If transfer mechanisms involved: verify DPF certification status, SCC version currency380381**Phase 3 -- Triangulation for high-risk clauses:**382- For clauses involving consent, special categories, DPIA, or transfers: require minimum 2 independent official sources383- If sources conflict: flag the discrepancy, cite both, mark as `[REQUIRES LEGAL REVIEW]`384- For cookie/tracker clauses: cross-check ePrivacy text + Garante guidelines + CJEU jurisprudence385386### WebFetch for Source Extraction387388When WebSearch finds a relevant official source:3891. WebFetch the specific page -- request only the relevant section (article, recital, guideline paragraph)3902. Extract: exact text, article/paragraph number, publication date, amendment history3913. Store as evidence for the clause metadata392393### Recency Validation394395Before generating any document:396- Check if cited guidelines have been updated or superseded397- Search `site:edpb.europa.eu` and `site:garanteprivacy.it` for the current year to catch new guidance398- If a key source is older than 2 years: actively search for updates or confirmations399- Note the "last verified" date in the evidence pack400401## Research Output402403For each document, produce an internal research log (included in evidence pack):404405```406## Research Log407- Queries executed: {count}408- Official sources verified: {list with URLs}409- High confidence: {clauses with 2+ official sources}410- Medium confidence: {clauses with 1 official source}411- Needs verification: {clauses relying on training data only}412- Source recency: {oldest source date} to {newest source date}413```414