Short-term Hashes for Social Graph Search Index Optimization
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current social-networking systems face inefficiencies in indexing search queries due to the large size of search indices caused by hashing long keyword phrases, leading to higher costs and lower performance in data access.
Innovation Solution
The method involves determining search terms with prefixes and suffixes, generating binary numbers based on these structures, and indexing using hash tables with varying lengths to reduce the size of hash tables, thereby optimizing search index sizes.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If long keyword phrases are hashed for indexing search queries, then search accuracy is improved, but the size of hash tables increases significantly
Solution Approach 1:
The patent segments long keyword phrases into multiple shorter terms and creates separate hash indexes for each term. Instead of hashing the entire long phrase as one unit, the system breaks it down into component terms (e.g., splitting 'new york times' into 'new', 'york', 'times') and maintains individual hash tables for each segment. This segmentation reduces the memory footprint of each hash table while preserving search accuracy through combination of results.
Solution Approach 2:
The patent transitions from a single-dimension approach (one large hash table for complete phrases) to a multi-dimensional approach (multiple smaller hash tables for individual terms). By creating hash indexes across different dimensional slices of the search space - each term gets its own dimensional layer - the system achieves comprehensive coverage with reduced memory requirements at each layer.
2Ease of manufacture
If fixed-length binary numbers are used to represent all search terms, then implementation simplicity is maintained, but hash table sizes become unnecessarily large
Solution Approach 1:
The patent introduces dynamic binary number allocation where the length of binary representations varies based on the specific search term rather than using a fixed length for all terms. Shorter terms receive shorter binary encodings while longer terms receive longer encodings, optimizing the use of memory space. This dynamic approach replaces the static fixed-length scheme with an adaptive system that adjusts to actual term characteristics.
Solution Approach 2:
The patent changes the parameter of binary number length from a fixed constant to a variable that adapts to each search term. By modifying this critical parameter dynamically based on term properties, the system achieves more efficient memory utilization. The binary encoding length becomes a flexible parameter rather than a rigid constraint, allowing optimization of hash table sizes without sacrificing implementation feasibility.
Data Source
Figure 1
Figure 2
Figure 3
AI summary
In one embodiment, a server receives a search query; determines search terms based on the received search query, each search term including a prefix and a suffix, both of which correspond to elements of a social graph; and sends search results matching the prefix and suffix of a search term.