@wox-launcher/wox-plugin 0.0.69 → 0.0.71

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": "@wox-launcher/wox-plugin",
3
- "version": "0.0.69",
3
+ "version": "0.0.71",
4
4
  "description": "All nodejs plugin for Wox should use types in this package",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,4 +1,4 @@
1
- export namespace llm {
1
+ export namespace AI {
2
2
  export type ConversationRole = "user" | "system"
3
3
  export type ChatStreamDataType = "streaming" | "finished" | "error"
4
4
 
package/types/index.d.ts CHANGED
@@ -1,5 +1,7 @@
1
- import { llm } from "./llm.js"
2
1
  import { MetadataCommand, PluginSettingDefinitionItem } from "./setting.js"
2
+ import { AI } from "./ai.js"
3
+
4
+ export type MapString = { [key: string]: string }
3
5
 
4
6
  export type Platform = "windows" | "darwin" | "linux"
5
7
 
@@ -81,6 +83,8 @@ export interface Result {
81
83
  Icon: WoxImage
82
84
  Preview?: WoxPreview
83
85
  Score?: number
86
+ Group?: string
87
+ GroupScore?: number
84
88
  ContextData?: string
85
89
  Actions?: ResultAction[]
86
90
  // refresh result after specified interval, in milliseconds. If this value is 0, Wox will not refresh this result
@@ -192,7 +196,7 @@ export interface PublicAPI {
192
196
  /**
193
197
  * Register deep link callback
194
198
  */
195
- OnDeepLink: (ctx: Context, callback: (arguments: Map<string, string>) => void) => Promise<void>
199
+ OnDeepLink: (ctx: Context, callback: (arguments: MapString) => void) => Promise<void>
196
200
 
197
201
  /**
198
202
  * Register query commands
@@ -202,7 +206,7 @@ export interface PublicAPI {
202
206
  /**
203
207
  * Chat using LLM
204
208
  */
205
- LLMStream: (ctx: Context, conversations: llm.Conversation[], callback: llm.ChatStreamFunc) => Promise<void>
209
+ LLMStream: (ctx: Context, conversations: AI.Conversation[], callback: AI.ChatStreamFunc) => Promise<void>
206
210
  }
207
211
 
208
212
  export type WoxImageType = "absolute" | "relative" | "base64" | "svg" | "url" | "emoji"