Skip to content
Anton GoncharovAI systems developer

Web app · personal data · healthcare · analytics

Anonymizing data before it reaches a neural network

A clinic wants a neural network to answer patients and process insurers’ emails, but full names, passports and diagnoses can’t be sent outside: this is personal data, and health is a special category under Russia’s Federal Law 152-FZ. Replace everything with asterisks and the answer becomes useless. Here the agent shows every finding with an explanation, substitutes labels or plausible names in the same grammatical case, verifies that no hidden value leaks out and restores the answer for the staff member.

Scenario: Myata Clinic — fictional: a complaint in chat, an insurer’s letter of guarantee, a call-center call, a doctor’s CV and an export of 200 patients for analytics. You can paste your own text.

Demo screenshot: Anonymizing data before it reaches a neural network

Open the demo

Best on a computer: the original text and what goes to the neural network are side by side.

The app runs in your browser: nothing is sent to a server.

What the demo shows

  • Full names in any case, with initials and in reverse order: Russian case forms of the same surname are recognized as one person

  • Phones, emails, handles, passports, compulsory and voluntary health insurance policies, addresses, car plates, IP addresses

  • SNILS, tax IDs and cards with checksum validation: a number with an error is still hidden but flagged for review

  • ICD-10 diagnoses and health-related words are a special category: they can only be replaced with a label

  • The clinic’s and insurer’s details — company tax ID, bank account, contract number — aren’t hidden but explained

  • Three modes: “[NAME_1]” labels, substitution with plausible data of the same format, a “+7 (9**) ***-**-18” mask

  • A substituted name is declined like the real one, and a husband and wife keep a shared fictional surname

  • A check before sending: no hidden value in the request; the neural network’s answer is restored from the substitution vault

  • Your own rule in one click: select a fragment and it’s hidden everywhere in the text; a false finding can be left as is

  • Patient table: k-anonymity, generalizing birth dates and cities, removing rare groups and groups with a single diagnosis, auto-tuning

  • An audit log of submissions: what went out, how many values were hidden, whether there were leaks

How to try it

  1. See what the agent found

    The patient’s complaint has names, a birth date, a card, a phone, a policy and a diagnosis highlighted. Click a highlight and the agent explains why it’s personal data.

  2. Turn on “Substitution” and send

    The neural network gets a different patient and a different doctor in the same grammatical cases and writes a reply. On the right is the same reply with the real names and card.

  3. Open the letter of guarantee

    The passport, SNILS and diagnosis are hidden, while the clinic’s tax ID and the insurer’s bank account remain: they are company details, not personal data.

  4. Find what the agent missed

    In the call, the intercom code “87K1234” doesn’t match any format. Select it with the mouse and it’s hidden everywhere in the text.

  5. Anonymize the patient table

    In the export everyone can be identified by name. Press “Tune automatically”: names and phones go, the birth date becomes a decade, and diagnosis analytics stays.

  6. Paste your own text

    “Your text” — an example or any email. The example has a card number with a checksum error: the agent hides it and asks you to check it.

No paid neural networks

Personal data is found by rules: a dictionary of names and surname declensions, phone and document formats, SNILS, tax ID and card checksums, and diagnosis marker words. The neural network here is a stub that replies from a template based on what it was sent. In a production project there’s a model call in its place, and data search can be boosted with a named-entity recognition model on your own server.

The demo runs without OpenAI, YandexGPT or GigaChat API keys. Wherever a production system calls a model, there’s a local stub with the same interface — so the demo is free, always available and never makes things up.

What a production project adds

  • Anonymization as a separate service in front of any call to GPT, Claude, YandexGPT or GigaChat: chatbots, email triage, analytics
  • Name and address search is complemented by an entity recognition model (Natasha, spaCy) running on your side — data never leaves your perimeter
  • The substitution vault lives only for the duration of a request and is encrypted; the log stores anonymized text
  • Exports from medical information systems, CRM and 1C are anonymized with the same rules before analytics and model training
  • Industry rules: medical, banking and HR documents; staff members’ manual rules become shared

Stack

  • React 19
  • TypeScript
  • Zustand
  • Vite
  • Tailwind CSS

Developer’s comment

Anton Goncharov

AI systems developer · Python

For business

  • A neural network can be connected to the clinic’s chat, email and analytics without sending out any full names or diagnoses.
  • The reply to the patient stays useful: the model sees a plausible name in the right grammatical case, and the staff member sees the real one.
  • The submission log shows an auditor exactly what went to an external service and that nothing leaked.

For developers

  • Detection, replacement and restoration are pure functions of the text and settings: tests run all documents in three modes and check that the request contains no hidden value.
  • Names are found by word roles — surname, first name, patronymic, initials — trying every grammatical case, so the replacement uses the same form and all mentions of a person get one label.
  • Numbers are checked by checksums, not only by format: SNILS, tax IDs and cards (Luhn) are distinguished from a contract number.

Tips

  • Tip 01

    Put anonymization at the boundary with the external API rather than inside each bot: one place for rules, checks and the log.

  • Tip 02

    Removing full names isn’t enough for analytics: birth date, gender and a small town together also point to a person — check k-anonymity.

