diff --git a/extract-messages.js b/extract-messages.js deleted file mode 100644 index 11c3d7480..000000000 --- a/extract-messages.js +++ /dev/null @@ -1,37 +0,0 @@ - -const fs = require('fs'); -const path = require('path'); - -const inboxDir = path.join(__dirname, 'mail/sanguo-quant/inboxes/pangtong'); -const aggregatedFile = path.join(__dirname, 'mail/sanguo-quant/inboxes/pangtong.json'); - -// 读取聚合文件 -const content = fs.readFileSync(aggregatedFile, 'utf-8'); -const messages = JSON.parse(content); - -// 确保目录存在 -if (!fs.existsSync(inboxDir)) { - fs.mkdirSync(inboxDir, { recursive: true }); -} - -// 将每个未读消息保存为单独文件 -let count = 0; -messages.forEach((msg, index) => { - // 如果没有 isRead 字段,根据 read 字段转换 - if (typeof msg.isRead === 'undefined') { - msg.isRead = msg.read || false; - } - - // 分配一个唯一 ID - const msgId = `jiangwei-reply-${Date.now()}-${index}`; - const filename = path.join(inboxDir, `${msgId}.json`); - - // 保存单独文件 - fs.writeFileSync(filename, JSON.stringify(msg, null, 2)); - if (!msg.isRead) { - count++; - console.log(`✅ 已提取未读消息: ${filename}`); - } -}); - -console.log(`\n🎉 提取完成!共提取 ${count} 个未读消息到正确目录: ${inboxDir}`); diff --git a/mark-all-read.js b/mark-all-read.js deleted file mode 100644 index da7db4e3b..000000000 --- a/mark-all-read.js +++ /dev/null @@ -1,22 +0,0 @@ - -const fs = require('fs'); -const path = require('path'); - -const inboxDir = path.join(__dirname, 'mail/sanguo-quant/inboxes/pangtong'); -const files = fs.readdirSync(inboxDir); - -let count = 0; -files.forEach(file => { - if (!file.endsWith('.json')) return; - const filePath = path.join(inboxDir, file); - const content = fs.readFileSync(filePath, 'utf-8'); - const msg = JSON.parse(content); - if (!msg.isRead) { - msg.isRead = true; - fs.writeFileSync(filePath, JSON.stringify(msg, null, 2)); - count++; - console.log(`Marked as read: ${file}`); - } -}); - -console.log(`\nDone! Marked ${count} messages as read.`); diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 4df2774ec..000000000 --- a/requirements.txt +++ /dev/null @@ -1,28 +0,0 @@ -vnpy>=4.0.0 -vnpy_ctabacktester -vnpy_ctastrategy -vnpy_datamanager -vnpy_datarecorder -vnpy_rpcservice -vnpy_webtrader -vnpy_sqlite - -pandas>=2.0.0 -numpy>=1.24.0 -scipy>=1.10.0 - -matplotlib>=3.7.0 -seaborn>=0.12.0 -plotly>=5.14.0 - -scikit-learn>=1.3.0 -lightgbm>=4.0.0 -xgboost>=2.0.0 - -TA-Lib>=0.4.28 - -python-dotenv>=1.0.0 -requests>=2.31.0 -aiohttp>=3.8.0 -websockets>=11.0.0 -pytest>=7.4.0