This lesson is an optional deeper look that goes with course F07. It has worked examples with numbers and technical words. Start with F07 if you are new. Go to course F07 →
Law, Privacy and Responsibility Basics
You can place a concrete AI use in one of three classes, permitted, conditional, or prohibited. The classes are this course's house rules, built on GDPR and the EU AI Act. You can also strip identity numbers, contact details, and secrets from a text with the same filter every time, before the text is sent.
- Level
- First Light
- Time
- 10 h
- Prerequisites
- F07

Jump to
After this course you can
The student can classify 30 concrete AI deployment scenarios into permitted, conditional, or prohibited using the course's house rules built on GDPR and the EU AI Act, and strip personal data and secrets from text payloads using a deterministic pre-filter.
Personal data and who decides
When you type a customer's name, email, phone number, or Swedish personal identity number into a tool, that text is personal data if it points to a living person. A voice recording, a photo of a face, and a chat log tied to an account also count. A company name alone usually does not. If you can single someone out by combining fields, such as the nurse on night shift at Ward 4, treat the text as personal data even when the name is missing.
The one who decides the purpose and the means, why the data is used and how, is the controller. That is normally the organization, not the employee who types. The company that only runs the system on the controller's written instructions is the processor. If you paste a client's file into a public chat tool, your organization normally answers for that sending, even though you chose to do it. The provider then handles the text on terms you often cannot see. A written contract between controller and processor is how those terms get fixed before any transfer.
Legal basis, retention, and breaches
GDPR allows processing only when you have one of six legal bases. Consent means the person freely agreed and can take it back. Contract means you need the data to do what you agreed with them. Legal obligation means a statute forces you to keep or report it. Vital interests cover a serious threat to life. Public task covers official functions. Legitimate interests needs three things: a real interest, processing that is necessary for it, and a balance where the person's interests and rights do not override it. What the person can reasonably expect counts in that balance. Choose the basis before you send anything, and write it down.
Keep personal data only for as long as the stated purpose needs it. After that, delete it or anonymise it so nobody can single the person out. A person can ask you to erase data about them. You erase it when, for example, the purpose is done, they withdraw consent, or the data was never lawful to hold, unless a statute tells you to keep the file. Write the retention period next to the purpose before the first upload, in days or months you can check.
If a personal data breach is likely to risk people's rights and freedoms, notify the supervisory authority within 72 hours of becoming aware, where that is feasible. Tell the affected people when the risk to them is high. Fines for the most serious GDPR failures can reach 20 million euro or 4 percent of worldwide annual turnover, whichever figure is higher. This text is general information for learning. Ask a qualified lawyer to apply the rules to a real matter.
The EU AI Act: literacy, openness, bans
Article 4 of the EU AI Act requires firms that supply or use AI to give the people who operate those systems enough AI literacy. That means they understand what the system can do, where it fails, and what harm a wrong output can cause in their work. A clinic, a school, and a web shop need different depth. If staff paste customer text into a model, give them a written rule for what may be pasted, who checks the output, and when a human decides.
Article 50 requires openness. If a person could reasonably think they are talking to a human, you tell them they are talking to an AI. The same idea covers marking synthetic audio, images, and video when the rules say the audience must be able to tell the content was generated. A label in the footer that a reader never sees misses the duty. Give the notice at the latest at the first interaction, in plain language, on the screen they actually use, including a phone.
Some uses are banned in the EU. Article 5(1)(a) bans subliminal, manipulative, or deceptive techniques that materially distort behaviour by impairing an informed decision and cause, or are reasonably likely to cause, significant harm. Article 5(1)(b) bans exploiting a weakness linked to age, disability, or a specific social or economic situation in the same way. Social scoring that rates a person across life areas and then withholds a service is banned. Article 5(1)(e) bans building or expanding a facial recognition database by untargeted scraping of face images from the internet or CCTV footage. Emotion recognition at work and in schools is banned aside from narrow cases you should assume you lack. If your idea is on this list, stop.
Copyright, keys, and the Polaris rules
Paste a text, image, or recording into a model only when you already have the right to use it for that purpose. A paywalled article, a client's unpublished draft, and a private photo need that right first. A website login only lets you read the page. Forwarding the file to a model vendor needs a separate right. Read every output before you publish. Cut any passage that repeats source material you were not allowed to reuse, and note what you supplied.
An API key is a secret that can spend money and read data in your name. Store it in an environment variable on the machine that runs the program, and load it at start-up. Keep it out of source files, chat windows, screenshots, and tickets. If a key has landed in any of those, revoke it and issue a new one. Before a payload leaves your machine, run one fixed pre-filter, same patterns, same order, every time. Strip identity numbers, emails, phone numbers, and key-like strings.
Four Polaris house rules apply before practice work. Never present a chatbot as a human. Never paste personal data or secrets into a public chatbot. Never feed in material you lack the right to use. Never put an API key in code or in a prompt. Breaking one makes the case prohibited here. Conditional means you continue only after a named fix, such as a lawful basis or a finished pre-filter. Permitted means the text is yours, with no personal data or secrets, and the assistant shows it is AI.
Three cases and one filter you can check
Use the same three labels on each case: prohibited, conditional, or permitted. Case one. A shop bot opens with a human first name and a job title, and the screen never says the speaker is software. A reasonable person can think they have reached a staff member. Article 50 requires a clear statement that they are talking to an AI, and house rule one bans the human pretence. Label: prohibited. It becomes shippable only after the first message itself says the assistant is AI, in words the user sees on that screen.
Case two. An agent pastes this example mail into a public chatbot: "Anna Berg, personnummer 19800505-1234, order 4401, please refund." The identity number is made up for the exercise, and the shape still points at one living person. The public tool has no processor contract you can show, and you have written neither a legal basis nor a retention period. House rule two bans the paste. Label: prohibited. The same mail becomes conditional only inside a tool the employer has contracted, after the basis and the retention period are written down and the pre-filter has run.
Case three. You ask a model to shorten your own notes: "Discussed the budget draft. Next step is a one-page brief on Tuesday." You wrote the notes. They hold no name, no contact detail, no identity number, and no secret. Label: permitted. You still run the filter, so a later sentence cannot add a name without the hit count moving.
Now run the filter on the case-two mail and check the arithmetic by hand. The example mail is 65 characters. Rule ID matches eight digits, a hyphen, and four digits. One hit, 19800505-1234, 13 characters at positions 25 to 37. Replace it with [ID], 4 characters. Rule NAME matches two capitalised words in a row. One hit, Anna Berg, 9 characters at positions 1 to 9. Replace it with [NAME], 6 characters. Rule EMAIL matches an @ sign. Zero hits. Rule KEY matches sk- plus at least ten further characters. Zero hits. Characters removed: 13 + 9 = 22. Characters added: 4 + 6 = 10. Net change: 22 - 10 = 12. Cleaned length: 65 - 12 = 53. The cleaned example reads: "[NAME], personnummer [ID], order 4401, please refund." Order 4401 stays, because four digits do not match the ID rule. The filter checks shape, not that the number is a real identity number.
Clean one note on paper
Copy this example note into a text editor or onto paper: "Note: Kari Nilsen called. Email kari.n@example.com. Ref 2020. Key sk-abc1234567890 sits in the draft." Apply the rules in this order. NAME: two words in a row that each start with a capital letter become [NAME]. EMAIL: a token that contains @ becomes [EMAIL]. KEY: sk- followed by at least ten characters becomes [KEY]. ID: eight digits, a hyphen, and four digits becomes [ID]. Then label the act of pasting the original note into a public chatbot as permitted, conditional, or prohibited, and count the characters in your cleaned line.
The cleaned line is "Note: [NAME] called. Email [EMAIL]. Ref 2020. Key [KEY] sits in the draft." The original has 101 characters and the cleaned line has 74, because you removed 11 + 18 + 16 = 45 characters and inserted 6 + 7 + 5 = 18, and 101 - 45 + 18 = 74. Ref 2020 is still there. The ID rule fired zero times. The public paste is prohibited, because the original holds a name, an email, and a key.
Check questions
How many legal bases does GDPR provide for processing personal data, and which basis can the person take back?
Six. Consent, because it holds only while the person still agrees and they can withdraw it.
A breach is likely to risk people's rights. How fast do you notify the supervisory authority, counting from when you become aware, where that speed is feasible?
Within 72 hours.
Which label do you give a chatbot that uses a human name and never says it is AI, and which EU AI Act article is the reason in this text?
Prohibited under house rule one. The EU AI Act reason is Article 50, which requires you to tell the person they are talking to an AI.
In the worked mail of 65 characters, what is the cleaned length after the ID and NAME replacements, and which class is the public paste?
53 characters. The public paste is prohibited.
Write the purpose, the legal basis, and the retention period before personal data moves, and say so when a person is talking to an AI. Run the same pre-filter on every payload so identity numbers and keys stay on your machine.
Final task
Pass a 30-item keyed legal/safety classification benchmark and submit a PII/secret redaction pre-filter script that removes 100% of seeded personal identifiers, emails, phone numbers, and API keys across 20 fixed test fixtures.
This lesson is open to read. Tests, diplomas and accounts come later; the waitlist is for those. Join the waitlist