PrivAgents: MCP server for confidential homomorphic-encryption workflows

PrivAgents: MCP server for confidential homomorphic-encryption workflows

privagent•byuvrajsb

A privacy-first framework with a trustless MCP server that performs encrypted similarity calculations on homomorphically encrypted data, paired with on-device or cloud agents.

License: Not specified•Runtime: Awaiting documentation review•Category: ai agents-models

WHAT IT DOES

  • •Runs a modular MCP server that computes encrypted similarity calculations on the backend.
  • •Performs encrypted similarity calculations between an encrypted user vector and plaintext movie profiles using a dot product under encryption.
  • •Works with either an on-device Ollama agent or a cloud-based OpenAI agent.

BEST FOR

  • •Privacy-preserving recommendation systems such as movie preference matching.
  • •Sensitive environments such as healthcare, personalization, and finance.

ABOUT PRIVAGENT

PrivAgents: MCP server for confidential homomorphic-encryption workflows is cataloged as an MCP server attributed to uvrajsb. A privacy-first framework with a trustless MCP server that performs encrypted similarity calculations on homomorphically encrypted data, paired with on-device or cloud agents. It is categorized under ai agents-models. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.

HOW TO INSTALL

Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.

LICENSE

Catalog license label: Not specified. Check the source repository's current license and terms before using, modifying or distributing this software.

能力检查器

能力定义尚未审核。未核验的采集内容不会作为可信接口展示。

