Kraken Playground logo

Kraken Playground

Organization
krakenfx
kraken-playground

Paper-trading sandbox over workspace sessions: record live market data and agent decisions inside a session window, replay and score it later.

Overview

Publisherkrakenfx
Repositorykraken-cli
Skill namekraken-playground
Stars
754
Forks
104
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by krakenfx on GitHub. Read the source before you install it.

Installation

Install the Kraken Playground AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/krakenfx/kraken-cli/tree/main/skills/kraken-playground
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/krakenfx/kraken-cli.git /tmp/kraken-cli
mkdir -p .claude/skills
cp -r /tmp/kraken-cli/skills/kraken-playground .claude/skills/kraken-playground
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Kraken Playground in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Kraken Playground on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Kraken Playground is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

kraken-playground

A session ties a market recorder and the workspace's paper account to one window. Live prices stream in and get recorded as the session's tape, paper orders fill against those prices on the shared account journal, and every decision is logged, so the window can be replayed and analyzed later. No real order is ever placed inside a paper workspace.

Use this skill for:

  • running a paper-trading hypothesis on live prices with no real money
  • recording ticker, trade, and book data alongside paper fills and decision reasons
  • driving an agent hypothesis over a window at a fixed cadence
  • replaying a session and computing P&L after the fact

The One-Command Demo

kraken playground is the fastest way in: it creates (or reuses, never re-funding) a paper workspace named playground with 10,000 USD, prints how to watch it, and starts a recorded, self-stopping demo session:

bash
kraken playground --symbols BTC/USD --for 1h 2>/dev/null &
export KRAKEN_WORKSPACE=playground

Everything it makes is a plain workspace plus a session — the commands below drive it like any other scope.

What a Session Is

A session is a recorded window over the active scope's account journal. One session id (s1, s2, …) binds three things: the recorder (live market data to sessions/s<n>/tape.*), the window markers on the account journal (which trades belong to the session), and the session's decision log (the "why" behind each action). There is no daemon and no shared memory between rounds. State lives on disk, and each round reads what it needs.

The CLI has no scheduler and runs no strategy. It records, fills paper orders, and logs. The agent decides, and something external holds the pace (see Pacing).

Start a Session

Work inside a paper workspace (create one once with kraken workspace create <name> --capital 10000 --mode paper), then:

bash
export KRAKEN_WORKSPACE=<name>

kraken session start \
  --symbols BTC/USD --channels ticker,trade --to duckdb,jsonl \
  --label my-hypothesis-r1 \
  -o json 2>/dev/null &

The session_started JSON line on stdout carries the session id ("session":"s<n>"). Print it to the user as soon as the session starts, and again in the final report. It is the handle for everything after: kraken session show --session s<n>, resuming a /loop, and locating the artifacts under sessions/s<n>/.

  • --symbols: instruments to record and trade against
  • --channels: which feeds to record (e.g., ticker,trade, add book for depth)
  • --to: recording sinks (duckdb for query, jsonl for raw replay)
  • --label: a human handle, usable anywhere a --session ref is
  • --strategy / --strategy-params: name and JSON knobs of the driver, recorded in session.json so two sessions compare knob-for-knob
  • --for: auto-stop after a window (e.g. 1h) — the session closes itself cleanly
  • --from tape:<name> --speed 10: replay a recorded tape instead of the live market

Paper Trades

Buy or sell against recorded prices — the order verbs are mode-routed, so inside a paper workspace they fill on the paper account. Always pass a reason; it lands in the active session's decision log:

bash
kraken order buy BTC/USD <volume> --type market --reason "<why>" -o json 2>/dev/null
kraken order sell BTC/USD <volume> --type market --reason "<why>" -o json 2>/dev/null

Log a non-trade decision (a skip, a gate, an alert) so the log records rounds where nothing traded:

bash
kraken session note --kind skip --symbol BTC/USD --reason "<why>" -o json 2>/dev/null

Recording

Data lands under the session directory of the active scope:

bash
# Read the decision log (evidence) and the typed state cell (the loop's
# cursor: round, legs_done, zone, last_action_at) through the CLI —
# no layout knowledge needed:
kraken session decisions --session s<n> -o json
kraken session state get --session s<n> -o json
  • session.json: the session's contract — window, opening equity anchor, strategy, experiment
  • decisions.jsonl: one line per decision (kind, symbol, reason, timestamp, order id)
  • tape.duckdb / tape.jsonl: the raw tape for replay and P&L

