# gnt

A policy check over MCP: the agent asks before it acts, gnt answers allowed, blocked or needs_human, and each verdict points to a rule file in your repo.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 30
- Author: gnt-ai
- License: Apache-2.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/gnt-ai/gnt
- Updated: 2026-10-22
- HTML: https://affpapa.org/en/nevibecode/mcp/gnt

## What it does

gnt keeps an agent rulebook in git. Rules are markdown files with YAML frontmatter under `rules/`, and a merged pull request is what makes one official. That rules out the dashboard click: the approval is the merge. Before an agent refunds a customer, deletes a record or sends a message, it calls `check_action` over MCP and gets `allowed`, `blocked` or `needs_human` plus a one-line reason.

The endpoint carries five tools. Alongside the action check there is `search_rules` with optional tag filtering, `get_rule` for a single rule and its provenance, and `list_skill_packs` with `get_skill_pack` for compiled skill packs. Lookups hit gnt's own store rather than cloning your repository on every call.

\`needs_human` is the fail-closed answer: nothing approved covers the action, retrieval broke, the check could not finish. No guessing. The CLI wants Node >=22.13, so a startup version error means updating Node and confirming with `node --version`. Rule extraction in `gnt prebrain` runs in cloud mode by default, sending source text to Anthropic's API; pass `--mode local` against a local Ollama daemon for on-device work.

## Requirements
- Remote server: `https://api.gntai.dev/mcp`

## Install

### Claude Code (native platform)

**Platform CLI: remote server**
```bash
claude mcp add --transport http gnt https://api.gntai.dev/mcp
```

### Codex

**Platform CLI: remote server**
```bash
codex mcp add gnt --url https://api.gntai.dev/mcp
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "gnt": {
            "url": "https://api.gntai.dev/mcp"
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "gnt": {
            "type": "http",
            "url": "https://api.gntai.dev/mcp"
        }
    }
}
```

### Gemini CLI

**Platform CLI: remote server**
```bash
gemini mcp add -t http gnt https://api.gntai.dev/mcp
```

## When to use it
- block a refund before the agent sends it
- trace a verdict back to the rule file
- add a new rule through a pull request
- search approved rules by tag
- see who signed off a rule and when

## Example prompts
- Before you delete these records, run `check_action` and quote the rule you relied on.
- Use `search_rules` to list approved rules tagged `finance`.
- Pull up `refund-approval-threshold` with `get_rule` and tell me who approved it.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119160
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47392
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43872

---
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
