By · Last updated 2026-03-20

返回博客GDPR 与合规

仅支持英语的PII工具:GDPR合规盲区

德国税号(Steuer-ID,11位含校验位)与美国社会安全号码在结构上截然不同。法国NIR号码有15位。波兰PESEL和瑞典Personnummer各有其格式。

March 20, 20268 分钟阅读
GDPR multilingual complianceSteuer-ID detectionFrench NIRSwedish PersonnummerEU PII identifier formats

仅支持英语的PII工具:GDPR合规盲区

GDPR不区分语言

GDPR覆盖任何语言的个人数据。德语、法语、波兰语、瑞典语——均受到同等保护。遗漏一个Steuer-ID(税号)所带来的法律风险,与遗漏一个社会安全号码完全相同。法律不在乎数据是什么语言。

然而,大多数PII检测工具确实在乎。

主流商业和开源工具均以英文文本为基础构建,其实体检测器也反映了这一点——能够良好识别美国社会安全号码、美国驾照和北美电话格式,但对非英语国家身份证件的检测精度明显不足:更新不及时,漏报率更高。

这对欧盟成员国的企业而言,形成了显著的覆盖缺口。工具报告显示检测已完成,但非英语标识符依然留存于数据中——而这些标识符往往是某些国家GDPR合规风险最高的字段。

数据监管机构对此心知肚明,审计人员也会重点关注这一问题。一款工具在处理英文记录时表现良好,却在德语或法语记录上失效,同样不符合合规要求。审计报告没有问题,并不代表实际没有问题。

各国国家标识符结构各异

以英语为中心的工具与多语言工具之间的差距,并非多加几条正则表达式就能弥补。欧盟各国的国家标识符格式差异极大,需要针对各国的专项逻辑才能准确识别。

德国税务识别号(Steuer-ID): 11位数字,采用基于Luhn变体的校验算法。通用社会安全号码正则无法匹配;而针对任意11位数字的正则又会在德语文档中产生大量误报。

法国国家身份号码(NIR): 15位数字,编码了性别、出生年份、出生月份和出生省份,还包含出生序列号和2位校验码,必须验证校验码才能准确识别。

瑞典个人号码(Personnummer): 10位数字,含Luhn校验位。1990年前出生的人使用 + 作为分隔符,而非 -,导致需要识别的格式不同。

波兰全民身份证号(PESEL): 11位数字,编码了出生日期、性别及基于加权求和的校验位,准确识别需同时匹配格式和验证校验位。

以上标识符没有共同的格式规律:长度不同、校验方式不同、各字段编码位置也不同。以英语训练的命名实体识别(NER)模型看到法语NIR号码时,不会将其识别为国家标识符,而是直接忽略或错误分类。

实际合规风险

设想一位欧洲BPO(业务流程外包)公司的合规官,同时处理来自德国、法国、波兰和荷兰的数据。工具报告显示PII匿名化已成功完成。

但结果并不完整:德语记录中的Steuer-ID依然存在,法语记录中的NIR号码依然存在,波兰语记录中的PESEL号码依然存在。工具对这些格式的检测器缺失或精度不足。

随后,该数据集进入分析环节或流向研究合作伙伴,其中仍包含可重新识别的国家标识符。GDPR合规问题不会出现在工具的输出日志中,而是在数据主体访问请求到达时浮现,或在数据监管机构审计期间曝光,甚至在数据泄露事件后才暴露。

对比混合多语言方法与以英语为中心工具的研究结论非常明确:混合方法在欧洲各地区的F1分数达到0.60至0.83,而纯英语工具在非英语国家身份证格式上的得分接近于零。

关于这些差距如何对应GDPR义务,请参阅我们的GDPR合规概述

全面覆盖的必要条件

要实现针对欧盟GDPR合规的真正多语言PII检测,需要三个层次的支撑。

语言原生spaCy模型提供对文本语言的语义理解。以德语文本训练的模型知道Müller是常见的德国姓氏;spaCy已为25种欧盟主要语言提供对应模型。

