# Privacy Notice (EU GDPR, UK GDPR / DPA 2018 & US CCPA/CPRA)

> **DRAFT FOR LEGAL COUNSEL REVIEW:** This document is a draft prepared for review by qualified legal counsel prior to publication or commercial use. Replace all bracketed placeholders (`[PLACEHOLDER]`) with verified entity details.

**Effective Date:** `[EFFECTIVE_DATE]`  
**Version:** `1.0`

---

## 1. Data Controller Identity

The data controller responsible for processing personal data in connection with the **Imladris** software ("Software") and associated documentation portals is:

* **Controller:** `[LEGAL_ENTITY_NAME]`
* **Registration / Company Number:** `[COMPANY_REG_NUMBER]`
* **VAT / Tax ID:** `[VAT_OR_TAX_ID]`
* **Registered Address:** `[REGISTERED_ADDRESS]`
* **Privacy / Data Protection Contact:** `[PRIVACY_CONTACT_EMAIL]` (or `[PEC_OR_LEGAL_EMAIL]`)

---

## 2. Core Privacy Architecture: Local-First, Zero Telemetry

Imladris is engineered as a **local-first desktop workbench**. The Software:

* collects **no** usage analytics, advertising identifiers, crash telemetry, or behavioral tracking;
* sets **no** HTTP cookies; and
* transmits **no** data to `[LEGAL_ENTITY_NAME]` on startup, during editing, or on shutdown.

---

## 3. Categories of Personal Data, Purposes & Lawful Bases

| Processing Activity | Data Categories | Purpose | Lawful Basis (EU/UK GDPR Art. 6) |
| :--- | :--- | :--- | :--- |
| **Local Workspace & Qualitative Audit Trail** (`.imladris-qual.db`, XDG config/cache) | User-entered coder identifier (defaults to local OS username), authored manuscripts, analytical memos, CRA review queries, UTC timestamps | Provide local editing, qualitative coding, and ALCOA+ reproducibility audit logs on the user's device | Performance of a contract / user-directed local processing (Art. 6(1)(b)) |
| **Opt-In Cloud AI Inference** (`AiClient`, `CopilotAuthService`) | Prompts and manuscript excerpts explicitly submitted by the user; OAuth device tokens (stored locally in OS keyring / `0600` config) | Generate AI code or text completions via the user's chosen external AI provider | Explicit consent (Art. 6(1)(a)) / Performance of a user-requested action (Art. 6(1)(b)) |
| **User-Triggered Scientific & Documentation Lookups** | Gene/protein/DOI search terms, package names, Galaxy API key (if configured by user), HTTP `If-None-Match` ETag headers | Resolve biological/citation identifiers, install R/Python packages, and update offline Help Hub manuals | Performance of a user-requested action (Art. 6(1)(b)) / Legitimate interest in software delivery (Art. 6(1)(f)) |
| **Optional Privacy & Support Inquiries** | Name, email address, and inquiry content sent by the user | Respond to support requests or exercise statutory data protection rights | Legitimate interest (Art. 6(1)(f)) / Legal obligation (Art. 6(1)(c)) |

---

## 4. External Recipients & International Data Transfers

Imladris does not sell personal data or share personal data for cross-context behavioral advertising (as defined under the **California Consumer Privacy Act / CPRA**). External network requests occur **only** when explicitly initiated or configured by the user:

1. **User-Selected Cloud AI Providers** (e.g., OpenAI, Anthropic, Google Gemini, DeepSeek, NVIDIA, Moonshot/Kimi, Alibaba Qwen, Groq, Cerebras, OpenRouter, GitHub Models / Copilot): Requests travel directly over TLS from the user's device to the selected provider's API endpoint using the user's own credentials. Free-tier quota failover is disabled unless explicitly enabled (`free_api_consent_accepted`).
2. **Scientific & Documentation Endpoints:** Public read-only queries to UniProt, Ensembl, AlphaFold DB, CRAN, PyPI, CrossRef, HuggingFace Hub, and GitHub Raw documentation repositories; or user-authenticated requests to Galaxy (`usegalaxy.eu`, `usegalaxy.org`, `usegalaxy.org.au`) or Zotero.
3. **Exported Reveal.js HTML Slides:** HTML presentations exported from `PresentationTemplateDialog` reference `cdn.jsdelivr.net` for Reveal.js assets when viewed in a web browser.

Where user-initiated requests transfer data outside the **European Economic Area (EEA)** or the **United Kingdom**, such transfers are governed directly by the user's agreement with the chosen third-party provider and applicable safeguards (such as the **EU-US Data Privacy Framework**, **EU Standard Contractual Clauses [SCCs]**, and the **UK International Data Transfer Addendum [IDTA]**).

---

## 5. Retention Periods

* **On-Device Data:** Retained under the user's sole control until deleted by the user or erased via `imladris --purge-user-data`.
* **Support & Legal Correspondence:** Retained for `[RETENTION_PERIOD_SUPPORT]` or as required by applicable statutory limitation periods.

---

## 6. Your Statutory Rights (EU GDPR, UK GDPR & US State Laws)

Subject to applicable law, you have the right to:

* **Access & Portability (GDPR Art. 15 & 20; DMA):** Obtain confirmation and export your data in open, machine-readable formats (Markdown, Quarto `.qmd`, JSON, CSV, CX2, GraphML, SQLite).
* **Rectification & Erasure (GDPR Art. 16 & 17):** Correct inaccurate data or permanently erase all local application state, caches, and credentials using `imladris --purge-user-data` (or by contacting `[PRIVACY_CONTACT_EMAIL]` for any correspondence held by `[LEGAL_ENTITY_NAME]`).
* **Restriction, Objection & Withdrawal of Consent (GDPR Art. 7(3), 18, 21):** Disable cloud AI providers or withdraw `free_api_consent_accepted` at any time in Preferences without affecting offline functionality.
* **Non-Discrimination (CCPA/CPRA):** We will not discriminate against you for exercising privacy rights.

### Supervisory Authorities

* **European Union:** You may lodge a complaint with the **Garante per la protezione dei dati personali** (Italy) or your local EU Data Protection Authority.
* **United Kingdom:** You may lodge a complaint with the **Information Commissioner's Office (ICO)** (`ico.org.uk`).
* **United States:** You may contact your relevant State Attorney General.

---

## 7. Children's & Youth Data

Imladris is a professional scientific workbench not directed to children. Users must meet the minimum age of digital consent in their jurisdiction (**13 years** in the UK and US under COPPA; **14 years** in Italy; **13–16 years** across EU Member States under GDPR Art. 8) or have verifiable parental/guardian authorization.
