Functional forms of interaction methods.

These implementations allow for an arbitrary number of batch dimensions, as well as broadcasting and thus naturally support slicing and 1:n scoring.


conve_interaction(h, r, t, t_bias, ...)

Evaluate the ConvE interaction function.

convkb_interaction(h, r, t, conv, ...)

Evaluate the ConvKB interaction function.

cp_interaction(h, r, t)

Evaluate the Canonical Tensor Decomposition interaction function.

cross_e_interaction(h, r, c_r, t, bias, ...)

Evaluate the interaction function of CrossE for the given representations from [zhang2019b].

dist_ma_interaction(h, r, t)

Evaluate the DistMA interaction function from [shi2019].

distmult_interaction(h, r, t)

Evaluate the DistMult interaction function.

ermlp_interaction(h, r, t, hidden, ...)

Evaluate the ER-MLP interaction function.

ermlpe_interaction(h, r, t, mlp)

Evaluate the ER-MLPE interaction function.

hole_interaction(h, r, t)

Evaluate the HolE interaction function.

kg2e_interaction(h_mean, h_var, r_mean, ...)

Evaluate the KG2E interaction function.

multilinear_tucker_interaction(h, r, t, ...)

Evaluate the (original) multi-linear TuckEr interaction function.

mure_interaction(h, b_h, r_vec, r_mat, t, b_t)

Evaluate the MuRE interaction function from [balazevic2019b].

ntn_interaction(h, t, w, vh, vt, b, u, ...)

Evaluate the NTN interaction function.

pair_re_interaction(h, t, r_h, r_t[, p, ...])

Evaluate the PairRE interaction function.

proje_interaction(h, r, t, d_e, d_r, b_c, ...)

Evaluate the ProjE interaction function.

rescal_interaction(h, r, t)

Evaluate the RESCAL interaction function.

simple_interaction(h, r, t, h_inv, r_inv, t_inv)

Evaluate the SimplE interaction function.

se_interaction(h, r_h, r_t, t, p[, power_norm])

Evaluate the Structured Embedding interaction function.

transd_interaction(h, r, t, h_p, r_p, t_p, p)

Evaluate the TransD interaction function.

transe_interaction(h, r, t[, p, power_norm])

Evaluate the TransE interaction function.

transf_interaction(h, r, t)

Evaluate the TransF interaction function.

transh_interaction(h, w_r, d_r, t, p[, ...])

Evaluate the DistMult interaction function.

transr_interaction(h, r, t, m_r, p[, power_norm])

Evaluate the TransR interaction function.

transformer_interaction(h, r, t, ...)

Evaluate the Transformer interaction function, as described in [galkin2020]..

triple_re_interaction(h, r_head, r_mid, ...)

Evaluate the TripleRE interaction function.

tucker_interaction(h, r, t, core_tensor, ...)

Evaluate the TuckEr interaction function.

um_interaction(h, t, p[, power_norm])

Evaluate the SimplE interaction function.

linea_re_interaction(h, r_head, r_mid, r_tail, t)

Evaluate the LineaRE interaction function.