Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prevWins Clarity #852

Merged
merged 3 commits into from
Dec 8, 2023
Merged

prevWins Clarity #852

merged 3 commits into from
Dec 8, 2023

Conversation

thegreatfatzby
Copy link
Contributor

While digging in on the nature of prevWins, I wasn't sure whether there's a gap between my understanding of the explainer (updated here) and the full spec, in particular bullets 5-7 of the "To generate a bid" section (search for "Let prevWins be a new sequence.").

Based on the spec I think it's saying:

  • The field in browserSignals is prevWinsMs.
  • prevWins as a whole is a list (sequence) and each element is a PreviousWin dictionary that has the timeDelta btw the win and now, and full serialized JSON from the ad component of what was returned by generateBid for that win.

This is a little different than what is written and maybe implied, or at least not clear to me, in the explainer:

  • The field in browserSignals is prevWins.
  • The value is a list, with element being itself a list of 2 elements, the first being the "time" and the second being the "ad". My initial assumption here had been that the "time" was the timestamp of the won auction, and the ad was the creative from the IGs ads list.

So my PR here hopes to reconcile this with the following hopes:

  • That the name of the field in browserSignals is indeed prevWins rather than prevWinsMs, and that the spec needs a minor update here (or there's an alias I'm missing).
  • That the contents of prevWins has the detail indicated in the spec.

While digging in on the nature of `prevWins`, I wasn't sure whether there's a gap between my understanding of the explainer (updated here) and the [full spec](https://wicg.github.io/turtledove/), in particular bullets 5-7 of the "To generate a bid" section (search for "Let prevWins be a new sequence<PreviousWin>.").

Based on the spec I think it's saying:
* The field in `browserSignals` is `prevWinsMs`. 
* `prevWins` as a whole is a list (sequence) and each element is a `PreviousWin` dictionary that has the `timeDelta` btw the win and now, and full serialized JSON from the `ad` component of what was returned by `generateBid` for that win.

This is a little different than what is written and maybe implied, or at least not clear to me, in the explainer:
* The field in `browserSignals` is `prevWins`.
* The value is a list, with element being itself a list of 2 elements, the first being the "time" and the second being the "ad". My initial assumption here had been that the "time" was the timestamp of the won auction, and the ad was the creative from the IGs ads list.

So my PR here hopes to reconcile this with the following hopes:
* That the name of the field in `browserSignals` is indeed `prevWins` rather than `prevWinsMs`, and that the spec needs a minor update here (or there's an alias I'm missing).
* That the contents of `prevWins` has the detail indicated in the spec.
@thegreatfatzby
Copy link
Contributor Author

Also the "all wins on the browser" part is intended to add some certainty to what I'm fairly sure (sure hoping) is a misquote of @alextcone-google here on capping.

@alextcone-google
Copy link
Contributor

Also the "all wins on the browser" part is intended to add some certainty to what I'm fairly sure (sure hoping) is a misquote of @alextcone-google here on capping.

It was indeed a misquote. We've asked for a correction.

FLEDGE.md Outdated Show resolved Hide resolved
FLEDGE.md Outdated Show resolved Hide resolved
@JensenPaul
Copy link
Collaborator

Isaac, what do you think of the edits I proposed? I'd like to merge this sooner than later as this is an area of frequent questions so a clarification will really help folks.

Co-authored-by: Paul Jensen <JensenPaul@users.noreply.github.com>
@thegreatfatzby
Copy link
Contributor Author

Sorry I was out the last 3 weeks paying limited attention, just accepted.

Isaac seemed to only accept my last comment but I think he meant to accept this one too, so merging it.
@JensenPaul JensenPaul merged commit 820763e into WICG:main Dec 8, 2023
2 checks passed
github-actions bot added a commit that referenced this pull request Dec 8, 2023
SHA: 820763e
Reason: push, by JensenPaul

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.

None yet

4 participants