USL-01Unit as Primitive
USL-01 · end-to-end worked example

推荐系统为什么需要 unit?

固定注册账户 42,从三条已验证 interactions 一路追到下一次 slate 决策:哪些是 samples,谁是持续的 response bearer,item 怎样成为 treatment,以及“同一个用户换一种推荐会不会留存更好”究竟比普通排序多出了什么。

public owner-review preview · not a formal releasev1.2 · 2026-07-28 direct-address-response-content contractlocal source v0.15 · public contract v0.12verified main PDF v0.14 · supplement v0.9noindex · navigation refreshed 2026-07-31
THE ONE-LINE MAPUser account 是当前 query 的 unit;interaction 是 sample;exposed item / slate 是 treatment;feedback / retention 是 outcome。

一条 row 只告诉我们“这次发生了什么”。持续的 user unit 才把多轮 evidence 与 alternative actions 锚定到同一个响应承受者。

unitaccount 42
samplesinteractions
treatmentexposed slate
outcomefeedback / retention
querysame-user what-if
00 · page contract

这是压力测试,不是“重新发明 user”

本页要做的

用同一条数据—计算—query 链检查 selected individual、interaction sample、known referent、latent property、action、outcome 与 evaluation group 是否保持正确类型。

本页不声称的

不声称推荐系统从未使用 user embedding,不把 PMF posterior 当作 which-user belief,也不声称 logged recommendation 已识别 causal effect。

推荐系统恰好把这些对象同时放在一个系统里,因此是 unit-selector framework 很好的压力测试:经典方法在 response / representation layer 上是重要邻居,但自身并没有实现 Population selector 与 learner-specific which-unit inference。

01 · one account, many records

先固定同一个注册账户:42

本页把注册账户 42声明为当前 query 的 focal account-individual。在 Population selector notation 中写作 \(U=u_{42}\),其中 \(u_{42}\in\mathcal U\) 表示 persistent referent,并语义索引 \(P_\theta(dy\mid x;u_{42})\);它不等于一条已经完成的 user embedding。user_id = 42 固定该 referent 与稳定 update address,response training 则可在此地址学习 \(u_\theta(42)\)。这不是另建 foundational vector,而是在单一 unit ontology 内明确 referential address 与 task-specific numerical content 的边界。candidate query 改变时,answer subject 仍是账户 42。它不等于声称账户 42 必然对应唯一自然人;共享账号、一人多账号与跨设备 linkage 需要另行处理。

t₁
新账户、少量 profile · item \(a_1\)决策前历史 \(H_{42,1}\);观测结果 click。
t₂
历史已包含 \(t_1\) · slate \(a_2\)决策前历史 \(H_{42,2}\);观测结果 dwell time、no purchase。
t₃
历史已包含 \(t_1,t_2\) · item \(a_3\)决策前历史 \(H_{42,3}\);观测结果 purchase,随后可观察 retention。
t
现在:在 candidate slates 之间选择对账户 42,在固定后续推荐策略 \(\pi^+\) 下比较 \(\Delta\) 时间后留存。
时间Pre-action history实际曝光观测结果
\(t_1\)新账户、少量 profileitem \(a_1\)click
\(t_2\)已包含 \(t_1\)slate \(a_2\)dwell time、no purchase
\(t_3\)已包含 \(t_1,t_2\)item \(a_3\)purchase,随后可观察 retention

三行是关于同一个 account-individual 的三个 samples。只有 answer time 之前 admissible 的 factual rows 才进入 \(\mathcal O_t^{F,\mathrm{known}}\);candidate item \(a^Q\) 是 query,不会更新 which-user belief。History 中直接改变 response 的部分另行声明为 \(c_t^Q\)。

02 · object typing

每个对象只能做自己的工作

U = u₄₂Persistent account-individual referent

Population 中当前 query 涉及的 account-individual,语义索引 fixed-user response law;不是 interaction row,也不是 learned embedding coordinate。

user_id = 42Trusted resolver key

固定 referent 与稳定 update address;不会给出已学习完成的 user representation;是否完全揭示 individual 由 protocol 决定。

\(u_\theta(42)\) / \(Z_{42}\)Learned preference content

