@one_deploy/sdk 1.2.0 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ForexPoolDataGenerator--__twRwl.d.mts → ForexPoolDataGenerator-JxTPpJPz.d.mts} +1 -1
- package/dist/{ForexPoolDataGenerator-eUgwsU_B.d.ts → ForexPoolDataGenerator-qwWv6sCE.d.ts} +1 -1
- package/dist/{OneForexTradeHistory-TlKxjbFF.d.ts → OneForexTradeHistory-BE4rJH5t.d.ts} +1 -1
- package/dist/{OneForexTradeHistory-iDySMcw0.d.mts → OneForexTradeHistory-DbuHXRy0.d.mts} +1 -1
- package/dist/components/index.d.mts +2 -2
- package/dist/components/index.d.ts +2 -2
- package/dist/config/index.d.mts +1 -1
- package/dist/config/index.d.ts +1 -1
- package/dist/{console-BfTMA7ah.d.mts → console-Dvf-N9Gr.d.mts} +7 -0
- package/dist/{console-BfTMA7ah.d.ts → console-Dvf-N9Gr.d.ts} +7 -0
- package/dist/hooks/index.d.mts +2 -2
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/index.js +399 -38
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +399 -38
- package/dist/hooks/index.mjs.map +1 -1
- package/dist/index.d.mts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +399 -38
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +399 -38
- package/dist/index.mjs.map +1 -1
- package/dist/providers/index.d.mts +1 -1
- package/dist/providers/index.d.ts +1 -1
- package/dist/react-native.d.mts +4 -4
- package/dist/react-native.d.ts +4 -4
- package/dist/react-native.js +239 -36
- package/dist/react-native.js.map +1 -1
- package/dist/react-native.mjs +239 -36
- package/dist/react-native.mjs.map +1 -1
- package/dist/services/index.d.mts +2 -2
- package/dist/services/index.d.ts +2 -2
- package/dist/services/index.js +239 -36
- package/dist/services/index.js.map +1 -1
- package/dist/services/index.mjs +239 -36
- package/dist/services/index.mjs.map +1 -1
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/{useForexTrading-ZgW_G40Q.d.ts → useForexTrading-CA2DPQVf.d.ts} +1 -1
- package/dist/{useForexTrading-BleeSor8.d.mts → useForexTrading-I7nIQyog.d.mts} +1 -1
- package/package.json +1 -1
- package/src/services/forex/BotSimulationEngine.ts +463 -35
- package/src/services/forex/index.ts +12 -1
package/dist/hooks/index.mjs
CHANGED
|
@@ -927,9 +927,39 @@ var init_ForexSimulationEngine = __esm({
|
|
|
927
927
|
// src/services/forex/BotSimulationEngine.ts
|
|
928
928
|
var BotSimulationEngine_exports = {};
|
|
929
929
|
__export(BotSimulationEngine_exports, {
|
|
930
|
+
INVESTMENT_CYCLES: () => INVESTMENT_CYCLES,
|
|
931
|
+
INVESTMENT_TIERS: () => INVESTMENT_TIERS,
|
|
930
932
|
STRATEGY_PERSONALITIES: () => STRATEGY_PERSONALITIES,
|
|
931
|
-
botSimulationEngine: () => botSimulationEngine
|
|
933
|
+
botSimulationEngine: () => botSimulationEngine,
|
|
934
|
+
calculateDailyYield: () => calculateDailyYield,
|
|
935
|
+
estimateReturns: () => estimateReturns
|
|
932
936
|
});
|
|
937
|
+
function calculateDailyYield(strategy, tier, cycle) {
|
|
938
|
+
const baseYield = (strategy.dailyYieldMin + strategy.dailyYieldMax) / 2;
|
|
939
|
+
const tierBonuses = {
|
|
940
|
+
starter: 0,
|
|
941
|
+
basic: 0.02,
|
|
942
|
+
standard: 0.05,
|
|
943
|
+
premium: 0.08,
|
|
944
|
+
elite: 0.12,
|
|
945
|
+
vip: 0.15
|
|
946
|
+
};
|
|
947
|
+
const grossYield = baseYield * cycle.bonusMultiplier * (1 + tierBonuses[tier]);
|
|
948
|
+
const platformFee = grossYield * (cycle.profitSharePercent / 100);
|
|
949
|
+
const netYield = grossYield - platformFee;
|
|
950
|
+
return { grossYield, netYield, platformFee };
|
|
951
|
+
}
|
|
952
|
+
function estimateReturns(principal, strategy, tier, cycle) {
|
|
953
|
+
const { netYield, platformFee } = calculateDailyYield(strategy, tier, cycle);
|
|
954
|
+
const days = cycle.days || 30;
|
|
955
|
+
const dailyReturn = principal * (netYield / 100);
|
|
956
|
+
const totalReturn = dailyReturn * days;
|
|
957
|
+
const finalAmount = principal + totalReturn;
|
|
958
|
+
const platformProfit = principal * (platformFee / 100) * days;
|
|
959
|
+
const userProfit = totalReturn;
|
|
960
|
+
const apr = netYield * 365;
|
|
961
|
+
return { dailyReturn, totalReturn, finalAmount, platformProfit, userProfit, apr };
|
|
962
|
+
}
|
|
933
963
|
function genId3() {
|
|
934
964
|
return `log_${Date.now()}_${++idCounter2}`;
|
|
935
965
|
}
|
|
@@ -950,18 +980,195 @@ function formatPrice(price) {
|
|
|
950
980
|
if (price >= 1) return price.toFixed(3);
|
|
951
981
|
return price.toFixed(5);
|
|
952
982
|
}
|
|
953
|
-
var STRATEGY_PERSONALITIES, PAIR_PRICES, CHAIN_INFO, NEWS_HEADLINES, idCounter2, BotSimulationEngine, botSimulationEngine;
|
|
983
|
+
var INVESTMENT_TIERS, INVESTMENT_CYCLES, STRATEGY_PERSONALITIES, PAIR_PRICES, CHAIN_INFO, NEWS_HEADLINES, idCounter2, BotSimulationEngine, botSimulationEngine;
|
|
954
984
|
var init_BotSimulationEngine = __esm({
|
|
955
985
|
"src/services/forex/BotSimulationEngine.ts"() {
|
|
986
|
+
INVESTMENT_TIERS = {
|
|
987
|
+
starter: {
|
|
988
|
+
id: "starter",
|
|
989
|
+
name: "Starter",
|
|
990
|
+
nameCn: "\u5165\u95E8\u7248",
|
|
991
|
+
minInvestment: 100,
|
|
992
|
+
maxInvestment: 999,
|
|
993
|
+
color: "#6B7280",
|
|
994
|
+
icon: "\u{1F331}"
|
|
995
|
+
},
|
|
996
|
+
basic: {
|
|
997
|
+
id: "basic",
|
|
998
|
+
name: "Basic",
|
|
999
|
+
nameCn: "\u57FA\u7840\u7248",
|
|
1000
|
+
minInvestment: 1e3,
|
|
1001
|
+
maxInvestment: 4999,
|
|
1002
|
+
color: "#3B82F6",
|
|
1003
|
+
icon: "\u{1F4CA}"
|
|
1004
|
+
},
|
|
1005
|
+
standard: {
|
|
1006
|
+
id: "standard",
|
|
1007
|
+
name: "Standard",
|
|
1008
|
+
nameCn: "\u6807\u51C6\u7248",
|
|
1009
|
+
minInvestment: 5e3,
|
|
1010
|
+
maxInvestment: 19999,
|
|
1011
|
+
color: "#10B981",
|
|
1012
|
+
icon: "\u{1F48E}"
|
|
1013
|
+
},
|
|
1014
|
+
premium: {
|
|
1015
|
+
id: "premium",
|
|
1016
|
+
name: "Premium",
|
|
1017
|
+
nameCn: "\u9AD8\u7EA7\u7248",
|
|
1018
|
+
minInvestment: 2e4,
|
|
1019
|
+
maxInvestment: 49999,
|
|
1020
|
+
color: "#8B5CF6",
|
|
1021
|
+
icon: "\u{1F451}"
|
|
1022
|
+
},
|
|
1023
|
+
elite: {
|
|
1024
|
+
id: "elite",
|
|
1025
|
+
name: "Elite",
|
|
1026
|
+
nameCn: "\u7CBE\u82F1\u7248",
|
|
1027
|
+
minInvestment: 5e4,
|
|
1028
|
+
maxInvestment: 99999,
|
|
1029
|
+
color: "#F59E0B",
|
|
1030
|
+
icon: "\u{1F3C6}"
|
|
1031
|
+
},
|
|
1032
|
+
vip: {
|
|
1033
|
+
id: "vip",
|
|
1034
|
+
name: "VIP",
|
|
1035
|
+
nameCn: "VIP\u4E13\u5C5E",
|
|
1036
|
+
minInvestment: 1e5,
|
|
1037
|
+
maxInvestment: Infinity,
|
|
1038
|
+
color: "#EF4444",
|
|
1039
|
+
icon: "\u{1F525}"
|
|
1040
|
+
}
|
|
1041
|
+
};
|
|
1042
|
+
INVESTMENT_CYCLES = [
|
|
1043
|
+
{
|
|
1044
|
+
id: "flexible",
|
|
1045
|
+
days: 0,
|
|
1046
|
+
name: "Flexible",
|
|
1047
|
+
nameCn: "\u7075\u6D3B\u671F",
|
|
1048
|
+
profitSharePercent: 30,
|
|
1049
|
+
// Platform 30%, User 70%
|
|
1050
|
+
bonusMultiplier: 1,
|
|
1051
|
+
earlyWithdrawPenalty: 0
|
|
1052
|
+
},
|
|
1053
|
+
{
|
|
1054
|
+
id: "week",
|
|
1055
|
+
days: 7,
|
|
1056
|
+
name: "7 Days",
|
|
1057
|
+
nameCn: "7\u5929\u671F",
|
|
1058
|
+
profitSharePercent: 25,
|
|
1059
|
+
// Platform 25%, User 75%
|
|
1060
|
+
bonusMultiplier: 1.1,
|
|
1061
|
+
earlyWithdrawPenalty: 5
|
|
1062
|
+
},
|
|
1063
|
+
{
|
|
1064
|
+
id: "biweek",
|
|
1065
|
+
days: 14,
|
|
1066
|
+
name: "14 Days",
|
|
1067
|
+
nameCn: "14\u5929\u671F",
|
|
1068
|
+
profitSharePercent: 22,
|
|
1069
|
+
// Platform 22%, User 78%
|
|
1070
|
+
bonusMultiplier: 1.2,
|
|
1071
|
+
earlyWithdrawPenalty: 8
|
|
1072
|
+
},
|
|
1073
|
+
{
|
|
1074
|
+
id: "month",
|
|
1075
|
+
days: 30,
|
|
1076
|
+
name: "30 Days",
|
|
1077
|
+
nameCn: "30\u5929\u671F",
|
|
1078
|
+
profitSharePercent: 20,
|
|
1079
|
+
// Platform 20%, User 80%
|
|
1080
|
+
bonusMultiplier: 1.35,
|
|
1081
|
+
earlyWithdrawPenalty: 10
|
|
1082
|
+
},
|
|
1083
|
+
{
|
|
1084
|
+
id: "quarter",
|
|
1085
|
+
days: 90,
|
|
1086
|
+
name: "90 Days",
|
|
1087
|
+
nameCn: "90\u5929\u671F",
|
|
1088
|
+
profitSharePercent: 15,
|
|
1089
|
+
// Platform 15%, User 85%
|
|
1090
|
+
bonusMultiplier: 1.5,
|
|
1091
|
+
earlyWithdrawPenalty: 15
|
|
1092
|
+
},
|
|
1093
|
+
{
|
|
1094
|
+
id: "halfyear",
|
|
1095
|
+
days: 180,
|
|
1096
|
+
name: "180 Days",
|
|
1097
|
+
nameCn: "180\u5929\u671F",
|
|
1098
|
+
profitSharePercent: 12,
|
|
1099
|
+
// Platform 12%, User 88%
|
|
1100
|
+
bonusMultiplier: 1.8,
|
|
1101
|
+
earlyWithdrawPenalty: 20
|
|
1102
|
+
},
|
|
1103
|
+
{
|
|
1104
|
+
id: "year",
|
|
1105
|
+
days: 365,
|
|
1106
|
+
name: "365 Days",
|
|
1107
|
+
nameCn: "365\u5929\u671F",
|
|
1108
|
+
profitSharePercent: 10,
|
|
1109
|
+
// Platform 10%, User 90%
|
|
1110
|
+
bonusMultiplier: 2,
|
|
1111
|
+
earlyWithdrawPenalty: 25
|
|
1112
|
+
}
|
|
1113
|
+
];
|
|
956
1114
|
STRATEGY_PERSONALITIES = [
|
|
1115
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1116
|
+
// CONSERVATIVE STRATEGIES (保守型) - Low risk, stable returns
|
|
1117
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1118
|
+
{
|
|
1119
|
+
id: "stable-yield-01",
|
|
1120
|
+
name: "Stable Yield",
|
|
1121
|
+
shortName: "STB",
|
|
1122
|
+
color: "#6B7280",
|
|
1123
|
+
scanIntervalMin: 8e4,
|
|
1124
|
+
scanIntervalMax: 12e4,
|
|
1125
|
+
tradeFrequency: 0.15,
|
|
1126
|
+
positionSizeMin: 5,
|
|
1127
|
+
positionSizeMax: 15,
|
|
1128
|
+
leverageMin: 1,
|
|
1129
|
+
leverageMax: 3,
|
|
1130
|
+
primaryIndicators: ["Bollinger", "Volume"],
|
|
1131
|
+
riskTolerance: "low",
|
|
1132
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT"],
|
|
1133
|
+
rsiBias: 45,
|
|
1134
|
+
tier: "starter",
|
|
1135
|
+
dailyYieldMin: 0.15,
|
|
1136
|
+
dailyYieldMax: 0.25,
|
|
1137
|
+
description: "\u7A33\u5065\u6536\u76CA\u7B56\u7565\uFF0C\u4F4E\u98CE\u9669\u4F4E\u6CE2\u52A8\uFF0C\u9002\u5408\u65B0\u624B\u5165\u95E8",
|
|
1138
|
+
category: "conservative"
|
|
1139
|
+
},
|
|
957
1140
|
{
|
|
958
|
-
id: "
|
|
1141
|
+
id: "conservative-shield-01",
|
|
1142
|
+
name: "Conservative Shield",
|
|
1143
|
+
shortName: "CON",
|
|
1144
|
+
color: "#10B981",
|
|
1145
|
+
scanIntervalMin: 6e4,
|
|
1146
|
+
scanIntervalMax: 9e4,
|
|
1147
|
+
tradeFrequency: 0.25,
|
|
1148
|
+
positionSizeMin: 10,
|
|
1149
|
+
positionSizeMax: 20,
|
|
1150
|
+
leverageMin: 2,
|
|
1151
|
+
leverageMax: 5,
|
|
1152
|
+
primaryIndicators: ["Bollinger", "Volume", "RSI"],
|
|
1153
|
+
riskTolerance: "low",
|
|
1154
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT"],
|
|
1155
|
+
rsiBias: 45,
|
|
1156
|
+
tier: "basic",
|
|
1157
|
+
dailyYieldMin: 0.25,
|
|
1158
|
+
dailyYieldMax: 0.4,
|
|
1159
|
+
description: "\u4FDD\u5B88\u9632\u5FA1\u7B56\u7565\uFF0C\u6CE8\u91CD\u8D44\u91D1\u5B89\u5168\uFF0C\u7A33\u5B9A\u6536\u76CA",
|
|
1160
|
+
category: "conservative"
|
|
1161
|
+
},
|
|
1162
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1163
|
+
// BALANCED STRATEGIES (平衡型) - Moderate risk, balanced returns
|
|
1164
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1165
|
+
{
|
|
1166
|
+
id: "balanced-alpha-01",
|
|
959
1167
|
name: "Balanced Alpha",
|
|
960
1168
|
shortName: "BAL",
|
|
961
1169
|
color: "#3B82F6",
|
|
962
|
-
scanIntervalMin:
|
|
963
|
-
|
|
964
|
-
scanIntervalMax: 4e4,
|
|
1170
|
+
scanIntervalMin: 45e3,
|
|
1171
|
+
scanIntervalMax: 7e4,
|
|
965
1172
|
tradeFrequency: 0.4,
|
|
966
1173
|
positionSizeMin: 15,
|
|
967
1174
|
positionSizeMax: 35,
|
|
@@ -970,34 +1177,92 @@ var init_BotSimulationEngine = __esm({
|
|
|
970
1177
|
primaryIndicators: ["RSI", "MACD"],
|
|
971
1178
|
riskTolerance: "medium",
|
|
972
1179
|
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT"],
|
|
973
|
-
rsiBias: 50
|
|
1180
|
+
rsiBias: 50,
|
|
1181
|
+
tier: "standard",
|
|
1182
|
+
dailyYieldMin: 0.4,
|
|
1183
|
+
dailyYieldMax: 0.65,
|
|
1184
|
+
description: "\u5E73\u8861\u578B\u7B56\u7565\uFF0C\u98CE\u9669\u6536\u76CA\u5747\u8861\uFF0C\u9002\u5408\u7A33\u5065\u6295\u8D44\u8005",
|
|
1185
|
+
category: "balanced"
|
|
974
1186
|
},
|
|
975
1187
|
{
|
|
976
|
-
id: "
|
|
977
|
-
name: "
|
|
978
|
-
shortName: "
|
|
979
|
-
color: "#
|
|
980
|
-
scanIntervalMin:
|
|
981
|
-
|
|
1188
|
+
id: "smart-rebalance-01",
|
|
1189
|
+
name: "Smart Rebalance",
|
|
1190
|
+
shortName: "SRB",
|
|
1191
|
+
color: "#06B6D4",
|
|
1192
|
+
scanIntervalMin: 5e4,
|
|
1193
|
+
scanIntervalMax: 75e3,
|
|
1194
|
+
tradeFrequency: 0.35,
|
|
1195
|
+
positionSizeMin: 12,
|
|
1196
|
+
positionSizeMax: 30,
|
|
1197
|
+
leverageMin: 3,
|
|
1198
|
+
leverageMax: 8,
|
|
1199
|
+
primaryIndicators: ["RSI", "EMA", "Volume"],
|
|
1200
|
+
riskTolerance: "medium",
|
|
1201
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "BNB/USDT", "SOL/USDT"],
|
|
1202
|
+
rsiBias: 50,
|
|
1203
|
+
tier: "standard",
|
|
1204
|
+
dailyYieldMin: 0.45,
|
|
1205
|
+
dailyYieldMax: 0.7,
|
|
1206
|
+
description: "\u667A\u80FD\u518D\u5E73\u8861\u7B56\u7565\uFF0C\u52A8\u6001\u8C03\u6574\u6301\u4ED3\uFF0C\u4F18\u5316\u6536\u76CA",
|
|
1207
|
+
category: "balanced"
|
|
1208
|
+
},
|
|
1209
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1210
|
+
// GROWTH STRATEGIES (成长型) - Higher risk, higher returns
|
|
1211
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1212
|
+
{
|
|
1213
|
+
id: "growth-momentum-01",
|
|
1214
|
+
name: "Growth Momentum",
|
|
1215
|
+
shortName: "GRO",
|
|
1216
|
+
color: "#8B5CF6",
|
|
1217
|
+
scanIntervalMin: 4e4,
|
|
1218
|
+
scanIntervalMax: 6e4,
|
|
1219
|
+
tradeFrequency: 0.45,
|
|
1220
|
+
positionSizeMin: 20,
|
|
1221
|
+
positionSizeMax: 40,
|
|
1222
|
+
leverageMin: 5,
|
|
1223
|
+
leverageMax: 12,
|
|
1224
|
+
primaryIndicators: ["RSI", "MACD", "EMA"],
|
|
1225
|
+
riskTolerance: "medium",
|
|
1226
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "AVAX/USDT"],
|
|
1227
|
+
rsiBias: 52,
|
|
1228
|
+
tier: "premium",
|
|
1229
|
+
dailyYieldMin: 0.6,
|
|
1230
|
+
dailyYieldMax: 0.95,
|
|
1231
|
+
description: "\u6210\u957F\u52A8\u91CF\u7B56\u7565\uFF0C\u8FFD\u6C42\u8F83\u9AD8\u6536\u76CA\uFF0C\u9002\u5408\u6709\u7ECF\u9A8C\u6295\u8D44\u8005",
|
|
1232
|
+
category: "growth"
|
|
1233
|
+
},
|
|
1234
|
+
{
|
|
1235
|
+
id: "trend-hunter-01",
|
|
1236
|
+
name: "Trend Hunter",
|
|
1237
|
+
shortName: "TRH",
|
|
1238
|
+
color: "#EC4899",
|
|
1239
|
+
scanIntervalMin: 38e3,
|
|
982
1240
|
scanIntervalMax: 55e3,
|
|
983
|
-
tradeFrequency: 0.
|
|
984
|
-
positionSizeMin:
|
|
985
|
-
positionSizeMax:
|
|
986
|
-
leverageMin:
|
|
987
|
-
leverageMax:
|
|
988
|
-
primaryIndicators: ["
|
|
989
|
-
riskTolerance: "
|
|
990
|
-
preferredPairs: ["BTC/USDT", "ETH/USDT"],
|
|
991
|
-
rsiBias:
|
|
1241
|
+
tradeFrequency: 0.48,
|
|
1242
|
+
positionSizeMin: 22,
|
|
1243
|
+
positionSizeMax: 42,
|
|
1244
|
+
leverageMin: 5,
|
|
1245
|
+
leverageMax: 15,
|
|
1246
|
+
primaryIndicators: ["EMA", "MACD", "Volume", "Bollinger"],
|
|
1247
|
+
riskTolerance: "medium",
|
|
1248
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "ARB/USDT", "OP/USDT"],
|
|
1249
|
+
rsiBias: 53,
|
|
1250
|
+
tier: "premium",
|
|
1251
|
+
dailyYieldMin: 0.65,
|
|
1252
|
+
dailyYieldMax: 1,
|
|
1253
|
+
description: "\u8D8B\u52BF\u730E\u624B\u7B56\u7565\uFF0C\u6355\u6349\u5E02\u573A\u8D8B\u52BF\uFF0C\u8FFD\u6C42\u8D85\u989D\u6536\u76CA",
|
|
1254
|
+
category: "growth"
|
|
992
1255
|
},
|
|
1256
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1257
|
+
// AGGRESSIVE STRATEGIES (激进型) - High risk, high returns
|
|
1258
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
993
1259
|
{
|
|
994
|
-
id: "aggressive-01",
|
|
1260
|
+
id: "aggressive-momentum-01",
|
|
995
1261
|
name: "Aggressive Momentum",
|
|
996
1262
|
shortName: "AGG",
|
|
997
1263
|
color: "#EF4444",
|
|
998
|
-
scanIntervalMin:
|
|
999
|
-
|
|
1000
|
-
scanIntervalMax: 3e4,
|
|
1264
|
+
scanIntervalMin: 35e3,
|
|
1265
|
+
scanIntervalMax: 55e3,
|
|
1001
1266
|
tradeFrequency: 0.5,
|
|
1002
1267
|
positionSizeMin: 25,
|
|
1003
1268
|
positionSizeMax: 50,
|
|
@@ -1006,7 +1271,103 @@ var init_BotSimulationEngine = __esm({
|
|
|
1006
1271
|
primaryIndicators: ["RSI", "MACD", "EMA", "Volume"],
|
|
1007
1272
|
riskTolerance: "high",
|
|
1008
1273
|
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "DOGE/USDT", "AVAX/USDT"],
|
|
1009
|
-
rsiBias: 55
|
|
1274
|
+
rsiBias: 55,
|
|
1275
|
+
tier: "elite",
|
|
1276
|
+
dailyYieldMin: 0.85,
|
|
1277
|
+
dailyYieldMax: 1.4,
|
|
1278
|
+
description: "\u6FC0\u8FDB\u52A8\u91CF\u7B56\u7565\uFF0C\u9AD8\u98CE\u9669\u9AD8\u6536\u76CA\uFF0C\u9002\u5408\u98CE\u9669\u627F\u53D7\u80FD\u529B\u5F3A\u7684\u6295\u8D44\u8005",
|
|
1279
|
+
category: "aggressive"
|
|
1280
|
+
},
|
|
1281
|
+
{
|
|
1282
|
+
id: "leverage-maximizer-01",
|
|
1283
|
+
name: "Leverage Maximizer",
|
|
1284
|
+
shortName: "LEV",
|
|
1285
|
+
color: "#F97316",
|
|
1286
|
+
scanIntervalMin: 3e4,
|
|
1287
|
+
scanIntervalMax: 5e4,
|
|
1288
|
+
tradeFrequency: 0.55,
|
|
1289
|
+
positionSizeMin: 30,
|
|
1290
|
+
positionSizeMax: 55,
|
|
1291
|
+
leverageMin: 10,
|
|
1292
|
+
leverageMax: 25,
|
|
1293
|
+
primaryIndicators: ["RSI", "MACD", "EMA", "Volume", "Bollinger"],
|
|
1294
|
+
riskTolerance: "high",
|
|
1295
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "DOGE/USDT", "AVAX/USDT", "ARB/USDT"],
|
|
1296
|
+
rsiBias: 55,
|
|
1297
|
+
tier: "elite",
|
|
1298
|
+
dailyYieldMin: 1,
|
|
1299
|
+
dailyYieldMax: 1.8,
|
|
1300
|
+
description: "\u6760\u6746\u6700\u5927\u5316\u7B56\u7565\uFF0C\u8FFD\u6C42\u6781\u81F4\u6536\u76CA\uFF0C\u9700\u8981\u4E13\u4E1A\u6295\u8D44\u7ECF\u9A8C",
|
|
1301
|
+
category: "aggressive"
|
|
1302
|
+
},
|
|
1303
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1304
|
+
// QUANTITATIVE STRATEGIES (量化型) - AI-driven, advanced algorithms
|
|
1305
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
1306
|
+
{
|
|
1307
|
+
id: "ai-quant-alpha-01",
|
|
1308
|
+
name: "AI Quant Alpha",
|
|
1309
|
+
shortName: "AQA",
|
|
1310
|
+
color: "#A855F7",
|
|
1311
|
+
scanIntervalMin: 42e3,
|
|
1312
|
+
scanIntervalMax: 65e3,
|
|
1313
|
+
tradeFrequency: 0.42,
|
|
1314
|
+
positionSizeMin: 18,
|
|
1315
|
+
positionSizeMax: 38,
|
|
1316
|
+
leverageMin: 4,
|
|
1317
|
+
leverageMax: 12,
|
|
1318
|
+
primaryIndicators: ["RSI", "MACD", "EMA", "Volume", "Bollinger"],
|
|
1319
|
+
riskTolerance: "medium",
|
|
1320
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "BNB/USDT"],
|
|
1321
|
+
rsiBias: 51,
|
|
1322
|
+
tier: "premium",
|
|
1323
|
+
dailyYieldMin: 0.7,
|
|
1324
|
+
dailyYieldMax: 1.1,
|
|
1325
|
+
description: "AI\u91CF\u5316Alpha\u7B56\u7565\uFF0C\u673A\u5668\u5B66\u4E60\u9A71\u52A8\uFF0C\u667A\u80FD\u98CE\u63A7",
|
|
1326
|
+
category: "quantitative"
|
|
1327
|
+
},
|
|
1328
|
+
{
|
|
1329
|
+
id: "neural-trader-01",
|
|
1330
|
+
name: "Neural Trader",
|
|
1331
|
+
shortName: "NRT",
|
|
1332
|
+
color: "#14B8A6",
|
|
1333
|
+
scanIntervalMin: 4e4,
|
|
1334
|
+
scanIntervalMax: 62e3,
|
|
1335
|
+
tradeFrequency: 0.44,
|
|
1336
|
+
positionSizeMin: 20,
|
|
1337
|
+
positionSizeMax: 40,
|
|
1338
|
+
leverageMin: 5,
|
|
1339
|
+
leverageMax: 15,
|
|
1340
|
+
primaryIndicators: ["RSI", "MACD", "EMA", "Volume", "Bollinger"],
|
|
1341
|
+
riskTolerance: "medium",
|
|
1342
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "AVAX/USDT", "LINK/USDT"],
|
|
1343
|
+
rsiBias: 52,
|
|
1344
|
+
tier: "elite",
|
|
1345
|
+
dailyYieldMin: 0.8,
|
|
1346
|
+
dailyYieldMax: 1.25,
|
|
1347
|
+
description: "\u795E\u7ECF\u7F51\u7EDC\u4EA4\u6613\u7B56\u7565\uFF0C\u6DF1\u5EA6\u5B66\u4E60\u6A21\u578B\uFF0C\u81EA\u9002\u5E94\u5E02\u573A",
|
|
1348
|
+
category: "quantitative"
|
|
1349
|
+
},
|
|
1350
|
+
{
|
|
1351
|
+
id: "quantum-edge-01",
|
|
1352
|
+
name: "Quantum Edge",
|
|
1353
|
+
shortName: "QTE",
|
|
1354
|
+
color: "#6366F1",
|
|
1355
|
+
scanIntervalMin: 35e3,
|
|
1356
|
+
scanIntervalMax: 55e3,
|
|
1357
|
+
tradeFrequency: 0.5,
|
|
1358
|
+
positionSizeMin: 25,
|
|
1359
|
+
positionSizeMax: 50,
|
|
1360
|
+
leverageMin: 8,
|
|
1361
|
+
leverageMax: 20,
|
|
1362
|
+
primaryIndicators: ["RSI", "MACD", "EMA", "Volume", "Bollinger"],
|
|
1363
|
+
riskTolerance: "high",
|
|
1364
|
+
preferredPairs: ["BTC/USDT", "ETH/USDT", "SOL/USDT", "AVAX/USDT", "ARB/USDT", "OP/USDT"],
|
|
1365
|
+
rsiBias: 54,
|
|
1366
|
+
tier: "vip",
|
|
1367
|
+
dailyYieldMin: 1.2,
|
|
1368
|
+
dailyYieldMax: 2,
|
|
1369
|
+
description: "VIP\u91CF\u5B50\u4F18\u52BF\u7B56\u7565\uFF0C\u9876\u7EA7AI\u7B97\u6CD5\uFF0C\u6781\u81F4\u6536\u76CA\u8FFD\u6C42",
|
|
1370
|
+
category: "quantitative"
|
|
1010
1371
|
}
|
|
1011
1372
|
];
|
|
1012
1373
|
PAIR_PRICES = {
|
|
@@ -1227,7 +1588,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1227
1588
|
},
|
|
1228
1589
|
delay
|
|
1229
1590
|
});
|
|
1230
|
-
delay += rand3(
|
|
1591
|
+
delay += rand3(2e3, 3500);
|
|
1231
1592
|
const thinkingMessages = this.generateThinkingProcess(strategy, pair, price);
|
|
1232
1593
|
for (const thinking of thinkingMessages) {
|
|
1233
1594
|
entries.push({
|
|
@@ -1240,7 +1601,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1240
1601
|
},
|
|
1241
1602
|
delay
|
|
1242
1603
|
});
|
|
1243
|
-
delay += rand3(
|
|
1604
|
+
delay += rand3(1500, 2500);
|
|
1244
1605
|
}
|
|
1245
1606
|
const indicatorParts = [];
|
|
1246
1607
|
if (strategy.primaryIndicators.includes("RSI") || strategy.primaryIndicators.includes("MACD")) {
|
|
@@ -1272,7 +1633,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1272
1633
|
},
|
|
1273
1634
|
delay
|
|
1274
1635
|
});
|
|
1275
|
-
delay += rand3(
|
|
1636
|
+
delay += rand3(2e3, 3500);
|
|
1276
1637
|
if (Math.random() < 0.12) {
|
|
1277
1638
|
const sentiment = Math.random() > 0.4 ? "Bullish" : "Bearish";
|
|
1278
1639
|
entries.push({
|
|
@@ -1285,7 +1646,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1285
1646
|
},
|
|
1286
1647
|
delay
|
|
1287
1648
|
});
|
|
1288
|
-
delay += rand3(
|
|
1649
|
+
delay += rand3(2500, 4e3);
|
|
1289
1650
|
}
|
|
1290
1651
|
if (Math.random() < 0.4) {
|
|
1291
1652
|
const analysis = this.generateAnalysis(strategy, indicators, pair);
|
|
@@ -1299,7 +1660,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1299
1660
|
},
|
|
1300
1661
|
delay
|
|
1301
1662
|
});
|
|
1302
|
-
delay += rand3(
|
|
1663
|
+
delay += rand3(2500, 4e3);
|
|
1303
1664
|
}
|
|
1304
1665
|
const signal = this.evaluateSignal(strategy, indicators);
|
|
1305
1666
|
state.lastSignal = signal.direction;
|
|
@@ -1323,7 +1684,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1323
1684
|
},
|
|
1324
1685
|
delay
|
|
1325
1686
|
});
|
|
1326
|
-
delay += rand3(
|
|
1687
|
+
delay += rand3(3e3, 5e3);
|
|
1327
1688
|
entries.push({
|
|
1328
1689
|
entry: {
|
|
1329
1690
|
strategyId: strategy.id,
|
|
@@ -1335,7 +1696,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1335
1696
|
},
|
|
1336
1697
|
delay
|
|
1337
1698
|
});
|
|
1338
|
-
delay += rand3(
|
|
1699
|
+
delay += rand3(3e3, 4500);
|
|
1339
1700
|
const decision = this.makeTradeDecision(strategy, signal, state);
|
|
1340
1701
|
if (decision.execute) {
|
|
1341
1702
|
entries.push({
|
|
@@ -1355,7 +1716,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1355
1716
|
},
|
|
1356
1717
|
delay
|
|
1357
1718
|
});
|
|
1358
|
-
delay += rand3(
|
|
1719
|
+
delay += rand3(2500, 4e3);
|
|
1359
1720
|
const orderId = `ORD_${Date.now().toString(36).toUpperCase()}`;
|
|
1360
1721
|
const orderPrice = signal.direction === "LONG" ? price * (1 - rand3(1e-4, 5e-4)) : price * (1 + rand3(1e-4, 5e-4));
|
|
1361
1722
|
entries.push({
|
|
@@ -1380,7 +1741,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1380
1741
|
},
|
|
1381
1742
|
delay
|
|
1382
1743
|
});
|
|
1383
|
-
delay += rand3(
|
|
1744
|
+
delay += rand3(4e3, 7e3);
|
|
1384
1745
|
const fillPrice = orderPrice * (1 + rand3(-3e-4, 3e-4));
|
|
1385
1746
|
const slippage = Math.abs(fillPrice - orderPrice) / orderPrice * 100;
|
|
1386
1747
|
entries.push({
|
|
@@ -1429,7 +1790,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1429
1790
|
}
|
|
1430
1791
|
}
|
|
1431
1792
|
if (state.openPositions.length > 0 && Math.random() < 0.5) {
|
|
1432
|
-
delay += rand3(
|
|
1793
|
+
delay += rand3(3500, 5500);
|
|
1433
1794
|
let totalPositionPnl = 0;
|
|
1434
1795
|
const pnlParts = [];
|
|
1435
1796
|
for (const pos of state.openPositions) {
|
|
@@ -1465,7 +1826,7 @@ var init_BotSimulationEngine = __esm({
|
|
|
1465
1826
|
});
|
|
1466
1827
|
}
|
|
1467
1828
|
if (Math.random() < 0.2) {
|
|
1468
|
-
delay += rand3(
|
|
1829
|
+
delay += rand3(3e3, 5e3);
|
|
1469
1830
|
const exposure = state.openPositions.reduce((sum, p) => sum + p.size * p.leverage, 0);
|
|
1470
1831
|
const maxDrawdown = rand3(2, 12);
|
|
1471
1832
|
entries.push({
|