Skip to content

Add predictive attributes docs - #1994

Open
Jack Keene (Jack-Keene) wants to merge 10 commits into
mainfrom
predictive-attributes-docs
Open

Jack Keene (Jack-Keene) wants to merge 10 commits into
mainfrom
predictive-attributes-docs

Conversation

@Jack-Keene

@Jack-Keene Jack Keene (Jack-Keene) commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

What changed?

Adds documentation for predictive attributes in Signals.

New pages:

  • docs/signals/predictive-attributes/: define a predictive attribute in Console or the Python SDK. Covers how training builds examples, choosing inputs and the goal, checking the data, training options, reading the metrics, and publishing, retraining, and rolling back.
  • docs/signals/applications/predictive-attributes/: retrieve a score with the Python SDK, Node.js SDK, or API. Covers identifiers for each attribute key, the response, how to interpret the score, and error codes.
  • release-notes/new-in-signals-predictive-attributes/: product news announcement.

Updated pages:

  • docs/signals/concepts/: adds predictive attributes as a fifth component, with a short section on what they are and how versioning works.
  • docs/signals/applications/: links the new retrieval page.
  • docs/signals/attributes/attribute-groups/: notes that you can't delete an attribute group version used by a predictive attribute, or unpublish it while that predictive attribute is published.

Why?

