Prototyp · Vorschau: alle Server aus der offiziellen Registry, alle 30 Minuten synchronisiert. Mit Google anmelden, um Bewertungen zu schreiben.
PopNx MCPMCP-Server für alle, die KI nutzen · in einfachen Worten erklärt

Reins

von R2RlabsVersion 0.1.8i★ 0iLäuft auf deinem Computer
Name in der Registryio.github.R2Rlabs/hyperliquid-reins

So installierst du es

Überblick

Beschreibung vom Entwickler (englisches Original)

Risk limits and an audit log for AI agents trading Hyperliquid, enforced outside the model.

Was du damit machen kannst

Für diesen Server haben wir noch keine Zusammenfassung in einfacher Sprache geschrieben. Unten stehen die Fakten, die wir aus der Registry gelesen haben.

  • Verbindung: Läuft auf deinem Computer
  • Transport: stdio
  • Kategorie: Buchhaltung, Finanzen & Steuern
  • Das musst du eintragen: REINS_SYMBOLS, REINS_MAX_POSITION_USD, REINS_DAILY_LOSS_USD, REINS_PRIVATE_KEY

Installation

Wähle die KI-App, die du nutzt, und kopiere die Einstellungen.

2/2 Prüfungen bestanden · Läuft auf deinem Computer

Zuerst: Welche KI nutzt du?

Wähle deine App, dann erscheinen die Schritte unten.

Klappt mit Claude, aber erst etwas vorbereiten

Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal) · Nur in der Claude-App für den Computer (Windows oder Mac), nicht im Web oder auf dem Handy

  1. Node.js installieren

    Nur einmal; gilt für alle Server, die Node.js brauchen

    Download-Seite von Node.js öffnen ↗

  2. Bei Reins registrieren und Schlüssel erstellen

    Öffne die Seite des Anbieters, registriere dich und erstelle einen API-Schlüssel für den nächsten Schritt. Kann Geld kosten.

    Seite von Reins öffnen ↗

  3. Einstellungsdatei der Claude-Desktop-App öffnen

    SettingsDeveloperEdit Config

  4. Diese Einstellungen einfügen und speichern

    {
      "mcpServers": {
        "hyperliquid-reins": {
          "command": "npx",
          "args": [
            "-y",
            "@r2rlabs/reins"
          ],
          "env": {
            "REINS_SYMBOLS": "your-value",
            "REINS_MAX_POSITION_USD": "your-value",
            "REINS_DAILY_LOSS_USD": "your-value",
            "REINS_MAX_LEVERAGE": "your-value",
            "REINS_MODE": "your-value",
            "REINS_NETWORK": "your-value",
            "REINS_REQUIRE_STOP_LOSS": "your-value",
            "REINS_LOG_FILE": "your-value",
            "REINS_PAPER_FILE": "your-value",
            "REINS_ACCOUNT_ADDRESS": "your-value",
            "REINS_PRIVATE_KEY": "your-value"
          }
        }
      }
    }

    Füge den Schlüssel nur in das Feld der App ein, nie in einen Chat und schick ihn niemandem

  5. Claude beenden und neu öffnen

  6. Ausprobieren

    Nutze Reins und sag mir, was du für mich tun kannst; zeig mir dann eine Sache

    ✓ Wenn Claude sagt, dass es Reins nutzt, oder ein Werkzeug von Reins in der Antwort zeigt, bist du verbunden

Menünamen am 11. Nov. 2026 mit der Hilfe von Anthropic abgeglichen · dein Bildschirm kann je nach App-Version leicht abweichen

ChatGPT kann Reins noch nicht verbinden

Reins läuft auf deinem Computer, aber ChatGPT verbindet nur Server, die im Web laufen

Das kannst du stattdessen tun

A · Eine App nutzen, die Reins verbinden kann

  • Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal) · Nur in der Claude-App für den Computer (Windows oder Mac), nicht im Web oder auf dem Handy
  • Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)
  • Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)
  • Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)

B · Andere in Buchhaltung, Finanzen & Steuern, die mit ChatGPT funktionieren

Aus den meistgenutzten derselben Kategorie, nur solche, die per Adresse ohne Schlüssel verbinden

