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

Multi touch attribution unified #502

Conversation

sidneyzanetti
Copy link
Contributor

@sidneyzanetti sidneyzanetti commented Dec 11, 2024

Description

New use case: Multi-touch Attribution with Private Aggregation & Shared Storage

Affected services

  • Home
  • News
  • Shop
  • Travel
  • Adtech

Other:

Copy link
Contributor

@code-review-assist code-review-assist bot left a comment

Choose a reason for hiding this comment

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

Hi @sidneyzanetti and reviewers,

I'm currently reviewing this pull request and will post my detailed review in a few minutes. In the meantime, here's a quick summary to help everyone get up to speed:

This pull request introduces a new multi-touch attribution use case, leveraging Private Aggregation, Shared Storage, and the Aggregation Service. The intent is to enhance the existing demo by enabling more sophisticated attribution modeling for digital ads. Specifically, it allows for distributing conversion credit across multiple publishers involved in a user's journey leading to a conversion.

The changes include:

  • README.md: Updated the table of use cases to include the new multi-touch attribution demo.
  • services/ad-tech/src/lib/common-utils.ts: Added a new function getMTATemplateVariables to generate variables for the MTA template, and added constants for multiple news hosts.
  • services/ad-tech/src/lib/constants.ts: Added GARDENING_NEWS_HOST constant.
  • services/ad-tech/src/public/js/dsp/mta-conversion-tag.js: Added a new script to load an iframe for MTA conversion tracking.
  • services/ad-tech/src/public/js/dsp/mta-conversion-worklet.js: Added a new worklet to handle the multi-touch attribution logic using Shared Storage and Private Aggregation.
  • services/ad-tech/src/public/js/dsp/mta-conversion.js: Added a script to initiate the MTA conversion process.
  • services/ad-tech/src/public/js/dsp/mta-static-ad-tag.js: Added a script to load a static ad for MTA.
  • services/ad-tech/src/routes/common/ads-router.ts: Added a new route to handle MTA ad requests.
  • services/ad-tech/src/routes/dsp/buyer-router.ts: Added a new route to serve the MTA conversion HTML page.
  • services/ad-tech/src/views/dsp/mta-conversion.ejs: Created a new EJS template for the MTA conversion page.
  • services/ad-tech/src/views/mta-ad-frame.ejs: Created a new EJS template for the MTA ad frame, which includes logic to store impression context in Shared Storage.
  • services/home/docs/demos/index.md: Updated the documentation to include the new multi-touch attribution demo.
  • services/home/docs/demos/multi-touch-conversion-attribution.md: Added a new documentation page explaining the multi-touch attribution demo.
  • services/home/docs/intro.md: Updated the introduction page to include the new multi-touch attribution demo.
  • services/news/src/index.ts: Added AD_SERVER_HOST to the template variables.
  • services/news/src/views/display-mta-ad.ejs: Updated the template to include the MTA static ad tag.
  • services/shop/src/index.ts: Added AD_SERVER_HOST to the constants and updated the checkout route to include the MTA conversion tag URL.
  • services/shop/src/views/checkout.ejs: Added the MTA conversion tag to the checkout page.

Let me know if you have any questions.


And now, a little poem:

Shared Storage holds the key,
Private Aggregation, the way,
Attribution's art.

Copy link
Contributor

@code-review-assist code-review-assist bot left a comment

Choose a reason for hiding this comment

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

This pull request introduces multi-touch attribution (MTA) using Private Aggregation, Shared Storage, and the Aggregation Service. The implementation looks good overall, and the documentation is thorough. A few minor suggestions for improvement are included below.

@sidneyzanetti sidneyzanetti force-pushed the multi_touch_attribution_unified branch from 3633bd8 to 80ac5ac Compare December 11, 2024 23:31
Copy link
Contributor

@siddharth-sahoo siddharth-sahoo left a comment

Choose a reason for hiding this comment

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

I didn't read through the markdown files. But everything else looks pretty good!

@siddharth-sahoo siddharth-sahoo self-requested a review December 17, 2024 01:53
@siddharth-sahoo siddharth-sahoo merged commit f0117cc into privacysandbox:dev Dec 17, 2024
2 checks passed
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.

2 participants