known account 地址上由 response training 学习的 embedding、preference factor 或 random effect;不是 which-user selector,也不是 person 本身。

S₄₂,tInteraction sample

一次 history—action—feedback episode;不是每行新造一个 user。

H₄₂,tPre-action factual source

用于 which-user inference 的部分进入 \(\mathcal O_t^F\);直接改变 response 的部分显式形成 \(c_t^Q\);不得包含当前 action 后的 feedback。

A₄₂,t = aTreatment / action

实际曝光的 item / slate 及位置、顺序和呈现;不是 user unit,也不是 item embedding。

Y₄₂,t+ΔOutcome

预先声明窗口内的 feedback / retention;未曝光不自动等于 outcome 为 0。

\((42,t)\mapsto\) account 42Observed attribution

在 trusted logging protocol 下,多条 interactions 已知属于同一 account-individual。

cₜQExplicit response context

fixed-\(u\) 后直接改变 response 的已知 history / policy context;不是整包 abductive evidence,也不能含 query 后的 outcome。

$$S_{42,t}=(H_{42,t},A_{42,t},Y_{42,t}),\qquad t=1,\ldots,T_{42},\qquad U=u_{42}$$
$$\mathcal O_t^{F,\mathrm{known}}=\{H=h_{42,t},\mathrm{ID}=42\},\qquad \mathcal O_t^{F,\mathrm{sel}}=\{H=h_t,\widetilde{\mathrm{ID}}=\widetilde k,\text{side information}=s_t\}$$

这是两个不同 factual-evidence regimes,不能用同一个 \(\mathcal O_t^F\) 混写。known-account regime 中,若 protocol 保证 ID 42 唯一揭示 \(u_{42}\),这个 world conditional 是 \(\delta_{u_{42}}\),且 direct-access pipeline 无需学习或运行 \(Q_\phi\);user embedding、preference factor 或其 posterior 仍需由 response objective 估计——identity certainty 不等于 response-content certainty。selector regime 中,真实 \(u^\star\) 只作 evaluation truth,不进入 learner input;world side 与 learner 分别写 \(P(U\in du\mid\mathcal O_t^{F,\mathrm{sel}})\) 和 \(Q_\phi(du\mid\mathcal O_t^{F,\mathrm{sel}})\)。若 history 同时直接改变 response,协议只把相应部分显式投影为 \(c_t^Q\),不会把整包 \(\mathcal O_t^F\) 再送入 kernel。

03 · three different learning questions

同一份推荐日志,至少对应三个不同问题

A · LOGGED PREDICTION

日志条件下会发生什么?

实际 action \(A_{42,t}=a_t\) 已被观察且 admissible 后,把它加入 known-account factual information:\(\mathcal O_t^{F,\mathrm{log}}=(\mathcal O_t^{F,\mathrm{known}},A_{42,t}=a_t)\),再预测尚未观察的当前 target \(Y_{42,t}^Q\)。它描述 logged-policy distribution,不自动等于 intervention response;待预测的 \(Y_{42,t}^Q\) 不能同时放入 \(\mathcal O_t^{F,\mathrm{log}}\)。

B · PERSONALIZED RANKING

已知 account 42,哪个候选分数更高?

用 ID 与 history 排序可以是强 personalization,但 predictive ranking 不自动成为 personalized causal effect。

C · SAME-UNIT WHAT-IF

同一个用户换一种推荐会怎样?

固定 focal unit、pre-action evidence 与 future policy \(\pi^+\),比较 alternative current treatments 的 delayed outcome。

$$\tau_{42,t}(a,a';\pi^+)=\mathbb E\!\left[Y_{42,t+\Delta}(a;\pi^+)-Y_{42,t+\Delta}(a';\pi^+)\mid H_{42,t},U=u_{42}\right]$$

问题 C 使“推荐哪个 item”获得明确的 same-user counterfactual 锚点,并固定当前 action 后共同执行的 \(\pi^+\)。但能写出这个 estimand,不等于从现有日志识别了它。每个决策时点通常只观察一个 factual treatment 与 outcome。

04 · known referent versus latent property

先知道“是谁”,再建模“这个 user 有什么属性”

