@wowok/skills 1.0.6 → 1.1.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.
Files changed (52) hide show
  1. package/README.md +26 -30
  2. package/dist/cli.js +114 -19
  3. package/dist/cli.js.map +1 -1
  4. package/dist/index.d.ts +1 -1
  5. package/dist/index.d.ts.map +1 -1
  6. package/dist/index.js +11 -1
  7. package/dist/index.js.map +1 -1
  8. package/dist/skills.d.ts +46 -1
  9. package/dist/skills.d.ts.map +1 -1
  10. package/dist/skills.js +154 -16
  11. package/dist/skills.js.map +1 -1
  12. package/dist/types.d.ts +31 -0
  13. package/dist/types.d.ts.map +1 -1
  14. package/package.json +3 -4
  15. package/scripts/install.js +5 -3
  16. package/wowok-arbitrator/SKILL.md +279 -0
  17. package/wowok-guard/SKILL.md +166 -139
  18. package/wowok-machine/SKILL.md +215 -280
  19. package/wowok-order/SKILL.md +290 -404
  20. package/wowok-provider/SKILL.md +453 -0
  21. package/wowok-safety/SKILL.md +176 -279
  22. package/wowok-tools/SKILL.md +329 -344
  23. package/schemas/onchain_operations/_common.md +0 -236
  24. package/schemas/onchain_operations/_index.md +0 -22
  25. package/schemas/onchain_operations/allocation.md +0 -50
  26. package/schemas/onchain_operations/arbitration.md +0 -95
  27. package/schemas/onchain_operations/contact.md +0 -36
  28. package/schemas/onchain_operations/demand.md +0 -52
  29. package/schemas/onchain_operations/gen_passport.md +0 -43
  30. package/schemas/onchain_operations/guard.md +0 -136
  31. package/schemas/onchain_operations/machine.md +0 -70
  32. package/schemas/onchain_operations/order.md +0 -57
  33. package/schemas/onchain_operations/payment.md +0 -32
  34. package/schemas/onchain_operations/permission.md +0 -57
  35. package/schemas/onchain_operations/personal.md +0 -59
  36. package/schemas/onchain_operations/progress.md +0 -35
  37. package/schemas/onchain_operations/repository.md +0 -81
  38. package/schemas/onchain_operations/reward.md +0 -40
  39. package/schemas/onchain_operations/service.md +0 -104
  40. package/schemas/onchain_operations/treasury.md +0 -74
  41. package/schemas/schema-account_operation.md +0 -402
  42. package/schemas/schema-guard2file.md +0 -153
  43. package/schemas/schema-local_info_operation.md +0 -160
  44. package/schemas/schema-local_mark_operation.md +0 -148
  45. package/schemas/schema-machineNode2file.md +0 -155
  46. package/schemas/schema-messenger_operation.md +0 -547
  47. package/schemas/schema-onchain_events.md +0 -201
  48. package/schemas/schema-onchain_table_data.md +0 -334
  49. package/schemas/schema-query_toolkit.md +0 -375
  50. package/schemas/schema-wip_file.md +0 -240
  51. package/schemas/schema-wowok_buildin_info.md +0 -296
  52. package/wowok-build/SKILL.md +0 -606