Klappt mit Claude Code, aber erst etwas vorbereiten

Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)

  1. Node.js installieren

    Nur einmal; gilt für alle Server, die Node.js brauchen

    Download-Seite von Node.js öffnen ↗

  2. Bei Reins registrieren und Schlüssel erstellen

    Öffne die Seite des Anbieters, registriere dich und erstelle einen API-Schlüssel für den nächsten Schritt. Kann Geld kosten.

    Seite von Reins öffnen ↗

  3. Terminal öffnen

    Mac: Command+Leertaste drücken und Terminal tippen · Windows: PowerShell öffnen

  4. Diesen Befehl einfügen und Enter drücken

    claude mcp add hyperliquid-reins --env REINS_SYMBOLS=your-value --env REINS_MAX_POSITION_USD=your-value --env REINS_DAILY_LOSS_USD=your-value --env REINS_MAX_LEVERAGE=your-value --env REINS_MODE=your-value --env REINS_NETWORK=your-value --env REINS_REQUIRE_STOP_LOSS=your-value --env REINS_LOG_FILE=your-value --env REINS_PAPER_FILE=your-value --env REINS_ACCOUNT_ADDRESS=your-value --env REINS_PRIVATE_KEY=your-value -- npx -y @r2rlabs/reins

    Ersetze „your-value“ vor dem Enter durch deinen Schlüssel

    Füge den Schlüssel nur in das Feld der App ein, nie in einen Chat und schick ihn niemandem

  5. /mcp in Claude Code eingeben

    Reins sollte in der Liste als verbunden erscheinen

  6. Ausprobieren

    Nutze Reins und sag mir, was du für mich tun kannst; zeig mir dann eine Sache

    ✓ Wenn Claude Code sagt, dass es Reins nutzt, oder ein Werkzeug von Reins in der Antwort zeigt, bist du verbunden

Menünamen am 11. Nov. 2026 mit der Hilfe von Anthropic abgeglichen · dein Bildschirm kann je nach App-Version leicht abweichen

Klappt mit Cursor, aber erst etwas vorbereiten

Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)

  1. Node.js installieren

    Nur einmal; gilt für alle Server, die Node.js brauchen

    Download-Seite von Node.js öffnen ↗

  2. Bei Reins registrieren und Schlüssel erstellen

    Öffne die Seite des Anbieters, registriere dich und erstelle einen API-Schlüssel für den nächsten Schritt. Kann Geld kosten.

    Seite von Reins öffnen ↗

  3. Mit diesem Button Cursor öffnen

    In Cursor öffnen

    Cursor fragt nach einer Bestätigung; klicke Install

  4. Schlüssel eintragen

    In den Einstellungen von Reins ist REINS_SYMBOLS, REINS_MAX_POSITION_USD, REINS_DAILY_LOSS_USD, REINS_MAX_LEVERAGE, REINS_MODE, REINS_NETWORK, REINS_REQUIRE_STOP_LOSS, REINS_LOG_FILE, REINS_PAPER_FILE, REINS_ACCOUNT_ADDRESS, REINS_PRIVATE_KEY leer; trag deinen Schlüssel ein und speichere

    Füge den Schlüssel nur in das Feld der App ein, nie in einen Chat und schick ihn niemandem

  5. KI-Chat in Cursor im Agent-Modus öffnen

  6. Ausprobieren

    Nutze Reins und sag mir, was du für mich tun kannst; zeig mir dann eine Sache

    ✓ Wenn Cursor sagt, dass es Reins nutzt, oder ein Werkzeug von Reins in der Antwort zeigt, bist du verbunden

Menünamen am 11. Nov. 2026 mit der Hilfe von Cursor abgeglichen · dein Bildschirm kann je nach App-Version leicht abweichen

Klappt mit VS Code, aber erst etwas vorbereiten

