# Kshana PNT-resilience simulator

Wires a real simulation engine into your assistant: orbits, GNSS, INS fusion and receiver trust instead of a model guessing at the numbers.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 6
- Author: ashfordeOU
- License: AGPL-3.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/ashfordeOU/kshana/tree/HEAD/mcp/kshana-mcp
- Updated: 2026-10-23
- HTML: https://affpapa.org/en/nevibecode/mcp/kshana-pnt-resilience-simulator

## What it does

Language models are worst exactly where Kshana is strongest. SGP4 orbit propagation, IAU reference frames, Allan deviations, GNSS availability and DOP, ARAIM protection levels, GNSS/INS fusion, quantum-sensor models — `kshana-mcp` hands the assistant tools that run the actual engine and return JSON, with every figure carrying a unit and a VALIDATED or MODELLED tag.

Roughly twenty tools sit behind the server. `run_scenario` executes a TOML scenario and returns the summary plus the full result; `list_scenario_kinds` documents the 87 built-in kinds with their required and optional fields; `validate_scenario` parses a TOML and detects its kind before anything runs. A second group handles export: CZML, KML, GeoJSON, STK ephemeris, SP3-c, CCSDS OMM and OEM, and the reproducibility table as CSV. `sky_geometry` works out which satellites a skyline hides, and `assess_receiver_log` runs trust monitors over a receiver log given as `ubx`, `rinex`, `android`, `nmea` or `sbf`.

Transport is stdio and the server starts through `npx`. Some tools expect `KSHANA_MCP_IQ_DIR` and `KSHANA_MCP_IQ_MAX_SAMPLES`; leave them out and IQ handling stops there. Two limits worth knowing before you wire it in: `sky_geometry` is MODELLED and runs no Monte Carlo over MCP, and `export_table_csv` only emits a table for a handful of scenario kinds — anything else comes back as an error listing the ones that qualify.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `KSHANA_MCP_IQ_DIR`, `KSHANA_MCP_IQ_MAX_SAMPLES` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env KSHANA_MCP_IQ_DIR=<KSHANA_MCP_IQ_DIR> --env KSHANA_MCP_IQ_MAX_SAMPLES=<KSHANA_MCP_IQ_MAX_SAMPLES> --transport stdio kshana-mcp -- npx -y kshana-mcp
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add kshana-mcp --env KSHANA_MCP_IQ_DIR=<KSHANA_MCP_IQ_DIR> --env KSHANA_MCP_IQ_MAX_SAMPLES=<KSHANA_MCP_IQ_MAX_SAMPLES> -- npx -y kshana-mcp
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "kshana-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "kshana-mcp"
            ],
            "env": {
                "KSHANA_MCP_IQ_DIR": "<KSHANA_MCP_IQ_DIR>",
                "KSHANA_MCP_IQ_MAX_SAMPLES": "<KSHANA_MCP_IQ_MAX_SAMPLES>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "kshana-mcp": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "kshana-mcp"
            ],
            "env": {
                "KSHANA_MCP_IQ_DIR": "<KSHANA_MCP_IQ_DIR>",
                "KSHANA_MCP_IQ_MAX_SAMPLES": "<KSHANA_MCP_IQ_MAX_SAMPLES>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e KSHANA_MCP_IQ_DIR=<KSHANA_MCP_IQ_DIR> -e KSHANA_MCP_IQ_MAX_SAMPLES=<KSHANA_MCP_IQ_MAX_SAMPLES> kshana-mcp npx -y kshana-mcp
```
Replace <…> with your own values

## When to use it
- compute GNSS availability and DOP values for a site and time
- propagate an orbit with SGP4 and export ephemeris as SP3-c or OEM
- check a TOML scenario before spending a run on it
- score a real receiver log for jamming and position jumps
- produce a report where each figure keeps its unit and provenance

## Example prompts
- Run the scenario in `orbit.toml` and show me the summary with a chart
- Which fields are required for the `leo-navmsg` scenario kind?
- Assess the receiver log `rover.ubx` for trust, format named in the TOML

## Similar
- [blender-optics-simulator](https://affpapa.org/en/nevibecode/mcp/blender-optics-simulator.md) — MCP server · ★ 24
- [game-strategy-simulator](https://affpapa.org/en/nevibecode/skills/game-strategy-simulator.md) — skill · 385 installs
- [MaBoSS Boolean Network Simulator](https://affpapa.org/en/nevibecode/mcp/maboss-boolean-network-simulator.md) — MCP server · ★ 20
- [project-timeline-simulator](https://affpapa.org/en/nevibecode/commands/project-timeline-simulator.md) — command · 253 installs
- [monte-carlo-simulator](https://affpapa.org/en/nevibecode/commands/monte-carlo-simulator.md) — command · 193 installs
- [Sidereon](https://affpapa.org/en/nevibecode/mcp/sidereon.md) — MCP server · ★ 18

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
