Skip to content

fix(privacy): align PII scrub copy with Presidio state and expose Solo audit log - #167

Merged
ramedey merged 1 commit into
mainfrom
privacy/155-156-scrub-copy-and-solo-audit
Nov 2, 2026
Merged

ramedey merged 1 commit into
mainfrom
privacy/155-156-scrub-copy-and-solo-audit

Conversation

@ramedey

@ramedey ramedey commented Nov 2, 2026

Copy link
Copy Markdown
Contributor

Lane (required)

pillar:privacy

Spec (required for non-chore)

  • Existing spec: docs/specs/privacy-pack-and-scrub-transparency.md

What & why

Closes #155
Closes #156

  1. [Privacy] Privacy tab says scrubbing "Removes names" but Advanced privacy says names are NOT redacted #155 (PII scrub copy accuracy): personalize.html hardcoded "Removes names, emails and IDs first." under Scrub personal details before training even when presidio_available() was False (base install without the privacy pack), contradicting scrub_coverage() and /settings. Meanwhile, settings.html repeated the "not redacted" caveat twice in one line.
  2. [Audit log] Solo users have no visible way to reach the audit log, and its times are UTC without a label #156 (Solo audit log reachability & UTC label): Solo users had no visible link to /audit from either the dashboard or Settings -> Privacy, and audit.html rendered UTC event timestamps without a timezone label.

How

  • anthill/web/app.py: pass presidio_available() into personalize_get() and pass scrub_coverage() / presidio_available() / privacy_pack_can_install / privacy_installing into settings_post().
  • anthill/web/templates/personalize.html: branch the Scrub personal details before training description on presidio_available() (with an Install link to /settings for admins when absent) and add a direct link to /audit in the Privacy tab footer.
  • anthill/web/templates/settings.html: drop the duplicated trailing clauses after {{ scrub_coverage }}.
  • anthill/web/templates/dashboard.html: add /audit link to the Solo Your workspace card.
  • anthill/web/templates/audit.html: append UTC to event timestamps.
  • tests/test_privacy_pack_web.py, docs/specs/privacy-pack-and-scrub-transparency.md, changelog.d/155.fixed.md, changelog.d/156.fixed.md: update spec, add regression tests, and record changelog fragments.

Disclosure (required - ASDD)

  • Authored by a human.
  • Authored or co-authored by an AI agent under human direction (named below; each agent commit
    carries the Agent: trailer).
  • I have read and understand this change and take responsibility for it (whoever or whatever
    wrote it). Disclosure is attribution; this is accountability.

Agent identity (if any): Antigravity - Instructed by (human handle): ramedey

Checklist

  • Every commit in this PR is signed off (DCO): use git commit -s; intake checks the full PR range.
  • make test is green.
  • New behavior has tests (model-free where possible).
  • Optional features degrade gracefully (a missing key/dep disables only itself).
  • Docs updated if behavior or setup changed (docs/specs/privacy-pack-and-scrub-transparency.md, changelog.d/155.fixed.md, changelog.d/156.fixed.md).
  • If this touches a protected path, a founding-contributor review is requested.

…o audit log

- Branch the 'Scrub personal details before training' description in
  personalize.html on presidio_available() so base installs without the
  privacy pack state that emails, phone numbers, and IDs are removed while
  names and places require the privacy pack (#155).
- Pass presidio_available() and scrub_coverage() in personalize_get() and
  settings_post(), and drop the duplicated trailing caveat in settings.html
  (#155).
- Link /audit from the Solo dashboard 'Your workspace' card and the
  Settings -> Privacy tab, and append UTC to event timestamps in audit.html
  (#156).

Closes #155
Closes #156
Spec: docs/specs/privacy-pack-and-scrub-transparency.md

Agent: Antigravity (automated, instructed-by: ramedey)
Signed-off-by: Raul Amedey Ciria <raul.amedey@rentslam.com>
@ramedey ramedey added the pillar:privacy Core pillar: sovereignty/consent/audit label Nov 2, 2026
@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

ASDD review - advisory (recommendation: comment)

Produced by an automated agent under human direction. Advisory only: a human approves and merges.
Nothing here merges automatically.

The PR correctly implements the requested UI updates for PII scrub transparency and audit log accessibility for Solo users. It aligns the copy in personalize.html and settings.html with the actual state of the Presidio privacy pack and adds missing navigation links to the audit log. The changes are backed by a spec update and new regression tests. | Adversarial pass: The PR corrects misleading UI copy regarding PII scrubbing and improves the accessibility of the audit log for Solo users. It introduces minimal net complexity, primarily consisting of template branching and passing existing state variables to the frontend. The changes are focused and align with the provided specifications. Security scan (deterministic + SAST): 10 finding(s).

CODE - ok

No findings.

SECURITY - ok

  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).
  • note: Use of assert detected. The enclosed code will be removed when compiling to optimised byte code. (severity LOW, confidence HIGH).

SPEC - ok

No findings.

QUALITY - ok

No findings.

QUALITY - ok

  • note: The change adds logic to personalize.html to branch copy based on presidio_available. While this increases template complexity, it is necessary to prevent misleading the user about privacy guarantees.
  • note: The adversarial refutation: A maintainer might argue that adding 'UTC' as a hardcoded string in the template is a naive approach to localization, but given the current scope of the project, it is the simplest correct fix for ambiguity.

Generated by the ASDD advisory review. Mode: live.

@ramedey
ramedey merged commit 15e48c9 into main Nov 2, 2026
20 of 25 checks passed
@ramedey
ramedey deleted the privacy/155-156-scrub-copy-and-solo-audit branch November 2, 2026 14:05
@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

Documentation agent - proposed doc updates for PR #167 (15e48c9)

Apply by hand: each block is plain text to copy in. The agent edited nothing. Role: documentation, model gemma-4-31B-it.

1. Impact log (docs/SYSTEM_IMPACT_LOG.md)

Paste this directly under the ## 2026-09 heading, with a blank line after it:

### PR #167 - fix(privacy): align PII scrub copy with Presidio state and expose Solo audit log - merged 2026-11-02
**System impact:** The web interface now dynamically updates PII scrubbing descriptions based on whether the Presidio privacy pack is installed. Solo users can now access the audit log directly from their dashboard and privacy settings, and audit timestamps are explicitly labeled as UTC.
**Surface:** `anthill/web/app.py`, `anthill/web/templates/audit.html`, `anthill/web/templates/dashboard.html`, `anthill/web/templates/personalize.html`, `anthill/web/templates/settings.html`
**User-visible:** yes: users see accurate PII scrub descriptions and solo users gain audit log links
**Footprint:** refactor; no significant risk as it primarily affects UI copy and navigation

2. Changelog

Create changelog.d/167.fixed.md containing exactly this (no heading, no leading dash):

Aligned PII scrub descriptions in Settings and Personalize with actual system state, added audit log access for solo users via the dashboard and privacy settings, and added UTC labels to audit timestamps.

3. Docs that are now untrue

None found.

Proposed by the ASDD documentation agent (advisory). A human applies or discards it. Nothing merges automatically.

@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

Test agent - result for 15e48c9153be0f9645051497e41397a887d74294

PASS (agent-reported; run on gpt-oss-120b, the test_runner role)

  • Tested: full test suite
  • Passed: 4198 / Failed: 0
  • Reasoning: All tests completed successfully with 4198 passed and 0 failed, indicating the change does not break existing functionality.

Reported by the ASDD test agent (advisory, post-merge). A human acts on it. Nothing merges automatically.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pillar:privacy Core pillar: sovereignty/consent/audit

Projects

None yet

1 participant