Du brauchst einen Schlüssel von Reins (auf der Seite des Anbieters registrieren, kann kosten) · Installiere zuerst Node.js auf deinem Computer (nur einmal)

  1. Node.js installieren

    Nur einmal; gilt für alle Server, die Node.js brauchen

    Download-Seite von Node.js öffnen ↗

  2. Bei Reins registrieren und Schlüssel erstellen

    Öffne die Seite des Anbieters, registriere dich und erstelle einen API-Schlüssel für den nächsten Schritt. Kann Geld kosten.

    Seite von Reins öffnen ↗

  3. Mit diesem Button VS Code öffnen

    In VS Code öffnen

    VS Code fragt nach einer Bestätigung; klicke Install

  4. Schlüssel eintragen

    In den Einstellungen von Reins ist REINS_SYMBOLS, REINS_MAX_POSITION_USD, REINS_DAILY_LOSS_USD, REINS_MAX_LEVERAGE, REINS_MODE, REINS_NETWORK, REINS_REQUIRE_STOP_LOSS, REINS_LOG_FILE, REINS_PAPER_FILE, REINS_ACCOUNT_ADDRESS, REINS_PRIVATE_KEY leer; trag deinen Schlüssel ein und speichere

    Füge den Schlüssel nur in das Feld der App ein, nie in einen Chat und schick ihn niemandem

  5. KI-Chat in VS Code im Agent-Modus öffnen

  6. Ausprobieren

    Nutze Reins und sag mir, was du für mich tun kannst; zeig mir dann eine Sache

    ✓ Wenn VS Code sagt, dass es Reins nutzt, oder ein Werkzeug von Reins in der Antwort zeigt, bist du verbunden

Menünamen am 11. Nov. 2026 mit der Hilfe von VS Code abgeglichen · dein Bildschirm kann je nach App-Version leicht abweichen

Andere Apps mit MCP, etwa Windsurf, Zed oder Gemini CLI, fügen Server unterschiedlich hinzu. Sieh in der App-Liste nach

Alle Apps mit MCP ansehen →

JSON-Einstellungen stehen unten unter „Für Entwickler“

Hängst du fest? Frag Leute, die Reins nutzen💬 Diskussion →
Für Entwickler: Terminal-Befehle und JSON-Einstellungen

Auf deinem Computer installiert

Claude Code

claude mcp add hyperliquid-reins --env REINS_SYMBOLS=your-value --env REINS_MAX_POSITION_USD=your-value --env REINS_DAILY_LOSS_USD=your-value --env REINS_MAX_LEVERAGE=your-value --env REINS_MODE=your-value --env REINS_NETWORK=your-value --env REINS_REQUIRE_STOP_LOSS=your-value --env REINS_LOG_FILE=your-value --env REINS_PAPER_FILE=your-value --env REINS_ACCOUNT_ADDRESS=your-value --env REINS_PRIVATE_KEY=your-value -- npx -y @r2rlabs/reins

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "hyperliquid-reins": {
      "command": "npx",
      "args": [
        "-y",
        "@r2rlabs/reins"
      ],
      "env": {
        "REINS_SYMBOLS": "your-value",
        "REINS_MAX_POSITION_USD": "your-value",
        "REINS_DAILY_LOSS_USD": "your-value",
        "REINS_MAX_LEVERAGE": "your-value",
        "REINS_MODE": "your-value",
        "REINS_NETWORK": "your-value",
        "REINS_REQUIRE_STOP_LOSS": "your-value",
        "REINS_LOG_FILE": "your-value",
        "REINS_PAPER_FILE": "your-value",
        "REINS_ACCOUNT_ADDRESS": "your-value",
        "REINS_PRIVATE_KEY": "your-value"
      }
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "hyperliquid-reins": {
      "command": "npx",
      "args": [
        "-y",
        "@r2rlabs/reins"
      ],
      "env": {
        "REINS_SYMBOLS": "your-value",
        "REINS_MAX_POSITION_USD": "your-value",
        "REINS_DAILY_LOSS_USD": "your-value",
        "REINS_MAX_LEVERAGE": "your-value",
        "REINS_MODE": "your-value",
        "REINS_NETWORK": "your-value",
        "REINS_REQUIRE_STOP_LOSS": "your-value",
        "REINS_LOG_FILE": "your-value",
        "REINS_PAPER_FILE": "your-value",
        "REINS_ACCOUNT_ADDRESS": "your-value",
        "REINS_PRIVATE_KEY": "your-value"
      }
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "hyperliquid-reins": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@r2rlabs/reins"
      ],
      "env": {
        "REINS_SYMBOLS": "your-value",
        "REINS_MAX_POSITION_USD": "your-value",
        "REINS_DAILY_LOSS_USD": "your-value",
        "REINS_MAX_LEVERAGE": "your-value",
        "REINS_MODE": "your-value",
        "REINS_NETWORK": "your-value",
        "REINS_REQUIRE_STOP_LOSS": "your-value",
        "REINS_LOG_FILE": "your-value",
        "REINS_PAPER_FILE": "your-value",
        "REINS_ACCOUNT_ADDRESS": "your-value",
        "REINS_PRIVATE_KEY": "your-value"
      }
    }
  }
}

