From 085a14c49d984ae94aeab9e248bfe95f10567b53 Mon Sep 17 00:00:00 2001 From: Siddharth2207 Date: Thu, 16 Jan 2025 20:04:47 +0530 Subject: [PATCH] rkfi<>usdc dsf, auction --- .../raindex/1-auction-dca/auction-dca.rain | 223 ++++++++++++++++++ .../2-dynamic-spread/dynamic-spread.rain | 120 ++++++++++ 2 files changed, 343 insertions(+) diff --git a/public/_strategies/raindex/1-auction-dca/auction-dca.rain b/public/_strategies/raindex/1-auction-dca/auction-dca.rain index aa01f1fa..8a6c66b8 100644 --- a/public/_strategies/raindex/1-auction-dca/auction-dca.rain +++ b/public/_strategies/raindex/1-auction-dca/auction-dca.rain @@ -136,6 +136,10 @@ tokens: network: base address: 0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf decimals: 8 + base-rkfi: + network: base + address: 0x65FdA84473084bA2CcA8452883E6eA3561092234 + decimals: 18 base-usdc: network: base address: 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 @@ -349,6 +353,20 @@ orders: - token: base-paid outputs: - token: base-usdc + base-usdc-rkfi: + orderbook: base + network: base + inputs: + - token: base-usdc + outputs: + - token: base-rkfi + base-rkfi-usdc: + orderbook: base + network: base + inputs: + - token: base-rkfi + outputs: + - token: base-usdc base-usdc-wlth: orderbook: base network: base @@ -828,6 +846,12 @@ deployments: base-paid-usdc: order: base-paid-usdc scenario: base + base-usdc-rkfi: + order: base-usdc-rkfi + scenario: base + base-rkfi-usdc: + order: base-rkfi-usdc + scenario: base base-usdc-wlth: order: base-usdc-wlth scenario: base @@ -4180,6 +4204,205 @@ gui: value: 20 - name: 50 value: 50 + + - deployment: base-usdc-rkfi + name: Sell RKFI for USDC on Base. + description: > + Sell RKFI for USDC on Base. + deposits: + - token: base-rkfi + min: 0 + presets: + - 0 + - 10000 + - 50000 + - 100000 + - 1000000 + + fields: + - binding: time-per-amount-epoch + name: Budget period (in seconds) + description: > + The budget is spent over this time period. + min: 1 + presets: + - name: Every 30 minutes (1800) + value: 1800 + - name: Per hour (3600) + value: 3600 + - name: Per day (86400) + value: 86400 + - name: Per week (604800) + value: 604800 + - binding: amount-per-epoch + name: Budget (RKFI per period) + description: > + The amount of RKFI to spend each budget period. + min: 0 + - binding: max-trade-amount + name: Maximum trade size (RKFI) + description: > + The maximum amount of RKFI to sell in a single auction. + min: 0 + - binding: min-trade-amount + name: Minimum trade size (RKFI) + description: > + The minimum amount of RKFI to sell in a single auction. + min: 0 + - binding: time-per-trade-epoch + name: Auction period (in seconds) + description: > + The auction period is the time between each auction price halvening. + presets: + - name: Every hour (3600) + value: 3600 + - name: Every 2 hours (7200) + value: 7200 + - name: Every 4 hours (14400) + value: 14400 + - binding: baseline + name: Baseline USDC per RKFI + description: > + The absolute minimum amount of USDC per RKFI that the auction will trade at (e.g. 0.0010 USDC per RKFI) + min: 0 + presets: + - name: 0.01 + value: 0.01 + - name: 0.02 + value: 0.02 + - name: 0.05 + value: 0.05 + - binding: next-trade-multiplier + name: Auction start multiplier + description: > + The multiplier to apply to the last trade to kick off the next auction. + min: 1.01 + presets: + - name: 1.01x + value: 1.01 + - name: 1.02x + value: 1.02 + - name: 1.05x + value: 1.05 + - binding: next-trade-baseline-multiplier + name: Auction end multiplier + description: > + The multiplier to apply to the last trade to set the baseline for the next auction. + presets: + - name: Disabled (0) + value: 0 + - name: 0.9x + value: 0.9 + - name: 0.95x + value: 0.95 + - binding: initial-io + name: Kickoff USDC per RKFI + description: > + The initial USDC per RKFI to kickoff the first auction (e.g. 0.0014 USDC per RKFI) + min: 0 + presets: + - name: 0.05 + value: 0.05 + - name: 0.1 + value: 0.1 + + - deployment: base-rkfi-usdc + name: Buy RKFI with USDC on Base. + description: > + Buy RKFI with USDC on Base. + deposits: + - token: base-usdc + min: 0 + presets: + - 0 + - 100 + - 1000 + - 10000 + + fields: + - binding: time-per-amount-epoch + name: Budget period (in seconds) + description: > + The budget is spent over this time period. + min: 1 + presets: + - name: Per hour (3600) + value: 3600 + - name: Per day (86400) + value: 86400 + - name: Per week (604800) + value: 604800 + - binding: amount-per-epoch + name: Budget (USDC per period) + description: > + The amount of USDC to spend each budget period. + min: 0 + - binding: max-trade-amount + name: Maximum trade size (USDC) + description: > + The maximum amount of USDC to spend in a single auction. + min: 0 + - binding: min-trade-amount + name: Minimum trade size (USDC) + description: > + The minimum amount of USDC to spend in a single auction. + min: 0 + - binding: time-per-trade-epoch + name: Auction period (in seconds) + description: > + The auction period is the time between each auction price halvening. + presets: + - name: Every hour (3600) + value: 3600 + - name: Every 2 hours (7200) + value: 7200 + - name: Every 4 hours (14400) + value: 14400 + - binding: baseline + name: Baseline RKFI per USDC + description: > + The absolute minimum amount of RKFI per USDC that the auction will trade at (e.g. 600 RKFI per USDC) + min: 0 + presets: + - name: 10 + value: 10 + - name: 20 + value: 20 + - name: 50 + value: 50 + - binding: next-trade-multiplier + name: Auction start multiplier + description: > + The multiplier to apply to the last trade to kick off the next auction. + min: 1.01 + presets: + - name: 1.01x + value: 1.01 + - name: 1.02x + value: 1.02 + - name: 1.05x + value: 1.05 + - binding: next-trade-baseline-multiplier + name: Auction end multiplier + description: > + The multiplier to apply to the last trade to set the baseline for the next auction. + presets: + - name: Disabled (0) + value: 0 + - name: 0.9x + value: 0.9 + - name: 0.95x + value: 0.95 + - binding: initial-io + name: Kickoff RKFI per USDC + description: > + The initial RKFI per USDC to kickoff the first auction (e.g. 681 RKFI per USDC) + min: 0 + presets: + - name: 20 + value: 20 + - name: 50 + value: 50 - deployment: base-usdc-wlth name: Sell WLTH for USDC on Base. diff --git a/public/_strategies/raindex/2-dynamic-spread/dynamic-spread.rain b/public/_strategies/raindex/2-dynamic-spread/dynamic-spread.rain index 79e1fe11..2cbe3d71 100644 --- a/public/_strategies/raindex/2-dynamic-spread/dynamic-spread.rain +++ b/public/_strategies/raindex/2-dynamic-spread/dynamic-spread.rain @@ -1139,6 +1139,104 @@ gui: - 10000 - 20000 + - deployment: base-usdc-rkfi + name: USDC<>RKFI on Base. + description: Rotate USDC and RKFI on Base. + + fields: + - binding: is-fast-exit + name: Fast exit? + description: If enabled, the strategy will attempt to exit any position it builds up in a single trade, as soon as it can do so profitably. + presets: + - name: Yes + value: 1 + - name: No + value: 0 + - binding: initial-io + name: Initial price (USDC per RKFI) + description: The rough USDC price you see for RKFI on Dex Screener (e.g. 0.0014). + min: 0 + - binding: next-trade-multiplier + name: Next trade multiplier + description: This is the most the strategy will move the price in a single trade. Larger numbers will capture larger price jumps but trade less often, smaller numbers will trade more often but be less defensive against large price jumps in the market. + min: 1 + presets: + - name: 1.01x + value: 1.01 + - name: 1.02x + value: 1.02 + - name: 1.05x + value: 1.05 + - binding: cost-basis-multiplier + name: Cost basis multiplier + description: The minimum spread applied to the breakeven in addition to the auction. This is applied in both directions so 1.01x would be a 2% total spread. + min: 1 + presets: + - name: 1 (auction spread only) + value: 1 + - name: 1.0005x (0.1% total) + value: 1.0005 + - name: 1.001x (0.2% total) + value: 1.001 + - name: 1.0025x (0.5% total) + value: 1.0025 + - name: 1.005x (1% total) + value: 1.005 + - binding: time-per-epoch + name: Time per halving (seconds) + description: The amount of time (in seconds) between halvings of the price and the amount offered during each auction, relative to their baselines. + min: 600 + presets: + - name: 1 hour (3600) + value: 3600 + - name: 2 hours (7200) + value: 7200 + - name: 4 hours (14400) + value: 14400 + - name: 8 hours (28800) + value: 28800 + - binding: max-amount + name: Max amount + description: The maximum amount of USDC that will be offered in a single auction. + min: 5 + presets: + - name: $100 + value: 100 + - name: $200 + value: 200 + - name: $500 + value: 500 + - name: $1000 + value: 1000 + - binding: min-amount + name: Minimum amount + description: The minimum amount of USDC that will be offered in a single auction. + min: 5 + presets: + - name: $500 + value: 500 + - name: $200 + value: 200 + - name: $100 + value: 100 + deposits: + - token: base-usdc + min: 0 + presets: + - 0 + - 100 + - 200 + - 500 + - 1000 + - token: base-rkfi + min: 0 + presets: + - 0 + - 1000 + - 5000 + - 10000 + - 20000 + - deployment: arbitrum-usdc-weth name: USDC<>WETH on Arbitrum. description: Rotate USDC and WETH on Arbitrum. @@ -3144,6 +3242,12 @@ scenarios: amount-token: 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913 initial-output-token: 0x655A51e6803faF50D4acE80fa501af2F29C856cF initial-input-token: 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913 + usdc-rkfi: + runs: 1 + bindings: + amount-token: 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913 + initial-output-token: 0x65FdA84473084bA2CcA8452883E6eA3561092234 + initial-input-token: 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913 wlth-usdc: runs: 1 bindings: @@ -3476,6 +3580,10 @@ tokens: network: base address: 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913 decimals: 6 + base-rkfi: + network: base + address: 0x65FdA84473084bA2CcA8452883E6eA3561092234 + decimals: 18 base-weth: network: base address: 0x4200000000000000000000000000000000000006 @@ -3662,6 +3770,15 @@ orders: outputs: - token: base-usdc - token: base-weth + base-usdc-rkfi: + network: base + orderbook: base + inputs: + - token: base-usdc + - token: base-rkfi + outputs: + - token: base-usdc + - token: base-rkfi base-lucky-weth: network: base orderbook: base @@ -3916,6 +4033,9 @@ deployments: base-usdc-weth: order: base-usdc-weth scenario: base.usdc-weth + base-usdc-rkfi: + order: base-usdc-rkfi + scenario: base.usdc-rkfi base-lucky-weth: order: base-lucky-weth scenario: base.lucky-weth