@zhin.js/plugin-lottery 2.0.2 → 2.0.3
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/commands/lottery/{[game:string=].js → [[game]].js} +1 -0
- package/commands/lottery/{[game:string=].ts → [[game]].ts} +1 -0
- package/commands/lottery-backtest/{[game:string=].js → [[game]].js} +1 -0
- package/commands/lottery-backtest/{[game:string=].ts → [[game]].ts} +1 -0
- package/commands/lottery-history/{[game:string].js → [game].js} +1 -0
- package/commands/lottery-history/{[game:string].ts → [game].ts} +1 -0
- package/commands/lottery-stats/{[game:string].js → [game].js} +1 -0
- package/commands/lottery-stats/{[game:string].ts → [game].ts} +1 -0
- package/commands/lottery-train/{[game:string=].js → [[game]].js} +1 -0
- package/commands/lottery-train/{[game:string=].ts → [[game]].ts} +1 -0
- package/package.json +5 -5
- package/plugin.js +4 -2
|
@@ -5,6 +5,7 @@ import { buildPipelineDeps, formatPipelineReply, getLotteryDb, runLotteryPipelin
|
|
|
5
5
|
import { resolveLotteryRuntime } from "../../lib/runtime-state.js";
|
|
6
6
|
export default defineCommand({
|
|
7
7
|
description: 'Run full pipeline: sync → review → recommend (manual, no push)',
|
|
8
|
+
params: { game: { type: 'string', default: '' } },
|
|
8
9
|
async execute({ params, config, owner, use }) {
|
|
9
10
|
const cfg = resolveLotteryConfig(config);
|
|
10
11
|
const gid = parseGameId(String(params.game ?? ''));
|
|
@@ -12,6 +12,7 @@ import { resolveLotteryRuntime } from '../../src/runtime-state.js';
|
|
|
12
12
|
|
|
13
13
|
export default defineCommand<LotteryConfig>({
|
|
14
14
|
description: 'Run full pipeline: sync → review → recommend (manual, no push)',
|
|
15
|
+
params: { game: { type: 'string', default: '' } },
|
|
15
16
|
async execute({ params, config, owner, use }) {
|
|
16
17
|
const cfg = resolveLotteryConfig(config);
|
|
17
18
|
const gid = parseGameId(String(params.game ?? ''));
|
|
@@ -7,6 +7,7 @@ import { lotteryEnabledGames } from "../../lib/config.js";
|
|
|
7
7
|
import { resolveLotteryRuntime } from "../../lib/runtime-state.js";
|
|
8
8
|
export default defineCommand({
|
|
9
9
|
description: 'Walk-forward backtest vs random baseline',
|
|
10
|
+
params: { game: { type: 'string', default: '' } },
|
|
10
11
|
async execute({ params, config, owner, use }) {
|
|
11
12
|
const db = resolveLotteryRuntime({ owner, use })?.db ?? getLotteryDb();
|
|
12
13
|
if (!db)
|
|
@@ -14,6 +14,7 @@ import { resolveLotteryRuntime } from '../../src/runtime-state.js';
|
|
|
14
14
|
|
|
15
15
|
export default defineCommand<LotteryConfig>({
|
|
16
16
|
description: 'Walk-forward backtest vs random baseline',
|
|
17
|
+
params: { game: { type: 'string', default: '' } },
|
|
17
18
|
async execute({ params, config, owner, use }) {
|
|
18
19
|
const db = resolveLotteryRuntime({ owner, use })?.db ?? getLotteryDb();
|
|
19
20
|
if (!db) return '数据库未就绪';
|
|
@@ -6,6 +6,7 @@ import { getLotteryDb } from "../../lib/command-helpers.js";
|
|
|
6
6
|
import { resolveLotteryRuntime } from "../../lib/runtime-state.js";
|
|
7
7
|
export default defineCommand({
|
|
8
8
|
description: 'List historical draw results',
|
|
9
|
+
params: { game: { type: 'string' } },
|
|
9
10
|
async execute({ params, args, owner, use }) {
|
|
10
11
|
const gid = parseGameId(String(params.game ?? ''));
|
|
11
12
|
if (!gid)
|
|
@@ -6,6 +6,7 @@ import { resolveLotteryRuntime } from '../../src/runtime-state.js';
|
|
|
6
6
|
|
|
7
7
|
export default defineCommand<LotteryConfig>({
|
|
8
8
|
description: 'List historical draw results',
|
|
9
|
+
params: { game: { type: 'string' } },
|
|
9
10
|
async execute({ params, args, owner, use }) {
|
|
10
11
|
const gid = parseGameId(String(params.game ?? ''));
|
|
11
12
|
if (!gid) return '请指定玩法';
|
|
@@ -9,6 +9,7 @@ import { lotteryKl8 } from "../../lib/config.js";
|
|
|
9
9
|
import { resolveLotteryRuntime } from "../../lib/runtime-state.js";
|
|
10
10
|
export default defineCommand({
|
|
11
11
|
description: 'Single-game stats snapshot',
|
|
12
|
+
params: { game: { type: 'string' } },
|
|
12
13
|
async execute({ params, config, owner, use }) {
|
|
13
14
|
const gid = parseGameId(String(params.game ?? ''));
|
|
14
15
|
if (!gid)
|
|
@@ -13,6 +13,7 @@ import { resolveLotteryRuntime } from '../../src/runtime-state.js';
|
|
|
13
13
|
|
|
14
14
|
export default defineCommand<LotteryConfig>({
|
|
15
15
|
description: 'Single-game stats snapshot',
|
|
16
|
+
params: { game: { type: 'string' } },
|
|
16
17
|
async execute({ params, config, owner, use }) {
|
|
17
18
|
const gid = parseGameId(String(params.game ?? ''));
|
|
18
19
|
if (!gid) return '请指定玩法';
|
|
@@ -7,6 +7,7 @@ import { lotteryEnabledGames } from "../../lib/config.js";
|
|
|
7
7
|
import { resolveLotteryRuntime } from "../../lib/runtime-state.js";
|
|
8
8
|
export default defineCommand({
|
|
9
9
|
description: 'Full-history weight training',
|
|
10
|
+
params: { game: { type: 'string', default: '' } },
|
|
10
11
|
async execute({ params, config, owner, use }) {
|
|
11
12
|
const db = resolveLotteryRuntime({ owner, use })?.db ?? getLotteryDb();
|
|
12
13
|
if (!db)
|
|
@@ -14,6 +14,7 @@ import { resolveLotteryRuntime } from '../../src/runtime-state.js';
|
|
|
14
14
|
|
|
15
15
|
export default defineCommand<LotteryConfig>({
|
|
16
16
|
description: 'Full-history weight training',
|
|
17
|
+
params: { game: { type: 'string', default: '' } },
|
|
17
18
|
async execute({ params, config, owner, use }) {
|
|
18
19
|
const db = resolveLotteryRuntime({ owner, use })?.db ?? getLotteryDb();
|
|
19
20
|
if (!db) return '数据库未就绪';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zhin.js/plugin-lottery",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.3",
|
|
4
4
|
"description": "Multi-game lottery analysis for Zhin.js (Plugin Runtime)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./lib/index.js",
|
|
@@ -41,18 +41,18 @@
|
|
|
41
41
|
},
|
|
42
42
|
"license": "MIT",
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@zhin.js/command": "1.0.
|
|
45
|
-
"@zhin.js/plugin-runtime": "1.1.
|
|
44
|
+
"@zhin.js/command": "1.0.7",
|
|
45
|
+
"@zhin.js/plugin-runtime": "1.1.3"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"typescript": "^6.0.3",
|
|
49
49
|
"vitest": "^4.1.10",
|
|
50
50
|
"zod": "^4.4.3",
|
|
51
|
-
"@zhin.js/agent": "1.1.
|
|
51
|
+
"@zhin.js/agent": "1.1.3"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
54
|
"zod": "^4.0.0",
|
|
55
|
-
"@zhin.js/agent": "1.1.
|
|
55
|
+
"@zhin.js/agent": "1.1.3"
|
|
56
56
|
},
|
|
57
57
|
"peerDependenciesMeta": {
|
|
58
58
|
"@zhin.js/agent": {
|
package/plugin.js
CHANGED
|
@@ -38,8 +38,10 @@ export default definePlugin({
|
|
|
38
38
|
await outbound.send({
|
|
39
39
|
adapter: target.adapter,
|
|
40
40
|
endpointId: target.endpointId || target.adapter,
|
|
41
|
-
|
|
42
|
-
|
|
41
|
+
conversation: {
|
|
42
|
+
kind: (target.channelType || 'private'),
|
|
43
|
+
id: target.channelId,
|
|
44
|
+
},
|
|
43
45
|
content: text,
|
|
44
46
|
});
|
|
45
47
|
}
|