hedgequantx 2.7.85 → 2.7.86

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hedgequantx",
3
- "version": "2.7.85",
3
+ "version": "2.7.86",
4
4
  "description": "HedgeQuantX - Prop Futures Trading CLI",
5
5
  "main": "src/app.js",
6
6
  "bin": {
@@ -30,21 +30,28 @@ const algoTradingMenu = async (service) => {
30
30
  console.log(chalk.cyan('║') + chalk.magenta.bold(centerText('ALGO-TRADING', W)) + chalk.cyan('║'));
31
31
  console.log(chalk.cyan('╠' + '═'.repeat(W) + '╣'));
32
32
 
33
- // Options centered in 2 columns
33
+ // 3 columns layout
34
34
  const col1 = '[1] ONE ACCOUNT';
35
35
  const col2 = '[2] COPY TRADING';
36
- const colWidth = Math.floor(W / 2);
36
+ const col3 = '[3] CUSTOM STRATEGY';
37
+ const colWidth = Math.floor(W / 3);
38
+ const lastColWidth = W - 2 * colWidth;
39
+
37
40
  const pad1 = Math.floor((colWidth - col1.length) / 2);
38
41
  const pad2 = Math.floor((colWidth - col2.length) / 2);
39
- const line = ' '.repeat(pad1) + chalk.cyan(col1) + ' '.repeat(colWidth - col1.length - pad1) +
40
- ' '.repeat(pad2) + chalk.cyan(col2) + ' '.repeat(colWidth - col2.length - pad2);
41
- console.log(chalk.cyan('║') + line + chalk.cyan('║'));
42
+ const pad3 = Math.floor((lastColWidth - col3.length) / 2);
43
+
44
+ const col1Str = ' '.repeat(pad1) + chalk.cyan(col1) + ' '.repeat(colWidth - col1.length - pad1);
45
+ const col2Str = ' '.repeat(pad2) + chalk.yellow(col2) + ' '.repeat(colWidth - col2.length - pad2);
46
+ const col3Str = ' '.repeat(pad3) + chalk.green(col3) + ' '.repeat(lastColWidth - col3.length - pad3);
47
+
48
+ console.log(chalk.cyan('║') + col1Str + col2Str + col3Str + chalk.cyan('║'));
42
49
 
43
50
  console.log(chalk.cyan('╠' + '─'.repeat(W) + '╣'));
44
51
  console.log(chalk.cyan('║') + chalk.red(centerText('[B] BACK', W)) + chalk.cyan('║'));
45
52
  console.log(chalk.cyan('╚' + '═'.repeat(W) + '╝'));
46
53
 
47
- const input = await prompts.textInput(chalk.cyan('SELECT (1/2/B): '));
54
+ const input = await prompts.textInput(chalk.cyan('SELECT (1/2/3/B): '));
48
55
  const choice = (input || '').toLowerCase().trim();
49
56
 
50
57
  log.debug('Algo mode selected', { choice });
@@ -62,6 +69,10 @@ const algoTradingMenu = async (service) => {
62
69
  log.info('Starting Copy Trading mode');
63
70
  await copyTradingMenu();
64
71
  break;
72
+ case '3':
73
+ log.info('Starting Custom Strategy mode');
74
+ await customStrategyMenu(service);
75
+ break;
65
76
  default:
66
77
  console.log(chalk.red(' INVALID OPTION'));
67
78
  await new Promise(r => setTimeout(r, 1000));
@@ -76,4 +87,27 @@ const algoTradingMenu = async (service) => {
76
87
  }
77
88
  };
78
89
 
90
+ /**
91
+ * Custom Strategy Menu - AI-powered strategy creation
92
+ */
93
+ const customStrategyMenu = async (service) => {
94
+ console.clear();
95
+ displayBanner();
96
+
97
+ const boxWidth = getLogoWidth();
98
+ const W = boxWidth - 2;
99
+
100
+ console.log(chalk.cyan('╔' + '═'.repeat(W) + '╗'));
101
+ console.log(chalk.cyan('║') + chalk.green.bold(centerText('CUSTOM STRATEGY', W)) + chalk.cyan('║'));
102
+ console.log(chalk.cyan('╠' + '═'.repeat(W) + '╣'));
103
+ console.log(chalk.cyan('║') + centerText('Create your own trading strategy with AI assistance', W) + chalk.cyan('║'));
104
+ console.log(chalk.cyan('╠' + '─'.repeat(W) + '╣'));
105
+ console.log(chalk.cyan('║') + chalk.gray(centerText('Coming soon...', W)) + chalk.cyan('║'));
106
+ console.log(chalk.cyan('╠' + '─'.repeat(W) + '╣'));
107
+ console.log(chalk.cyan('║') + chalk.red(centerText('[B] BACK', W)) + chalk.cyan('║'));
108
+ console.log(chalk.cyan('╚' + '═'.repeat(W) + '╝'));
109
+
110
+ await prompts.waitForEnter();
111
+ };
112
+
79
113
  module.exports = { algoTradingMenu };