Referential layer · resolver

trusted account key \(k\) 解析 known referent 与稳定 response/update address \(u(k)\),把每个 interaction 归属于同一 selected account-individual;它不提供一条已完成的用户数值表示。

Property / response layer · objective

response training 在该地址学习 user content \(u_\theta(k)\),也可写作 latent preference variable \(Z_k\);MAP 版本学习 point vector,Bayesian 版本保留 posterior。

$$K=42,\qquad Z_{42}\sim p(dz\mid R,K=42),\qquad \widehat s_{ka}=\widehat z_k^\top v_a\ \text{或对 }p(dz_k\mid R,K=k)\text{ marginalize}$$

若 protocol 保证 user_id=42 唯一揭示 account-individual,world-side which-user conditional 可以 collapse:\(P(U\in du\mid\mathrm{ID}=42)=\delta_{u_{42}}(du)\),well-specified learner 应近似它;这个 Dirac 在 persistent referent 上,绝不在 trainable \(u_\theta(42)\) 上。即便如此,PMF 对 latent preference \(Z_{42}\) 的 posterior 仍可 non-degenerate;referent certainty 不等于 preference-property certainty。Logged response 与 interventional response 仍然是不同对象:

$$P\!\left(Y_{u_{42},t+\Delta}\mid A_{42,t}=a,H_{42,t};u_{42}\right)\not\equiv P\!\left(Y_{u_{42},t+\Delta}(a;\pi^+)\mid H_{42,t};u_{42}\right)$$

Identification boundary:从左式走到右式,需要 assignment / exposure、positivity、confounding、carryover、interference、treatment version 与 future-policy 条件;unit-conditioned computation 本身不自动生成 causal semantics。

05 · same-user reuse contract

比较 A 与 B 时,什么必须固定?

一份 factual-evidence belief · 显式 \(c_t^Q\) · 多个 designed candidates

\(Q_\phi(du\mid\mathcal O_t^{F,\mathrm{sel}})\)formed once
\(c_t^Q\)direct response context
\(\int P(dy^Q\mid a^Q,c_t^Q,u)dQ\)candidate response

Candidate 改变不会重算 unit belief;新 factual evidence 真正到达后才更新 \(\mathcal O_t^F\)。

$$Q_\phi(du\mid\mathcal O_t^{F,\mathrm{sel}})\longrightarrow\left\{\int_{\mathcal U}P_\theta(dy^Q\mid a^Q,c_t^Q,u)Q_\phi(du\mid\mathcal O_t^{F,\mathrm{sel}}):a^Q\in\mathcal A\right\}$$
$$\text{trusted account:}\qquad \left\{P_\theta(dy^Q\mid a^Q,c_{42,t}^Q,u_{42}):a^Q\in\mathcal A\right\}$$

它要求:

  1. 不因 designed candidate item 改变而偷偷改变 factual evidence、response context 或重算 selector belief;
  2. 不把该 candidate 之后才出现的 click、purchase 或 retention 倒灌进 \(H_{42,t}\);
  3. 允许显式 \(c_t^Q\) 与合法的 candidate-conditioned computation,但禁止把整包 \(\mathcal O_t^{F,\mathrm{sel}}\) 当作未分型 response input;固定 unit 不等于所有 hidden states 必须数值相同;
  4. 新 feedback 真正到达后,下一时点的 admissible Population information 可以更新,它对 selector 与 property/state 的作用取决于当前 regime。

所以 same unit 不等于 static user。两种 regime 的更新不同:trusted-account 下 selected-individual conditional 仍是关于 \(u_{42}\) 的同一 Dirac,更新的是 history、response/property state 或其 uncertainty;ambiguous selector 下,新到达且 admissible 的 Population event 才可能同时更新 \(P(U\in du\mid\mathcal O_{\mathrm{new}}^{\mathrm{sel}})\) 与 learner \(Q_\phi\)。

06 · response-layer neighbors

已有推荐方法与 unit-selector framework 在哪里相邻?

MATRIX FACTORIZATION

Known referent, learned content

