@jaybon24/plugin-moonshot 0.0.1 → 0.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.
Binary file
Binary file
Binary file
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAoBxD,QAAA,MAAM,MAAM,EAAE,WAAW,CAAC,GAAG,CA2B5B,CAAC;AAEF,eAAe,MAAM,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAwBxD,QAAA,MAAM,MAAM,EAAE,WAAW,CAAC,GAAG,CA2B5B,CAAC;AAEF,eAAe,MAAM,CAAC"}
package/dist/index.js CHANGED
@@ -2,10 +2,12 @@ import { readFileSync } from 'fs';
2
2
  import { fileURLToPath } from 'url';
3
3
  import { dirname, join } from 'path';
4
4
  import { z } from 'zod';
5
- import { SvgIcon } from './types.js';
6
5
  import { MoonshotModule } from './moonshot.module.js';
7
6
  const __filename = fileURLToPath(import.meta.url);
8
7
  const __dirname = dirname(__filename);
8
+ // Read PNG icon as data URL. No fallback/try-catch: missing asset should fail fast.
9
+ const iconPngDataUrl = 'data:image/png;base64,' +
10
+ readFileSync(join(__dirname, '_assets/icon_s_en.png')).toString('base64');
9
11
  const packageJson = JSON.parse(readFileSync(join(__dirname, '../package.json'), 'utf8'));
10
12
  const ConfigSchema = z.object({});
11
13
  const plugin = {
@@ -14,8 +16,8 @@ const plugin = {
14
16
  version: packageJson.version,
15
17
  category: 'model',
16
18
  icon: {
17
- type: 'svg',
18
- value: SvgIcon,
19
+ type: 'image',
20
+ value: iconPngDataUrl,
19
21
  },
20
22
  displayName: 'Moonshot AI (Kimi)',
21
23
  description: 'Provide Moonshot AI (Kimi) Models with Long Context Support',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jaybon24/plugin-moonshot",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "author": {
5
5
  "name": "XpertAI",
6
6
  "url": "https://xpertai.cn"