Werte, die du selbst einträgst

  • REINS_SYMBOLS erforderlich env
    Markets the agent may trade, comma separated, e.g. BTC,ETH. Every other market is refused.
  • REINS_MAX_POSITION_USD erforderlich env
    Largest position per market, in USD.
  • REINS_DAILY_LOSS_USD erforderlich env
    Realised loss in a UTC day after which new risk is refused.
  • REINS_MAX_LEVERAGE env
    Largest total exposure as a multiple of account value.
  • REINS_MODE env
    paper (live prices, simulated fills, nothing signed) or live.
  • REINS_NETWORK env
    Hyperliquid network for prices and, in live mode, orders. Mainnet spends real money.
  • REINS_REQUIRE_STOP_LOSS env
    true to refuse any order that adds risk without a stop-loss.
  • REINS_LOG_FILE env
    Decision log, one JSON line per action with the agent's stated reason. In memory if unset.
  • REINS_PAPER_FILE env
    Where the paper account is kept between runs. In memory if unset.
  • REINS_ACCOUNT_ADDRESS env
    Live mode: the Hyperliquid account traded. Approve Reins' 2 bp builder fee from it first: npx @r2rlabs/reins approve-builder
  • REINS_PRIVATE_KEY geheim env
    Live mode: an API wallet's key, which can trade but not withdraw. Never the account's own key.

Diese Einstellungen werden aus dem Registry-Eintrag des Entwicklers erzeugt. Wenn in der README etwas anderes steht, folge der README.

Auf einen Blick

Downloads pro Wochei
109/Wo.
Lizenzi
Keine Lizenz angegeben
Verbindung
Läuft auf deinem Computer
Neueste Versioni
0.1.8
In der Registry veröffentlichti
4. Okt. 2026
Code zuletzt geänderti
3. Okt. 2026
Entwickler
R2Rlabs
Pakete
npm: @r2rlabs/reins
Registry-Status
Aktiv

Welche Apps ihn nutzen können

Basierend darauf, wie sich dieser Server verbindet, und auf der eigenen Doku jeder App, geprüft am 10. Nov. 2026.

Laufen auf deinem Computer in

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

Alle Apps, mit Vor- und Nachteilen →

Was er kann

Läuft auf deinem Computer; die Tool-Liste erscheint nach der Installation in deiner KI-App.

Basischecksi

Wir prüfen Informationen, die jeder sehen kann; den Code haben wir nicht gelesen. Checks, die nicht zutreffen, werden nicht mitgezählt. · Geprüft am 11. Nov. 2026

  • ✓ Bestanden

    Entwickler passt zum Repo

    Der Registry-Name wurde mit dem GitHub-Konto R2Rlabs bestätigt, dem das Repo gehört

  • ✓ Bestanden

    Wird noch gepflegt

    Code zuletzt geändert: vor 40 Tagen

  • … Noch nicht geprüft

    Hat eine Lizenz

    Dieses Repo haben wir noch nicht von GitHub gelesen

  • – Nicht zutreffend

    Endpunkt antwortet

    Dieser Server läuft auf deinem Computer; es gibt keinen Endpunkt im Internet

  • – Nicht zutreffend

    Anmeldung mit OAuth

    Läuft auf deinem Computer und nutzt stattdessen lokale Einstellungen

  • … Noch nicht geprüft

    Keine versteckten Anweisungen in Tool-Beschreibungen

    Läuft auf deinem Computer; Tool-Listen können wir nur von Endpunkten im Internet lesen

Diskussion

Fragen, Tipps teilen oder melden, dass etwas nicht geht. Sortiert nach „hilfreich“.

Noch keine Beiträge. Stell die erste Frage oder teile einen Tipp.

Beiträge hier stammen von Nutzern, nicht vom PopNx-Team.

Mit Google anmelden, um zu posten

Nutzerbewertungen

Noch keine Bewertungen

Mit Google anmelden, um zu bewerten