先接收 already-known user referent \(K=k\):这个 key 决定读取和更新哪一个 persistent parameter address;response training 再在该地址学习 user content \(u_\theta(k)\),也可写成 latent preference variable \(Z_k\)。它回答“known user 的 response content 应当怎样估计”,不是 which-user selection。

SEQUENTIAL RECOMMENDATION

History-conditioned state

SASRec 等方法用 already-grouped user history 形成当前 state,通常在模型外先获得 user membership;state 可能同时包含长期偏好、短期 intent 与既往 treatment effects,不能自动解释为 which-user belief。

PROBABILISTIC CF

Property posterior 已经存在

Mult-VAE 等方法已经推断 known user's latent distribution。必须检查 posterior 的 event subject:它通常不是 \(P(U\in du\mid\mathcal O)\) 或 learner \(Q_\phi\)。

CAUSAL RECOMMENDATION

Recommendation as treatment 已经存在

已有工作处理 exposure、self-selection 与 logged-policy bias。item-as-treatment 是直接邻居和 identification reference,不是新术语。

$$K=k,\qquad Z_k\sim p(dz\mid R,K=k),\qquad \widehat s_{ka}=\widehat z_k^\top v_a\ \text{ or }\ \int z^\top v_a\,p(dz\mid R,K=k)$$

标准 RecSys 同时具有 direct referential access 与 learned unit-indexed response content:resolver 决定更新哪个 persistent address,objective 决定该地址上的数值。PMF 对 known user 的 \(Z_k\) 或 \(u_\theta(k)\) 属于 response/property layer;它不是 Unit Abduction,也不需要被表述为模型“学出了这个人本身”。

最诚实的关系:Conventional recommendation supplies known-referent response and representation mechanisms that USL-01 can use. It is an important neighboring layer; the Population selector and which-unit epistemic layer remain separate.

07 · what breaks without an explicit unit

如果只剩 interaction rows,会具体坏在哪里?

隐含权重改变高频用户贡献更多 rows,可能在没有 estimand 理由时主导训练和 metric。
Within-user 与 between-user variation 混桶同一人的状态变化被当作不同人之间的差异。
Evaluation leakage同一用户的历史跨 train/test,却被误报成 new-user generalization。
Same-user what-if 失去锚点“相似用户在 \(a'\) 下的 response”不能自动替代账户 42 在 \(a'\) 下的 response。

这些一般后果已经在 Unit / sample 基础页解释;本页只展示它们怎样在 recommendation log 中出现。

$$\widehat R_{\rm interaction}=\frac{1}{\sum_iT_i}\sum_i\sum_t\ell_{it},\qquad \widehat R_{\rm unit}=\frac1N\sum_i\frac1{T_i}\sum_t\ell_{it}$$

前者对应随机 interaction,后者对应随机 account unit;没有一个在所有部署目标下自动正确。区分 unit / sample 的收益,是让论文必须声明 deployment estimand。若设计本来就是一 row 对应一 unit,则二者可以 operationally collapse。

08 · causal and temporal boundary

七日留存不是一个孤立 item 的静态标签

PASTpast actions & outcomes
EVIDENCEpre-action \(H_t\)
POLICYlogging \(\pi_0\)
TREATMENTslate / exposure \(A_t\)
FEEDBACKclick / purchase \(Y_t\)
FUTUREhistory & retention
  • \(H_t\) 可以包含过去 actions 与 outcomes,但不能含当前 action 后的信息。
  • treatment version 包括是否真正曝光、位置、顺序、slate composition 与呈现方式。
  • 未曝光不是 \(Y=0\);slate 内 items 互相竞争,也可能存在 interference。
  • 长期 retention 通常受当前及未来多轮推荐共同影响;本页用 \(Y_{t+\Delta}(a;\pi^+)\) 固定同一个 future policy,更一般时应声明 dynamic regime。
  • 从 \(p(Y\mid H,A)\) 到 \(p(Y(a)\mid H)\) 还需要 assignment、positivity、confounding 与 identification contract。
09 · training and evaluation

query 一变,正确的 split 与 metric 也会变

计数轴

interaction-weighted objective 与 account-unit-weighted objective 分别服务不同 deployment populations;row 数不能替 unit 数做默认权重。

