Circuit PSI is a generic construction for private set intersection that encodes the intersection computation as a Boolean circuit and evaluates it using a secure two-party computation protocol, typically garbled circuits. Unlike custom PSI protocols optimized for specific set operations, this approach expresses the logic as a circuit of AND and XOR gates, enabling arbitrary intersection variants—such as threshold matching or fuzzy PSI—to be computed privately without designing a bespoke cryptographic protocol for each variant.
Glossary
Circuit PSI

What is Circuit PSI?
Circuit PSI is a generic approach to private set intersection that represents the intersection logic as a Boolean circuit evaluated using secure two-party computation techniques.
The primary advantage of Circuit PSI lies in its flexibility and composability. By representing the intersection function as a circuit, developers can incorporate additional logic, such as filtering by associated metadata or computing PSI cardinality, directly into the secure evaluation. However, this generality incurs higher communication complexity and computational overhead compared to highly optimized dedicated protocols like KKRT, making Circuit PSI most suitable for complex intersection predicates where custom protocol design is impractical.
Key Features of Circuit PSI
Circuit PSI represents a generic and highly flexible approach to private set intersection, constructing the intersection logic as a Boolean circuit evaluated securely between parties. This paradigm leverages general-purpose secure computation protocols to compute arbitrary functions over private sets.
Boolean Circuit Representation
The core idea is to express the intersection logic as a Boolean circuit. Each party's input set is encoded as a bit-vector or list of elements, and the circuit computes membership checks. This allows for arbitrary intersection variants beyond simple equality, such as threshold-based or fuzzy matching, by modifying the circuit logic rather than the underlying cryptographic protocol.
Garbled Circuit Evaluation
Circuit PSI protocols typically rely on Yao's Garbled Circuits for secure evaluation. One party (the garbler) encrypts the Boolean circuit, and the other party (the evaluator) computes it using oblivious transfer for input wire labels. This ensures that neither party learns anything beyond the final intersection output, maintaining semantic security against semi-honest adversaries.
Generic Functionality Support
Unlike specialized PSI protocols that only compute exact set intersection, Circuit PSI can compute any function over the intersection. This includes:
- PSI Cardinality: Revealing only the size of the intersection
- Labeled PSI: Returning associated metadata for matched elements
- Threshold PSI: Matching elements that meet a similarity threshold
- PSI-Sum: Computing aggregates over intersecting elements
OT-Based Input Encoding
Input wires in the garbled circuit are assigned labels using Oblivious Transfer (OT). For each bit of a party's input, the other party acts as the OT sender, providing two wire labels. The receiver selects the label corresponding to their actual input bit without revealing which one was chosen. OT extension techniques make this process highly efficient for large input sets.
Communication vs. Computation Trade-off
Circuit PSI protocols exhibit a distinct performance profile. The communication complexity scales with the circuit size, which is typically O(n log n) or O(n) in the number of elements. However, the computational cost is dominated by garbled circuit generation and evaluation. This makes Circuit PSI particularly suitable when the desired intersection function is complex and specialized protocols do not exist.
Malicious Security Extensions
While base garbled circuit protocols achieve semi-honest security, Circuit PSI can be upgraded to malicious security using techniques like cut-and-choose, where the garbler generates multiple circuits and the evaluator checks a random subset for correctness. More recent approaches use authenticated garbling or the LEGO protocol to achieve malicious security with better concrete efficiency.
Frequently Asked Questions
Explore the core concepts behind Circuit-based Private Set Intersection, a generic and flexible approach to secure two-party computation for finding common data elements.
Circuit PSI is a generic approach to constructing Private Set Intersection protocols by securely evaluating a Boolean circuit that computes the intersection function. Instead of relying on specialized cryptographic primitives like Oblivious Pseudorandom Functions (OPRF) , it represents the set intersection logic as a digital circuit. The two parties then use a general-purpose Secure Two-Party Computation (2PC) protocol, typically based on Garbled Circuits, to jointly evaluate this circuit. One party acts as the garbler, creating an encrypted version of the circuit, while the other acts as the evaluator, computing the output without learning the intermediate values. This method offers high flexibility, allowing the computation of arbitrary functions over the intersection, such as summing associated values or checking thresholds, directly within the secure computation layer.
Circuit PSI vs. Specialized PSI Protocols
Comparing the generic circuit-based approach to private set intersection against purpose-built specialized protocols across key performance and security dimensions.
| Feature | Circuit PSI | Specialized PSI | Hybrid Approaches |
|---|---|---|---|
Underlying Primitive | Garbled circuits, OT | OT extension, OPRF, VOLE | Circuit + specialized sub-protocols |
Communication Complexity | O(n log n) to O(n²) | O(n) to O(n log n) | Varies by composition |
Computational Overhead | High (circuit garbling/evaluation) | Low to moderate (symmetric-key ops) | Moderate |
Supports Arbitrary Functions | |||
Malicious Security | Achievable with overhead | Native in many protocols (e.g., KKRT) | Depends on composition |
Best for Unbalanced Sets | |||
Round Complexity | Constant (2-3 rounds) | 2-4 rounds typical | 2-4 rounds typical |
Maturity & Tooling | Moderate (MPC frameworks) | High (dedicated libraries) | Low (custom engineering) |
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Circuit PSI relies on a stack of cryptographic primitives and protocol design patterns. Understanding these building blocks is essential for evaluating the security, performance, and applicability of a circuit-based private set intersection implementation.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us