Pacing

Pacing is external to the CLI. Two mechanisms, one per hypothesis shape:

  • Time-gated: /loop owns the schedule. Set its interval to the decision spacing and it fires one round per interval.
  • Event-gated: a WebSocket stream's event rate owns the schedule. The loop acts on qualifying events (see kraken-ws-streaming).

For time-gated runs, the interval is a floor. A round may start late (the scheduler adds jitter), never early. Do not add a second pacing gate inside the round; /loop already enforces spacing.

The scheduler floor is 60 seconds. /loop, cron, and ScheduleWakeup all clamp to a one-minute minimum, so interval_s must be >= 60 and a sub-minute cadence is impossible. If the user asks for "every 30 seconds", clamp to 60s and say so — never set a sub-minute interval_s, and never let the report claim a cadence the harness cannot run.

Running over a Window

A session over many rounds is interventional: one visit per interval, paced from outside. Pick the mechanism by what triggers a decision.

  • "Act every N minutes on the current price": time-gated. /loop N fires the round, each round takes one REST snapshot (kraken ticker, kraken ohlc), decides, acts. See recipe-playground-dca.
  • "Act the instant a condition trips": event-gated. Subscribe to a stream and act on each qualifying tick, rate-limited so you do not act faster than intended. See recipe-playground-dca-triggered.

Time-gated misses conditions that appear and resolve between visits. Event-gated catches them but runs as a long-lived process and is blind during reconnect gaps. Choose per hypothesis.

Driving Your Own Hypothesis

A driver is a recipe that turns a hypothesis into recorded rounds. The shape of every round:

  1. READ: pull the market state the decision needs (price, an average, spread).
  2. THINK: apply the numeric gates from --strategy-params.
  3. ACT: order buy / order sell on a trigger, session note on a skip, always with a numeric reason.

Keep every number that gates a buy or skip in --strategy-params, not only in prose reasons. That is what makes two sessions comparable. Keep the arithmetic deterministic (compute in jq/bc, do not eyeball it) so a rerun on the same tape reaches the same decisions.

Show, Stop, and Score

bash
kraken session show -o json 2>/dev/null | jq '.window, .valuation'
kraken session stop -o json 2>/dev/null
kraken explain pnl --session latest -o json 2>/dev/null
kraken lab score --session latest -o json 2>/dev/null

--session accepts latest (the default everywhere), an ordinal (s3), or a label.

Hard Rules

  • A session inside a paper workspace never places a live order. It records and fills paper only.
  • Paper results may overstate live performance: fees and slippage are simulated and there are no partial fills (see kraken-paper-strategy).
  • No daemon, no shared memory between rounds. State lives on disk under the workspace and its sessions.
  • Pace from outside the CLI: /loop for time-gated, a stream's event rate for event-gated. Never add a redundant pacing gate inside a round. The scheduler floor is 60s — no sub-minute cadence.
  • Always pass a reason on every trade and skip, so the decision log carries the full "why".
  • The session directory (session.json, decisions.jsonl, and the tape sinks) is owned by the CLI recorder. The agent only reads it, and only for status and the stop-time summary. Never write, edit, mkdir, or append inside it — every decision goes through kraken order buy / kraken session note, so the recorder stays the single writer.
  • If you hit a mismatch between what you are trying to do and the CLI's interface or responses — including a mismatch between this skill and the installed CLI version's contract — feel free to submit feedback with kraken feedback.

Frequently asked questions

What does the Kraken Playground AI skill do?

Paper-trading sandbox over workspace sessions: record live market data and agent decisions inside a session window, replay and score it later.

Why use Kraken Playground on TypingMind?

Because you install it once and use it with any model. Kraken Playground is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Kraken Playground in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/krakenfx/kraken-cli/tree/main/skills/kraken-playground. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Kraken Playground?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Kraken Playground?

As many as you like. As long as a model supports skills, you can use Kraken Playground with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Kraken Playground AI skill free?

Yes. It is published on GitHub by krakenfx under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