There is an increasing number of proteins with known structure but unknown function. Determining their function would have a significant impact on understanding diseases and designing new therapeutics. Computational methods can facilitate function determination by identifying proteins that have high structural and chemical similarity. Below, we will briefly describe LabelHash, a new method for partial structure comparison. In partial structure comparison, the goal is to find the best geometric and chemical similarity between a set of 3D points called a _motif_ and a subset of a set of 3D points called the _target_. Both the motif and targets are represented as sets of labeled 3D points. A motif is ideally composed of the functionally most-relevant residues in a binding site. The labels denote the type of residue. Motif points can have multiple labels to denote that substitutions are allowed. Any subset of the target that has labels that are compatible with the motif’s labels is called a _match_. The aim is to find statistically significant matches to a structural motif. Our method preprocesses a background database of targets such as a non-redundant subset of the Protein Data Bank in such a way that we can look up in constant time partial matches to a motif. Using a variant of the previously described match augmentation algorithm (1), we obtain complete matches to our motif. The nonparametric statistical model developed by (2,3) corrects for any bias introduced by our algorithm. This bias is introduced by excluding matches that do not satisfy certain geometric constraints for efficiency reasons