dsh-multigameassistant 2.2.0 → 2.2.1

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/lib/feishu.js CHANGED
@@ -2,7 +2,7 @@ import { createRequire as __adgCreateRequire } from 'node:module'; import { dirn
2
2
  import {
3
3
  replyMarkdown,
4
4
  replyPlain
5
- } from "./chunk-I4NHWXKH.js";
5
+ } from "./chunk-YSTZL6HE.js";
6
6
  import {
7
7
  require_extension,
8
8
  require_permessage_deflate,
@@ -12,8 +12,8 @@ import {
12
12
  require_subprotocol,
13
13
  require_websocket,
14
14
  require_websocket_server
15
- } from "./chunk-KTOQFJ7R.js";
16
- import "./chunk-ICJLH3DP.js";
15
+ } from "./chunk-OFVGRKTD.js";
16
+ import "./chunk-52LYI7WP.js";
17
17
  import {
18
18
  writeFileAtomic
19
19
  } from "./chunk-RESS7WVY.js";
@@ -22,7 +22,7 @@ import {
22
22
  FEISHU_SECRET_REF,
23
23
  FeishuPending,
24
24
  FeishuSettings
25
- } from "./chunk-NEUZQ7TI.js";
25
+ } from "./chunk-F7ZQE7BT.js";
26
26
  import {
27
27
  external_exports
28
28
  } from "./chunk-6DSSLS7I.js";
package/lib/game-intel.js CHANGED
@@ -4,12 +4,12 @@ import {
4
4
  GAME_MANIFEST_FILE,
5
5
  GameManifest,
6
6
  parseGameManifest
7
- } from "./chunk-26JIEF6M.js";
7
+ } from "./chunk-IBPJC6DX.js";
8
8
  import {
9
9
  sessionConversations
10
- } from "./chunk-I4NHWXKH.js";
11
- import "./chunk-KTOQFJ7R.js";
12
- import "./chunk-ICJLH3DP.js";
10
+ } from "./chunk-YSTZL6HE.js";
11
+ import "./chunk-OFVGRKTD.js";
12
+ import "./chunk-52LYI7WP.js";
13
13
  import {
14
14
  ExeIcons,
15
15
  writeFileAtomic
@@ -23,7 +23,7 @@ import {
23
23
  SCREEN_SOURCE,
24
24
  SHOT_IMAGE,
25
25
  taskMessage
26
- } from "./chunk-NEUZQ7TI.js";
26
+ } from "./chunk-F7ZQE7BT.js";
27
27
  import {
28
28
  external_exports
29
29
  } from "./chunk-6DSSLS7I.js";
@@ -32,7 +32,7 @@ import "./chunk-2UFLGPDY.js";
32
32
  // packages/game-intel/lib/index.js
33
33
  import { createHash as createHash2 } from "node:crypto";
34
34
  import { existsSync } from "node:fs";
35
- import { mkdir as mkdir2, readdir, readFile as readFile2, rm, writeFile } from "node:fs/promises";
35
+ import { mkdir as mkdir2, readdir, readFile as readFile2, rm, stat, writeFile } from "node:fs/promises";
36
36
  import { isAbsolute, join as join2, resolve } from "node:path";
37
37
  import { Service } from "@deepseek-ai/cordis";
38
38
 
@@ -194,8 +194,10 @@ var StoredSchema = external_exports.object({
194
194
  report: GamesSettings.shape.report.partial().default({}),
195
195
  followed: external_exports.array(external_exports.string()).default([]),
196
196
  /** Game packs taken off the game page (the pack stays installed). */
197
- hidden: external_exports.array(external_exports.string()).default([])
198
- }).default({ report: {}, followed: [], hidden: [] }),
197
+ hidden: external_exports.array(external_exports.string()).default([]),
198
+ /** The picture the user chose for a game's banner (`own:<file>`), by game. */
199
+ banners: external_exports.record(external_exports.string(), external_exports.string()).default({})
200
+ }).default({ report: {}, followed: [], hidden: [], banners: {} }),
199
201
  /** Pages the user added to a game (games/source/add), by game. */
200
202
  links: external_exports.record(external_exports.string(), external_exports.array(external_exports.object({ id: external_exports.string(), name: external_exports.string(), url: external_exports.string(), at: external_exports.number() }))).default({}),
201
203
  /** Announcements (version updates, long-term notices, news), by game. */