Im Vergleich mit anderen in Buchhaltung, Finanzen & Steuerni

  • Mehr Sterne als 0 % der anderen 3126 Server in dieser Kategorie
  • Neuer in der Registry veröffentlicht als 45 % der anderen 3126 Server in dieser Kategorie
  • Basischecks gleich gut wie oder besser als bei 100 % der anderen 3126 Server in dieser Kategorie

Verglichen mit allen aktiven Servern dieser Kategorie in der Registry. Sterne zählen nur, wenn dem Herausgeber das Repo gehört.

Häufige Fragen

Ist Reins sicher?

Er hat 2 von 2 zutreffenden Basischecks bestanden. Den Code haben wir nicht gelesen. Bevor du einen Schlüssel oder Token hinzufügst, sieh nach, welche Zugriffe der Server verlangt, und nutze einen Schlüssel, der nur die Berechtigungen hat, die du brauchst.

Welche Schlüssel oder Codes braucht er?

Das musst du eintragen: REINS_SYMBOLS, REINS_MAX_POSITION_USD, REINS_DAILY_LOSS_USD, REINS_PRIVATE_KEY

Läuft er auf meinem Computer oder in der Cloud?

Er läuft auf deinem Computer. Deine KI-App startet ihn bei Bedarf, und die Daten laufen nicht über die Server des Entwicklers (außer der Server ruft selbst einen Onlinedienst auf).

Wird er noch gepflegt?

Das GitHub-Repo wurde zuletzt vor 40 Tagen geändert, und die neueste Version (0.1.8) kam vor 38 Tagen in die Registry.

Welche Apps können ihn nutzen?

Apps, die MCP unterstützen, etwa Claude Desktop, Claude Code, Cursor und VS Code. Außerdem brauchst du Node.js auf deinem Computer.

Was kann ich stattdessen nutzen?

In derselben Kategorie: CCXT, Finance Toolkit, AKQuant

Alternativen

Server derselben Kategorie von anderen Entwicklern, sortiert nach Sternen.

So liest du eine Karte:↓ Downloads pro Wochei★ GitHub-SterneiDrei Säulen: Bewertungen · Checks · NutzungiAktualisiert = neueste Version in der Registry veröffentlichti

CCXT

Official CCXT MCP server - Market data and trading across 100+ exchanges and prediction markets

von ccxtWeit verbreitet↓ 667/Wo.★ 44.855Aktualisiert vor 2 Monaten

Läuft auf deinem Computer

Finance Toolkit

500+ transparent financial methods calculated from raw statements, not third-party endpoints.

von JerBoumaWeit verbreitet↓ 15.624/Wo.★ 5517Aktualisiert vorgestern

Computer oder Cloud

AKQuant

Write and backtest trading strategies with AKQuant: API lookup, strategy checks, backtest runs

von akfamilyWeit verbreitet↓ 3280/Wo.★ 2582Aktualisiert heute

Läuft auf deinem Computer

README vom Entwickler

README öffnen

Unverändert aus dem Repo des Entwicklers übernommen. PopNx MCP hat den Inhalt weder geprüft noch empfiehlt es ihn. HTML, Bilder und Skripte wurden entfernt. Links führen von dieser Website weg.

Reins

Let an AI agent trade without giving it the power to lose everything.

npx @r2rlabs/reins init      # adds a paper-trading Reins server to .mcp.json

See it at work: an AI agent trading Hyperliquid on paper, run 2.

The source is on GitHub: R2Rlabs/reins. Every limit in this README is a function you can read.

What Reins is
  • Limits the agent can't argue with. Every order passes checks that live outside the model: position size, leverage, daily loss, which markets it may trade, and a stop-loss on every position. No prompt, clever reasoning or mistake gets around them.
  • A record you can check. Every decision is logged with the reason the agent gave — including the orders it was refused, the times it chose to wait, and what the exchange did without it. You can compare what the agent *said* with what actually *happened*.
  • Somewhere to rehearse. Paper trading on live Hyperliquid prices with realistic fills and fees, using the same tools and limits as live trading.
  • Non-custodial. Your money stays in your own Hyperliquid account. Reins trades through an API wallet, which can place orders but cannot withdraw.
  • Paid for openly. A small builder fee (2 bp) on live orders, shown up front.
