@stll/anonymize 2.8.2 → 2.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -20
- package/dist/build-native-package.d.mts +14 -0
- package/dist/build-native-package.mjs +2 -0
- package/dist/build-native-package2.mjs +211 -0
- package/dist/build-native-package2.mjs.map +1 -0
- package/dist/index.d.mts +4 -3
- package/dist/index.mjs +3 -3
- package/dist/native-node.d.mts +14 -2
- package/dist/native-node.mjs +3 -3
- package/dist/native-node2.d.mts +3 -3
- package/dist/native-node2.mjs +114 -141
- package/dist/native-node2.mjs.map +1 -1
- package/dist/native-runtime.d.mts +2 -2
- package/dist/native-runtime.mjs +1 -1
- package/dist/native.d.mts +8 -428
- package/dist/native.mjs +187 -18
- package/dist/native.mjs.map +1 -1
- package/dist/native2.d.mts +2 -2
- package/dist/types.d.mts +429 -0
- package/native-pipeline.cs.stlanonpkg +0 -0
- package/native-pipeline.de.stlanonpkg +0 -0
- package/native-pipeline.en.stlanonpkg +0 -0
- package/native-pipeline.stlanonpkg +0 -0
- package/package.json +7 -13
- package/scripts/build-native-pipeline-package.mjs +22 -10
package/dist/native.d.mts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { p as OperatorType } from "./constants2.mjs";
|
|
2
|
+
import { u as OperatorSelection } from "./types.mjs";
|
|
2
3
|
//#region src/native-search-config.d.ts
|
|
3
4
|
/**
|
|
4
5
|
* Structural type for the prepared static-search config the native binding
|
|
@@ -348,432 +349,6 @@ type NativePreparedSearchConfig = {
|
|
|
348
349
|
monetary_data?: NativeMonetaryData;
|
|
349
350
|
};
|
|
350
351
|
//#endregion
|
|
351
|
-
//#region src/types.d.ts
|
|
352
|
-
/**
|
|
353
|
-
* Fields shared by every entity span in the source text.
|
|
354
|
-
*/
|
|
355
|
-
type EntityBase = {
|
|
356
|
-
start: number;
|
|
357
|
-
end: number;
|
|
358
|
-
label: string;
|
|
359
|
-
text: string;
|
|
360
|
-
score: number;
|
|
361
|
-
sourceDetail?: "custom-deny-list" | "custom-regex" | "gazetteer-extension";
|
|
362
|
-
};
|
|
363
|
-
/**
|
|
364
|
-
* A PII entity span found by a primary detection layer
|
|
365
|
-
* (regex, NER, legal forms, deny list, ...).
|
|
366
|
-
*/
|
|
367
|
-
type DetectedEntity = EntityBase & {
|
|
368
|
-
source: Exclude<DetectionSource, typeof DETECTION_SOURCES.COREFERENCE>;
|
|
369
|
-
};
|
|
370
|
-
/**
|
|
371
|
-
* An alias mention of a previously detected entity: a
|
|
372
|
-
* defined term ("the Seller") or a propagated bare
|
|
373
|
-
* mention ("Acme" after "Acme Corp.").
|
|
374
|
-
*
|
|
375
|
-
* `corefSourceText` is required by construction, so an
|
|
376
|
-
* alias cannot exist without the link back to its source
|
|
377
|
-
* entity. Placeholder numbering reads it to give the
|
|
378
|
-
* alias the same placeholder as the source. The link
|
|
379
|
-
* travels with the entity instead of living in a
|
|
380
|
-
* side-channel map that a producer could forget to
|
|
381
|
-
* write — or that a later pass could clear.
|
|
382
|
-
*/
|
|
383
|
-
type CorefAliasEntity = EntityBase & {
|
|
384
|
-
source: typeof DETECTION_SOURCES.COREFERENCE;
|
|
385
|
-
/** Full text of the source entity this alias refers to. */
|
|
386
|
-
corefSourceText: string;
|
|
387
|
-
};
|
|
388
|
-
/**
|
|
389
|
-
* A detected PII entity span in the source text.
|
|
390
|
-
* Every detection layer produces these.
|
|
391
|
-
*/
|
|
392
|
-
type Entity = DetectedEntity | CorefAliasEntity;
|
|
393
|
-
/**
|
|
394
|
-
* Entity after human review. Extends the base Entity
|
|
395
|
-
* with a review decision.
|
|
396
|
-
*/
|
|
397
|
-
type ReviewDecision = "confirmed" | "rejected" | "relabeled";
|
|
398
|
-
type ReviewedEntity = Entity & {
|
|
399
|
-
decision?: ReviewDecision;
|
|
400
|
-
originalLabel?: string;
|
|
401
|
-
};
|
|
402
|
-
/**
|
|
403
|
-
* A single entry in the workspace-scoped gazetteer
|
|
404
|
-
* (deny list). Persisted in IndexedDB.
|
|
405
|
-
*/
|
|
406
|
-
type GazetteerEntry = {
|
|
407
|
-
id: string;
|
|
408
|
-
canonical: string;
|
|
409
|
-
label: string;
|
|
410
|
-
variants: string[];
|
|
411
|
-
workspaceId: string;
|
|
412
|
-
createdAt: number;
|
|
413
|
-
source: "manual" | "confirmed-from-model";
|
|
414
|
-
};
|
|
415
|
-
/** Extraction strategy — closed discriminated union. */
|
|
416
|
-
type TriggerStrategy = {
|
|
417
|
-
type: "to-next-comma";
|
|
418
|
-
/**
|
|
419
|
-
* Optional list of lowercase keywords that terminate
|
|
420
|
-
* the value scan, in addition to commas/newlines. Useful
|
|
421
|
-
* for triggers like court names that may continue past
|
|
422
|
-
* a missing comma into adjacent clause text ("Městským
|
|
423
|
-
* soudem v Praze dne 1. 1. 2020"); listing `"dne"` here
|
|
424
|
-
* stops the scan at the date boundary. Matched on a
|
|
425
|
-
* word-boundary, case-insensitive.
|
|
426
|
-
*/
|
|
427
|
-
stopWords?: string[];
|
|
428
|
-
/**
|
|
429
|
-
* Hard cap on the captured span length, in characters,
|
|
430
|
-
* regardless of where the next comma / stop char sits.
|
|
431
|
-
* Use for triggers that label short formulaic phrases
|
|
432
|
-
* ("State of Delaware") and must not absorb the rest
|
|
433
|
-
* of a long forum-selection clause when the comma is
|
|
434
|
-
* sentences away. Falls back to the default 100-char
|
|
435
|
-
* fallback when omitted.
|
|
436
|
-
*/
|
|
437
|
-
maxLength?: number;
|
|
438
|
-
} | {
|
|
439
|
-
type: "to-end-of-line";
|
|
440
|
-
} | {
|
|
441
|
-
type: "n-words";
|
|
442
|
-
count: number;
|
|
443
|
-
} | {
|
|
444
|
-
type: "company-id-value";
|
|
445
|
-
} | {
|
|
446
|
-
type: "address";
|
|
447
|
-
maxChars?: number;
|
|
448
|
-
} | {
|
|
449
|
-
/**
|
|
450
|
-
* Extract the first regex match in the value text.
|
|
451
|
-
* Useful for shape-bounded values that follow a
|
|
452
|
-
* label on the same line as other fields, where
|
|
453
|
-
* `to-end-of-line` would over-capture. The pattern
|
|
454
|
-
* is anchored to the start of the (already
|
|
455
|
-
* leading-whitespace-stripped) value, so use
|
|
456
|
-
* `(?:.*?)` prefix only when intentional.
|
|
457
|
-
*/
|
|
458
|
-
type: "match-pattern";
|
|
459
|
-
pattern: string;
|
|
460
|
-
flags?: string;
|
|
461
|
-
};
|
|
462
|
-
/** Validation rules — closed discriminated union. */
|
|
463
|
-
type TriggerValidation = {
|
|
464
|
-
type: "starts-uppercase";
|
|
465
|
-
} | {
|
|
466
|
-
type: "min-length";
|
|
467
|
-
min: number;
|
|
468
|
-
} | {
|
|
469
|
-
type: "max-length";
|
|
470
|
-
max: number;
|
|
471
|
-
} | {
|
|
472
|
-
type: "no-digits";
|
|
473
|
-
} | {
|
|
474
|
-
type: "has-digits";
|
|
475
|
-
} | {
|
|
476
|
-
type: "matches-pattern";
|
|
477
|
-
pattern: string;
|
|
478
|
-
flags?: string;
|
|
479
|
-
} |
|
|
480
|
-
/**
|
|
481
|
-
* Run a named stdnum validator (checksum + length)
|
|
482
|
-
* against the captured value. Keeps the trigger
|
|
483
|
-
* path symmetrical with the formatted-regex
|
|
484
|
-
* detectors so e.g. `CPF nº 00000000000` does not
|
|
485
|
-
* survive as a tax-ID entity.
|
|
486
|
-
*/
|
|
487
|
-
{
|
|
488
|
-
type: "valid-id";
|
|
489
|
-
validator: ValidIdValidator;
|
|
490
|
-
};
|
|
491
|
-
/** Built-in stdnum validators that can be referenced
|
|
492
|
-
* by `valid-id` validations. */
|
|
493
|
-
type ValidIdValidator = "br.cpf" | "br.cnpj" | "us.rtn";
|
|
494
|
-
/** Auto-generated trigger variants — closed set. */
|
|
495
|
-
type TriggerExtension = "add-colon" | "add-trailing-space" | "add-colon-space" | "normalize-spaces";
|
|
496
|
-
/** V2 trigger config entry (JSON shape). */
|
|
497
|
-
type TriggerGroupConfig = {
|
|
498
|
-
id?: string;
|
|
499
|
-
triggers: string[];
|
|
500
|
-
label: string;
|
|
501
|
-
strategy: TriggerStrategy;
|
|
502
|
-
extensions?: TriggerExtension[];
|
|
503
|
-
validations?: TriggerValidation[];
|
|
504
|
-
/** When true, include the trigger text in the
|
|
505
|
-
* entity span (e.g., court names). */
|
|
506
|
-
includeTrigger?: boolean;
|
|
507
|
-
};
|
|
508
|
-
/** Compiled validation with pre-built regex. */
|
|
509
|
-
type CompiledValidation = {
|
|
510
|
-
type: "starts-uppercase";
|
|
511
|
-
re: RegExp;
|
|
512
|
-
} | {
|
|
513
|
-
type: "min-length";
|
|
514
|
-
min: number;
|
|
515
|
-
} | {
|
|
516
|
-
type: "max-length";
|
|
517
|
-
max: number;
|
|
518
|
-
} | {
|
|
519
|
-
type: "no-digits";
|
|
520
|
-
re: RegExp;
|
|
521
|
-
} | {
|
|
522
|
-
type: "has-digits";
|
|
523
|
-
re: RegExp;
|
|
524
|
-
} | {
|
|
525
|
-
type: "matches-pattern";
|
|
526
|
-
re: RegExp;
|
|
527
|
-
} | {
|
|
528
|
-
type: "valid-id";
|
|
529
|
-
validator: ValidIdValidator;
|
|
530
|
-
check: (value: string) => boolean;
|
|
531
|
-
};
|
|
532
|
-
/**
|
|
533
|
-
* Runtime rule — one per trigger string after
|
|
534
|
-
* expansion. Fed to the Aho-Corasick automaton.
|
|
535
|
-
*/
|
|
536
|
-
type TriggerRule = {
|
|
537
|
-
trigger: string;
|
|
538
|
-
label: string;
|
|
539
|
-
strategy: TriggerStrategy;
|
|
540
|
-
validations: CompiledValidation[];
|
|
541
|
-
includeTrigger: boolean;
|
|
542
|
-
};
|
|
543
|
-
/** Per-label operator selection. Key is the entity label. */
|
|
544
|
-
type MaskDirection = "start" | "end";
|
|
545
|
-
type MaskOperatorConfig = {
|
|
546
|
-
type: "mask";
|
|
547
|
-
maskingCharacter: string;
|
|
548
|
-
charactersToMask: number;
|
|
549
|
-
direction: MaskDirection;
|
|
550
|
-
};
|
|
551
|
-
type OperatorSelection = Exclude<OperatorType, "mask"> | MaskOperatorConfig;
|
|
552
|
-
type OperatorConfig = {
|
|
553
|
-
/** Operator per label. Missing labels default to "replace". */
|
|
554
|
-
operators: Record<string, OperatorSelection>;
|
|
555
|
-
/** Custom replacement string for the redact operator. */
|
|
556
|
-
redactString: string;
|
|
557
|
-
};
|
|
558
|
-
/** Whether an operator produces a reversible redaction entry. */
|
|
559
|
-
type OperatorReversibility = "reversible" | "irreversible" | "preserving";
|
|
560
|
-
type AnonymisationOperator = {
|
|
561
|
-
type: OperatorType;
|
|
562
|
-
reversibility: OperatorReversibility;
|
|
563
|
-
/**
|
|
564
|
-
* Apply the operator to a single entity occurrence.
|
|
565
|
-
* Returns the replacement string to embed in the document.
|
|
566
|
-
*/
|
|
567
|
-
apply: (text: string, label: string, placeholder: string, redactString: string, selection: OperatorSelection) => string;
|
|
568
|
-
};
|
|
569
|
-
/**
|
|
570
|
-
* Redacted document output with stable entity mapping.
|
|
571
|
-
*/
|
|
572
|
-
type RedactionResult = {
|
|
573
|
-
redactedText: string;
|
|
574
|
-
/**
|
|
575
|
-
* Maps placeholder to original text. Only populated for
|
|
576
|
-
* reversible operators (replace). Empty for redact, keep, and mask.
|
|
577
|
-
*/
|
|
578
|
-
redactionMap: Map<string, string>;
|
|
579
|
-
/** Maps placeholder to the operator that produced it. */
|
|
580
|
-
operatorMap: Map<string, OperatorType>;
|
|
581
|
-
entityCount: number;
|
|
582
|
-
};
|
|
583
|
-
/**
|
|
584
|
-
* Configuration for the detection pipeline.
|
|
585
|
-
*/
|
|
586
|
-
type DenyListCategory = "Names" | "Places" | "Addresses" | "Courts" | "Financial" | "Government" | "Healthcare" | "Education" | "Political" | "Organizations" | "International";
|
|
587
|
-
/**
|
|
588
|
-
* Metadata for a single dictionary entry in the
|
|
589
|
-
* deny-list system. Mirrors the shape from
|
|
590
|
-
* the anonymize-data package so consumers can pass
|
|
591
|
-
* pre-loaded data without a runtime dependency.
|
|
592
|
-
*/
|
|
593
|
-
type DictionaryMeta = {
|
|
594
|
-
label: string;
|
|
595
|
-
category: DenyListCategory;
|
|
596
|
-
country: string | null;
|
|
597
|
-
};
|
|
598
|
-
/**
|
|
599
|
-
* Caller-supplied exact terms for deny-list matching.
|
|
600
|
-
* These entries are merged with the published deny-list
|
|
601
|
-
* dictionaries when `enableDenyList` is enabled.
|
|
602
|
-
*/
|
|
603
|
-
type CustomDenyListEntry = {
|
|
604
|
-
value: string;
|
|
605
|
-
label: string;
|
|
606
|
-
variants?: readonly string[];
|
|
607
|
-
};
|
|
608
|
-
/**
|
|
609
|
-
* Caller-supplied regex detector. The pattern is passed
|
|
610
|
-
* to the native Rust regex engine, so use its supported
|
|
611
|
-
* regex syntax. Inline flags such as `(?i)` are accepted
|
|
612
|
-
* when supported by that engine.
|
|
613
|
-
*/
|
|
614
|
-
type CustomRegexPattern = {
|
|
615
|
-
pattern: string;
|
|
616
|
-
label: string;
|
|
617
|
-
score?: number;
|
|
618
|
-
preparedArtifactPolicy?: "include" | "omit";
|
|
619
|
-
};
|
|
620
|
-
/**
|
|
621
|
-
* Pre-loaded dictionary data for dependency injection.
|
|
622
|
-
* Consumers that want name/city/deny-list detection
|
|
623
|
-
* load dictionaries themselves (e.g. from the
|
|
624
|
-
* anonymize-data package) and pass them here; the
|
|
625
|
-
* anonymize package has zero cross-package imports.
|
|
626
|
-
*
|
|
627
|
-
* All fields are optional. When a field is absent,
|
|
628
|
-
* the corresponding detection path is skipped (same
|
|
629
|
-
* behavior as when no dictionaries are available).
|
|
630
|
-
*/
|
|
631
|
-
type Dictionaries = {
|
|
632
|
-
/**
|
|
633
|
-
* First names per language code (e.g., "cs", "de").
|
|
634
|
-
*/
|
|
635
|
-
firstNames?: Readonly<Record<string, readonly string[]>>;
|
|
636
|
-
/**
|
|
637
|
-
* Surnames per language code.
|
|
638
|
-
*/
|
|
639
|
-
surnames?: Readonly<Record<string, readonly string[]>>;
|
|
640
|
-
/**
|
|
641
|
-
* Non-Western name tokens per locale code
|
|
642
|
-
* (e.g., "in", "ar", "ja-latn", "ko", "zh-latn",
|
|
643
|
-
* "th", "vi", "fil", "id"). Merged with bundled
|
|
644
|
-
* names-nw-*.json data at init time.
|
|
645
|
-
*/
|
|
646
|
-
nonWesternNames?: Readonly<Record<string, readonly string[]>>;
|
|
647
|
-
/**
|
|
648
|
-
* Pre-loaded deny-list dictionaries keyed by
|
|
649
|
-
* dictionary ID (e.g., "courts/CZ", "banks/DE").
|
|
650
|
-
* Each value is the array of terms for that
|
|
651
|
-
* dictionary.
|
|
652
|
-
*/
|
|
653
|
-
denyList?: Readonly<Record<string, readonly string[]>>;
|
|
654
|
-
/**
|
|
655
|
-
* Metadata per dictionary ID. Required when
|
|
656
|
-
* `denyList` is provided so the pipeline knows
|
|
657
|
-
* labels, categories, and country filters.
|
|
658
|
-
*/
|
|
659
|
-
denyListMeta?: Readonly<Record<string, DictionaryMeta>>;
|
|
660
|
-
/**
|
|
661
|
-
* Pre-loaded city names, already merged across
|
|
662
|
-
* all desired countries.
|
|
663
|
-
*
|
|
664
|
-
* Prefer `citiesByCountry` when callers also pass
|
|
665
|
-
* `denyListCountries` / `denyListRegions`; merged
|
|
666
|
-
* city arrays cannot be scoped after injection.
|
|
667
|
-
*/
|
|
668
|
-
cities?: readonly string[];
|
|
669
|
-
/**
|
|
670
|
-
* Pre-loaded city names keyed by ISO 3166-1 alpha-2
|
|
671
|
-
* country code. When provided, the deny-list builder
|
|
672
|
-
* applies `denyListCountries` / `denyListRegions`
|
|
673
|
-
* before adding city patterns to the search automaton.
|
|
674
|
-
*/
|
|
675
|
-
citiesByCountry?: Readonly<Record<string, readonly string[]>>;
|
|
676
|
-
};
|
|
677
|
-
/**
|
|
678
|
-
* Street-address detection without a known-city anchor.
|
|
679
|
-
*/
|
|
680
|
-
type StandaloneStreetDetection = "off" | "houseNumberAnchored";
|
|
681
|
-
type PipelineConfig = {
|
|
682
|
-
threshold: number;
|
|
683
|
-
enableTriggerPhrases: boolean;
|
|
684
|
-
enableRegex: boolean;
|
|
685
|
-
/**
|
|
686
|
-
* Expected content language codes. When present, these
|
|
687
|
-
* derive default dictionary scopes for name corpus and
|
|
688
|
-
* deny-list matching unless the lower-level scope fields
|
|
689
|
-
* below are set explicitly.
|
|
690
|
-
*/
|
|
691
|
-
languages?: string[];
|
|
692
|
-
/**
|
|
693
|
-
* Convenience form for single-language documents. Ignored
|
|
694
|
-
* when `languages` is also provided.
|
|
695
|
-
*/
|
|
696
|
-
language?: string;
|
|
697
|
-
/**
|
|
698
|
-
* Enables legal-form organization detection.
|
|
699
|
-
* Required for typed callers; legacy untyped
|
|
700
|
-
* callers that omit this field are treated as
|
|
701
|
-
* enabled at runtime for backward compatibility.
|
|
702
|
-
*/
|
|
703
|
-
enableLegalForms: boolean;
|
|
704
|
-
/**
|
|
705
|
-
* Enables first-name/surname/title corpus matching.
|
|
706
|
-
* When deny-list mode is enabled, this also controls
|
|
707
|
-
* whether name-corpus entries are injected into the
|
|
708
|
-
* deny-list search automaton.
|
|
709
|
-
*/
|
|
710
|
-
enableNameCorpus: boolean;
|
|
711
|
-
/**
|
|
712
|
-
* Optional language scope for first-name/surname
|
|
713
|
-
* dictionaries, using the keys present in
|
|
714
|
-
* `dictionaries.firstNames` / `dictionaries.surnames`
|
|
715
|
-
* (for example `["en", "de"]`). When omitted, all
|
|
716
|
-
* injected name languages are used for backward
|
|
717
|
-
* compatibility.
|
|
718
|
-
*/
|
|
719
|
-
nameCorpusLanguages?: string[];
|
|
720
|
-
enableDenyList: boolean;
|
|
721
|
-
denyListCountries?: string[];
|
|
722
|
-
denyListRegions?: string[];
|
|
723
|
-
denyListExcludeCategories?: string[];
|
|
724
|
-
/**
|
|
725
|
-
* Caller-owned exact terms to match through the
|
|
726
|
-
* deny-list layer. Requires `enableDenyList: true`.
|
|
727
|
-
*/
|
|
728
|
-
customDenyList?: readonly CustomDenyListEntry[];
|
|
729
|
-
/**
|
|
730
|
-
* Caller-owned regex detectors. Requires
|
|
731
|
-
* `enableRegex: true`.
|
|
732
|
-
*/
|
|
733
|
-
customRegexes?: readonly CustomRegexPattern[];
|
|
734
|
-
enableGazetteer: boolean;
|
|
735
|
-
/**
|
|
736
|
-
* Detect country names (ISO 3166-1 names, curated
|
|
737
|
-
* aliases, alpha-3 codes). Defaults to true. Names
|
|
738
|
-
* span all manifest languages plus widely-used
|
|
739
|
-
* additions (Dutch, Russian, Chinese, Arabic, etc.).
|
|
740
|
-
*/
|
|
741
|
-
enableCountries?: boolean;
|
|
742
|
-
enableConfidenceBoost: boolean;
|
|
743
|
-
enableCoreference: boolean;
|
|
744
|
-
enableZoneClassification?: boolean;
|
|
745
|
-
enableHotwordRules?: boolean;
|
|
746
|
-
/**
|
|
747
|
-
* Detect a street address that carries no known-city
|
|
748
|
-
* anchor. Defaults to `"off"`.
|
|
749
|
-
*
|
|
750
|
-
* `"houseNumberAnchored"` accepts a street-type word
|
|
751
|
-
* with a house number directly beside it, in either
|
|
752
|
-
* order ("14 Rue de la Paix", "Hauptstraße 5",
|
|
753
|
-
* "123 Main Street"). A bare street name with no
|
|
754
|
-
* number never fires.
|
|
755
|
-
*
|
|
756
|
-
* A street-type word plus a nearby number is a much
|
|
757
|
-
* weaker signal than a city-anchored address and does
|
|
758
|
-
* fire on contract prose ("District Court 2019"), so
|
|
759
|
-
* this stays opt-in per workspace.
|
|
760
|
-
*/
|
|
761
|
-
standaloneStreetDetection?: StandaloneStreetDetection;
|
|
762
|
-
/**
|
|
763
|
-
* Requested output labels. An empty array means
|
|
764
|
-
* "do not filter by label" for deterministic detectors.
|
|
765
|
-
*/
|
|
766
|
-
labels: string[];
|
|
767
|
-
workspaceId: string;
|
|
768
|
-
/**
|
|
769
|
-
* Pre-loaded dictionary data for name, deny-list,
|
|
770
|
-
* and city detection. When omitted, dictionary-based
|
|
771
|
-
* detection paths are skipped. Consumers load from
|
|
772
|
-
* the anonymize-data package and pass the data here.
|
|
773
|
-
*/
|
|
774
|
-
dictionaries?: Dictionaries;
|
|
775
|
-
};
|
|
776
|
-
//#endregion
|
|
777
352
|
//#region src/native.d.ts
|
|
778
353
|
type NativeBindingOperatorConfig = {
|
|
779
354
|
operators?: Record<string, OperatorSelection>;
|
|
@@ -940,6 +515,11 @@ type NativeOperatorConfig = {
|
|
|
940
515
|
redactString?: string;
|
|
941
516
|
};
|
|
942
517
|
declare const CALLER_DETECTION_CONTRACT_VERSION = 2;
|
|
518
|
+
declare const CALLER_DETECTION_MAX_COUNT = 1000000;
|
|
519
|
+
declare const CALLER_DETECTION_TEXT_MAX_BYTES: number;
|
|
520
|
+
declare const CALLER_DETECTION_REQUEST_JSON_MAX_BYTES: number;
|
|
521
|
+
declare const SESSION_CALLER_MAX_INPUTS = 100000;
|
|
522
|
+
declare const SESSION_CALLER_INPUTS_JSON_MAX_BYTES: number;
|
|
943
523
|
declare const EXTERNAL_DETECTION_BATCH_VERSION: 1;
|
|
944
524
|
declare const EXTERNAL_DETECTION_BATCH_MAX_BYTES: number;
|
|
945
525
|
declare const EXTERNAL_DETECTION_DOCUMENT_MAX_BYTES: number;
|
|
@@ -1209,5 +789,5 @@ type PreparedSearch = PreparedNativeAnonymizer;
|
|
|
1209
789
|
declare const PreparedAnonymizer: typeof PreparedNativeAnonymizer;
|
|
1210
790
|
type PreparedAnonymizer = PreparedNativeAnonymizer;
|
|
1211
791
|
//#endregion
|
|
1212
|
-
export {
|
|
792
|
+
export { SESSION_CALLER_INPUTS_JSON_MAX_BYTES as $, NativePreparedRedactionSessionBinding as A, NativeSessionDeletionSummary as B, NativeCreateSessionWithLifecycleOptions as C, prepare_search_package as Ct, NativeOperatorConfig as D, summary_diagnostics_json as Dt, NativeOpenSessionArchiveOptions as E, redact_text_stream_json as Et, NativeSearchPackageInput as F, NativeStaticRedactionResult as G, NativeSessionMetadata as H, NativeSearchPackageOptions as I, PreparedNativeAnonymizer as J, NativeTextReplacement as K, NativeSessionBlockRedactionPlan as L, NativePreparedSessionRedactionPlanBinding as M, NativeRedactionResult as N, NativePipelineEntity as O, NativePreparedSearchConfig as Ot, NativeResultEventCallback as P, PreparedSearch as Q, NativeSessionCallerRedactionInput as R, NativeCallerRedactionOptions as S, prepareNativeSearchPackage as St, NativeNormalizeOptions as T, redact_text_json as Tt, NativeSessionRedactionAtOptions as U, NativeSessionLifecycle as V, NativeSessionStatus as W, PreparedNativeRedactionSession as X, PreparedNativePipeline as Y, PreparedNativeSessionRedactionPlan as Z, NativeAnonymizeBinding as _, getNativeBindingVersion as _t, ConvertExternalDetectionBatchOptions as a, SharedNativeRedactTextOptions as at, NativeBindingVersionOptions as b, native_package_version as bt, EXTERNAL_DETECTION_DOCUMENT_MAX_BYTES as c, assertNativeBindingVersion as ct, EXTERNAL_DETECTION_MAX_METADATA_BYTES as d, createNativeAnonymizerFromPackage as dt, SESSION_CALLER_MAX_INPUTS as et, EXTERNAL_DETECTION_OFFSET_UNITS as f, createNativePipelineFromPackage as ft, NATIVE_BINDING_PARITY_MEMBERS as g, encodeNativeSearchConfigInput as gt, ExternalDetectionOffsetUnit as h, encodeNativeSearchConfig as ht, CALLER_DETECTION_TEXT_MAX_BYTES as i, SharedNativeRedactTextJsonOptions as it, NativePreparedSearchBinding as j, NativePipelineFromPackageOptions as k, EXTERNAL_DETECTION_MAX_DETECTIONS as l, convert_external_detection_batch as lt, ExternalDetectionBatch as m, diagnostics_stream_json as mt, CALLER_DETECTION_MAX_COUNT as n, SharedNativeDiagnosticsStreamJsonOptions as nt, EXTERNAL_DETECTION_BATCH_MAX_BYTES as o, SharedNativeRedactTextStreamJsonOptions as ot, EXTERNAL_DETECTION_PROVIDER_ID_MAX_BYTES as p, diagnostics_json as pt, PreparedAnonymizer as q, CALLER_DETECTION_REQUEST_JSON_MAX_BYTES as r, SharedNativePreparedPackageOptions as rt, EXTERNAL_DETECTION_BATCH_VERSION as s, SharedNativeSearchPackageOptions as st, CALLER_DETECTION_CONTRACT_VERSION as t, SharedNativeDiagnosticsJsonOptions as tt, EXTERNAL_DETECTION_MAX_LABEL_MAPPINGS as u, createNativeAnonymizerFromConfig as ut, NativeAnonymizerFromConfigOptions as v, isNativeAnonymizeBinding as vt, NativeDiagnosticsBatchCallback as w, redact_text as wt, NativeCallerDetection as x, normalize_for_search as xt, NativeAnonymizerFromPackageOptions as y, load_prepared_package as yt, NativeSessionCallerRedactionPlanOptions as z };
|
|
1213
793
|
//# sourceMappingURL=native.d.mts.map
|