Preparing case and citizen data for analysis in a public body: what to remove before a file leaves your system
Public bodies hold records about people who had no choice about being in them. This guide shows what an analysis of a case, service or request file really needs, what to remove before the file goes to an AI tool or another team, and which questions to ask first.
Public bodies are asked to do more with less. Analysts there are curious about what an AI assistant could do with a spreadsheet: find patterns in service requests, summarize months of case outcomes, or point out where waiting times grow.
The records behind those questions are different from commercial data. Residents, applicants and service users did not choose to be in them. Many were obliged to provide their details to obtain a benefit, a permit, a school place or care. This guide explains what an analysis usually needs from such a file, what to take out first, and which questions to put to the right person in your organization before anything leaves your systems.
Key terms
- Case or service file
- a table with one row per case, request, application or contact, kept by a public body.
- Direct identifier
- a value that names a person on its own, such as a name, an email address, a national identification number or a phone number.
- Indirect identifier
- a value that points to a person only in combination with others, such as a postal code together with an age and a rare occupation.
- Stand-in
- a made-up label used in place of a real name or number, such as
CASE_0412. - Approved tool
- a service your organization's security or data protection function has examined and permitted for a stated kind of data.
Why does this need separate attention?
Three things make public-sector files different.
- The people had no choice. A customer can stop buying from a company. A resident usually cannot stop dealing with the authority.
- The files often reveal sensitive circumstances. A housing list, a social-care register or an appeals file says something about health, income or family life by its existence.
- Plans and decisions are sensitive too. A file that shows what a department intends to do next can be sensitive even when it has no personal data in it.
Many governments have written guidance on this. The United Kingdom's guidance for civil servants on generative AI, for example, says not to enter personal data, sensitive information or classified information into publicly available tools. It says to avoid input that would reveal government intentions that are not yet public. It also says that specialist analysis of large text datasets should use tools hosted on government servers that are not publicly available. That guidance was later superseded by a longer framework, so the current document is the one to read, and your own country and organization may have their own rules.
Who decides what you may use?
Before you think about which columns to remove, find out which tools your organization has approved, and for which kinds of data. In many public bodies the answer is that public AI services are not approved for personal or sensitive data at all, and that approved tools run on the organization's own infrastructure or under a contract with specific terms.
The data protection officer, the security team, or the person who manages information governance can usually tell you in a short conversation. Bring the question you want to answer, the columns you think you need, and the tool you have in mind.
What does the analysis need?
Write the question first. "How long do applications of each type take, month by month?" needs the application type, the date received and the date decided. It does not need an applicant's name, address, identification number or the caseworker's notes.
| Kind of file | Often needed | Usually not needed |
|---|---|---|
| Service requests | Request type, date received, date closed, district, channel | Name, street address, phone number, email, free-text description |
| Benefit or permit applications | Application type, dates, decision category, processing office | Name, date of birth, identification number, address, supporting documents |
| Case management | Case type, stage, dates, outcome category, team | Name, family details, notes, referral reasons in free text |
| Staff or workload records | Team, grade band, month, hours | Name, employee number, manager's comments |
What about free-text fields?
Case descriptions, call records and complaint text are written in ordinary sentences. They name neighbours, children, employers and conditions, and a search for the names in your own table will not find all of them. Remove them unless the question depends on them. If it does, the decision to share them belongs to the person responsible for that data, and the file will usually need to stay inside an approved environment.
Can small numbers identify people?
Yes. A table that counts three households with a certain condition in one small district may point to the people involved, even when no name appears. Public bodies often have rules on small numbers when they publish statistics, and the same care applies when you share a working file. Combine small districts into larger regions, use age bands instead of birth dates, and use months instead of days.
How do you protect the file?
- Ask which tools are approved for this kind of data, and use only those.
- Write down the question and list the columns it needs.
- Delete every other column, starting with names, identification numbers, addresses, contact details and free text.
- Replace what you must keep, such as a case reference, with a stand-in that is the same every time.
- Make rare values coarser, such as a small district, an unusual occupation or an exact date.
- Keep the list of stand-ins in a separate, controlled place. Anyone who holds it can undo the protection.
- Record what you did, with the date, the question, the tool and who received the file. Public bodies are often asked to account for such decisions later.
How do you check what is left?
Can you read the results in terms of real cases?
If you kept the stand-in list, yes. When the assistant says "CASE_0412 took the longest", you put the real reference back on your own computer, inside your organization. See putting the original values back after an AI answers.
How can DataAttendant help?
DataAttendant is a tool that runs in your web browser, on your own computer. You open a CSV or Excel file. It looks for names, email addresses, phone numbers, account numbers and other personal details, and suggests what to do with each kind of value. It shows you a preview and a list of what remains before you download the protected copy. You decide every treatment, and you can save your choices as a reusable plan for the next export of the same kind. It cannot find everything, so the checks above still apply, and it does not decide whether a file may be shared or whether a service is approved. Your file is processed in your browser and is not sent to DataAttendant. How DataAttendant works shows the steps. Whether using it fits your organization's rules is a question for your security or data protection function.
Sources
- UK Government, "Guidance to civil servants on use of generative AI", gov.uk. Read 28 October 2026. The page states that it has been superseded by the Generative AI Framework for HMG; it is cited here as an example of the kind of rule public bodies publish, not as a rule that applies to every reader.
- European Data Protection Supervisor, press release of 28 October 2025 on revised guidance on generative AI for EU institutions, which describes a compliance checklist and clarifies when an institution acts as controller, joint controller or processor. Read 28 October 2026.
- Which rules apply to a particular public body (national law, sector rules, security classification schemes) is not covered here; the reader's own data protection officer or legal adviser decides.
Where next?
- How to remove personal details from a spreadsheet before you use an AI assistant
- Replacing real names with consistent stand-ins so your analysis still works
- Which files DataAttendant can open, and what happens to each kind
- What data should not go into an external AI tool
- All articles
- What DataAttendant does
- Terms of service