Stanza NLP模型将覆盖范围扩展至spaCy尚未支持的语言,为更多欧盟语言社区提供识别能力。

跨语言Transformer模型(XLM-RoBERTa)处理跨语言场景。法语句子中的人名能被识别为人名,即使模型并未在该具体名字上进行训练。

带国家特定校验的正则表达式覆盖结构化国家标识符。Steuer-ID、NIR、PESEL和Personnummer各需其独立的校验逻辑,从而减少误报——不通过国家校验规则的数字序列将被过滤掉。

这一差距源于结构性问题。添加词表或更多正则表达式仅能带来微小改善,从一开始就内置欧盟标识符覆盖能力才是唯一可靠的解决方案。

检验您当前使用的工具

向供应商索要针对德语、法语、波兰语和荷兰语记录的F1分数。所谓「支持多语言」往往意味着工具先进行翻译再扫描,这并非原生扫描。GDPR合规要求原生扫描。

使用真实国家身份证样本进行测试:针对您业务中涉及的每种证件类型各准备10个样本——Steuer-ID、NIR、PESEL、Personnummer——检查检测率。这比完整的F1测试更快,能迅速暴露覆盖缺口。

了解anonym.legal如何满足这些要求,请访问安全与合规页面。关于实体类型定义,请访问实体参考

参考资料

准备好保护您的数据了吗?

开始使用 285 种实体类型在 48 种语言中匿名化 PII。

About this page

We update this page when our platform or the law changes.

Read our founder note for how we work.

Each change shows up in the timestamp at the top.

Related reading

We follow these rules

  • GDPR (EU 2016/679).
  • ISO/IEC 27001:2022.
  • NIS2 (EU 2022/2555).
  • HIPAA safe harbor under 45 CFR § 164.514(b)(2).

Our promise

We do not sell your data.

We do not train models on your text.

We store your files in Germany.

You can delete your account at any time.

You own your work.

Where we run

Our servers live in Falkenstein, Germany.

We use Hetzner. They hold ISO 27001 certification.

All data stays in the EU.

Backups run every day.

Need help?

Email support@anonym.legal.

We reply within one business day.

How we test

We run a full check suite on every release.

Each surface gets its own sweep script and report.

Human reviewers spot-check the output each week.

We track recall and precision on a labelled set.

Bad runs block the deploy.

What we never do

  • We never sell your information to third parties.
  • We never train models on what you upload.
  • We never keep your work after you delete it.
  • We never share keys with any outside firm.
  • We never run ads inside the product.

Plans in plain words

We sell credits, not seats.

One credit covers one short job.

Long jobs use a few credits each.

You can top up at any time.

Unused credits roll over each month.

Read the plans page for current rates.

Who built this

A small team of engineers and lawyers built this.

We ship from Europe and work in the open.

Our founder note spells out why we started.

Where to start

How the parts fit

A browser add-on cleans text inside Chrome.

A Word plug-in handles drafts in Office.

A small desktop tool works on whole folders.

An agent protocol link feeds large models safely.

All four share one core engine and one rule set.

Words from our team

We started this work after a lunch about cookies.

One friend kept getting odd ads on her phone.

We asked why a court file leaked through a draft.

We sketched the first build on a napkin that week.

By month three we had a tiny demo for a friend.

She used it on her first case the next day.

Common questions we hear

Can the tool read scanned PDFs? Yes, with OCR.

Does it work on long files? Yes, in small chunks.

Can I roll my own rule set? Yes, save it as a preset.

Does it run offline? The desktop build runs offline.

Do you keep my files? No, the cloud build wipes after each run.

Will it learn from my work? No, we never train on inputs.

A short tour of the workflow

Upload a file or paste a snippet of prose.

Pick the entities you want gone from the draft.

Choose a method: replace, mask, hash, encrypt, or redact.

Press run and watch the side panel show each hit.

Skim the result and tweak any rule that misfired.

Save the cleaned file or send it to a teammate.