Summary
Support a new optional per-policy config.analysis.spanDisambiguation boolean (schema default true) so a policy can skip span disambiguation, the context-vector step that resolves ambiguously-typed spans (for example SSN vs. phone number). This is the runtime half of PhiSQL RFC philterd/phisql#20; the schema field is added in the redaction policy schema 1.2.0.
Requires phisql 1.2.0, the schema version that defines config.analysis.spanDisambiguation. phisql 1.2.0 is currently in development, so this work is blocked until that schema version is targeted.
Current state in phileas-python
This is forward-looking parity, not a direct port. Unlike the Java and .NET implementations:
- phileas-python does not currently implement span disambiguation (there is no disambiguation service).
- The policy model does not model the
config.analysis object, so identification and spanDisambiguation are not parsed today.
So there is no disambiguation step to gate yet. The point of this issue is parity: track that when phileas-python gains span disambiguation (or when it starts modeling config.analysis), the spanDisambiguation field is honored, and in the meantime the field is not silently dropped in a way that would mislead an author into thinking it takes effect.
What to change
- When
config.analysis is modeled, parse and preserve spanDisambiguation (boolean, default true) so it round-trips rather than being silently discarded.
- If and when span disambiguation is implemented in phileas-python, honor the flag with the same precedence as the other implementations: disambiguation runs only when a global feature is enabled AND the policy has not set
spanDisambiguation to false. A policy can turn it off but not force it on when disabled globally.
Backward compatibility
Additive and non-breaking. Absent or true preserves current behavior. Existing policies are unaffected.
Acceptance criteria
Reference: PhiSQL RFC philterd/phisql#20.
Summary
Support a new optional per-policy
config.analysis.spanDisambiguationboolean (schema defaulttrue) so a policy can skip span disambiguation, the context-vector step that resolves ambiguously-typed spans (for example SSN vs. phone number). This is the runtime half of PhiSQL RFC philterd/phisql#20; the schema field is added in the redaction policy schema 1.2.0.Requires phisql 1.2.0, the schema version that defines
config.analysis.spanDisambiguation. phisql 1.2.0 is currently in development, so this work is blocked until that schema version is targeted.Current state in phileas-python
This is forward-looking parity, not a direct port. Unlike the Java and .NET implementations:
config.analysisobject, soidentificationandspanDisambiguationare not parsed today.So there is no disambiguation step to gate yet. The point of this issue is parity: track that when phileas-python gains span disambiguation (or when it starts modeling
config.analysis), thespanDisambiguationfield is honored, and in the meantime the field is not silently dropped in a way that would mislead an author into thinking it takes effect.What to change
config.analysisis modeled, parse and preservespanDisambiguation(boolean, defaulttrue) so it round-trips rather than being silently discarded.spanDisambiguationtofalse. A policy can turn it off but not force it on when disabled globally.Backward compatibility
Additive and non-breaking. Absent or
truepreserves current behavior. Existing policies are unaffected.Acceptance criteria
config.analysisis modeled,spanDisambiguation(defaulttrue) is parsed and preserved on round-trip.config.analysis.spanDisambiguation = falseskips it even when the global feature is enabled.trueruns disambiguation as normal when the global feature is enabled, and a policytruecannot override a global off.Reference: PhiSQL RFC philterd/phisql#20.