What Reins is not
  • Not a trading bot or a strategy. Reins doesn't decide what to trade and won't make an agent profitable. The demo agent is a test drive, not the product.
  • Not an exchange, broker or custodian. It holds no funds and matches no orders; Hyperliquid does that.
  • Not a promise against losses. Limits cap how much can go wrong. They don't make bad trades good, and stops can slip in fast markets.
  • Not financial advice.
  • Not something you have to take on trust. Not the agent's word, and not ours: every action is on the record.
Principles
  1. Limits live outside the model.
  2. The record outranks the reasoning.
  3. Paper before real money.
  4. Your keys, your funds.

Why this exists

Several open-source Hyperliquid MCP servers already exist. They are thin API wrappers: you hand them a private key and hope the model behaves. The gap is everything around that — the limits, the sandbox, the audit trail. That is what this repo is.

Status

Early, but real. 391 tests, no network calls in any of them.

ModuleWhat it does
src/risk.tsThe risk engine — position cap, risk per trade, leverage cap, daily loss halt, allowlist, rate limit
src/client.tsHyperliquid REST client — orders, cancels, book, candles, fills, account state, builder code
src/mcp-server.tsThe agent-facing tools, each risk-checked and logged before anything is sent
src/paper.tsPaper trading — live prices, simulated fills. See below
src/paper-store.tsPersists a paper run across restarts
src/trading-client.tsThe interface live and paper both satisfy
src/decision-log.tsAppend-only record of every attempt and its stated reason
src/decision-log-file.tsJSON Lines log on disk
src/bin/cli.tsThe reins command: serve (default), init, approve-builder, live-check, http and stats
src/bin/serve.tsstdio entry point
src/bin/http.tsreins http — the HTTP server: token, binding, JSON
src/http-api.tsThe same nine tools as HTTP routes, for bots that do not speak MCP
src/runtime.tsThe limits, client, log and banner both front doors share
src/init.tsreins init — writes a paper-mode server entry into .mcp.json
src/builder-fee.tsReins' builder fee, and the approval live trading needs before it starts
src/approve-builder.tsreins approve-builder — the user approves the builder fee in their own wallet
src/live-check.tsreins live-check — proves the live exchange accepts what Reins sends
src/platform-stats.tsreins stats — accounts, trades, volume and fees through Reins' builder code
src/lz4.tsReads Hyperliquid's LZ4-compressed data files, without a dependency
src/builder-approval.tsThe ApproveBuilderFee action: EIP-712 typed data, signature checks
src/format.tsPrice and size formatting to Hyperliquid's tick and lot rules
src/signing.tsL1 action signing, verified against the Python SDK's vectors
src/private-key-signer.tsA Signer backed by a private key
src/signer.tsThe Signer interface plus a stub. See "On signing" below
src/mock-transport.tsIn-memory API stand-in, so agents can be tested without a network
examples/demo-agent/Claude trading on paper through Reins, producing a publishable decision log

All of it works end to end. Going live is now a matter of funding an account and setting REINS_MODE=live with a key.

Going live
REINS_MODE=live

REINS_NETWORK=testnet # mainnet spends real money REINS_ACCOUNT_ADDRESS=0x... # your Hyperliquid account REINS_PRIVATE_KEY=0x... # an API wallet's key, not your account's; omit to stay read-only

On mainnet, approve Reins' 2 bp builder fee once, from the account's own wallet, before the first live session: npx @r2rlabs/reins approve-builder. Until the account has, live mode refuses to start and says so.

Use an API wallet, not your account's own key. Hyperliquid lets an account approve API wallets that can trade for it but cannot withdraw from it — create one on Hyperliquid's API page, signing the approval with your main wallet. Put its key in REINS_PRIVATE_KEY and your account's address in REINS_ACCOUNT_ADDRESS: orders are signed by the API wallet, while positions, fills and stops are read from the account, because under the API wallet's own address the account looks empty. The startup banner names both. Hyperliquid prunes API wallets that expire or are replaced; make a fresh one rather than reusing an old address.

Every account mode works. Hyperliquid starts new accounts in Unified, where the USDC sits in the spot balance and the perps account reads $0; Reins asks the account which mode it is in and, for Unified and Portfolio margin, takes equity from the USDC balance plus the positions' unrealized PnL. Manual accounts are read from perps as before. (A *builder* address is different: it must be in Manual — standard — to earn fees.)