Want the same for your business?

Tell me about your task — I’ll tell you what from the demo fits, how long it will take and what I’ll need from you.

Other demos in this section

All demos
  • Web app · agent diagram

    live

    AI agent builder

    A support agent is assembled from blocks: intents, a knowledge base, API calls, checks and operator handover. Send a customer message and watch its path light up on the diagram step by step.

    • React
    • TypeScript
  • Web app · question → SQL → chart · PostgreSQL in the browser

    live

    AI data analyst

    A manager asks in plain words — “revenue by channel for Q3”, “which customers stopped ordering” — and gets SQL, a chart, a table and a conclusion. The sales database is real PostgreSQL running right in the browser.

    • React
    • TypeScript
  • Web app · risks against a standard · Word with tracked changes

    live

    Contract review

    A counterparty sent their own contract — the review compares it with the company’s standard, highlights risky clauses, explains why they’re dangerous and suggests wording. The output is a Word file with tracked changes and a disagreement protocol.

    • React
    • TypeScript
  • Web app · tasks from chat · kanban · evening digest

    live

    AI agent in a team chat

    People write in the team chat as usual — “Pete, fix the price list by Friday”. The agent creates a task on the kanban board, moves it through “On it” and “Done”, reschedules and reassigns tasks, reminds about overdue work in the morning and sends a digest in the evening.

    • React
    • TypeScript
  • Web app · shared inbox · CRM · protection against bank detail fraud

    live

    AI inbox triage

    The agent reads the sales team’s shared inbox: it understands what each email is, extracts fields, creates a deal, a ticket or a task in the CRM and drafts a reply. An invoice with new bank details or a phishing email is caught before anyone pays or clicks a link.

    • React
    • TypeScript
  • Web app · marketplaces · moderation check · unit economics

    live

    Product listings for WB and Ozon

    The agent turns a supplier’s text into two listings — for Wildberries and for Ozon: a title within the marketplace limit, a description with search keywords, attributes from the reference lists. Then it checks what listings usually fail moderation on and calculates what’s left from each sale.

    • React
    • TypeScript
  • Web app · meeting transcript · minutes · kanban

    live

    Meeting minutes → kanban tasks

    The agent reads a stand-up transcript and builds the minutes: decisions, tasks with an assignee and deadline taken from live speech, risks and open questions. Tasks go to the kanban board, and at the next meeting the agent moves them through statuses itself.

    • React
    • TypeScript
  • Web app · automation · amoCRM, 1C, Telegram

    live

    An n8n-style automation pipeline

    Three working scenarios of a furniture factory on a canvas, as in n8n: website leads go to amoCRM and to managers by lead temperature, YooKassa payments go to 1C with retries and an error branch, and every morning there’s a digest for the director. Trigger an event and watch records flow from node to node; the workflow can be edited and exported to real n8n.

    • React
    • TypeScript
  • Web app · multi-agent system · content

    live

    A team of AI agents for content

    Six agents prepare a publication from a brief: the editor-in-chief plans, the researcher finds facts in the knowledge base, the writer writes, the fact-checker and editor send the draft back for revision, and the SMM agent adapts the text for Telegram, VK, a newsletter, a blog and a carousel. You see the agents’ entire conversation, every edit and what would have been published without checks.

    • React
    • TypeScript
  • Web app · HR · scoring and chatbot

    live

    CV screening and an interviewer bot

    Twenty CVs for three vacancies are analyzed in seconds: employment periods, experience, salary and city, match with the requirements and a quote from the CV for every “yes” or “no”. What’s missing from the CV is clarified by a bot: it asks only the missing questions, follows up on vague answers and books an interview. Gender, age and family are left out of the assessment.

    • React
    • TypeScript
  • Web app · RAG · neural network in the browser

    live

    Search sandbox

    How a support bot finds an answer in a knowledge base: documents are cut into fragments, search runs by keywords, by meaning or as a hybrid, and every fragment found shows why it ranks above the others.

    • React
    • TypeScript
    • In-browser neural network
  • Web app · metrics · CI thresholds

    live

    Bot quality evaluation

    Before a new bot configuration is rolled out, it’s run against control questions. Here you can see how that works: hit@1, hit@3, the share of correct refusals, a comparison with production and a red banner if CI would block the release.

    • React
    • TypeScript
    • In-browser neural network
  • Web app · AI security · vanilla JS

    live

    Prompt injection defense trainer

    Try to trick a support bot: coax out a secret promo code, extract the system prompt or get a refund without grounds. Six defense levels, direct attacks and attacks via emails, reviews and the knowledge base, and a check log based on the OWASP Top 10 for LLMs.

    • Vanilla JS
  • Web app · AI economics · vanilla JS

    live

    AI bot cost calculator

    How much a bot will cost per month on GPT, Claude, YandexGPT, GigaChat or your own model on a rented GPU. Token-based calculation, all models compared on a chart, tips on paying less, and a real o200k tokenizer right in the browser.

    • Vanilla JS