-
-
Notifications
You must be signed in to change notification settings - Fork 21
Jackrabbit Mimic
OPEN ALPHA: There will be bugs! BACKUP your Jackrabbit Relay folders BEFORE activating Mimic.
Mimic's goal: If you can't make money here, you won't make money in a live market.
Jackrabbit Mimic is a groundbreaking educational platform meticulously designed to provide traders with a hands-on learning experience in the dynamic realm of cryptocurrency trading. Mimic transcends conventional simulation tools by offering a comprehensive yet accessible environment where traders can gain practical insights into market dynamics, risk management strategies, and trading psychology.
At its core, Mimic serves as a virtual exchange that mirrors the operations of real-world cryptocurrency markets, drawing upon live data from leading exchanges such as Binance, Kraken, and KuCoin. Through Mimic's immersive capabilities, traders can explore the nuances of market behavior, test trading strategies, and refine their decision-making processes in a controlled environment.
One of Mimic's standout features is its innovative approach to shorting, which simplifies the process of entering and exiting short positions while maintaining educational integrity. By allowing traders to issue negative amounts to initiate short positions, Mimic fosters a clear understanding of short-selling mechanics without the logistical complexities often associated with traditional exchanges.
Mimic is more than just a trading simulator; it is a platform for continuous learning and skill development. Whether you are a novice trader seeking to grasp the fundamentals of trading or an experienced professional looking to fine-tune your strategies, Mimic offers a wealth of educational resources and practical exercises to support your journey towards trading mastery.
Mimic serves as a versatile tool for traders seeking to replicate the trading experience of a live cryptocurrency exchange while harnessing the power of real-time data. Below are guidelines for using Mimic effectively:
Mimic leverages real-life cryptocurrency exchanges to mirror live data, including the ticker, order book, and OHLCV (Open, High, Low, Close, Volume) data. It is important to note that Mimic is designed to emulate the trading experience rather than directly replicate any specific exchange.
Setting up Mimic is straightforward and aligns with the standard procedures for configuring a cryptocurrency exchange within the Jackrabbit Relay framework. The setup process ensures seamless integration with the chosen data source, enabling traders to access accurate and up-to-date market information for simulation purposes.
While Mimic closely mimics the functionality of a live exchange, there are subtle differences that traders should be aware of. These variances will be elaborated upon throughout the documentation to ensure a comprehensive understanding of Mimic's unique features and capabilities.
Mimic's primary goal is to provide traders with an educational platform where they can practice trading strategies, refine their skills, and gain insights into market dynamics. The platform emphasizes practical learning experiences and offers a range of resources to support traders at every skill level.
By following these guidelines, traders can maximize their usage of Mimic and unlock its full potential as a powerful tool for trading simulation and skill development.
Please watch the Setup walkthrough for Mimic before proceeding.
It is importand to have the latest version of Jackrabbit Relay installed.
There are a few commands that need to be ran before we can really begin to use Mimic. First, let's start with building configuration to all exchanges you have available is YOUR legal juristion. This program runs through four different tests to determin which exchange has a public API access point that YOU are allowed to use.
/home/GitHub/JackrabbitRelay/Extras/AppendPublicConfig <port>
This command will build config files for every exchange you have access to. If an exchange already exists, it will APPEND the public reference to the config file. AS A PRECAUTION, You should back up your Relay folder FIRST.
The port MUST be the port number of YOUR local Jackrabbit Relay server. Take the time to double check your typing as this command will generate 100+ config files. Having to fix a simple typo after the fact will not be a pleseant experience.
Here is an EXAMPLE of what will be created is YOUR Jackrabbit Relay Config folder. In this example, port 80 is the port Jackrabbit Relay uses. API and SECRET MUST be Public.
# Public access API
{ "Framework":"ccxt","Account":"Public","MarketType":"Spot","API":"Public","SECRET":"Public","RateLimit":"1000","Webhook":"http://127.0.0.1:80" }
Now that you have all the public access point for exchanges YOU are allowed to use, we can build the Mimic config file.
/home/GitHub/JackrabbitRelay/Extras/AppendMimicConfig <port>
Just as above, Check your port number carefully.
Here is an example of what you will find in the mimic.cfg
file.
# Public Accounts
{ "Framework":"mimic","Account":"ascendexPublic","DataExchange":"ascendex","DataAccount":"Public","Fee":"0.2%","InitialBalance":"100000","Webhook":"http://127.0.0.1:80" }
{ "Framework":"mimic","Account":"bitgetPublic","DataExchange":"bitget","DataAccount":"Public","InitialBalance":"100000","Webhook":"http://127.0.0.1:80" }
{ "Framework":"mimic","Account":"currencycomPublic","DataExchange":"currencycom","DataAccount":"Public","InitialBalance":"100000","Webhook":"http://127.0.0.1:80" }
{ "Framework":"mimic","Account":"deribitPublic","DataExchange":"deribit","DataAccount":"Public","InitialBalance":"100000","Webhook":"http://127.0.0.1:80" }
{ "Framework":"mimic","Account":"timexPublic","DataExchange":"timex","DataAccount":"Public","InitialBalance":"100000","Webhook":"http://127.0.0.1:80" }
Below is the layout of each entry.
Item | Example | Description |
---|---|---|
Framework | mimic | This is the required framework identification for Mimic. |
Account | timexPublic | The account name that will be osed in order payloads. |
DataExchange | timex | The exchange to pull live data from. This file MUST exist and can use a public interface or your API/SECRET credentials (lower ratelimit and other exchange benefits) |
DataAccount | Public | The account that will be referenced by Mimic. You can have unlimited Mimic account point to a single exchange account. |
Fee | 0.26% | The Highest fee the exchange uses. If this is not present, Mimic will use 0.73%. This will be applied on both the buy and sell sides. |
InitialBalance | 100000 | The initial starting balance of your wallet. Mimic will set all Quote currencies to this value. |
Webhook | http://127.0.0.1:80 | The web hook that Mimic will use to communicate To Jackrabbit Relay. |
Now the wallet and history files will be detailed. These file are created in the
/home/JackrabbitRelay2/Data/Mimic/
folder as needed. The methodology of operations will also be discussed.
Let's start with an example wallet file.
{"Enabled": "Y", "Fees": 2.25152432, "Wallet": {"EUR": 100000.0, "USD": 100000.0, "ETH": 100000.0, "GBP": 100000.0, "BTC": 100000.0, "AUD": 100000.0, "USDT": 99416.66649809186, "JPY": 100000.0, "AED": 100000.0, "CHF": 100000.0, "DAI": 100000.0, "PYUSD": 100000.0, "USDC": 100000.0, "CAD": 100000.0, "DOT": 100000.0, "ADA": 70.30983280058058, "MATIC": 514.6519548822374}}
Item | Example | Description |
---|---|---|
Enabled | Y | Where or not the wallet is enabled. If the wallet has been liquidated, it will be disabled (N). |
Fees | 2.25152432 | The total fees paid to date. |
Wallet | {"USDT": 99416.66649809186, "MATIC": 514.6519548822374} | This is a complete lists of ALL wallets currrently in use. " |
Every wallet has a transaction history. Here is an example.
{"DateTime": "2024-03-05 18:57:29.292910", "ID": "17096650492929418", "Action": "buy", "Asset": "ADA/USDT", "ADA": 9.97051407842506, "USDT": 99992.79397812144, "Amount": 9.97051408, "Price": 0.720859, "Fee": 0.01868707}
{"DateTime": "2024-03-05 19:21:56.806021", "ID": "17096665168060500", "Action": "buy", "Asset": "MATIC/USDT", "MATIC": 28.182175217853352, "USDT": 99955.54538955183, "Amount": 18.82149331, "Price": 1.0621, "Fee": 0.0519748}
{"DateTime": "2024-03-05 21:14:27.185601", "ID": "17096732671856284", "Action": "sell", "Asset": "ADA/USDT", "ADA": 39.88472526976858, "USDT": 99700.039936767, "Amount": 10.51626004, "Price": 0.66649, "Fee": 0.01822335}
Now for the particulars of the transaction history.
Item | Example | Description |
---|---|---|
DateTime | 2024-03-05 18:57:29.292910 | The date and time the transaction was registered with the exchange. |
ID | 17096650492929418 | The transaction/ order ID. |
Action | buy | The action of side of the order. Either buy or sell. |
Asset | ADA/USDT | The asset represented as base / quote. |
ADA | 9.97051407842506 | The amount of the transaction for the base wallet. Shorts are represented as negative values. |
USDT | 99992.79397812144 | The current balance of the quote wallet. If the quote wallet hit zero or below, this ENTITE (all pairs) wallet is LIQUIDATED and disabled. |
Amount | 9.97051408 | The amount you purchased or sold AFTER fees. |
Price | 0.720859 | The price you were charged by the exchanged, NOT the price you wanted. |
Fee | 0.01868707 | The fee this transaction cost you. |
For the purposes of this discussion and examples, the following assumptions will hold true and will be based upon BTC/USDT. We will buy/sell 0.001 BTC in these examples.
Ticker: Ask: 67104.1, Bid: 67111.7, Spread: 7.6
OHLCV: Open: 67130.1, High: 67157.1, Low: 67086.4, Close: 67093.0, Volume 0.01799784
The two (2) wallets being used are BTC (base currency) and USDT (quote currency). BTC has a balance of zero (0), while USDT has a balance of 10,000.
For a long position at the current price, the actual price your position will take place at is Bid+Apread or 67111.7+7.6 or 67,119.3. The exchange we are using commands a 0.26% fee (Kraken)
Since we want 0.001 BTC, we will pay 67.1193 USDT. 0.0009 (This value is based upon the quote side after fees are paid) will be add to the BTC wallet, a fee of 0.1745 USDT will be paid to Kraken while 67.1193 will be subtracted from the USDT wallet.
For a short position, atthe current price, the actual price your position will take place at is Ask-Spread or 67104.1-7.6 or 67069.5.
Since we want 0.001 BTC, we will pay 67.0695 USDT. 0.0009 (This value is based upon the quote side after fees are paid) will be add to the BTC wallet, a fee of 0.1743 USDT will be paid to Kraken while 66.8961 will be subtracted from the USDT wallet.
Working with Mimic is no different then any other exchange. The same rules apply for TradingView or and custom program.
To buy a position in ADA.
{
"Exchange":"mimic",
"Market":"spot",
"Account":"Kraken",
"Action":"Buy",
"Asset":"ADA/USDT",
"USD":"7",
"ReduceOnly":"Yes",
"Identity":"Redacted"
}
Buying a position, then using OliverTwist to sell it.
{
"Exchange":"binance",
"Market":"Spot",
"Account":"Sandbox",
"Action":"Buy",
"Asset":"TRX/USDT",
"USD":"7",
"Conditional":"Yes",
"Direction":"Long",
"SellAction":"Sell",
"TakeProfit":"1%",
"StopLoss":"11%",
"Identity":"Redacted"
}
Short positions are a little different. To specify a short, just use a negative amount number.
Opening a short poition, then using OliverTwist to close it.
{
"Exchange":"mimic",
"Market":"margin",
"Account":"kucoinPublic",
"Action":"Buy",
"Asset":"RVN/USDT",
"Base":"-11",
"Conditional":"Yes",
"Direction":"Short",
"SellAction":"Sell",
"TakeProfit":"1%",
"StopLoss":"7%",
"Identity":"Redacted"
}
Position flipping in the cryptocurrency market involves quickly transitioning from buying to selling a cryptocurrency to profit from price movements. However, this carries the risk of losses due to market volatility, transaction costs, and timing challenges. Traders must be cautious and manage these risks effectively.
To disable position in Mimic, you must add this line to your mimic.cfg
for the specific account, or to
your order payload. Using this technique in the mimic.cfg
gives a global effect, while in the order payload
for fine tuned control,
"ReduceOnly":"Yes",
Thank you for your interest in Jackrabbit Mimic. I strive to provide the best possible experience for all users. However, please understand that outside of bug reports filed through the ticket system on GitHub, I am only able to offer direct support to patrons and sponsors of Jackrabbit Relay.
Maintaining and updating Mimic requires significant resources, both in terms of time and costs. By prioritizing support for patrons and sponsors (please pick one or the other, not both), I can ensure that they receive prompt assistance and continued access to the latest features and improvements.
Your understanding and support are greatly appreciated as I work to maintain the quality and sustainability of Mimic for all users. If you have any questions or concerns, please feel free to reach out to me through the appropriate channels.
Thank you.
Please note that Jackrabbit Relay is not related to the Apache Jackrabbit project. Jackrabbit Relay is a standalone framework and API delivery system for automated algorithmic trading, designed for relaying JSON payloads that contain buy/sell order information between different systems (Charting software, forex brokers, cryptocrrency exchanges using REST). It is developed by Robert Darin and is not affiliated with or endorsed by the Apache Software Foundation or the Apache Jackrabbit project.
If you would like to help support this project financially, please click on the heart shaped sponsor's button in the right column of this page. I also have a merch store with some awesome and really cool products. Please visit supporting Jackrabbit for more options.
All subscriptions/sales go to the costs of sustaining Jackrabbit Relay. Thank you.
RAPMD Crypto: Automated algorithmic trading done right
Frequency Weighted OrderBook Analysis
Introduction
Jackrabbit Relay
Introduction
Risks
Disclaimer
Notes
Video
Supported Exchanges/Brokers
Security and firewall
Installation
Updating
Configuration files
Live Trading
Installation-and-Setup
Creating a Virtual Environment
Installation/Setup
Requirements
Stopping Version 1
Installing and setting up Version 2
Configuration
Reboot startup
Manual startup
Configuration
Configuration
Configuration files
Location and file names
File contents
Order types
Examples for the CCXT framework
Examples for the OANDA framework
Conditional Orders
JackrabbitRelay Order Payloads
Oliver Twist: Jackrabbit Relay conditional and orphan order manager
Unveiling Oliver Twist's Conditional Methodology
Managing Orphan Orders: The Limit-Only Approach
The Literary Significance of "Oliver Twist"
Supported-Exchanges-and-Brokers
Supported Exchanges/Brokers
Forex Brokers
Confirmed working brokers
Cryptocurrency Exchanges
Confirmed working exchanges
Theoretically supported
Known-Issues
Known Issues
Closing a position fails
BitMex
Phemex
ByBit
Python 3.10
Kucoin Futures/TradingView
Jackrabbit-Mimic
Jackrabbit Mimic
Introduction
Usage
Data Source Integration
Simple Setup Process
Understanding Differences
Educational Focus
Setup and Configuration
Wallets and history
How cryptocurrency wallets work
Long positions
Short positions
Alert/Signal messages
Long positions
Short positions
Supporting Jackrabbit Mimic
Testing-TradingView-connection
Testing TradingView connection
Testing method
Setup
DSR Testing
Force feeding payloads
Next Steps
Step-by-step guide to live trading with TradingView
Step-by-step guide to live trading with TradingView
Walk Through
Strategy Differences