Defaults are deliberately safe: REINS_MODE is paper and REINS_NETWORK is testnet, so trading real funds takes two explicit changes rather than one forgotten variable. Live mode without a key stays read-only instead of failing at the first order, and mainnet prints a loud banner on startup.

The private key is only read in live mode — paper never signs anything, so it is never handed the means to.

See it run

npm run build

npm run demo -- --scripted # free: no API key, live prices, paper fills

With an Anthropic API key, npm run demo runs Claude as the agent under a hard spending cap. See examples/demo-agent for cost, limits and how to publish the result honestly.

The decision log

Every attempted action is appended to a log with the reason the agent gave for it — including the ones the risk limits refused. That is the point. "The agent tried to open six times its position cap at 3am, and here is what it said it was doing" is the most useful thing this system can tell you, and it only exists if refusals are written down.

place_order, close_position and set_stop_loss take a required reason. An optional field gets omitted; a required one gets answered.

Records are JSON Lines — one self-contained object per line, appended, never rewritten. Appends stay cheap as the file grows, a truncated write damages one line instead of the file, and you can query it with ordinary tools:

jq -r 'select(.risk.allowed == false) | [.time, .risk.code, .reason] | @tsv' decisions.jsonl

Each record holds the stated reason, the request, the account context at the time, the risk verdict, and the outcome. Set REINS_LOG_FILE to persist it; without it the log lives in memory and dies with the process.

The exchange also acts on its own: a stop-loss fires, a resting order fills hours after it was placed. Before every tool call Reins compares the account's fills with the log and appends each one it has not seen as an exchange_fill record, whose reason starts "Not an agent decision:" and says whether it was a stop, a resting order, or a fill Reins did not place. Without them the trade that mattered most, the stop that closed it, would be missing from the record. The agent reads them back through get_recent_decisions like anything else.

Two things to be clear about

`reason` is testimony, not ground truth. It is the model's own account of why it acted, captured because reasoning that is not asked for cannot be recovered later. A model can rationalise after the fact, and a confident explanation is not evidence that the explanation is what actually drove the decision. It is extremely useful for debugging and audit. It is not proof.

A failed log write never fails a filled order. If the log cannot be written, the tool still reports success and attaches a warning. An agent told its order failed will place it again — so a lost log line would become a doubled position, which is far worse than the missing line. The risk engine is the safety mechanism; the log is observability.

Paper trading

REINS_MODE=paper (the default) runs the same tools, the same risk engine and the same agent against real prices with simulated fills. Nothing is signed and nothing reaches the exchange.

Paper and live are swapped behind one interface, so an agent cannot tell which one it is talking to — which is the point. A strategy that works on paper runs unchanged on live.

What the simulation models
  • Real book depth. A large order walks levels and pays real slippage instead of filling entirely at the touch.
  • Partial fills when the book is too thin inside the limit price.
  • Taker and maker fees at Hyperliquid's base tier (0.045% / 0.015%), plus any builder fee, so the equity curve is net of what trading actually costs.
  • **Resting orders that only fill when the market trades strictly *through* them**, never merely to them. At your own price you are behind a queue this simulation cannot see; assuming a fill there is the most common way a paper equity curve lies.
  • Fills between polls. Each call checks resting orders against the one-minute candles printed since they were placed, not just the book at that moment, and fills them at the minute the market first went through. Cancelling an order that already filled is refused, as the exchange would. Before this, the demo agent's breakout bid went unfilled under a dip that lasted two minutes, and it then cancelled an order Hyperliquid would already have filled.
What it does not model

The first five flatter the result; the last two can miss a fill either way. All of them are listed rather than buried:

  • Latency — fills are priced off the book as it was when the tool was called
  • Market impact — your order never moves the price or removes liquidity
  • Funding payments on perps
  • Slippage past a stop inside a minute already gone — a stop found triggered in a past candle fills at its trigger, or at the candle's open if the market gapped through it. One triggered right now walks the real book.
  • Mark price — Hyperliquid triggers stops on the mark price; paper uses traded prices, which can differ briefly
  • The minute an order was placed in — candles are only counted from the first minute that opened after it, so a dip in that same minute is missed
  • Orders resting longer than about three days — only the latest 5000 one-minute candles are available, so older stretches go unchec

Nur der Anfang wird gezeigt; den Rest findest du im Repo