@@ -204,7 +206,7 @@ var StoredSchema = external_exports.object({
204
206
  var Calendar = class {
205
207
  #dir;
206
208
  #items = [];
207
- #saved = { refreshed: {}, readings: {}, report: {}, settings: { report: {}, followed: [], hidden: [] }, versions: {}, pools: {}, links: {}, notices: {} };
209
+ #saved = { refreshed: {}, readings: {}, report: {}, settings: { report: {}, followed: [], hidden: [], banners: {} }, versions: {}, pools: {}, links: {}, notices: {} };
208
210
  constructor(dir) {
209
211
  this.#dir = dir;
210
212
  }
@@ -313,6 +315,19 @@ var Calendar = class {
313
315
  this.#saved.settings.hidden = hidden ? [...list, gameId] : list;
314
316
  await this.save();
315
317
  }
318
+ /** The picture the user chose for a game's banner (`own:<file>`); undefined: the version's art. */
319
+ banner(gameId) {
320
+ const image = this.#saved.settings.banners[gameId];
321
+ return image !== void 0 && OWN_IMAGE.test(image) ? image : void 0;
322
+ }
323
+ /** Show the user's picture on a game's banner (`own:<file>`), or the version's art again (undefined). */
324
+ async setBanner(gameId, image) {
325
+ if (image !== void 0 && !OWN_IMAGE.test(image))
326
+ throw new Error(`\u4E0D\u662F\u7528\u6237\u6DFB\u52A0\u7684\u56FE\u7247\uFF1A${image}`);
327
+ const { [gameId]: _, ...rest } = this.#saved.settings.banners;
328
+ this.#saved.settings.banners = image === void 0 ? rest : { ...rest, [gameId]: image };
329
+ await this.save();
330
+ }
316
331
  /** Forget everything about a game (one made here that is deleted): its events, readings, version, pools and pages. */
317
332
  async forget(gameId) {
318
333
  this.#items = this.#items.filter((a) => a.game !== gameId);
@@ -324,6 +339,7 @@ var Calendar = class {
324
339
  delete this.#saved.links[gameId];
325
340
  delete this.#saved.notices[gameId];
326
341
  this.#saved.settings.hidden = this.#saved.settings.hidden.filter((id) => id !== gameId);
342
+ delete this.#saved.settings.banners[gameId];
327
343
  await this.save();
328
344
  }
329
345
  /** Announcements (of one game, or all): the long-term ones first, then the newest. */
@@ -656,9 +672,9 @@ var Calendar = class {
656
672
  this.#derive(item, timeZone(item.game));
657
673
  await this.save();
658
674
  }
659
- /** The pictures the user added that an event still shows (`own:<file>`). */
675
+ /** The pictures the user added that an event or a game's banner still shows (`own:<file>`). */
660
676
  ownImages() {
661
- const out = /* @__PURE__ */ new Set();
677
+ const out = new Set(Object.values(this.#saved.settings.banners).filter((b) => OWN_IMAGE.test(b)));
662
678
  for (const a of this.#items)
663
679
  if (a.mine?.cover?.startsWith("own:") === true)
664
680
  out.add(a.mine.cover);
@@ -1466,6 +1482,8 @@ function gameTools(deps) {
1466
1482
  guide: { type: "string", description: "GAME.md \u6B63\u6587\uFF08\u53EF\u9009\uFF09\uFF1A\u54EA\u4E9B\u6765\u6E90\u770B\u4EC0\u4E48\u3001\u516C\u544A\u9875\u600E\u4E48\u627E\u6D3B\u52A8\u3002" }
1467
1483
  },
1468
1484
  required: ["id", "name", "sources"],
1485
+ // The sources the plugin reads itself are read before it returns.
1486
+ timeoutMs: 12e4,
1469
1487
  kind: "other",
1470
1488
  title: (a) => `\u6DFB\u52A0\u6E38\u620F\uFF1A${String(a["name"] ?? a["id"] ?? "")}`,
1471
1489
  execute: async (args) => {
@@ -1495,8 +1513,16 @@ function gameTools(deps) {
1495
1513
  ...s.steam_appid == null ? {} : { steam: { appid: s.steam_appid } }
1496
1514
  }))
1497
1515
  };
1498
- const game = await deps.add(manifest, a.guide ?? void 0);
1499
- return { added: game.id, name: game.name, sources: game.sources.map((s) => `${s.name}\uFF08${s.auto ? "\u81EA\u52A8\u8BFB" : "agent \u8BFB"}\uFF09`), note: "\u5DF2\u52A0\u5230\u6E38\u620F\u9875\uFF1B\u80FD\u81EA\u52A8\u8BFB\u7684\u6765\u6E90\u6B63\u5728\u8BFB\u53D6" };
1516
+ const { game, read } = await deps.add(manifest, a.guide ?? void 0);
1517
+ return {
1518
+ added: game.id,
1519
+ name: game.name,
1520
+ sources: game.sources.map((s) => `${s.name}\uFF08${s.auto ? "\u81EA\u52A8\u8BFB" : "agent \u8BFB"}\uFF09`),
1521
+ ...read === void 0 ? { note: "\u5DF2\u52A0\u5230\u6E38\u620F\u9875\uFF1B\u6CA1\u6709\u80FD\u81EA\u52A8\u8BFB\u7684\u6765\u6E90\uFF0C\u516C\u544A\u548C\u6D3B\u52A8\u8981 agent \u8BFB" } : {
1522
+ read_now: { activities: read.count, notices: read.notices ?? 0, ...read.detail === void 0 ? {} : { failed: read.detail } },
1523
+ note: `\u5DF2\u52A0\u5230\u6E38\u620F\u9875\uFF0C\u80FD\u81EA\u52A8\u8BFB\u7684\u6765\u6E90\u5DF2\u7ECF\u8BFB\u4E86\u4E00\u6B21\uFF1A${read.count} \u4E2A\u6D3B\u52A8\u3001${read.notices ?? 0} \u6761\u516C\u544A\uFF08\u4EE5\u540E\u6BCF\u5929\u81EA\u52A8\u8BFB\uFF09\u3002\u8FD9\u4E9B\u4E0D\u7528\u518D\u7528 game_record / game_notice \u8BB0\uFF1B\u53EA\u8BFB agent \u8BFB\u7684\u6765\u6E90\u3002`
1524
+ }
1525
+ };
1500
1526
  }
1501
1527
  }),
1502
1528
  tool({
@@ -1640,7 +1666,8 @@ function gameTools(deps) {
1640
1666
  description: [
1641
1667
  "\u628A\u8BFB\u5230\u7684\u516C\u544A\u8BB0\u5230\u6E38\u620F\u9875\u7684\u300C\u516C\u544A\u300D\u91CC\uFF0C\u5B83\u4EEC\u4E0D\u662F\u6709\u8D77\u6B62\u65F6\u95F4\u7684\u9650\u65F6\u6D3B\u52A8\uFF08\u9650\u65F6\u6D3B\u52A8\u7528 game_record\uFF09\uFF1A",
1642
1668
  "kind=update \u7248\u672C\u66F4\u65B0\u3001\u8865\u4E01\u8BF4\u660E\uFF08\u5199\u4E0A\u7248\u672C\u53F7\uFF09\uFF1Bkind=notice \u516C\u544A\uFF0C\u957F\u671F\u6709\u6548\u7684\uFF08\u5E38\u9A7B\u89C4\u5219\u3001\u957F\u671F\u6D3B\u52A8\u8BF4\u660E\u3001\u505C\u670D / \u7EF4\u62A4\u5B89\u6392\uFF09\u5199 lasting=true\uFF0C\u4F1A\u4E00\u76F4\u7559\u5728\u6700\u524D\u9762\uFF1Bkind=news \u5176\u4ED6\u8D44\u8BAF\u3002",
1643
- "\u5355\u673A\u6E38\u620F\u4E3B\u8981\u8BB0\u8FD9\u4E2A\u3002\u540C\u4E00\u4E2A\u7F51\u5740\uFF08\u6CA1\u6709\u7F51\u5740\u65F6\u540C\u4E00\u4E2A\u6807\u9898\uFF09\u518D\u8BB0\u5C31\u662F\u66F4\u65B0\u539F\u6765\u90A3\u6761\uFF1Blasting=false \u53EF\u4EE5\u628A\u957F\u671F\u516C\u544A\u6536\u56DE\u3002\u53EA\u8BB0\u6709\u51FA\u5904\u7684\u5185\u5BB9\uFF0Csummary \u7528\u4E00\u4E24\u53E5\u4E2D\u6587\u5199\u6E05\u695A\u6539\u4E86\u4EC0\u4E48\u3002"
1669
+ "\u5355\u673A\u6E38\u620F\u4E3B\u8981\u8BB0\u8FD9\u4E2A\u3002\u516C\u544A\u5217\u8868\u4E0A\u6700\u8FD1\u7684\u6BCF\u4E00\u7BC7\u90FD\u8BB0\uFF08\u6807\u9898\u3001\u65E5\u671F\u3001\u7F51\u5740\u7167\u5217\u8868\u5199\uFF09\uFF0C\u4E0D\u662F\u53EA\u8BB0\u70B9\u5F00\u8BFB\u8FC7\u7684\uFF1B\u8BFB\u8FC7\u5168\u6587\u7684\u5199 summary\uFF0C\u7528\u4E00\u4E24\u53E5\u4E2D\u6587\u5199\u6E05\u695A\u6539\u4E86\u4EC0\u4E48\u3002",
1670
+ "\u540C\u4E00\u4E2A\u7F51\u5740\uFF08\u6CA1\u6709\u7F51\u5740\u65F6\u540C\u4E00\u4E2A\u6807\u9898\uFF09\u518D\u8BB0\u5C31\u662F\u66F4\u65B0\u539F\u6765\u90A3\u6761\uFF1Blasting=false \u53EF\u4EE5\u628A\u957F\u671F\u516C\u544A\u6536\u56DE\u3002\u53EA\u8BB0\u6709\u51FA\u5904\u7684\u5185\u5BB9\u3002"
1644
1671
  ].join(""),
1645
1672
  properties: {
1646
1673
  game: GAME,
@@ -1844,6 +1871,7 @@ function gameTools(deps) {
1844
1871
  }
1845
1872
 
1846
1873
  // packages/game-intel/lib/index.js
1874
+ var readsItself = (s) => s.smw !== void 0 || s.sra !== void 0 || s.steam !== void 0;
1847
1875
  var ConfigSchema = external_exports.object({
1848
1876
  /** The calendar and screenshots: `<dataDir>/games/`; the user's Game Packs: `<dataDir>/games/<id>/game.yaml`. */
1849
1877
  dataDir: external_exports.string().min(1),
@@ -2077,6 +2105,13 @@ var AdgGameIntel = class extends Service {
2077
2105
  await this.ready;
2078
2106
  return this.picture(params.url);
2079
2107
  },
2108
+ "games/banner/set": async (params) => {
2109
+ await this.ready;
2110
+ const p = params;
2111
+ const image = p.image !== void 0 ? Buffer.from(p.image.data, "base64") : p.path !== void 0 ? await this.imageFile(p.path) : void 0;
2112
+ const banner = await this.setBanner(p.game, image);
2113
+ return banner === void 0 ? {} : { banner };
2114
+ },
2080
2115
  "games/source/add": async (params) => {
2081
2116
  await this.ready;
2082
2117
  const p = params;
@@ -2271,6 +2306,31 @@ var AdgGameIntel = class extends Service {
2271
2306
  throw new Error("\u4EC0\u4E48\u90FD\u6CA1\u7559\u4E0B\uFF1A\u8FD9\u4E2A\u6D3B\u52A8\u53EA\u6709\u4F60\u586B\u7684\u5185\u5BB9\uFF0C\u6E05\u7A7A\u540E\u5C31\u4ECE\u65E5\u5386\u53BB\u6389\u4E86");
2272
2307
  return activity;
2273
2308
  }
2309
+ /**
2310
+ * The picture the user picked for a game's banner, kept under
2311
+ * `<data>/games/images/own/`; undefined: the version's art again (the old
2312
+ * picture is let go). @returns its address (`own:<hash>.<ext>`).
2313
+ */
2314
+ async setBanner(gameId, image) {
2315
+ const { manifest } = this.game(gameId);
2316
+ const banner = image === void 0 ? void 0 : await this.keepImage(image);
2317
+ await this.calendar.setBanner(manifest.id, banner);
2318
+ await this.sweepImages();
2319
+ this.changed(manifest.id);
2320
+ return banner;
2321
+ }
2322
+ /** A picture file the user picked in a file dialog on this computer. @throws Error when it is not one, or too big. */
2323
+ async imageFile(path) {
2324
+ const full = path.replace(/^"|"$/g, "");
2325
+ if (!isAbsolute(full))
2326
+ throw new Error("\u56FE\u7247\u8DEF\u5F84\u8981\u662F\u5B8C\u6574\u8DEF\u5F84");
2327
+ const info = await stat(full).catch(() => void 0);
2328
+ if (info === void 0 || !info.isFile())
2329
+ throw new Error(`\u627E\u4E0D\u5230\u56FE\u7247\u6587\u4EF6\uFF1A${full}`);
2330
+ if (info.size > MAX_IMAGE_BYTES)
2331
+ throw new Error("\u56FE\u7247\u592A\u5927\uFF08\u6700\u591A 8 MB\uFF09");
2332
+ return readFile2(full);
2333
+ }
2274
2334
  timezone(game) {
2275
2335
  return this.games.find((g) => g.manifest.id === game)?.manifest.timezone ?? "Asia/Shanghai";
2276
2336
  }
@@ -2502,6 +2562,7 @@ var AdgGameIntel = class extends Service {
2502
2562
  const webReading = this.calendar.reading(`${m.id}#web`);
2503
2563
  const version = this.calendar.version(m.id);
2504
2564
  const pools = this.calendar.pools(m.id, this.clock.now());
2565
+ const banner = this.calendar.banner(m.id);
2505
2566
  return {
2506
2567
  id: m.id,
2507
2568
  name: m.name,
@@ -2509,9 +2570,10 @@ var AdgGameIntel = class extends Service {
2509
2570
  scripts: scripts.get(m.id) ?? m.scripts,
2510
2571
  timezone: m.timezone,
2511
2572
  ...m.screen === void 0 ? {} : { screen: { target: m.screen.target, ...m.screen.window === void 0 ? {} : { window: m.screen.window } } },
2512
- sources: m.sources.map((s) => ({ id: s.id, name: s.name, ...s.homepage === void 0 ? {} : { homepage: s.homepage }, auto: s.smw !== void 0 || s.sra !== void 0 || s.steam !== void 0, .../^link-\d+$/.test(s.id) && this.calendar.links(m.id).some((l) => l.id === s.id) ? { added: true } : {} })),
2573
+ sources: m.sources.map((s) => ({ id: s.id, name: s.name, ...s.homepage === void 0 ? {} : { homepage: s.homepage }, auto: readsItself(s), .../^link-\d+$/.test(s.id) && this.calendar.links(m.id).some((l) => l.id === s.id) ? { added: true } : {} })),
2513
2574
  builtin,
2514
2575
  ...m.art === void 0 ? {} : { art: m.art },
2576
+ ...banner === void 0 ? {} : { banner },
2515
2577
  ...followed === true ? { followed: true } : {},
2516
2578
  ...sra.length === 0 ? {} : { sra },
2517
2579
  ...own === true ? { own: true } : {},
@@ -2530,7 +2592,7 @@ var AdgGameIntel = class extends Service {
2530
2592
  const games = gameId === void 0 ? this.games : [this.game(gameId)];
2531
2593
  const results = [];
2532
2594
  for (const { manifest } of games) {
2533
- const sources = manifest.sources.filter((s) => s.smw !== void 0 || s.sra !== void 0 || s.steam !== void 0);
2595
+ const sources = manifest.sources.filter(readsItself);
2534
2596
  if (sources.length === 0) {
2535
2597
  const where = manifest.sources.map((s) => s.homepage).filter(Boolean).join(" \u6216 ") || "\u5B98\u7F51\u516C\u544A";
2536
2598
  results.push({ game: manifest.id, ok: false, count: 0, detail: manifest.single === true ? `\u6CA1\u6709\u80FD\u76F4\u63A5\u8BFB\u7684\u516C\u544A\u6765\u6E90\uFF1A\u7528 web_fetch \u770B ${where}\uFF0C\u7248\u672C\u66F4\u65B0\u548C\u516C\u544A\u7528 game_notice \u8BB0\u4E0B` : `\u6CA1\u6709\u80FD\u76F4\u63A5\u8BFB\u7684\u6570\u636E\u7AD9\uFF1A\u7528 web_fetch\uFF08\u53EA\u62FF\u5230\u7A7A\u58F3\u65F6\u7528\u5185\u7F6E\u6D4F\u89C8\u5668\uFF09\u770B ${where}\uFF0C\u518D\u7528 game_record\uFF08source=site\uFF09\u8BB0\u4E0B` });
@@ -2647,6 +2709,11 @@ var AdgGameIntel = class extends Service {
2647
2709
  * sources. A built-in pack of the same id is not replaced.
2648
2710
  * @returns the game as the board shows it. @throws Error with what is wrong in the manifest.
2649
2711
  */
2712
+ /**
2713
+ * Write a game pack of the user's own (game_add). The sources the plugin
2714
+ * reads itself are read before this returns, so the agent sees what they
2715
+ * gave (Steam's announcements, a site's events) and does not read them again.
2716
+ */
2650
2717
  async addGame(input, guide) {
2651
2718
  const parsed = GameManifest.safeParse(input);
2652
2719
  if (!parsed.success)
@@ -2673,9 +2740,9 @@ ${guide.trim()}
2673
2740
  await this.calendar.hide(manifest.id, false);
2674
2741
  await this.loadGames(this.log);
2675
2742
  this.changed(manifest.id);
2676
- if (manifest.sources.some((s) => s.smw !== void 0 || s.sra !== void 0))
2677
- void this.refresh(manifest.id).catch(() => []);
2678
- return this.infos().find((g) => g.id === manifest.id);
2743
+ const read = manifest.sources.some(readsItself) ? (await this.refresh(manifest.id).catch(() => []))[0] : void 0;
2744
+ const game = this.infos().find((g) => g.id === manifest.id);
2745
+ return read === void 0 ? { game } : { game, read: { count: read.count, ...read.notices === void 0 ? {} : { notices: read.notices }, ...read.detail === void 0 ? {} : { detail: read.detail } } };
2679
2746
  }
2680
2747
  // ── which games are on the page (apart from the 技能库's packs) ──
2681
2748
  /**
@@ -2806,7 +2873,7 @@ ${JSON.stringify({ id, name: wanted, sources: [] }, null, 2)}
2806
2873
  "3. \u5B98\u7F51\u7684\u65B0\u95FB / \u516C\u544A\u5217\u8868\u9875\uFF1A\u5199\u6210\u53EA\u6709 homepage \u7684\u6765\u6E90\uFF08agent \u8BFB\uFF09\u3002",
2807
2874
  " \u5355\u673A\u6E38\u620F\uFF08\u4E70\u65AD\u5236\u3001\u6CA1\u6709\u9650\u65F6\u6D3B\u52A8\u7684\uFF09\uFF1A\u5728 Steam \u4E0A\u6709\u7684\uFF0C\u518D\u5199\u4E00\u4E2A Steam \u6765\u6E90\uFF08steam_appid \u662F\u5546\u5E97\u9875 store.steampowered.com/app/<\u6570\u5B57> \u91CC\u7684\u6570\u5B57\uFF09\uFF0C\u63D2\u4EF6\u6BCF\u5929\u81EA\u52A8\u8BFB\u5B83\u5728 Steam \u7684\u5B98\u65B9\u516C\u544A\uFF08\u7248\u672C\u66F4\u65B0\u3001\u8865\u4E01\u8BF4\u660E\uFF09\uFF1Bgame_add \u65F6\u5199 single=true\u3002",
2808
2875
  `4. \u7528 game_add \u5199\u5B83\u7684\u6E38\u620F\u5305\uFF1Aid \u4E00\u5B9A\u7528 ${manifest.id}\uFF08\u6362\u4E86 id \u6E38\u620F\u9875\u4E0A\u5C31\u6210\u4E86\u53E6\u4E00\u4E2A\u6E38\u620F\uFF09\uFF0Cname \u7528\u5B83\u7684\u4E2D\u6587\u6B63\u5F0F\u540D\uFF08\u7528\u6237\u5199\u7684\u540D\u5B57\u662F\u300C${manifest.name}\u300D\uFF09\uFF0Caliases \u5199\u5E38\u89C1\u7B80\u79F0\uFF0Ctimezone \u5199\u670D\u52A1\u5668\u65F6\u533A\uFF0Csources \u5199\u627E\u5230\u7684\uFF08\u539F\u6765\u6709\u7684\u4FDD\u7559\uFF09\uFF1Bguide \u5199\u51E0\u884C\uFF1A\u54EA\u4E9B\u6765\u6E90\u770B\u4EC0\u4E48\u3001\u516C\u544A\u9875\u600E\u4E48\u627E\u6D3B\u52A8\u3002`,
2809
- "5. \u5199\u597D\u540E game_activities \u770B\u8BFB\u5230\u4E86\u4EC0\u4E48\uFF1B\u53EA\u6709\u7F51\u9875\u6765\u6E90\u7684\uFF0C\u5C31\u6309\u6280\u80FD\u8BFB\u4E00\u6B21\u516C\u544A\u9875\uFF0C\u7528 game_record\uFF08source=site\uFF09\u8BB0\u4E0B\u6D3B\u52A8\u3002\u5355\u673A\u6E38\u620F\u8BFB\u4E00\u6B21\u5B98\u65B9\u7684\u66F4\u65B0\u65E5\u5FD7\uFF0C\u7528 game_notice \u8BB0\u4E0B\u6700\u8FD1\u7684\u7248\u672C\u66F4\u65B0\u548C\u957F\u671F\u516C\u544A\u3002",
2876
+ "5. game_add \u7684\u7ED3\u679C\u91CC read_now \u662F\u80FD\u81EA\u52A8\u8BFB\u7684\u6765\u6E90\u521A\u8BFB\u5230\u7684\uFF08Steam \u516C\u544A\u3001\u6570\u636E\u7AD9\u6D3B\u52A8\uFF09\uFF0C\u8FD9\u4E9B\u4E0D\u7528\u518D\u8BB0\u3002\u53EA\u6709\u7F51\u9875\u6765\u6E90\u7684\uFF08\u6216\u53EA\u6709\u7F51\u9875\u624D\u6709\u7684\u6D88\u606F\uFF09\uFF1A\u6309\u6280\u80FD\u8BFB\u4E00\u6B21\u516C\u544A\u5217\u8868\uFF0C\u6709\u8D77\u6B62\u65F6\u95F4\u7684\u6D3B\u52A8\u7528 game_record\uFF08source=site\uFF09\u8BB0\u4E0B\uFF1B\u516C\u544A\u7528 game_notice \u8BB0\u4E0B\u2014\u2014\u5217\u8868\u4E0A\u6700\u8FD1\u4E09\u4E2A\u6708\u7684\u6BCF\u4E00\u7BC7\u90FD\u8BB0\uFF08\u6700\u591A 20 \u7BC7\uFF0C\u6807\u9898\u3001\u65E5\u671F\u3001\u7F51\u5740\u3001\u5217\u8868\u4E0A\u7684\u7F29\u7565\u56FE\uFF0C\u5217\u8868\u4E0A\u5C31\u6709\uFF0C\u4E0D\u7528\u6BCF\u7BC7\u70B9\u5F00\uFF09\uFF0C\u53EA\u70B9\u5F00\u6700\u65B0\u7684\u4E24\u4E09\u7BC7\uFF08\u6700\u8FD1\u7684\u7248\u672C\u66F4\u65B0\u3001\u957F\u671F\u516C\u544A\uFF09\u8BFB\u5168\u6587\u5199 summary\u3002",
2810
2877
  "6. \u627E\u4E0D\u5230\u8FD9\u4E2A\u6E38\u620F\uFF08\u540D\u5B57\u4E0D\u5BF9\u3001\u6CA1\u6709\u516C\u5F00\u7684\u6D3B\u52A8\u4FE1\u606F\uFF09\u5C31\u4E0D\u8981 game_add\uFF0C\u76F4\u63A5\u8BF4\u660E\u627E\u4E86\u54EA\u91CC\u3001\u4E3A\u4EC0\u4E48\u6CA1\u627E\u5230\u3002",
2811
2878
  "\u4E0D\u8981\u5411\u7528\u6237\u63D0\u95EE\uFF1B\u6700\u540E\u544A\u8BC9\u7528\u6237\u52A0\u4E86\u4EC0\u4E48\u6765\u6E90\u3001\u54EA\u4E9B\u80FD\u81EA\u52A8\u8BFB\u3001\u73B0\u5728\u6709\u51E0\u4E2A\u6D3B\u52A8\u3002"
2812
2879
  ].join("\n");
@@ -2818,7 +2885,7 @@ ${JSON.stringify({ id, name: wanted, sources: [] }, null, 2)}
2818
2885
  const sessions = this.ctx.get("sessionController");
2819
2886
  if (sessions === void 0)
2820
2887
  throw new Error("agent \u73B0\u5728\u4E0D\u53EF\u7528\uFF08\u4F1A\u8BDD\u670D\u52A1\u6CA1\u6709\u52A0\u8F7D\uFF09");
2821
- const chosen = sourceId === void 0 ? manifest.sources.filter((s) => s.smw === void 0 && s.sra === void 0) : manifest.sources.filter((s) => s.id === sourceId);
2888
+ const chosen = sourceId === void 0 ? manifest.sources.filter((s) => !readsItself(s)) : manifest.sources.filter((s) => s.id === sourceId);
2822
2889
  if (sourceId !== void 0 && chosen.length === 0)
2823
2890
  throw new Error(`${manifest.name}\u6CA1\u6709\u6765\u6E90\u300C${sourceId}\u300D`);
2824
2891
  const conversations = sessionConversations(sessions, () => this.ctx.get("adgGateway")?.workspaceDir(), (id, f) => this.ctx.get("adgGateway")?.skillScope.setFocus(id, f) ?? Promise.resolve(), () => this.ctx.get("adgGateway"));
@@ -2829,14 +2896,14 @@ ${JSON.stringify({ id, name: wanted, sources: [] }, null, 2)}
2829
2896
  const prompt = (manifest.single === true ? [
2830
2897
  `\u4E0A\u7F51\u67E5\u5355\u673A\u6E38\u620F\u300C${manifest.name}\u300D\u6700\u8FD1\u7684\u5B98\u65B9\u516C\u544A\uFF08\u6E38\u620F id\uFF1A${manifest.id}\uFF09\uFF0C\u6309\u6280\u80FD web-reading \u548C game-intel\uFF1A`,
2831
2898
  `1. \u5148 game_activities\uFF08game=${manifest.id}\uFF09\u770B\u5DF2\u7ECF\u8BB0\u4E86\u54EA\u4E9B\u516C\u544A\uFF0C\u4E0D\u7528\u91CD\u590D\u8BB0\u3002`,
2832
- `2. ${where}\u770B\u5B98\u65B9\u7684\u66F4\u65B0\u65E5\u5FD7\u6216\u516C\u544A\u5217\u8868\uFF08Steam \u65B0\u95FB\u3001\u5B98\u7F51\u535A\u5BA2\u3001\u516C\u544A\u9875\uFF09\uFF0C\u53EA\u6253\u5F00\u6700\u8FD1\u7684\u51E0\u7BC7\u3002`,
2833
- "3. \u7248\u672C\u66F4\u65B0\u3001\u8865\u4E01\u8BF4\u660E\u7528 game_notice \u8BB0\u4E0B\uFF08kind=update\uFF0C\u5199\u4E0A\u7248\u672C\u53F7\u3001\u53D1\u5E03\u65E5\u671F\u3001\u4E00\u4E24\u53E5\u6539\u4E86\u4EC0\u4E48\u548C\u7F51\u5740\uFF1B\u6709\u914D\u56FE\u5C31\u5199\u8FDB cover\uFF09\uFF1B\u957F\u671F\u6709\u6548\u7684\u516C\u544A kind=notice\u3001lasting=true\uFF1B\u5176\u4ED6\u8D44\u8BAF kind=news\u3002\u5355\u673A\u6E38\u620F\u4E00\u822C\u6CA1\u6709\u9650\u65F6\u6D3B\u52A8\uFF0C\u771F\u6709\uFF08\u9650\u65F6\u6298\u6263\u3001\u8054\u52A8\u3001\u8282\u65E5\u6D3B\u52A8\uFF09\u624D\u7528 game_record\u3002",
2899
+ `2. ${where}\u770B\u5B98\u65B9\u7684\u66F4\u65B0\u65E5\u5FD7\u6216\u516C\u544A\u5217\u8868\uFF08Steam \u65B0\u95FB\u3001\u5B98\u7F51\u535A\u5BA2\u3001\u516C\u544A\u9875\uFF09\u3002`,
2900
+ "3. \u5217\u8868\u4E0A\u6700\u8FD1\u4E09\u4E2A\u6708\u7684\u516C\u544A\u6BCF\u4E00\u7BC7\u90FD\u7528 game_notice \u8BB0\u4E0B\uFF08\u6700\u591A 20 \u7BC7\uFF1B\u6807\u9898\u3001\u53D1\u5E03\u65E5\u671F\u3001\u7F51\u5740\u3001\u5217\u8868\u4E0A\u7684\u7F29\u7565\u56FE\u5199\u8FDB cover\u2014\u2014\u5217\u8868\u4E0A\u5C31\u6709\uFF0C\u4E0D\u7528\u6BCF\u7BC7\u70B9\u5F00\uFF09\uFF1A\u7248\u672C\u66F4\u65B0\u3001\u8865\u4E01\u8BF4\u660E kind=update\uFF08\u6807\u9898\u91CC\u6709\u7248\u672C\u53F7\u5C31\u5199\u4E0A\uFF09\uFF0C\u957F\u671F\u6709\u6548\u7684\u516C\u544A kind=notice\u3001lasting=true\uFF0C\u5176\u4ED6\u8D44\u8BAF kind=news\u3002\u53EA\u70B9\u5F00\u6700\u65B0\u7684\u4E24\u4E09\u7BC7\uFF08\u6700\u8FD1\u7684\u7248\u672C\u66F4\u65B0\u3001\u957F\u671F\u516C\u544A\uFF09\u8BFB\u5168\u6587\uFF0C\u5199\u4E00\u4E24\u53E5 summary\u3002\u5355\u673A\u6E38\u620F\u4E00\u822C\u6CA1\u6709\u9650\u65F6\u6D3B\u52A8\uFF0C\u771F\u6709\uFF08\u9650\u65F6\u6298\u6263\u3001\u8054\u52A8\u3001\u8282\u65E5\u6D3B\u52A8\uFF09\u624D\u7528 game_record\u3002",
2834
2901
  "4. \u4E0D\u6253\u5F00\u6E38\u620F\uFF0C\u4E0D\u5411\u7528\u6237\u63D0\u95EE\u3002\u6700\u540E\u7528\u4E24\u4E09\u53E5\u8BDD\u603B\u7ED3\uFF1A\u6700\u65B0\u7248\u672C\u662F\u4EC0\u4E48\u3001\u6539\u4E86\u4EC0\u4E48\u3001\u6709\u6CA1\u6709\u8981\u6CE8\u610F\u7684\u516C\u544A\u3002"
2835
2902
  ] : [
2836
2903
  `\u4E0A\u7F51\u67E5\u300C${manifest.name}\u300D\u73B0\u5728\u7684\u6D3B\u52A8\u548C\u6700\u65B0\u6D88\u606F\uFF08\u6E38\u620F id\uFF1A${manifest.id}\uFF09\uFF0C\u6309\u6280\u80FD web-reading \u548C game-intel\uFF1A`,
2837
2904
  `1. \u5148 game_activities\uFF08game=${manifest.id}\uFF09\u770B\u65E5\u5386\u91CC\u5DF2\u7ECF\u6709\u4EC0\u4E48\uFF0C\u4E0D\u7528\u91CD\u590D\u67E5\u3002`,
2838
- `2. ${where}\u5148\u8BFB\u5217\u8868\u9875\uFF0C\u53EA\u6253\u5F00\u6700\u8FD1\u7684\u6D3B\u52A8\u3001\u7248\u672C\u548C\u7EF4\u62A4\u516C\u544A\u3002`,
2839
- "3. \u6BCF\u4E2A\u627E\u5230\u8D77\u6B62\u65F6\u95F4\u7684\u6D3B\u52A8\u7528 game_record\uFF08source=site\uFF0C\u5199\u4E0A url\uFF1B\u516C\u544A\u91CC\u6709\u8FD9\u4E2A\u6D3B\u52A8\u7684\u914D\u56FE\u5C31\u628A\u56FE\u7247\u5730\u5740\u5199\u8FDB cover\uFF09\u8BB0\u4E0B\uFF1B\u53EA\u8BB0\u6709\u786E\u5207\u51FA\u5904\u7684\u65F6\u95F4\u3002\u7248\u672C\u66F4\u65B0\u516C\u544A\u548C\u957F\u671F\u6709\u6548\u7684\u516C\u544A\uFF08\u6CA1\u6709\u7ED3\u675F\u65F6\u95F4\u7684\uFF09\u7528 game_notice \u8BB0\u4E0B\uFF08kind=update \u6216 notice\uFF0C\u957F\u671F\u7684\u5199 lasting=true\uFF09\u3002",
2905
+ `2. ${where}\u5148\u8BFB\u5217\u8868\u9875\uFF1B\u8981\u8D77\u6B62\u65F6\u95F4\u3001\u8981\u7EC6\u8282\u7684\u624D\u70B9\u5F00\uFF08\u6700\u8FD1\u7684\u6D3B\u52A8\u3001\u7248\u672C\u548C\u7EF4\u62A4\u516C\u544A\uFF09\u3002`,
2906
+ "3. \u6BCF\u4E2A\u627E\u5230\u8D77\u6B62\u65F6\u95F4\u7684\u6D3B\u52A8\u7528 game_record\uFF08source=site\uFF0C\u5199\u4E0A url\uFF1B\u516C\u544A\u91CC\u6709\u8FD9\u4E2A\u6D3B\u52A8\u7684\u914D\u56FE\u5C31\u628A\u56FE\u7247\u5730\u5740\u5199\u8FDB cover\uFF09\u8BB0\u4E0B\uFF1B\u53EA\u8BB0\u6709\u786E\u5207\u51FA\u5904\u7684\u65F6\u95F4\u3002\u6CA1\u6709\u8D77\u6B62\u65F6\u95F4\u7684\u516C\u544A\u7528 game_notice \u8BB0\u4E0B\uFF1A\u5217\u8868\u4E0A\u6700\u8FD1\u4E00\u4E2A\u6708\u7684\u6BCF\u4E00\u7BC7\u90FD\u8BB0\uFF08\u6700\u591A 20 \u7BC7\uFF1B\u6807\u9898\u3001\u65E5\u671F\u3001\u7F51\u5740\u3001\u5217\u8868\u4E0A\u7684\u7F29\u7565\u56FE\uFF0C\u4E0D\u7528\u6BCF\u7BC7\u70B9\u5F00\uFF09\uFF0C\u7248\u672C\u66F4\u65B0 kind=update\uFF0C\u957F\u671F\u6709\u6548\u7684 kind=notice\u3001lasting=true\uFF0C\u5176\u4ED6 kind=news\uFF1B\u70B9\u5F00\u8BFB\u8FC7\u7684\u5199\u4E00\u4E24\u53E5 summary\u3002",
2840
2907
  "4. \u4E0D\u6253\u5F00\u6E38\u620F\uFF0C\u4E0D\u5411\u7528\u6237\u63D0\u95EE\u3002\u6700\u540E\u7528\u4E24\u4E09\u53E5\u8BDD\u603B\u7ED3\uFF1A\u73B0\u5728\u6709\u54EA\u4E9B\u6D3B\u52A8\u3001\u54EA\u4E9B\u5FEB\u7ED3\u675F\u3001\u6709\u4EC0\u4E48\u65B0\u6D88\u606F\uFF08\u65B0\u7248\u672C\u3001\u7EF4\u62A4\u3001\u798F\u5229\uFF09\u3002"
2841
2908
  ]).join("\n");
2842
2909
  void conversations.ask(sessionId, taskMessage("\u4F60", `\u6E38\u620F\u8D44\u8BAF\uFF1A${manifest.name}`, prompt), AbortSignal.timeout(READ_TIMEOUT_MS)).then((answer) => this.calendar.setReading(`${manifest.id}#web`, { state: "done", at: this.clock.now(), sessionId, summary: answer.slice(0, 400) }), (error) => this.calendar.setReading(`${manifest.id}#web`, { state: "failed", at: this.clock.now(), sessionId, summary: error instanceof Error ? error.message : String(error) })).finally(() => this.changed(manifest.id));
package/lib/gateway.js CHANGED
@@ -23,10 +23,10 @@ import {
23
23
  pluginVersion,
24
24
  streamFacts,
25
25
  userSkills
26
- } from "./chunk-KTOQFJ7R.js";
27
- import "./chunk-ICJLH3DP.js";
26
+ } from "./chunk-OFVGRKTD.js";
27
+ import "./chunk-52LYI7WP.js";
28
28
  import "./chunk-RESS7WVY.js";
29
- import "./chunk-NEUZQ7TI.js";
29
+ import "./chunk-F7ZQE7BT.js";
30
30
  import "./chunk-6DSSLS7I.js";
31
31
  import "./chunk-2UFLGPDY.js";
32
32
  export {
package/lib/guard.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __adgCreateRequire } from 'node:module'; import { dirname as __adgDirname } from 'node:path'; import { fileURLToPath as __adgFileURLToPath } from 'node:url'; const require = __adgCreateRequire(import.meta.url); const __filename = __adgFileURLToPath(import.meta.url); const __dirname = __adgDirname(__filename);
2
2
  import {
3
3
  GUARD_CAPABILITY
4
- } from "./chunk-NEUZQ7TI.js";
4
+ } from "./chunk-F7ZQE7BT.js";
5
5
  import "./chunk-6DSSLS7I.js";
6
6
  import "./chunk-2UFLGPDY.js";
7
7
 
package/lib/intervene.js CHANGED
@@ -2,16 +2,16 @@ import { createRequire as __adgCreateRequire } from 'node:module'; import { dirn
2
2
  import {
3
3
  finalText,
4
4
  sessionConversations
5
- } from "./chunk-I4NHWXKH.js";
6
- import "./chunk-KTOQFJ7R.js";
7
- import "./chunk-ICJLH3DP.js";
5
+ } from "./chunk-YSTZL6HE.js";
6
+ import "./chunk-OFVGRKTD.js";
7
+ import "./chunk-52LYI7WP.js";
8
8
  import {
9
9
  writeFileAtomic
10
10
  } from "./chunk-RESS7WVY.js";
11
11
  import {
12
12
  INTERVENE_CAPABILITY,
13
13
  UPDATE_RULE
14
- } from "./chunk-NEUZQ7TI.js";
14
+ } from "./chunk-F7ZQE7BT.js";
15
15
  import {
16
16
  external_exports
17
17
  } from "./chunk-6DSSLS7I.js";
@@ -38,8 +38,8 @@ import {
38
38
  summaryTarget,
39
39
  summaryText,
40
40
  taskOver
41
- } from "./chunk-ICJLH3DP.js";
42
- import "./chunk-NEUZQ7TI.js";
41
+ } from "./chunk-52LYI7WP.js";
42
+ import "./chunk-F7ZQE7BT.js";
43
43
  import "./chunk-6DSSLS7I.js";
44
44
  import "./chunk-2UFLGPDY.js";
45
45
  export {
package/lib/monitor.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { createRequire as __adgCreateRequire } from 'node:module'; import { dirname as __adgDirname } from 'node:path'; import { fileURLToPath as __adgFileURLToPath } from 'node:url'; const require = __adgCreateRequire(import.meta.url); const __filename = __adgFileURLToPath(import.meta.url); const __dirname = __adgDirname(__filename);
2
2
  import {
3
3
  parseDuration
4
- } from "./chunk-EKTA4OYC.js";
5
- import "./chunk-26JIEF6M.js";
4
+ } from "./chunk-EOZKHLHK.js";
5
+ import "./chunk-IBPJC6DX.js";
6
6
  import {
7
7
  writeFileAtomic
8
8
  } from "./chunk-RESS7WVY.js";
@@ -10,7 +10,7 @@ import {
10
10
  Incident,
11
11
  MONITOR_CAPABILITY,
12
12
  MonitorSettings
13
- } from "./chunk-NEUZQ7TI.js";
13
+ } from "./chunk-F7ZQE7BT.js";
14
14
  import {
15
15
  external_exports
16
16
  } from "./chunk-6DSSLS7I.js";
package/lib/notify.js CHANGED
@@ -16,11 +16,11 @@ import {
16
16
  replyPlain,
17
17
  sessionConversations,
18
18
  textReply
19
- } from "./chunk-I4NHWXKH.js";
20
- import "./chunk-KTOQFJ7R.js";
21
- import "./chunk-ICJLH3DP.js";
19
+ } from "./chunk-YSTZL6HE.js";
20
+ import "./chunk-OFVGRKTD.js";
21
+ import "./chunk-52LYI7WP.js";
22
22
  import "./chunk-RESS7WVY.js";
23
- import "./chunk-NEUZQ7TI.js";
23
+ import "./chunk-F7ZQE7BT.js";
24
24
  import "./chunk-6DSSLS7I.js";
25
25
  import "./chunk-2UFLGPDY.js";
26
26
  export {
@@ -4,18 +4,18 @@ import {
4
4
  PARAMS_SCHEMA,
5
5
  parseDuration,
6
6
  taskParams
7
- } from "./chunk-EKTA4OYC.js";
7
+ } from "./chunk-EOZKHLHK.js";
8
8
  import {
9
9
  TaskInputError,
10
10
  renderTask
11
- } from "./chunk-26JIEF6M.js";
11
+ } from "./chunk-IBPJC6DX.js";
12
12
  import {
13
13
  MAIN,
14
14
  finalText,
15
15
  sessionConversations
16
- } from "./chunk-I4NHWXKH.js";
17
- import "./chunk-KTOQFJ7R.js";
18
- import "./chunk-ICJLH3DP.js";
16
+ } from "./chunk-YSTZL6HE.js";
17
+ import "./chunk-OFVGRKTD.js";
18
+ import "./chunk-52LYI7WP.js";
19
19
  import {
20
20
  writeFileAtomic
21
21
  } from "./chunk-RESS7WVY.js";
@@ -33,7 +33,7 @@ import {
33
33
  isMarker,
34
34
  taskMessage,
35
35
  withStartEnd
36
- } from "./chunk-NEUZQ7TI.js";
36
+ } from "./chunk-F7ZQE7BT.js";
37
37
  import {
38
38
  external_exports
39
39
  } from "./chunk-6DSSLS7I.js";
package/lib/qqbot.js CHANGED
@@ -4,9 +4,9 @@ import {
4
4
  questionText,
5
5
  replyMarkdown,
6
6
  replyPlain
7
- } from "./chunk-I4NHWXKH.js";
8
- import "./chunk-KTOQFJ7R.js";
9
- import "./chunk-ICJLH3DP.js";
7
+ } from "./chunk-YSTZL6HE.js";
8
+ import "./chunk-OFVGRKTD.js";
9
+ import "./chunk-52LYI7WP.js";
10
10
  import {
11
11
  writeFileAtomic
12
12
  } from "./chunk-RESS7WVY.js";
@@ -15,7 +15,7 @@ import {
15
15
  QQBOT_SECRET_REF,
16
16
  QQPending,
17
17
  QQSettings
18
- } from "./chunk-NEUZQ7TI.js";
18
+ } from "./chunk-F7ZQE7BT.js";
19
19
  import {
20
20
  external_exports
21
21
  } from "./chunk-6DSSLS7I.js";
package/lib/runner.js CHANGED
@@ -25,9 +25,9 @@ import {
25
25
  setIn,
26
26
  taskParams,
27
27
  tidyRuns
28
- } from "./chunk-EKTA4OYC.js";
29
- import "./chunk-26JIEF6M.js";
30
- import "./chunk-NEUZQ7TI.js";
28
+ } from "./chunk-EOZKHLHK.js";
29
+ import "./chunk-IBPJC6DX.js";
30
+ import "./chunk-F7ZQE7BT.js";
31
31
  import "./chunk-6DSSLS7I.js";
32
32
  import "./chunk-2UFLGPDY.js";
33
33
  export {
package/lib/scheduler.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __adgCreateRequire } from 'node:module'; import { dirname as __adgDirname } from 'node:path'; import { fileURLToPath as __adgFileURLToPath } from 'node:url'; const require = __adgCreateRequire(import.meta.url); const __filename = __adgFileURLToPath(import.meta.url); const __dirname = __adgDirname(__filename);
2
2
  import {
3
3
  SCHEDULE_CAPABILITY
4
- } from "./chunk-NEUZQ7TI.js";
4
+ } from "./chunk-F7ZQE7BT.js";
5
5
  import {
6
6
  external_exports
7
7
  } from "./chunk-6DSSLS7I.js";
@@ -17,14 +17,14 @@ import {
17
17
  packForRepo,
18
18
  parseMcpConfig,
19
19
  readSkills
20
- } from "./chunk-J4QJC6UZ.js";
20
+ } from "./chunk-NOZCFSQP.js";
21
21
  import "./chunk-B4UT4NYH.js";
22
- import "./chunk-26JIEF6M.js";
23
- import "./chunk-I4NHWXKH.js";
24
- import "./chunk-KTOQFJ7R.js";
25
- import "./chunk-ICJLH3DP.js";
22
+ import "./chunk-IBPJC6DX.js";
23
+ import "./chunk-YSTZL6HE.js";
24
+ import "./chunk-OFVGRKTD.js";
25
+ import "./chunk-52LYI7WP.js";
26
26
  import "./chunk-RESS7WVY.js";
27
- import "./chunk-NEUZQ7TI.js";
27
+ import "./chunk-F7ZQE7BT.js";
28
28
  import "./chunk-6DSSLS7I.js";
29
29
  import "./chunk-2UFLGPDY.js";
30
30
  export {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-multigameassistant",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "多游戏助手 MultiGameAssistant 的 dsh 插件版:让 agent 管好各个游戏的日常脚本(安装、编排定时流水线、看护运行、查活动),界面在自己的网页里。",
5
5
  "keywords": [
6
6
  "dsh",
@@ -12,14 +12,15 @@ description: 游戏活动信息:查有什么活动、还剩几天、商店换
12
12
  1. `game_activities` 看日历。某个游戏的 refreshed 超过半天,先 `game_sites_refresh` 再看。
13
13
  2. 照日历回答:活动名、还剩几天、商店开到什么时候、还没做完的事。有 `mismatch` 的说明以数据站为准。`todo` / `done` 可能是 agent 在游戏里读到的,也可能是用户自己在「游戏 → 全部活动」里勾的;`finished_by_user` 表示用户说这个活动做完了,不要再提醒它。
14
14
  用户想看更多游戏(原神、绝区零、鸣潮等没有游戏包的):告诉他在「游戏 → 全部活动 → 更多游戏」里勾上,活动来自 SRA 公共 API,每天自动刷新。
15
- 3. 游戏包里没有可直接读的数据站(`game_list` 里 auto 都是 false):按技能 web-reading 的顺序查(先公开 API,如 SRA 公共 API,再 Wiki 接口,最后官网公告页),找到活动名和起止时间后 `game_record`(source=site,带上 `url`)。
15
+ 3. 游戏包里没有可直接读的数据站(`game_list` 里 auto 都是 false):按技能 web-reading 的顺序查(先公开 API,如 SRA 公共 API,再 Wiki 接口,最后官网公告页),找到活动名和起止时间后 `game_record`(source=site,带上 `url`,有配图把图片地址写进 `cover`)。
16
16
 
17
17
  ## 公告和版本更新(单机游戏主要看这个)
18
18
 
19
19
  不是限时活动的消息记在游戏的「公告」里:版本更新、补丁说明、长期有效的公告、其他资讯。`game_activities` 每个游戏带着最近的 `notices`(`single_player` 为 true 的是单机游戏)。
20
20
 
21
21
  - 用户问「XX 最近更新了什么」「最新版本是多少」:先看 `notices`;没有或太旧,先 `game_sites_refresh`(有 Steam 来源的游戏,插件每天自己读它在 Steam 的官方公告),再按技能 web-reading 上网查。
22
- - 自己读到的公告用 `game_notice` 记下:版本更新 kind=update(写上版本号、发布日期、一两句改了什么、网址),长期有效的 kind=notice 加 lasting=true(会一直排在最前面,过时了用 lasting=false 收回),其他 kind=news。同一个网址再记就是更新原来那条。
22
+ - `notices` 里只有一两句摘要。用户要细节(具体改了哪些卡、平衡调整、修复了什么):按技能 web-reading 读那一篇的全文(Steam 用 `enddate` 取单篇,或读中文 RSS),按小标题把要点讲全,附上网址。
23
+ - 自己读到的公告用 `game_notice` 记下,公告列表上最近的每一篇都记(最多 20 篇,没点开的照列表写标题、日期、网址),不是只记点开读过的那几篇:版本更新 kind=update(写上版本号、发布日期、一两句改了什么、网址、配图地址 `cover`),长期有效的 kind=notice 加 lasting=true(会一直排在最前面,过时了用 lasting=false 收回),其他 kind=news。同一个网址再记就是更新原来那条。
23
24
  - 单机游戏(买断制、没有限时活动)一般不用 `game_record`;真有限时的事(限时折扣、联动、节日活动)才记成活动。
24
25
 
25
26
  ## 进游戏读进度
@@ -40,7 +41,7 @@ description: 游戏活动信息:查有什么活动、还剩几天、商店换
40
41
  用户说「帮我加一个活动」「把 XX 改成 …结束」「给这个活动换张图」时用 `game_activity_save`,不要用 `game_record`(那是记读到的):
41
42
 
42
43
  - 新加:写 `game`、`name`,有时间就写 `starts_at` / `ends_at`(游戏服务器时间)。改已有的:先 `game_activities` 找到 `id`,只写要改的字段。
43
- - 图片 `image`:用户给的图片网址、本机图片文件路径,或 `screenshot`(这个对话最近一张截图,比如刚用 `screen_capture` 截的活动页)。
44
+ - 图片 `image`:用户给的图片网址、本机图片文件路径,或 `screenshot`(这个对话最近一张截图,比如刚用 `screen_capture` 截的活动页;内置浏览器的截图不算)。用户让你「找张图」:按技能 web-reading 从公告、Wiki 或 Steam 取图片地址。
44
45
  - 活动图片分三级:用户设的 > 数据站和网页给的 > agent 的截图。`screenshot` 算 agent 的截图,有别的图时不显示;用户想让截图显示,用 `use_source`=screen。
45
46
  - 一个活动有多个来源时(`game_activities` 的 `sources`),用户说「用 PRTS 的时间」就写 `use_source`(来源 id、own、screen,或 default 恢复默认顺序):图片和时间都跟着换。
46
47
  - 用户填的内容比数据站优先,刷新不会改掉。要恢复成来源的:`clear` 列出字段,或 `game_activity_remove`(what=mine)。用户要删掉才用 `game_activity_remove`(what=all)。