Skip to main content

Module similarity

Module similarity 

Source
Expand description

Adaptive element similarity search for crate::page::PageHandle.

Computes a structural fingerprint for a reference DOM node and finds candidates on the current page that exceed a configurable similarity threshold, even after class names or depth have shifted.

Structs§

ElementFingerprint
A structural snapshot of a DOM element for similarity comparison.
SimilarMatch
A candidate element that exceeded the similarity threshold.
SimilarityConfig
Tuning parameters for crate::page::PageHandle::find_similar.

Functions§

jaccard_weighted
Compute the weighted Jaccard similarity between two element fingerprints.