Predictive attributes are merged in the Signals monorepo (#756, #767, #774, #776, #786, #798, #800, #801), the Python SDK (#165), and the TypeScript SDK (AISP-1584). The structure follows the agentic contexts and agentic attributes pages: one page to define the resource, and one to use it in your application.

Reviewer guidance

Every product claim was checked against origin/main of signals-monorepo, snowplow-signals-python-sdk, and snowplow-signals-typescript-sdk, and against the capability doc on signals-monorepo branch docs/predictive-attribute-capability.

Please check:

  • SDK releases: the predictive attribute methods are merged but not yet in a released Python SDK (still 0.4.10) or Node.js SDK (changeset pending, still 0.4.1). This PR should wait for those releases, or add the minimum versions once known.
  • Console: the Console tabs are written from the unmerged, feature-flagged feat/predictive-attributes-poc branch of msc-frontend-service. Labels match that code but may change, and there are no screenshots yet.
  • Score wording: the pages say to rank by the score rather than treat it as a calibrated probability. This matches the SDK docstrings, the OpenAPI description, and the glossary, even though The great data models rewrite #776 corrects scores for negative downsampling.

Unrelated, not changed here: docs/signals/attributes/attribute-groups/ says deleting a group version used by a published intervention unpublishes the intervention, but the API blocks the delete instead.

AI reviews

Claude will automatically review this PR against the docs style guide.

If you have questions or want it to look again at something specific, tag @claude in a comment.

🤖 Generated with Claude Code

@github-actions

Copy link
Copy Markdown
Contributor

Missing SEO metadata

The following markdown files are missing required metadata fields:

  • release-notes/new-in-signals-predictive-attributes/index.md: missing fields: keywords, sidebar_label

Required fields

The file metadata is important for SEO and marketing. All markdown files, except for those with filenames starting with _, should include:

  • title: Full, descriptive page title
  • sidebar_label: Short title for navigation sidebar (can be the same as the main title)
  • description: One to two sentences summarizing the page contents
  • keywords: Array of marketing/SEO keywords

Please add the missing metadata.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
documentation 8818ccb Commit Preview URL

Branch Preview URL
Oct 30 2026, 04:49 PM

@claude

claude Bot commented Oct 26, 2026

Copy link
Copy Markdown

Style review

The PR is well written and follows most conventions. Frontmatter is complete, internal links use /index.md, and all linked pages and anchors resolve. The release note frontmatter and link style match release-notes/_README.md. A few points to fix:

1. Multi-sentence list items are missing periods
docs/signals/predictive-attributes/index.md

  • A Snowflake warehouse connected to Signals, as described in warehouse configuration. Other warehouses aren't supported for training yet

Rule: style guide, Lists: "No period at the end unless the item contains multiple sentences."
Fix: end items that contain two sentences with a period. This also applies to:

  • "Input features: … Expand a group to leave out individual attributes"
  • "They come from stream attribute groups. Warehouse attribute groups aren't supported"
  • "Timestamp attributes aren't supported. Use a time_since_last or time_since_first aggregation instead"

2. Time-relative wording
docs/signals/predictive-attributes/index.md

Other warehouses aren't supported for training yet

Rule: style guide, Writing style: "Stay in the present tense. Never use 'currently', 'now', 'in the future'…". The word "yet" implies a roadmap in the same way.
Fix: "Training supports only Snowflake warehouses."

3. Passive, ambiguous sentence in the attribute groups page
docs/signals/attributes/attribute-groups/index.md (Python SDK tab)

Attribute groups used by a predictive attribute can't be deleted, or unpublished while the predictive attribute is published.

Rule: CLAUDE.md, Writing style: "Use active voice." Because of the comma, a reader can't tell whether "while … published" applies to deleting too.
Fix: match the Console tab wording: "If a predictive attribute uses the attribute group version, you can't delete it. You also can't unpublish it while that predictive attribute is published."

4. Non-imperative headings (minor)
docs/signals/applications/predictive-attributes/index.md: "Response format"; docs/signals/predictive-attributes/index.md: "How predictive attributes are trained"

Rule: CLAUDE.md, Headings: "Prefer imperative voice."
Fix: for example, "Read the response" and "Understand how training works". This is optional because a conceptual section can keep a descriptive heading.

No external URLs were added or modified in this PR.


A predictive attribute is a score between 0 and 1 for how likely a session is to reach a goal you define, for example a purchase or a sign-up. Signals trains a model on the history of your existing stream [attributes](/docs/signals/attributes/index.md) in your warehouse, then scores sessions in real time from the latest values of those attributes.

Use a predictive attribute when you want to act on intent before it shows up in the data. A rule such as "three product views and an add to cart" captures one pattern you already know about. A predictive attribute learns from every input attribute you give it, and weights them by how often they preceded the goal in your own data. Typical uses include showing a discount only to sessions unlikely to convert on their own, prioritizing high-intent sessions for live chat, or ranking which users to retarget.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

A rule such as "three product views and an add to cart" captures one pattern you already know about.

Not really following what this is supposed to mean – does it refer to a goal or an attribute?


Signals turns your event history into training examples, then trains a binary classifier on them. Understanding how the examples are built helps you choose the training settings.

Every event in a session that comes before the session's first goal event is a candidate example, called an anchor. For each anchor, Signals calculates the value each input attribute had at that moment, using only events before the anchor. The label is `1` if the session went on to reach the goal, and `0` if it didn't. This means the model learns from the same partial view of a session that it sees when it scores a live session.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Every event

It's not necessarily every event, right? Depends on max_anchors_per_session and min_events and excluded_events.

* Signals Python SDK

Once published, [retrieve a predictive attribute score](/docs/signals/applications/predictive-attributes/index.md) in your application.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Maybe it'd be worth adding a note with a link to the /docs/signals/ml-training-datasets/ page at some point saying that this is what the feature builds on and noting that if someone wants to train their own model, they can also do it?

@jborlase-snowplow jborlase-snowplow left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Few small points. Looks good!


A predictive attribute predicts how likely a session is to reach a goal you define, such as a purchase or a sign-up. Signals trains a model on your own stream [attribute](/docs/signals/attributes/index.md) definitions, then returns a score between 0 and 1 each time your application requests one.

Use a predictive attribute when you want a propensity score in production without building the pipeline around it. A propensity model usually needs labeled training data, a feature pipeline, a way to serve the model, and features in production that match the ones the model trained on. Signals builds the training data and serves the model from your attribute definitions, using the same definitions for both. Compared with a hand-written rule, such as an [intervention](/docs/signals/interventions/index.md) that triggers on a given rule, a predictive attribute learns from your own data which inputs matter and how much. For example, use it to show a discount only to sessions unlikely to convert on their own, or to route high-intent sessions to live chat first.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think we can leave comparison to interventions out - might confuse some people


A predictive attribute predicts how likely a session is to reach a goal you define, such as a purchase or a sign-up. Signals trains a model on your own stream [attribute](/docs/signals/attributes/index.md) definitions, then returns a score between 0 and 1 each time your application requests one.

Use a predictive attribute when you want a propensity score in production without building the pipeline around it. A propensity model usually needs labeled training data, a feature pipeline, a way to serve the model, and features in production that match the ones the model trained on. Signals builds the training data and serves the model from your attribute definitions, using the same definitions for both. Compared with a hand-written rule, such as an [intervention](/docs/signals/interventions/index.md) that triggers on a given rule, a predictive attribute learns from your own data which inputs matter and how much. For example, use it to show a discount only to sessions unlikely to convert on their own, or to route high-intent sessions to live chat first.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I would split out the examples into a few bullets with them so it’s clear

platforms:
- "Snowflake"
---
Stream attributes tell you what a user has done in a session: how many products they've viewed, what they added to their cart, how long since their last search. Deciding what that means for the session's outcome has meant writing rules by hand, such as "three product views and an add to cart", and guessing at the thresholds.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Let’s try talk to audience that might not be familiar with Signals - so let’s not talk attributes. We could say signals helps you understand what your users are doing in real-time, but it’s difficult to understand what they are going to do next - or if they will convert…

---
Stream attributes tell you what a user has done in a session: how many products they've viewed, what they added to their cart, how long since their last search. Deciding what that means for the session's outcome has meant writing rules by hand, such as "three product views and an add to cart", and guessing at the thresholds.

A predictive attribute replaces the guess with a model. You define a goal, such as a `transaction` event, and choose the stream attributes that describe the behavior leading up to it. Signals trains a model on your event history, then scores live sessions from the current values of those attributes. The score is a number between 0 and 1 for how likely the session is to reach the goal.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It’s very Opus to talk about something in the abstract like “a guess” here

This branch has not been deployed

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants