# Pedigree Relatedness Calculator AI Agent Connect

> Pedigree Relatedness Calculator is a specialized MCP for analyzing genetic relationships within animal pedigrees. It gives your AI client the ability to compute additive relationship coefficients, kinship values, and pedigree depth. You can use it to identify the least related pairs in a population to maintain genetic health and verify the mathematical consistency of your relationship matrices.

## Overview
- **Category:** data-analysis
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_QTAmUDgJhsNXtVwinjCb9aMTNlsRHF5WyOjW7bS8/ai-agent-connect
- **Tags:** pedigree, kinship, genetics, animal-breeding, mathematical-modeling

## Description

You can now give your AI agent the ability to perform complex genetic math on your breeding data. This MCP handles the heavy lifting of calculating kinship and additive relationship coefficients within a pedigree structure. Instead of manually checking lineage, you can ask your AI client to identify specific relationship values or find the best candidates for breeding to avoid inbreeding. 

It works by processing your pedigree data to measure how closely related individuals are. You can use it to check the depth of your genealogical records or ensure your relationship matrices are mathematically sound. If you are planning a breeding program, the MCP helps you find pairs with the lowest genetic similarity to keep your population healthy. It turns raw pedigree data into actionable genetic insights through a few simple prompts in your preferred AI interface.

## Tools

### analyze_pedigree_depth
This tool measures how deep and complex a pedigree structure is. It calculates the genealogical reach of your recorded lineages.

### calculate_pairwise_relatedness
This tool determines the additive relationship and kinship between two specific animals. It provides the exact coefficients for a chosen pair.

### rank_least_related_pairs
This tool identifies which pairs in your dataset have the lowest genetic similarity. It helps you find the best candidates for maintaining diversity.

### verify_matrix_integrity
This tool checks your pedigree matrix for mathematical consistency. It ensures your relationship data is valid and error-free.

## Prompt Examples

**Prompt:** 
```
What is the relationship between animal ID 'A123' and 'B456' in this pedigree data?
```

**Response:** 
```
The additive relationship between A123 and B456 is 0.25, with a kinship coefficient of 0.125. They share two common ancestors.
```

**Prompt:** 
```
How deep is this pedigree structure?
```

**Response:** 
```
The effective depth of the pedigree is 8 generations, containing a total of 142 individuals.
```

**Prompt:** 
```
Find the top 3 least related pairs from this list of IDs.
```

**Response:** 
```
The least related pairs are: 1. ID_01 and ID_99 (0.00), 2. ID_05 and ID_88 (0.01), 3. ID_12 and ID_44 (0.01).
```

## Capabilities

### Kinship Calculation
Your agent calculates additive relationship and kinship coefficients for any two animals.

### Diversity Planning
Your agent identifies pairs with minimal genetic similarity to help you avoid inbreeding.

### Data Validation
Your client verifies that pedigree matrices are mathematically consistent and accurate.

### Lineage Assessment
The MCP measures the effective depth and complexity of your genealogical records.

## Use Cases

### Inbreeding Prevention
Use the MCP to find the least related pairs in a herd to ensure healthy offspring.

### Lineage Auditing
Check the depth of your pedigree to understand the generational reach of your breeding lines.

### Data Quality Control
Run matrix integrity checks to make sure your pedigree records are mathematically sound.

### Pairwise Comparison
Quickly determine the exact relationship between two specific animals in a large dataset.

## Benefits

- Calculates precise kinship coefficients without manual math.
- Identifies low-similarity pairs to support genetic diversity.
- Validates pedigree matrix consistency to prevent data errors.
- Quantifies genealogical complexity through depth analysis.

## How It Works

You connect the MCP to your AI client and start asking questions about your pedigree data.

1. Connect your AI client to the Vinkius-hosted MCP.
2. Provide your pedigree data to the AI agent.
3. Ask your agent to perform specific calculations like kinship or depth.
4. The MCP executes the math and returns the results to your chat interface.

## Frequently Asked Questions

**What can this MCP calculate?**
It calculates additive relationship coefficients, kinship values, pedigree depth, and identifies least-related pairs.

**Which AI clients can use this MCP?**
You can use this MCP with any compatible client, including Claude, Cursor, Windsurf, and VS Code.

**How does it help with genetic diversity?**
It can rank pairs of animals by their lowest genetic similarity, making it easier to select candidates for breeding.

**Do I need to host the MCP myself?**
No, Vinkius hosts and manages the MCP for you. You connect it to your client.

**Can it check my pedigree data for errors?**
Yes, the verify_matrix_integrity tool checks the mathematical consistency of your pedigree matrices.

**What is an additive relationship coefficient?**
It is a measure of how much genetic material two individuals share due to common ancestry, representing the fraction of genes shared by descent.

**How can I check if my pedigree matrix is mathematically sound?**
You can use the `verify_matrix_integrity` tool to check if the relationship matrix is symmetric and consistent.

**How do I find animals that are least related?**
The `rank_least_related_pairs` tool identifies pairs with the lowest genetic similarity within a provided set of animal IDs.