Tools (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Resources (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Prompts (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

NEWSLETTER - COMING LATER

Newsletter subscriptions are not open yet

Email delivery is not connected. This page does not collect email addresses or create subscriptions.

Browse the registry for current listings instead.

Community Reviews

Coming later

Reviews for PrivAgents: MCP server for confidential homomorphic-encryption workflows are not available yet

Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.

FREQUENTLY ASKED QUESTIONS

Does the server ever see the user's data in plaintext?

No; the server performs encrypted calculations and never sees raw user data, requiring zero trust.

上游原版 README

在 GitHub 查看同一版本原文

README.md · 8ecdbcb48cce · 采集于 2026-11-13 12:14:20 UTC

保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。

当前显示最后一次成功采集的文档快照,请以来源页面为准。

PrivAgents: Agents and MCP servers for Confidential AI Workflows

PrivAgents is a privacy-first framework that showcases how autonomous agents, both on-device and in the cloud, can perform secure data processing through trustless MCP servers while ensuring complete confidentiality. It leverages Privacy-Enhancing Technologies (PETs) herein Homomorphic Encryption (HE) to compute on encrypted data without ever accessing raw information.

Through a conversational agent interface, user data is encrypted on the device, sent to a secure processing unit (MCP), and the results are returned in encrypted form to be decrypted locally. This creates a secure and intelligent system for sensitive environments such as healthcare, personalization, and finance.

PET enabled MCP server


🔐 Why PrivAgents

On-device models offer privacy but are often limited in power. Cloud models offer power but raise trust concerns. PrivAgents solves this by combining the strengths of both:

  • On-device or cloud-based agents to suit your compute and trust needs
  • Homomorphic encryption ensures data remains private during processing
  • Modular MCP server performs encrypted similarity calculations on the backend
  • End-to-end encrypted pipeline for secure data interaction

⚙️ Supported Agents

  • ✅ Ollama Agent for on-device reasoning using local models
  • ✅ OpenAI Agent for cloud-based intelligence via API

Choose your agent type based on privacy constraints and available resources.


🧠 Architecture Overview

      +------------------------+
      |     User Device        |
      |  (Agent + Encryption)  |
      +------------------------+
         |   Encrypted Input
         v
+------------------------+   ← Secure Channel →
|     MCP Server         |  (Encrypted Similarity Calculation)
+------------------------+
         |   Encrypted Result
         v
      +------------------------+
      |  User Device (Decrypt) |
      +------------------------+

📁 Project Structure

PrivAgents/
│
├── agent/           # Ollama and OpenAI agent implementations with PET tools
├── mcp/             # Encrypted processing logic for similarity-based analysis
├── utils/           # Context setup, encryption helpers
├── data/            # Sample inputs and encrypted output files
└── .env             # Configuration for ports and logging

🚀 Getting Started

1. Clone and Set Up

git clone https://github.com/UvrajSB/PrivRec.git
cd PrivRec
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt

2. Start the MCP Server

From the root directory:

PYTHONPATH=. python mcp/server.py

3. Run an Agent

  • Ollama Agent (Local Execution)
PYTHONPATH=. python agent/ollama_mcp_agent.py
  • OpenAI Agent (Cloud Execution)
PYTHONPATH=. python agent/openai_mcp_agent.py

Each agent encrypts the user input, sends it for encrypted similarity calculation, and decrypts the response privately on-device.


🎬 Movie Preference Matching: Encrypted End-to-End Personalization

The movie preference matching use case is a working demonstration of how privacy-preserving recommendation systems can function without accessing user data in plaintext. It showcases the end-to-end use of homomorphic encryption to encrypt user preferences, run secure similarity calculations, and deliver personalized results—all while ensuring zero exposure of raw data.


🔁 Workflow Overview

  1. User inputs a movie interest vector
    The user is asked to rate or prioritize different genres (e.g. Action, Romance, Sci-Fi). For example:

    [8, 2, 9] → represents user's preference intensity across three genres.
    
  2. Encryption on the agent side
    The agent (either Ollama or OpenAI based) uses TenSEAL to homomorphically encrypt the interest vector using the BFV scheme. The result is an encrypted tensor, unreadable even to the server.

  3. Encrypted similarity calculation on the MCP server

    • The MCP server has a collection of predefined movie profiles, each represented as a plaintext vector:
      MOVIES = {
        "Inception":     [9, 1, 8],
        "The Notebook":  [1, 9, 2],
        "Interstellar":  [8, 2, 9],
        "The Godfather": [7, 5, 4]
      }
      
    • It performs encrypted similarity calculations between the encrypted user vector and each plaintext movie profile.
    • This similarity is computed using a dot product under encryption, without decrypting the user vector.
  4. Encrypted results are returned
    The server writes the encrypted similarity scores for all movies to a file, for example:

    data/interest_results
    
  5. Decryption on the user device
    The agent loads the encrypted results and decrypts them locally using the original context and keys. The decrypted scores represent how closely each movie matches the user's preferences.

  6. Optional: Rank and display results
    The agent can sort the scores and show the top movie recommendations based on similarity, all while ensuring the user's input and preferences were never visible to the server.

Terminal

📦 Benefits

  • ✅ Zero Trust Required: Server never sees user data
  • ✅ Agent Agnostic: Works with both on-device and cloud-based LLM agents
  • ✅ Extendable: Can support more complex user profiles or additional domains (like music, shopping, healthcare)
  • ✅ Educational: Demonstrates how homomorphic encryption works in a practical context

👥 Contributing

Interested in building secure and intelligent systems with PETs? Whether it is extending agent logic, experimenting with new encrypted workflows, or refining the MCP layer, your contributions are welcome. Fork the repo and get started.

Install configuration

Are you the maintainer?

Claim this server with your GitHub account to request manual ownership verification.

README Embed Badge
Markdown

Link to the catalog listing for PrivAgents: MCP server for confidential homomorphic-encryption workflows from your README. This badge does not certify ownership, compatibility or security.

[![MCP catalog listing](https://img.shields.io/badge/MCP-awesome--mcp-orange?style=flat-square)](https://awesome-mcp.com/servers/privagent)

REPOSITORY STATS

GitHub StarsUnavailable
ForksUnavailable

Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.

下载与拉取统计

来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。

尚无已审核的包 / 镜像标识,暂不展示下载统计。

Related ai agents-models MCP Servers

Alternative and complementary servers in the same category

View all in ai agents-models →
Knowledge Graph Memory
@modelcontextprotocol/server-memory•Model Context Protocol

Store and retrieve entities, relations and observations in a persistent local knowledge graph.

create_entitiescreate_relationsadd_observations+6 more
92K
AI & Multi-Agent
Sequential Thinking
@modelcontextprotocol/server-sequential-thinking•Model Context Protocol

Organize problem solving into revisable, branching thought steps through an MCP tool.

sequential_thinking
92K
AI & Multi-Agent

Query-aware context compression with an MCP plugin for coding agents, plus Python and HTTP interfaces for reducing the context sent to a language model.

146
AI & Multi-Agent