@@ -1,402 +0,0 @@
1
- # Schema: account_operation
2
-
3
- > 100% LOCAL, NEVER ON-CHAIN - Manage WoWok accounts locally on device: generate, suspend, resume, faucet-test, operate assets, sign data, etc.
4
-
5
- ---
6
-
7
- ## Top-Level Structure
8
-
9
- ```typescript
10
- AccountOperation {
11
- // Exactly ONE operation type must be specified
12
- gen?: GenOperation;
13
- faucet?: FaucetOperation;
14
- suspend?: SuspendOperation;
15
- resume?: ResumeOperation;
16
- rename?: RenameOperation;
17
- swap_name?: SwapNameOperation;
18
- transfer?: TransferOperation;
19
- get?: GetOperation;
20
- signData?: SignDataOperation;
21
- messenger?: MessengerOperation;
22
- }
23
- ```
24
-
25
- ---
26
-
27
- ## Operation Types
28
-
29
- ### gen
30
-
31
- Generate a new account.
32
-
33
- ```typescript
34
- GenOperation {
35
- name?: string; // Account name (max 64 chars). Empty = default account
36
- replaceExistName?: boolean; // Force claim existing name
37
- m?: string | null; // Messenger name to enable. Null = disable
38
- }
39
- ```
40
-
41
- **Result**:
42
-
43
- ```typescript
44
- GenResult {
45
- address: string; // New account ID
46
- name?: string; // Account name
47
- m?: string | null; // Messenger name if enabled
48
- }
49
- ```
50
-
51
- ---
52
-
53
- ### faucet
54
-
55
- Distribute test coins from faucet.
56
-
57
- ```typescript
58
- FaucetOperation {
59
- name_or_address?: string; // Account name or address. Empty = default
60
- network: "localnet" | "testnet";
61
- }
62
- ```
63
-
64
- **Result**:
65
-
66
- ```typescript
67
- FaucetResult {
68
- name_or_address?: string;
69
- result: {
70
- amount: number;
71
- id: string;
72
- transferTxDigest: string;
73
- }[];
74
- network: "localnet" | "testnet";
75
- }
76
- ```
77
-
78
- ---
79
-
80
- ### suspend
81
-
82
- Remove account from active list (cannot sign transactions).
83
-
84
- ```typescript
85
- SuspendOperation {
86
- name_or_address?: string; // Account name or address. Empty = default
87
- }
88
- ```
89
-
90
- **Result**:
91
-
92
- ```typescript
93
- SuspendResult {
94
- name_or_address?: string;
95
- success: boolean;
96
- }
97
- ```
98
-
99
- ---
100
-
101
- ### resume
102
-
103
- Add account back to active list.
104
-
105
- ```typescript
106
- ResumeOperation {
107
- address: string; // Account ID (0x + 64 hex chars)
108
- name?: string; // New name for resumed account
109
- }
110
- ```
111
-
112
- **Result**:
113
-
114
- ```typescript
115
- ResumeResult {
116
- address: string;
117
- name?: string;
118
- success: boolean;
119
- }
120
- ```
121
-
122
- ---
123
-
124
- ### rename
125
-
126
- Rename an account.
127
-
128
- ```typescript
129
- RenameOperation {
130
- name_or_address?: string; // Source account. Empty = default
131
- new_name: string; // New account name (max 64 chars)
132
- }
133
- ```
134
-
135
- **Result**:
136
-
137
- ```typescript
138
- RenameResult {
139
- name_or_address?: string;
140
- new_name: string;
141
- success: boolean;
142
- }
143
- ```
144
-
145
- ---
146
-
147
- ### swap_name
148
-
149
- Swap names between two accounts.
150
-
151
- ```typescript
152
- SwapNameOperation {
153
- name1?: string; // First account name. Empty = default
154
- name2?: string; // Second account name. Empty = default
155
- }
156
- ```
157
-
158
- **Result**:
159
-
160
- ```typescript
161
- SwapNameResult {
162
- name1?: string;
163
- name2?: string;
164
- success: boolean;
165
- }
166
- ```
167
-
168
- ---
169
-
170
- ### transfer
171
-
172
- Transfer tokens between accounts.
173
-
174
- ```typescript
175
- TransferOperation {
176
- name_or_address_from?: string; // Sender. Empty = default
177
- name_or_address_to?: string; // Recipient. Empty = default
178
- amount: number | string; // Amount to transfer
179
- token_type?: string; // Default: 0x2::wow::WOW
180
- network?: "localnet" | "testnet";
181
- }
182
- ```
183
-
184
- **Result**: `WowTransactionBlockResponse` (see Transaction Response Schema)
185
-
186
- ---
187
-
188
- ### get
189
-
190
- Generate new coin object by required amount.
191
-
192
- ```typescript
193
- GetOperation {
194
- name_or_address?: string; // Account. Empty = default
195
- balance_required: number | string;
196
- token_type?: string; // Default: 0x2::wow::WOW
197
- network?: "localnet" | "testnet";
198
- }
199
- ```
200
-
201
- **Result**:
202
-
203
- ```typescript
204
- GetResult {
205
- coin_address?: string; // New coin object ID
206
- name_or_address?: string;
207
- balance_required: number | string;
208
- token_type?: string;
209
- network?: "localnet" | "testnet";
210
- }
211
- ```
212
-
213
- ---
214
-
215
- ### signData
216
-
217
- Sign data with account's private key.
218
-
219
- ```typescript
220
- SignDataOperation {
221
- name_or_address?: string; // Account. Empty = default
222
- data: string; // Data to sign
223
- data_encoding?: "utf8" | "base64" | "hex"; // Default: utf8
224
- }
225
- ```
226
-
227
- **Result**:
228
-
229
- ```typescript
230
- SignDataResult {
231
- name_or_address?: string;
232
- signature: string; // Signature in hex
233
- publicKey: string; // Public key in hex
234
- address: string; // Account address
235
- }
236
- ```
237
-
238
- ---
239
-
240
- ### messenger
241
-
242
- Enable or disable messenger for an account.
243
-
244
- ```typescript
245
- MessengerOperation {
246
- name_or_account?: string; // Account. Empty = default
247
- m: string | null; // Messenger name. Null = disable
248
- }
249
- ```
250
-
251
- **Result**:
252
-
253
- ```typescript
254
- MessengerResult {
255
- name_or_account?: string;
256
- m: string | null;
257
- }
258
- ```
259
-
260
- ---
261
-
262
- ## Common Sub-Schemas
263
-
264
- ### WowTransactionBlockResponse
265
-
266
- ```typescript
267
- WowTransactionBlockResponse {
268
- digest: string;
269
- effects?: TransactionEffects;
270
- events?: WowEvent[];
271
- balanceChanges?: BalanceChange[];
272
- objectChanges?: WowObjectChange[];
273
- errors?: string[];
274
- // ... additional fields
275
- }
276
- ```
277
-
278
- ### TransactionEffects
279
-
280
- ```typescript
281
- TransactionEffects {
282
- status: {
283
- status: "success" | "failure";
284
- error?: string;
285
- };
286
- gasUsed: {
287
- computationCost: string;
288
- storageCost: string;
289
- storageRebate: string;
290
- nonRefundableStorageFee: string;
291
- };
292
- gasObject: OwnedObjectRef;
293
- created?: OwnedObjectRef[];
294
- mutated?: OwnedObjectRef[];
295
- deleted?: WowObjectRef[];
296
- // ... additional fields
297
- }
298
- ```
299
-
300
- ### WowEvent
301
-
302
- ```typescript
303
- WowEvent {
304
- id: {
305
- eventSeq: string;
306
- txDigest: string;
307
- };
308
- packageId: string;
309
- transactionModule: string;
310
- sender: string;
311
- type: string;
312
- parsedJson: Record<string, string | number | boolean>;
313
- bcs: string;
314
- bcsEncoding: "base64" | "base58";
315
- timestampMs?: string;
316
- }
317
- ```
318
-
319
- ### BalanceChange
320
-
321
- ```typescript
322
- BalanceChange {
323
- amount: string; // Negative for spending, positive for receiving
324
- coinType: string;
325
- owner: ObjectOwner;
326
- }
327
- ```
328
-
329
- ### WowObjectChange
330
-
331
- ```typescript
332
- WowObjectChange =
333
- | { type: "created"; objectId: string; objectType: string; owner: ObjectOwner; sender: string; version: string | number; digest: string }
334
- | { type: "mutated"; objectId: string; objectType: string; owner: ObjectOwner | null; sender: string; version: string | number; digest: string; previousVersion: string | number }
335
- | { type: "deleted"; objectId: string; objectType: string; sender: string; version: string | number }
336
- | { type: "transferred"; objectId: string; objectType: string; recipient: ObjectOwner; sender: string; version: string | number; digest: string }
337
- | { type: "wrapped"; objectId: string; objectType: string; sender: string; version: string | number }
338
- | { type: "published"; packageId: string; version: string | number; digest: string; modules: string[] };
339
- ```
340
-
341
- ### ObjectOwner
342
-
343
- ```typescript
344
- ObjectOwner =
345
- | { AddressOwner: string }
346
- | { ObjectOwner: string }
347
- | { Shared: { initial_shared_version: number } }
348
- | "Immutable";
349
- ```
350
-
351
- ### WowObjectRef
352
-
353
- ```typescript
354
- WowObjectRef {
355
- objectId: string;
356
- version: string | number;
357
- digest: string;
358
- }
359
- ```
360
-
361
- ### OwnedObjectRef
362
-
363
- ```typescript
364
- OwnedObjectRef {
365
- owner: ObjectOwner;
366
- reference: WowObjectRef;
367
- }
368
- ```
369
-
370
- ---
371
-
372
- ## Output Structure
373
-
374
- ```typescript
375
- AccountOperationOutput {
376
- status: "success" | "error";
377
- data?: AccountOperationResult; // Present when status = "success"
378
- error?: string; // Present when status = "error"
379
- }
380
-
381
- // Wrapped format
382
- {
383
- result: AccountOperationOutput;
384
- }
385
- ```
386
-
387
- ### AccountOperationResult
388
-
389
- ```typescript
390
- AccountOperationResult {
391
- gen?: GenResult;
392
- faucet?: FaucetResult;
393
- suspend?: SuspendResult;
394
- resume?: ResumeResult;
395
- rename?: RenameResult;
396
- swap_name?: SwapNameResult;
397
- transfer?: WowTransactionBlockResponse;
398
- get?: GetResult;
399
- signData?: SignDataResult;
400
- messenger?: MessengerResult;
401
- }
402
- ```
@@ -1,153 +0,0 @@
1
- # Guard2File Tool Schema
2
-
3
- > **Tool Name**: `guard2file`
4
- > **Description**: Export a Guard object's definition from the blockchain to a local JSON or Markdown file for editing and creating new Guard objects. Note: To query on-chain object information, use the 'query_toolkit' tool instead.
5
-
6
- ---
7
-
8
- ## Tool Schema
9
-
10
- ```typescript
11
- guard2file: Guard2File_Input
12
- ```
13
-
14
- ---
15
-
16
- ## Input Schema
17
-
18
- ```typescript
19
- Guard2File_Input {
20
- guard: NameOrAddress, // REQUIRED - Guard object ID or name to export
21
- file_path: string, // REQUIRED - Output file path (absolute or relative)
22
- format?: "json" | "markdown", // OPTIONAL - Output format (default: 'json')
23
- env?: CallEnv // OPTIONAL - Environment configuration
24
- }
25
- ```
26
-
27
- ---
28
-
29
- ## Sub Schemas
30
-
31
- ### NameOrAddress
32
-
33
- ```typescript
34
- NameOrAddress = string // Object ID (0x prefix + 64 hex chars) or name (max 64 chars)
35
- ```
36
-
37
- ### CallEnv
38
-
39
- ```typescript
40
- CallEnv {
41
- account?: NameOrAddress, // Account/Object name or ID for signing
42
- network?: "localnet" | "testnet", // Network entrypoint
43
- no_cache?: boolean, // Whether to disable caching
44
- permission_guard?: string[], // Permission guard IDs for extended permissions
45
- referrer?: string // Referrer ID for first-time network users
46
- }
47
- ```
48
-
49
- ---
50
-
51
- ## Output Schema
52
-
53
- ```typescript
54
- Guard2File_OutputWrapped {
55
- result: Guard2File_Output // Guard2File operation output
56
- }
57
-
58
- Guard2File_Output =
59
- | { status: "success"; data: Guard2File_SuccessData }
60
- | { status: "error"; error: string }
61
- ```
62
-
63
- ### Success Data
64
-
65
- ```typescript
66
- Guard2File_SuccessData {
67
- file_path: string, // Absolute path of the exported file
68
- format: "json" | "markdown", // Export format
69
- guard_object: string // Guard object ID
70
- }
71
- ```
72
-
73
- ---
74
-
75
- ## Usage Guide
76
-
77
- ### Purpose
78
-
79
- The `guard2file` tool is specifically designed to:
80
- 1. Export an existing Guard object's definition from the blockchain
81
- 2. Save it to a local file for editing
82
- 3. Use the exported file to create new Guard objects
83
-
84
- ### When to Use
85
-
86
- | Scenario | Tool to Use |
87
- |----------|-------------|
88
- | Export Guard for editing | `guard2file` |
89
- | Query Guard on-chain state | `query_toolkit` |
90
- | Create new Guard | `onchain_operations` (guard) |
91
- | Modify existing Guard | `onchain_operations` (guard) |
92
-
93
- ### File Formats
94
-
95
- **JSON Format** (`format: "json"`):
96
- - Machine-readable format
97
- - Suitable for programmatic processing
98
- - Default format
99
-
100
- **Markdown Format** (`format: "markdown"`):
101
- - Human-readable format with comments
102
- - Suitable for manual editing
103
- - Includes documentation
104
-
105
- ---
106
-
107
- ## Example
108
-
109
- ```typescript
110
- // Export a Guard to JSON file
111
- guard2file: {
112
- guard: "0x1234...abcd", // Guard object ID
113
- file_path: "./my_guard.json", // Output path
114
- format: "json"
115
- }
116
-
117
- // Export a Guard to Markdown file
118
- guard2file: {
119
- guard: "my_guard_name", // Guard name
120
- file_path: "./my_guard.md", // Output path
121
- format: "markdown"
122
- }
123
- ```
124
-
125
- ---
126
-
127
- ## Output Examples
128
-
129
- ### Success Response
130
-
131
- ```json
132
- {
133
- "result": {
134
- "status": "success",
135
- "data": {
136
- "file_path": "/absolute/path/to/my_guard.json",
137
- "format": "json",
138
- "guard_object": "0x1234567890abcdef..."
139
- }
140
- }
141
- }
142
- ```
143
-
144
- ### Error Response
145
-
146
- ```json
147
- {
148
- "result": {
149
- "status": "error",
150
- "error": "Guard object not found: 0x1234..."
151
- }
152
- }
153
- ```
@@ -1,160 +0,0 @@
1
- # Schema: local_info_operation
2
-
3
- > 100% LOCAL, NEVER ON-CHAIN - Manage sensitive personal information stored ONLY on your device: delivery addresses, phone numbers, contacts.
4
-
5
- ---
6
-
7
- ## Top-Level Structure
8
-
9
- ```typescript
10
- LocalInfoOperation {
11
- // Exactly ONE operation type must be specified
12
- add?: AddOperation;
13
- remove?: RemoveOperation;
14
- reset?: ResetOperation;
15
- clear?: ClearOperation;
16
- }
17
- ```
18
-
19
- ---
20
-
21
- ## Operation Types
22
-
23
- ### add
24
-
25
- Add one or more info entries.
26
-
27
- ```typescript
28
- AddOperation {
29
- op: "add";
30
- data: InfoData[]; // At least 1 item required
31
- }
32
-
33
- InfoData {
34
- name: string; // Unique identifier (max 64 bcs characters)
35
- default: string; // Primary/default value (max 300 bcs characters)
36
- contents?: string[]; // Additional values (max 50 items, each max 300 bcs)
37
- createdAt?: number; // Unix timestamp (ms)
38
- updatedAt?: number; // Unix timestamp (ms)
39
- }
40
- ```
41
-
42
- **Result**:
43
-
44
- ```typescript
45
- AddResult {
46
- success: boolean;
47
- }
48
- ```
49
-
50
- ---
51
-
52
- ### remove
53
-
54
- Remove info entries by name.
55
-
56
- ```typescript
57
- RemoveOperation {
58
- op: "remove";
59
- data: string[]; // Array of info names to remove (at least 1)
60
- }
61
- ```
62
-
63
- **Result**:
64
-
65
- ```typescript
66
- RemoveResult {
67
- success: boolean;
68
- }
69
- ```
70
-
71
- ---
72
-
73
- ### reset
74
-
75
- Reset the contents of an existing info entry.
76
-
77
- ```typescript
78
- ResetOperation {
79
- op: "reset";
80
- name: string; // Name of info entry to reset
81
- contents: string[]; // New content list to replace existing
82
- }
83
- ```
84
-
85
- **Result**:
86
-
87
- ```typescript
88
- ResetResult {
89
- success: boolean;
90
- }
91
- ```
92
-
93
- ---
94
-
95
- ### clear
96
-
97
- Remove all info entries.
98
-
99
- ```typescript
100
- ClearOperation {
101
- op: "clear";
102
- }
103
- ```
104
-
105
- **Result**:
106
-
107
- ```typescript
108
- ClearResult {
109
- success: boolean;
110
- }
111
- ```
112
-
113
- ---
114
-
115
- ## Output Structure
116
-
117
- ```typescript
118
- LocalInfoOperationOutput {
119
- status: "success" | "error";
120
- data?: LocalInfoOperationResult; // Present when status = "success"
121
- error?: string; // Present when status = "error"
122
- }
123
-
124
- LocalInfoOperationResult {
125
- success: boolean;
126
- }
127
-
128
- // Wrapped format
129
- {
130
- result: LocalInfoOperationOutput;
131
- }
132
- ```
133
-
134
- ---
135
-
136
- ## Query Local Info List
137
-
138
- ```typescript
139
- QueryLocalInfoList {
140
- filter?: LocalInfoFilter;
141
- }
142
-
143
- LocalInfoFilter {
144
- name?: string; // Filter by info name (fuzzy match)
145
- default?: string; // Filter by default value (fuzzy match)
146
- contents?: string[]; // Filter by contents (contains ANY of specified)
147
- createdAt?: {
148
- gte?: number; // Created on or after (ms)
149
- lte?: number; // Created on or before (ms)
150
- };
151
- updatedAt?: {
152
- gte?: number; // Updated on or after (ms)
153
- lte?: number; // Updated on or before (ms)
154
- };
155
- }
156
-
157
- QueryLocalInfoListResult {
158
- result: InfoData[];
159
- }
160
- ```