chore: migrate to mobiletic-labs org and rename npm scope
- Git URLs: git.mobiletic.net/mobiletic/anonymizer -> .../mobiletic-labs/anonymizer (homepage, repository, bugs, CI badge, clone instructions). - npm package renamed @mobiletic/anonymizer -> @mobiletic-labs/anonymizer across package.json, lockfile, README, CONTRIBUTING, examples, issue template. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
4
.github/ISSUE_TEMPLATE/bug_report.md
vendored
4
.github/ISSUE_TEMPLATE/bug_report.md
vendored
@@ -17,7 +17,7 @@ A clear description of what's wrong.
|
|||||||
A minimal code sample or failing test:
|
A minimal code sample or failing test:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
// import { Anonymizer, presets } from '@mobiletic/anonymizer';
|
// import { Anonymizer, presets } from '@mobiletic-labs/anonymizer';
|
||||||
```
|
```
|
||||||
|
|
||||||
## Expected behavior
|
## Expected behavior
|
||||||
@@ -26,7 +26,7 @@ What you expected to happen.
|
|||||||
|
|
||||||
## Environment
|
## Environment
|
||||||
|
|
||||||
- `@mobiletic/anonymizer` version:
|
- `@mobiletic-labs/anonymizer` version:
|
||||||
- Node.js version:
|
- Node.js version:
|
||||||
- Using an LLM provider? (which endpoint/model, or regex-only):
|
- Using an LLM provider? (which endpoint/model, or regex-only):
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# Contributing to @mobiletic/anonymizer
|
# Contributing to @mobiletic-labs/anonymizer
|
||||||
|
|
||||||
Thanks for your interest in improving this project! Contributions of all kinds are welcome — bug reports,
|
Thanks for your interest in improving this project! Contributions of all kinds are welcome — bug reports,
|
||||||
new pattern presets, additional LLM providers, docs, and tests.
|
new pattern presets, additional LLM providers, docs, and tests.
|
||||||
@@ -6,7 +6,7 @@ new pattern presets, additional LLM providers, docs, and tests.
|
|||||||
## Getting started
|
## Getting started
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://git.mobiletic.net/mobiletic/anonymizer.git
|
git clone https://git.mobiletic.net/mobiletic-labs/anonymizer.git
|
||||||
cd anonymizer
|
cd anonymizer
|
||||||
npm install
|
npm install
|
||||||
npm test # run the test suite (vitest)
|
npm test # run the test suite (vitest)
|
||||||
|
|||||||
16
README.md
16
README.md
@@ -1,7 +1,7 @@
|
|||||||
# @mobiletic/anonymizer
|
# @mobiletic-labs/anonymizer
|
||||||
|
|
||||||
[](https://git.mobiletic.net/mobiletic/anonymizer/actions)
|
[](https://git.mobiletic.net/mobiletic-labs/anonymizer/actions)
|
||||||
[](https://www.npmjs.com/package/@mobiletic/anonymizer)
|
[](https://www.npmjs.com/package/@mobiletic-labs/anonymizer)
|
||||||
[](./LICENSE)
|
[](./LICENSE)
|
||||||
|
|
||||||
Framework-agnostic **PII anonymization & pseudonymization** for TypeScript/JavaScript.
|
Framework-agnostic **PII anonymization & pseudonymization** for TypeScript/JavaScript.
|
||||||
@@ -27,7 +27,7 @@ values afterwards — including across **streamed** tokens.
|
|||||||
## Install
|
## Install
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npm install @mobiletic/anonymizer
|
npm install @mobiletic-labs/anonymizer
|
||||||
```
|
```
|
||||||
|
|
||||||
Requires Node ≥ 18 (uses native `fetch`).
|
Requires Node ≥ 18 (uses native `fetch`).
|
||||||
@@ -37,7 +37,7 @@ Requires Node ≥ 18 (uses native `fetch`).
|
|||||||
### Regex-only (no LLM, fully deterministic)
|
### Regex-only (no LLM, fully deterministic)
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
import { Anonymizer, presets } from '@mobiletic/anonymizer';
|
import { Anonymizer, presets } from '@mobiletic-labs/anonymizer';
|
||||||
|
|
||||||
const anonymizer = new Anonymizer({ patterns: presets.swiss });
|
const anonymizer = new Anonymizer({ patterns: presets.swiss });
|
||||||
|
|
||||||
@@ -52,7 +52,7 @@ anonymizer.deanonymize(anon, mapping); // -> "Écris à jean@exemple.ch"
|
|||||||
### With an LLM (also catches names, addresses…)
|
### With an LLM (also catches names, addresses…)
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
import { Anonymizer, openAICompatibleProvider, presets } from '@mobiletic/anonymizer';
|
import { Anonymizer, openAICompatibleProvider, presets } from '@mobiletic-labs/anonymizer';
|
||||||
|
|
||||||
const anonymizer = new Anonymizer({
|
const anonymizer = new Anonymizer({
|
||||||
llm: openAICompatibleProvider({
|
llm: openAICompatibleProvider({
|
||||||
@@ -159,7 +159,7 @@ new Anonymizer({
|
|||||||
### Presets & custom patterns
|
### Presets & custom patterns
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
import { presets } from '@mobiletic/anonymizer';
|
import { presets } from '@mobiletic-labs/anonymizer';
|
||||||
|
|
||||||
presets.swiss; // AVS, IBAN CH, EMAIL, Swiss phone, DATE
|
presets.swiss; // AVS, IBAN CH, EMAIL, Swiss phone, DATE
|
||||||
presets.generic; // EMAIL, IBAN, credit card, IPv4, phone, DATE
|
presets.generic; // EMAIL, IBAN, credit card, IPv4, phone, DATE
|
||||||
@@ -187,7 +187,7 @@ so arbitrary long digit runs aren't mistaken for credit cards:
|
|||||||
Implement `LlmProvider` to use any backend (Anthropic, a local model, a rules engine…):
|
Implement `LlmProvider` to use any backend (Anthropic, a local model, a rules engine…):
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
import type { LlmProvider } from '@mobiletic/anonymizer';
|
import type { LlmProvider } from '@mobiletic-labs/anonymizer';
|
||||||
|
|
||||||
const myProvider: LlmProvider = {
|
const myProvider: LlmProvider = {
|
||||||
isConfigured: () => true,
|
isConfigured: () => true,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Live example
|
# Live example
|
||||||
|
|
||||||
[`demo.mjs`](./demo.mjs) runs `@mobiletic/anonymizer` against a real
|
[`demo.mjs`](./demo.mjs) runs `@mobiletic-labs/anonymizer` against a real
|
||||||
OpenAI-compatible LLM (built with Gemma 4 via Infomaniak) on a set of fictional
|
OpenAI-compatible LLM (built with Gemma 4 via Infomaniak) on a set of fictional
|
||||||
Swiss e-learning chats: 5 single messages of rising complexity (up to 5 people,
|
Swiss e-learning chats: 5 single messages of rising complexity (up to 5 people,
|
||||||
with rare attributes the model must coin itself) and 5 multi-turn conversations
|
with rare attributes the model must coin itself) and 5 multi-turn conversations
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Anonymizer, openAICompatibleProvider, AnonymizationError } from '@mobiletic/anonymizer';
|
import { Anonymizer, openAICompatibleProvider, AnonymizationError } from '@mobiletic-labs/anonymizer';
|
||||||
import { writeFileSync } from 'node:fs';
|
import { writeFileSync } from 'node:fs';
|
||||||
|
|
||||||
// ── LLM-only (no regex patterns) → everything is handled purely by the model.
|
// ── LLM-only (no regex patterns) → everything is handled purely by the model.
|
||||||
@@ -271,7 +271,7 @@ function toMarkdown() {
|
|||||||
return parts.join('\n');
|
return parts.join('\n');
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('\n@mobiletic/anonymizer — démonstration live (Infomaniak)\n');
|
console.log('\n@mobiletic-labs/anonymizer — démonstration live (Infomaniak)\n');
|
||||||
console.log(
|
console.log(
|
||||||
`Modèle: ${process.env.GEMMA_MODEL || '(non défini)'} · Endpoint: ${process.env.INFOMANIAK_AI_BASE_URL || '(non défini)'}\n`,
|
`Modèle: ${process.env.GEMMA_MODEL || '(non défini)'} · Endpoint: ${process.env.INFOMANIAK_AI_BASE_URL || '(non défini)'}\n`,
|
||||||
);
|
);
|
||||||
|
|||||||
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,11 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "@mobiletic/anonymizer",
|
"name": "@mobiletic-labs/anonymizer",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "@mobiletic/anonymizer",
|
"name": "@mobiletic-labs/anonymizer",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
{
|
{
|
||||||
"name": "@mobiletic/anonymizer",
|
"name": "@mobiletic-labs/anonymizer",
|
||||||
"version": "0.4.0",
|
"version": "0.4.0",
|
||||||
"description": "Framework-agnostic PII anonymization & pseudonymization: pluggable LLM detection for free-form PII (names, addresses) with a deterministic regex fallback, deterministic coreference, and streaming-safe de-anonymization.",
|
"description": "Framework-agnostic PII anonymization & pseudonymization: pluggable LLM detection for free-form PII (names, addresses) with a deterministic regex fallback, deterministic coreference, and streaming-safe de-anonymization.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"author": "Mobiletic",
|
"author": "Mobiletic",
|
||||||
"homepage": "https://git.mobiletic.net/mobiletic/anonymizer#readme",
|
"homepage": "https://git.mobiletic.net/mobiletic-labs/anonymizer#readme",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git+https://git.mobiletic.net/mobiletic/anonymizer.git"
|
"url": "git+https://git.mobiletic.net/mobiletic-labs/anonymizer.git"
|
||||||
},
|
},
|
||||||
"bugs": {
|
"bugs": {
|
||||||
"url": "https://git.mobiletic.net/mobiletic/anonymizer/issues"
|
"url": "https://git.mobiletic.net/mobiletic-labs/anonymizer/issues"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"anonymization",
|
"anonymization",
|
||||||
|
|||||||
Reference in New Issue
Block a user