@gbozee/ultimate 0.0.2-123 → 0.0.2-124
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/frontend-index.d.ts +2 -0
- package/dist/frontend-index.js +17 -7
- package/dist/index.cjs +17 -7
- package/dist/index.d.ts +5 -0
- package/dist/index.js +17 -7
- package/dist/mcp-server.cjs +17 -7
- package/dist/mcp-server.js +17 -7
- package/package.json +1 -1
package/dist/frontend-index.d.ts
CHANGED
|
@@ -295,6 +295,7 @@ export type AppConfig = {
|
|
|
295
295
|
max_size?: number;
|
|
296
296
|
last_value?: any;
|
|
297
297
|
entries?: any[];
|
|
298
|
+
max_quantity?: number;
|
|
298
299
|
};
|
|
299
300
|
export type ExtendConfigType = {
|
|
300
301
|
take_profit?: number;
|
|
@@ -761,6 +762,7 @@ export declare class Strategy {
|
|
|
761
762
|
gap?: number;
|
|
762
763
|
rr?: number;
|
|
763
764
|
max_size?: number;
|
|
765
|
+
max_quantity?: number;
|
|
764
766
|
};
|
|
765
767
|
identifyGapConfig(payload: {
|
|
766
768
|
factor?: number;
|
package/dist/frontend-index.js
CHANGED
|
@@ -1195,6 +1195,22 @@ function determineTPSl(payload) {
|
|
|
1195
1195
|
};
|
|
1196
1196
|
}
|
|
1197
1197
|
// src/helpers/shared.ts
|
|
1198
|
+
function getMaxQuantity(x, app_config) {
|
|
1199
|
+
let max_quantity = app_config.max_quantity;
|
|
1200
|
+
if (max_quantity) {
|
|
1201
|
+
return x <= max_quantity;
|
|
1202
|
+
}
|
|
1203
|
+
if (app_config.symbol === "BTCUSDT") {
|
|
1204
|
+
max_quantity = 0.03;
|
|
1205
|
+
}
|
|
1206
|
+
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
1207
|
+
max_quantity = 2;
|
|
1208
|
+
}
|
|
1209
|
+
if (!max_quantity) {
|
|
1210
|
+
return true;
|
|
1211
|
+
}
|
|
1212
|
+
return x <= max_quantity;
|
|
1213
|
+
}
|
|
1198
1214
|
function buildConfig(app_config, {
|
|
1199
1215
|
take_profit,
|
|
1200
1216
|
entry,
|
|
@@ -1269,13 +1285,7 @@ function buildAvg({
|
|
|
1269
1285
|
}
|
|
1270
1286
|
function sortedBuildConfig(app_config, options) {
|
|
1271
1287
|
const sorted = buildConfig(app_config, options).sort((a, b) => app_config.kind === "long" ? a.entry - b.entry : b.entry - b.entry).filter((x) => {
|
|
1272
|
-
|
|
1273
|
-
return x.quantity <= 0.03;
|
|
1274
|
-
}
|
|
1275
|
-
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
1276
|
-
return x.quantity <= 2;
|
|
1277
|
-
}
|
|
1278
|
-
return true;
|
|
1288
|
+
return getMaxQuantity(x.quantity, app_config);
|
|
1279
1289
|
});
|
|
1280
1290
|
return sorted.map((k, i) => {
|
|
1281
1291
|
const arrSet = sorted.slice(0, i + 1);
|
package/dist/index.cjs
CHANGED
|
@@ -53499,6 +53499,22 @@ class Signal {
|
|
|
53499
53499
|
}
|
|
53500
53500
|
|
|
53501
53501
|
// src/helpers/shared.ts
|
|
53502
|
+
function getMaxQuantity(x, app_config) {
|
|
53503
|
+
let max_quantity = app_config.max_quantity;
|
|
53504
|
+
if (max_quantity) {
|
|
53505
|
+
return x <= max_quantity;
|
|
53506
|
+
}
|
|
53507
|
+
if (app_config.symbol === "BTCUSDT") {
|
|
53508
|
+
max_quantity = 0.03;
|
|
53509
|
+
}
|
|
53510
|
+
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
53511
|
+
max_quantity = 2;
|
|
53512
|
+
}
|
|
53513
|
+
if (!max_quantity) {
|
|
53514
|
+
return true;
|
|
53515
|
+
}
|
|
53516
|
+
return x <= max_quantity;
|
|
53517
|
+
}
|
|
53502
53518
|
function buildConfig(app_config, {
|
|
53503
53519
|
take_profit,
|
|
53504
53520
|
entry,
|
|
@@ -53573,13 +53589,7 @@ function buildAvg({
|
|
|
53573
53589
|
}
|
|
53574
53590
|
function sortedBuildConfig(app_config, options) {
|
|
53575
53591
|
const sorted = buildConfig(app_config, options).sort((a, b) => app_config.kind === "long" ? a.entry - b.entry : b.entry - b.entry).filter((x) => {
|
|
53576
|
-
|
|
53577
|
-
return x.quantity <= 0.03;
|
|
53578
|
-
}
|
|
53579
|
-
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
53580
|
-
return x.quantity <= 2;
|
|
53581
|
-
}
|
|
53582
|
-
return true;
|
|
53592
|
+
return getMaxQuantity(x.quantity, app_config);
|
|
53583
53593
|
});
|
|
53584
53594
|
return sorted.map((k, i2) => {
|
|
53585
53595
|
const arrSet = sorted.slice(0, i2 + 1);
|
package/dist/index.d.ts
CHANGED
|
@@ -962,6 +962,7 @@ export declare class Strategy {
|
|
|
962
962
|
gap?: number;
|
|
963
963
|
rr?: number;
|
|
964
964
|
max_size?: number;
|
|
965
|
+
max_quantity?: number;
|
|
965
966
|
};
|
|
966
967
|
identifyGapConfig(payload: {
|
|
967
968
|
factor?: number;
|
|
@@ -1218,6 +1219,7 @@ export type AppConfig = {
|
|
|
1218
1219
|
max_size?: number;
|
|
1219
1220
|
last_value?: any;
|
|
1220
1221
|
entries?: any[];
|
|
1222
|
+
max_quantity?: number;
|
|
1221
1223
|
};
|
|
1222
1224
|
export type ExtendConfigType = {
|
|
1223
1225
|
take_profit?: number;
|
|
@@ -2054,6 +2056,7 @@ declare class ExchangeAccount$1 {
|
|
|
2054
2056
|
gap?: number;
|
|
2055
2057
|
rr?: number;
|
|
2056
2058
|
max_size?: number;
|
|
2059
|
+
max_quantity?: number;
|
|
2057
2060
|
}>;
|
|
2058
2061
|
runSimulation(payload: {
|
|
2059
2062
|
symbol: string;
|
|
@@ -2232,6 +2235,7 @@ declare class ExchangeAccount$1 {
|
|
|
2232
2235
|
gap?: number;
|
|
2233
2236
|
rr?: number;
|
|
2234
2237
|
max_size?: number;
|
|
2238
|
+
max_quantity?: number;
|
|
2235
2239
|
};
|
|
2236
2240
|
last_value: any;
|
|
2237
2241
|
config: {
|
|
@@ -2472,6 +2476,7 @@ declare class App {
|
|
|
2472
2476
|
gap?: number;
|
|
2473
2477
|
rr?: number;
|
|
2474
2478
|
max_size?: number;
|
|
2479
|
+
max_quantity?: number;
|
|
2475
2480
|
};
|
|
2476
2481
|
last_value: any;
|
|
2477
2482
|
config: {
|
package/dist/index.js
CHANGED
|
@@ -53449,6 +53449,22 @@ class Signal {
|
|
|
53449
53449
|
}
|
|
53450
53450
|
|
|
53451
53451
|
// src/helpers/shared.ts
|
|
53452
|
+
function getMaxQuantity(x, app_config) {
|
|
53453
|
+
let max_quantity = app_config.max_quantity;
|
|
53454
|
+
if (max_quantity) {
|
|
53455
|
+
return x <= max_quantity;
|
|
53456
|
+
}
|
|
53457
|
+
if (app_config.symbol === "BTCUSDT") {
|
|
53458
|
+
max_quantity = 0.03;
|
|
53459
|
+
}
|
|
53460
|
+
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
53461
|
+
max_quantity = 2;
|
|
53462
|
+
}
|
|
53463
|
+
if (!max_quantity) {
|
|
53464
|
+
return true;
|
|
53465
|
+
}
|
|
53466
|
+
return x <= max_quantity;
|
|
53467
|
+
}
|
|
53452
53468
|
function buildConfig(app_config, {
|
|
53453
53469
|
take_profit,
|
|
53454
53470
|
entry,
|
|
@@ -53523,13 +53539,7 @@ function buildAvg({
|
|
|
53523
53539
|
}
|
|
53524
53540
|
function sortedBuildConfig(app_config, options) {
|
|
53525
53541
|
const sorted = buildConfig(app_config, options).sort((a, b) => app_config.kind === "long" ? a.entry - b.entry : b.entry - b.entry).filter((x) => {
|
|
53526
|
-
|
|
53527
|
-
return x.quantity <= 0.03;
|
|
53528
|
-
}
|
|
53529
|
-
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
53530
|
-
return x.quantity <= 2;
|
|
53531
|
-
}
|
|
53532
|
-
return true;
|
|
53542
|
+
return getMaxQuantity(x.quantity, app_config);
|
|
53533
53543
|
});
|
|
53534
53544
|
return sorted.map((k, i2) => {
|
|
53535
53545
|
const arrSet = sorted.slice(0, i2 + 1);
|
package/dist/mcp-server.cjs
CHANGED
|
@@ -60196,6 +60196,22 @@ class Signal {
|
|
|
60196
60196
|
}
|
|
60197
60197
|
|
|
60198
60198
|
// src/helpers/shared.ts
|
|
60199
|
+
function getMaxQuantity(x, app_config) {
|
|
60200
|
+
let max_quantity = app_config.max_quantity;
|
|
60201
|
+
if (max_quantity) {
|
|
60202
|
+
return x <= max_quantity;
|
|
60203
|
+
}
|
|
60204
|
+
if (app_config.symbol === "BTCUSDT") {
|
|
60205
|
+
max_quantity = 0.03;
|
|
60206
|
+
}
|
|
60207
|
+
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
60208
|
+
max_quantity = 2;
|
|
60209
|
+
}
|
|
60210
|
+
if (!max_quantity) {
|
|
60211
|
+
return true;
|
|
60212
|
+
}
|
|
60213
|
+
return x <= max_quantity;
|
|
60214
|
+
}
|
|
60199
60215
|
function buildConfig(app_config, {
|
|
60200
60216
|
take_profit,
|
|
60201
60217
|
entry,
|
|
@@ -60257,13 +60273,7 @@ function buildConfig(app_config, {
|
|
|
60257
60273
|
}
|
|
60258
60274
|
function sortedBuildConfig(app_config, options) {
|
|
60259
60275
|
const sorted = buildConfig(app_config, options).sort((a, b) => app_config.kind === "long" ? a.entry - b.entry : b.entry - b.entry).filter((x) => {
|
|
60260
|
-
|
|
60261
|
-
return x.quantity <= 0.03;
|
|
60262
|
-
}
|
|
60263
|
-
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
60264
|
-
return x.quantity <= 2;
|
|
60265
|
-
}
|
|
60266
|
-
return true;
|
|
60276
|
+
return getMaxQuantity(x.quantity, app_config);
|
|
60267
60277
|
});
|
|
60268
60278
|
return sorted.map((k, i2) => {
|
|
60269
60279
|
const arrSet = sorted.slice(0, i2 + 1);
|
package/dist/mcp-server.js
CHANGED
|
@@ -60173,6 +60173,22 @@ class Signal {
|
|
|
60173
60173
|
}
|
|
60174
60174
|
|
|
60175
60175
|
// src/helpers/shared.ts
|
|
60176
|
+
function getMaxQuantity(x, app_config) {
|
|
60177
|
+
let max_quantity = app_config.max_quantity;
|
|
60178
|
+
if (max_quantity) {
|
|
60179
|
+
return x <= max_quantity;
|
|
60180
|
+
}
|
|
60181
|
+
if (app_config.symbol === "BTCUSDT") {
|
|
60182
|
+
max_quantity = 0.03;
|
|
60183
|
+
}
|
|
60184
|
+
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
60185
|
+
max_quantity = 2;
|
|
60186
|
+
}
|
|
60187
|
+
if (!max_quantity) {
|
|
60188
|
+
return true;
|
|
60189
|
+
}
|
|
60190
|
+
return x <= max_quantity;
|
|
60191
|
+
}
|
|
60176
60192
|
function buildConfig(app_config, {
|
|
60177
60193
|
take_profit,
|
|
60178
60194
|
entry,
|
|
@@ -60234,13 +60250,7 @@ function buildConfig(app_config, {
|
|
|
60234
60250
|
}
|
|
60235
60251
|
function sortedBuildConfig(app_config, options) {
|
|
60236
60252
|
const sorted = buildConfig(app_config, options).sort((a, b) => app_config.kind === "long" ? a.entry - b.entry : b.entry - b.entry).filter((x) => {
|
|
60237
|
-
|
|
60238
|
-
return x.quantity <= 0.03;
|
|
60239
|
-
}
|
|
60240
|
-
if (app_config.symbol?.toLowerCase().startsWith("sol")) {
|
|
60241
|
-
return x.quantity <= 2;
|
|
60242
|
-
}
|
|
60243
|
-
return true;
|
|
60253
|
+
return getMaxQuantity(x.quantity, app_config);
|
|
60244
60254
|
});
|
|
60245
60255
|
return sorted.map((k, i2) => {
|
|
60246
60256
|
const arrSet = sorted.slice(0, i2 + 1);
|