Skip to content

Conversation

@bmcase
Copy link
Contributor

@bmcase bmcase commented Nov 12, 2025

Creating a PR to add safety limits to the Attribution spec. This is based primarily on the BigBird algorithm from Section 4 of this paper https://arxiv.org/pdf/2506.05290. Algorithm 2 is the main algorithm that encompass both budget deduction and safety limit deduction.

This PR is still WIP but ready for some initial review.

Intended to address this open issue #237


Preview | Diff

This adds the checks that need to happen on user action context, following Alg 2 of BigBird; not that it follows the latest version which has conversion check moved within the for loop over epochs.
in Algo 2 in Big Bird, safety limit deductions occur if and only if privacy budget also happens.
Thus going to put the safety limits into the deduct privacy budget function (renamed as deduct privacy and safety budgets).

1. If |singleEpoch| is true:
1. Let |l1Norm| be the sum of the [=list/items=] in |histogram|.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to add quota checks to the singleEpoch case still

@bmcase bmcase changed the title [WIP] Safety limits [RFC] Safety limits Dec 5, 2025
@bmcase
Copy link
Contributor Author

bmcase commented Dec 5, 2025

User actions quota counts -- for the spec I think we should stick closely to the paper on the safety limit quotas themselves, but for the user action quota counts I think we could do a simplification.

The paper partitions the quota counts for a single user action by impression and conversion quotas with conversion quotas further partitioned by epoch.

I think it would be simpler to just have one single quota count per user action. If we think that is okay for now I can simplify this PR a bit.

Let me know if you have any thoughts on this @apasel422 @mt @csharrison @andyleiserson.

mdmostakmia433-sys

This comment was marked as spam.

@mdmostakmia433-sys

This comment was marked as spam.

Comment on lines +1538 to +1539
<p class=note>Typical values might be:
TODO
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In #174, I've added a section for implementation-defined limits. I think you could add to that section for these. In particular, you want to set these as multiples of the per-site epsilon budget, so you could set minimum values for them.

Comment on lines +1661 to +1663
<p class=issue>TODO: Define how to clear [=safety limits=] stores:
[=global privacy budget store=], [=impression site quota store=],
[=conversion site quota store=], and [=user action context store=].
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Open an issue to track this one, I think.

limiting its ability to rapidly deplete the [=global privacy budget=].


### User Action Context Store ### {#s-user-action-context-store}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's drop this store and switch to a global boolean flag attached to the window. That is set when the API is successfully invoked. And the API can be invoked if either a) the flag is set or b) transient activation is consumed.

@bmcase
Copy link
Contributor Author

bmcase commented Dec 11, 2025

Notes from meeting:

  1. drop user action stores by many dimensions
  2. drop conversion site quota

Follow ups:

  1. set minimum recommended multipliers
  2. clear history
  3. locking for atomic transaction

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants