Nearest Neighbor Search Service Incremental Vector Updates

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current nearest neighbor search services do not support incremental updates of vectors while allowing real-time queries, leading to inconvenient locking mechanisms that block searches during updates.

Innovation Solution

The implementation of a nearest neighbor search service that uses a node table with read and write locks to manage vector updates and queries incrementally, allowing for efficient addition, deletion, and updating of vectors without deadlocks, using Dijkstra's algorithm for graph creation and HNSW for high-recall approximate solutions.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If the entire graph is locked during vector updates, then data consistency is ensured, but query operations are blocked and latency increases

Engineering Contradiction:
Improvedata consistencyVSAvoidquery throughput
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent divides the graph locking mechanism into fine-grained locks at the node level instead of a single global lock. Each node in the graph has its own lock, allowing concurrent read operations on nodes that are not being modified. This segmentation enables query operations to proceed in parallel with update operations on different nodes, resolving the contradiction between data consistency and query throughput.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent implements dynamic lock management where locks are acquired and released based on the specific operations needed. Read operations acquire read locks that allow concurrent access, while write operations acquire write locks that prevent modifications during updates. This dynamic approach ensures data consistency only where needed while maintaining high query throughput overall.

Inventive Principle:
Principle #15Dynamics

2Adaptability or versatility

If a node table with read and write locks is implemented, then incremental updates are enabled, but system complexity increases

Engineering Contradiction:
Improveincremental update capabilityVSAvoidlocking mechanism complexity
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The node table structure serves multiple functions: it stores graph node data, manages locking states through read/write lock fields, and provides the foundation for incremental updates. By combining these functions into a single unified structure, the patent reduces overall system complexity while enabling versatile operations including reads, writes, and incremental modifications without requiring separate mechanisms for each operation.

Inventive Principle:
Principle #6Universality (Multi-functionality)

Solution Approach 2:

The node table acts as an intermediary layer between the graph data and the locking mechanism. It provides a standardized interface for managing access to graph nodes, abstracting the complexity of lock management from the graph traversal operations. This intermediary structure simplifies the implementation of incremental updates while maintaining clear separation of concerns.

Inventive Principle:
Principle #24Intermediary (Mediator)

3Reliability

If the graph is locked during updates, then data integrity is maintained, but query latency increases

Engineering Contradiction:
Improvedata integrityVSAvoidquery latency
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

By segmenting the lock into node-level granularity, the patent allows query operations to execute concurrently with update operations on different nodes. Reads on unaffected nodes proceed without waiting for updates to complete, significantly reducing query latency while maintaining data integrity through proper lock coordination.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The locking mechanism operates in periodic cycles where updates acquire write locks, perform modifications, and then release locks allowing reads to proceed. This periodic acquisition and release of locks ensures data integrity during updates while allowing queries to execute in between update cycles, reducing overall latency.

Inventive Principle:
Principle #19Periodic action

Data Source

PatentUS11055286B2Incremental updates for nearest neighbor search
Publication Date: 2021.07.06 AMAZON TECH INC
  • US11055286B2 patent drawing
  • US11055286B2 patent drawing
  • US11055286B2 patent drawing

AI summary

Techniques are described for a nearest neighbor search service that enables users to perform nearest neighbor searches. The nearest neighbor search service includes an interface that enables users to create collections of searchable vectors, add and update vectors to a collection, delete vectors from a collection, and perform searches for nearest neighbors to a given vector. The nearest neighbor search service enables users to add, update, and delete vectors of a collection in real-time while also enabling users to perform searches at the same time.