泛化轴

known-user new-interaction、cold-start but known identity、new user、identity-ambiguous session 与 off-policy evaluation 必须分别报告。

证据等级:offline ranking accuracy 不能证明 alternative recommendation 的 causal value;interaction-wise random split 也不能证明 new-user generalization。

10 · persistence without stasis

同一个用户可以不断变化

$$U=u_{42}\ \text{remains the selected account-individual},\qquad H_{42,t+1}=\operatorname{update}(H_{42,t},A_{42,t},Y_{42,t})$$

selected account-individual \(u_{42}\) 跨当前比较保持不变;history 与 response/property state 描述兴趣、意图、疲劳及受过去推荐影响的变化轨迹。在 trusted-account regime,新 history 形成未来 answer-time information \(\mathcal O_{\mathrm{new}}^{\mathrm{known}}\),但只要 reliable ID contract 不变,\(P(U\in du\mid\mathcal O_{\mathrm{new}}^{\mathrm{known}})\) 仍是关于 \(u_{42}\) 的同一 Dirac;新 feedback 更新的是 history、response/property state 或其 uncertainty,这不是重新选择 Population individual。Sequence-model state 是 known referent 的 time-varying response property:它可以作为 \(P_\theta\) 的额外输入或内部状态,而不改变 persistent identity,也不成为 Unit Abduction 的输出或第二个 foundational unit representation。

item 的 treatment 角色同样由 query 决定:在当前 user-retention 问题中 item / slate 是 treatment;若研究 item 生态、创作者供给或内容生命周期,item 或 creator 也可以成为另一个 focal unit,届时必须重新写一套 unit / treatment / outcome contract。

11 · what this case establishes

这个案例展示了什么,又没有展示什么?

已经展示

user unit 与 interaction sample 不能无声明地互换;observed account ID 可以可靠绑定多条 interaction attribution,解析 persistent referent 与稳定 update address,该地址上的 embedding / latent property / state 仍由 response training 学习;direct identity access 与 learned unit-indexed response content 可以同时存在——前者的 Dirac 在 referent 上,后者的 estimation error 在 response layer;matrix factorization、sequential 和 probabilistic recommenders 都不是 Unit Abduction,除非当前 user identity 本身未被 resolver 确定;same-user causal query 比 logged prediction 多出 identification contract。

尚未展示

USL-01 的 novelty 已成立;non-degenerate learner belief 优于 known-referent latent posterior 或 point-summary computation;logged recommendation 已识别个体 causal effect;account identity 等于自然人身份;长期 retention effect 已被实验验证。

真正的压力测试:在 conventional known-referent recommendation 已经很成熟的前提下,USL-01 的新增价值必须落在 Population selection、event-subject typing、evidence admissibility 与 two-source uncertainty 上,并用 matched baselines 和可证伪行为差异检验。

Primary anchors

推荐 response / representation 邻居的一手来源

这些来源只锚定已有推荐实践与 response-layer boundary;不为 unit-selector framework 的 novelty、identification 或 empirical advantage 背书。

Owner directive applied

这份 worked example 现在固定什么

  1. Population \(U\) 执行 individual selection;event \(U=u_{42}\) 固定/表示账户 42 这一 persistent referent,并语义索引 fixed-user response law。
  2. 多条 interactions 是关于同一 account 的 observed-attribution samples;这不表示每条 interaction 都重新抽取一个 indexed selector,也不定义 PMF latent。
  3. factual evidence \(\mathcal O_t^F\) 一次形成 which-user belief;多个 candidate \(a^Q\) 复用它,query 不重新进入 Unit Abduction。
  4. History 中直接改变 response 的信息显式成为 \(c_t^Q\);整包 \(\mathcal O_t^F\) 不回灌 response kernel。
  5. 账户 ID 按 trusted registry contract 解析 known referent 与稳定 response/update address \(u(k)\);identity conditional 的 Dirac 在 \(u(k)\) 上,绝不在 trainable \(u_\theta(k)\) 上——PMF 的 \(Z_{42}\) 是 known-account 地址上的 learned preference content,不是 which-user belief;logged prediction 也不冒充 intervention response。