23andme Raw Data File Lookup

by obuchowski

305 downloads
Not rated
GitHub

About

Querying genotype data by RSID from 23andMe raw file

Details

Author
obuchowski
Downloads
305
Categories
Search

- Parses 23andMe raw TSV genotype files.
- Looks up genotype by Reference SNP cluster ID.
- Runs entirely locally, no external data transmission.
- Read-only access, never modifies genetic data.
- Integrates with LLMs through Model Context Protocol.
- Simple installation via npm with Node.js v18+.

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name 23andme Raw Data File Lookup
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Install via npm after cloning the repository, then configure the server in your MCP client (e.g., Claude.app or Zed) by specifying the command node with arguments pointing to the server script and your 23andMe raw data file. Once running, you can ask an LLM to look up genotypes using the get_genotype_by_rsid tool with an RSID string.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "23andme raw data file lookup": {
            "23andMe Genotype Lookup": {
                "command": "node",
                "args": [
                    "~/src/index.js",
                    "~/sample-data.txt"
                ]
            }
        }
    }
}

McpServers

{
    "23andMe Genotype Lookup": {
        "command": "node",
        "args": [
            "~/src/index.js",
            "~/sample-data.txt"
        ]
    }
}

23andMe Raw Data MCP Server

A Model Context Protocol server that enables LLMs to query 23andMe raw genotype files by RSID (Reference SNP cluster ID). This server parses TSV-formatted 23andMe raw data files and provides instant access to genetic information, making it easy to look up specific genetic variants and their associated genotypes for research and educational purposes.

Available Tools

get_genotype_by_rsid - Get genotype for a given RSID, returns "--" if not found.

Required arguments:
- rsid (string): Reference SNP cluster ID (e.g., 'rs1234567', 'rs9876543')

Installation

Using npm

git clone https://github.com/yourusername/23andme-mcp-server.git
cd 23andme-mcp-server
npm install

Prerequisites

- Node.js v18 or higher
- 23andMe raw data file (TSV format, downloadable from 23andMe account)

Configuration

Configure for Claude.app

Add to your Claude settings:

{
  "mcpServers": {
    "23andMe Genotype Lookup": {
      "command": "node",
      "args": ["/path/to/23andme-mcp-server/src/index.js", "/path/to/your-23andme-data.txt"]
    }
  }
}

Configure for Zed

Add to your Zed settings.json:

{
  "context_servers": {
    "23andme-lookup": {
      "command": "node",
      "args": ["/path/to/23andme-mcp-server/src/index.js", "/path/to/your-23andme-data.txt"]
    }
  }
}

Data Format

The server expects 23andMe raw data files in the standard TSV format:

# Header comments (ignored)

rsid chromosome position genotype

rs1234567 1 123456 TT rs2345678 2 234567 CC rs3456789 3 345678 AG

Example Interactions

Get genotype for a specific RSID:

{
  "name": "get_genotype_by_rsid",
  "arguments": {
    "rsid": "rs1234567"
  }
}

Response:

TT

Query missing RSID:

{
  "name": "get_genotype_by_rsid",
  "arguments": {
    "rsid": "rs9999999"
  }
}

Response:

--

Running the Server

Basic Usage

npm start your-23andme-data.txt

or

node src/index.js your-23andme-data.txt

With Sample Data

npm start sample-data.txt

Debugging

You can use the MCP inspector to debug the server:

npx @modelcontextprotocol/inspector node src/index.js sample-data.txt

Examples of Questions for Claude

- "What is my genotype for rs1234567?"
- "Look up my genetic variant rs9876543"
- "Check if I have the rs1815739 variant and what genotype I have"
- "What are my genotypes for rs1234567, rs2345678, and rs3456789?"

Privacy and Security

- Local Processing: All genetic data processing happens locally on your machine
- No Data Transmission: The server only reads your local data file and doesn't transmit genetic information externally
- Read-Only Access: The server only reads your data file and never modifies it

Data Source

To use this server, you'll need to download your raw genetic data from 23andMe:

1. Log into your 23andMe account
2. Go to "Settings" → "Privacy" → "Download Data"
3. Request and download your raw genetic data
4. Use the downloaded file with this MCP server

Contributing

We encourage contributions to help expand and improve the 23andMe Raw Data MCP Server. Whether you want to add new genetic analysis tools, enhance existing functionality, or improve documentation, your input is valuable.

For examples of other MCP servers and implementation patterns, see: https://github.com/modelcontextprotocol/servers

Pull requests are welcome! Feel free to contribute new ideas, bug fixes, or enhancements to make the server even more powerful and useful for genetic research and education.

License

23andMe Raw Data MCP Server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

Disclaimer

This tool is intended for research, educational, and informational use only. It is not intended for medical or diagnostic purposes. Always consult with healthcare professionals for medical advice and genetic counseling.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.