@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.
- package/README.md +26 -30
- package/dist/cli.js +114 -19
- package/dist/cli.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +11 -1
- package/dist/index.js.map +1 -1
- package/dist/skills.d.ts +46 -1
- package/dist/skills.d.ts.map +1 -1
- package/dist/skills.js +154 -16
- package/dist/skills.js.map +1 -1
- package/dist/types.d.ts +31 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +3 -4
- package/scripts/install.js +5 -3
- package/wowok-arbitrator/SKILL.md +279 -0
- package/wowok-guard/SKILL.md +166 -139
- package/wowok-machine/SKILL.md +215 -280
- package/wowok-order/SKILL.md +290 -404
- package/wowok-provider/SKILL.md +453 -0
- package/wowok-safety/SKILL.md +176 -279
- package/wowok-tools/SKILL.md +329 -344
- package/schemas/onchain_operations/_common.md +0 -236
- package/schemas/onchain_operations/_index.md +0 -22
- package/schemas/onchain_operations/allocation.md +0 -50
- package/schemas/onchain_operations/arbitration.md +0 -95
- package/schemas/onchain_operations/contact.md +0 -36
- package/schemas/onchain_operations/demand.md +0 -52
- package/schemas/onchain_operations/gen_passport.md +0 -43
- package/schemas/onchain_operations/guard.md +0 -136
- package/schemas/onchain_operations/machine.md +0 -70
- package/schemas/onchain_operations/order.md +0 -57
- package/schemas/onchain_operations/payment.md +0 -32
- package/schemas/onchain_operations/permission.md +0 -57
- package/schemas/onchain_operations/personal.md +0 -59
- package/schemas/onchain_operations/progress.md +0 -35
- package/schemas/onchain_operations/repository.md +0 -81
- package/schemas/onchain_operations/reward.md +0 -40
- package/schemas/onchain_operations/service.md +0 -104
- package/schemas/onchain_operations/treasury.md +0 -74
- package/schemas/schema-account_operation.md +0 -402
- package/schemas/schema-guard2file.md +0 -153
- package/schemas/schema-local_info_operation.md +0 -160
- package/schemas/schema-local_mark_operation.md +0 -148
- package/schemas/schema-machineNode2file.md +0 -155
- package/schemas/schema-messenger_operation.md +0 -547
- package/schemas/schema-onchain_events.md +0 -201
- package/schemas/schema-onchain_table_data.md +0 -334
- package/schemas/schema-query_toolkit.md +0 -375
- package/schemas/schema-wip_file.md +0 -240
- package/schemas/schema-wowok_buildin_info.md +0 -296
- package/wowok-build/SKILL.md +0 -606
package/wowok-guard/SKILL.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
2
|
name: wowok-guard
|
|
3
3
|
description: |
|
|
4
4
|
WoWok Guard design mastery — comprehensive reference for the recursive,
|
|
@@ -26,34 +26,25 @@ A Guard is a **recursive computational tree** that evaluates to a boolean result
|
|
|
26
26
|
|
|
27
27
|
## Guard Structure
|
|
28
28
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
format?: "json" | "markdown";
|
|
49
|
-
};
|
|
50
|
-
|
|
51
|
-
rely?: { // Depend on other Guards
|
|
52
|
-
guards: string[]; // Guard IDs or names
|
|
53
|
-
logic_or?: boolean; // OR (true) vs AND (false/default)
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
```
|
|
29
|
+
**Operation**: `onchain_operations` with `operation_type: "guard"`.
|
|
30
|
+
|
|
31
|
+
**Schema Reference**: `schema_query({ action: "get", name: "onchain_operations_guard" })`
|
|
32
|
+
|
|
33
|
+
**Key Fields**:
|
|
34
|
+
- `namedNew`: Object creation options (name, tags, onChain, replaceExistName)
|
|
35
|
+
- `description`: Guard description
|
|
36
|
+
- `table`: Data table defining what the Guard validates
|
|
37
|
+
- `identifier`: 0-255, unique within this Guard
|
|
38
|
+
- `b_submission`: Must user submit this value?
|
|
39
|
+
- `value_type`: Expected type (0-18, see ValueType enum)
|
|
40
|
+
- `value`: Default value (if b_submission = false)
|
|
41
|
+
- `name`: Human-readable field name
|
|
42
|
+
- `root`: The computational tree
|
|
43
|
+
- `type: "node"`: Inline node definition
|
|
44
|
+
- `type: "file"`: Load from JSON/Markdown file
|
|
45
|
+
- `rely`: Dependencies on other Guards
|
|
46
|
+
- `guards`: Array of Guard IDs or names
|
|
47
|
+
- `logic_or`: OR (true) vs AND (false/default)
|
|
57
48
|
|
|
58
49
|
**CRITICAL**: The Guard's `table` defines ALL data the Guard uses — both submitted values and values passed from the calling object. Every `identifier` node in the tree references a table entry.
|
|
59
50
|
|
|
@@ -61,39 +52,46 @@ Guard {
|
|
|
61
52
|
|
|
62
53
|
## GuardNode — The Computational Tree
|
|
63
54
|
|
|
64
|
-
The GuardNode is a
|
|
55
|
+
The GuardNode is a discriminated union with 70+ type variants. Every node has a `type` field.
|
|
65
56
|
|
|
66
57
|
### Leaf Nodes (No Children)
|
|
67
58
|
|
|
68
59
|
#### identifier — Read from Guard Table
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
60
|
+
|
|
61
|
+
**Type**: `identifier`
|
|
62
|
+
|
|
63
|
+
**Key Field**:
|
|
64
|
+
- `identifier`: Guard table index (0-255)
|
|
65
|
+
|
|
66
|
+
Returns the value at the specified Guard table index.
|
|
73
67
|
|
|
74
68
|
#### value_type — Get ValueType of Child
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
69
|
+
|
|
70
|
+
**Type**: `value_type`
|
|
71
|
+
|
|
72
|
+
**Key Field**:
|
|
73
|
+
- `node`: Child GuardNode
|
|
74
|
+
|
|
78
75
|
Returns U8: the ValueType identifier of the child node's result.
|
|
79
76
|
|
|
80
77
|
---
|
|
81
78
|
|
|
82
79
|
### Query Node — Fetch On-Chain Data
|
|
83
80
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
```
|
|
81
|
+
**Type**: `query`
|
|
82
|
+
|
|
83
|
+
**Key Fields**:
|
|
84
|
+
- `query`: Query instruction ID (number) or name (string)
|
|
85
|
+
- `object`: Target object specification
|
|
86
|
+
- `identifier`: Guard table index for target object
|
|
87
|
+
- `convert_witness`: Optional witness conversion ID
|
|
88
|
+
- `parameters`: Array of GuardNode parameters for the query
|
|
89
|
+
|
|
90
|
+
Fetches data from on-chain WoWok objects. The `query` field references a built-in query instruction.
|
|
95
91
|
|
|
96
|
-
|
|
92
|
+
**Discover Available Queries**:
|
|
93
|
+
|
|
94
|
+
**Tool**: `wowok_buildin_info` with `info_type: "guard_instructions"`.
|
|
97
95
|
|
|
98
96
|
**System Addresses for Entity Queries**:
|
|
99
97
|
| Constant | Value | Use For |
|
|
@@ -108,26 +106,30 @@ Fetches data from on-chain WoWok objects. The `query` field references a built-i
|
|
|
108
106
|
All return **Bool**. Each takes 2-8 children unless noted.
|
|
109
107
|
|
|
110
108
|
#### Core Logic
|
|
111
|
-
|
|
109
|
+
|
|
110
|
+
| Type | Children | Description |
|
|
112
111
|
|------|----------|-------------|
|
|
113
112
|
| `logic_and` | `nodes[]` | ALL children must be true |
|
|
114
113
|
| `logic_or` | `nodes[]` | ANY child must be true |
|
|
115
114
|
| `logic_not` | `node` (1) | Inverts boolean result |
|
|
116
115
|
|
|
117
116
|
#### Equality
|
|
118
|
-
|
|
117
|
+
|
|
118
|
+
| Type | Children | Description |
|
|
119
119
|
|------|----------|-------------|
|
|
120
120
|
| `logic_equal` | `nodes[]` | Type+value equality; all must match first |
|
|
121
121
|
| `logic_string_nocase_equal` | `nodes[]` | Case-insensitive string equality |
|
|
122
122
|
|
|
123
123
|
#### String Comparison
|
|
124
|
-
|
|
124
|
+
|
|
125
|
+
| Type | Children | Description |
|
|
125
126
|
|------|----------|-------------|
|
|
126
127
|
| `logic_string_contains` | `nodes[]` | First contains all others (case-sensitive) |
|
|
127
128
|
| `logic_string_nocase_contains` | `nodes[]` | First contains all others (case-insensitive) |
|
|
128
129
|
|
|
129
130
|
#### Numeric Comparison (U256)
|
|
130
|
-
|
|
131
|
+
|
|
132
|
+
| Type | Children | Description |
|
|
131
133
|
|------|----------|-------------|
|
|
132
134
|
| `logic_as_u256_equal` | `nodes[]` | First == all others |
|
|
133
135
|
| `logic_as_u256_greater` | `nodes[]` | First > all others |
|
|
@@ -140,7 +142,8 @@ All return **Bool**. Each takes 2-8 children unless noted.
|
|
|
140
142
|
### Arithmetic Nodes (calc_*)
|
|
141
143
|
|
|
142
144
|
#### Numeric (all return U256, 2-8 children)
|
|
143
|
-
|
|
145
|
+
|
|
146
|
+
| Type | Operation |
|
|
144
147
|
|------|-----------|
|
|
145
148
|
| `calc_number_add` | first + second + third + ... |
|
|
146
149
|
| `calc_number_subtract` | first - second - third - ... |
|
|
@@ -149,7 +152,8 @@ All return **Bool**. Each takes 2-8 children unless noted.
|
|
|
149
152
|
| `calc_number_mod` | (first % second) % third % ... (throws on zero) |
|
|
150
153
|
|
|
151
154
|
#### String (return U64 or Bool)
|
|
152
|
-
|
|
155
|
+
|
|
156
|
+
| Type | Children | Returns | Description |
|
|
153
157
|
|------|----------|---------|-------------|
|
|
154
158
|
| `calc_string_length` | `node` (1) | U64 | UTF-8 byte length |
|
|
155
159
|
| `calc_string_contains` | `nodes[]` (2-8) | Bool | cs substring check |
|
|
@@ -157,9 +161,10 @@ All return **Bool**. Each takes 2-8 children unless noted.
|
|
|
157
161
|
| `calc_string_nocase_equal` | `nodes[]` (2-8) | Bool | ci equality |
|
|
158
162
|
|
|
159
163
|
#### String Index (return U64)
|
|
160
|
-
|
|
164
|
+
|
|
165
|
+
| Type | Children | Description |
|
|
161
166
|
|------|----------|-------------|
|
|
162
|
-
| `calc_string_indexof` | `nodeLeft` + `nodeRight` + `order` | Find substring index (cs). `order`: "forward"
|
|
167
|
+
| `calc_string_indexof` | `nodeLeft` + `nodeRight` + `order` | Find substring index (cs). `order`: "forward" or "backward". Not found → u64::MAX |
|
|
163
168
|
| `calc_string_nocase_indexof` | `nodeLeft` + `nodeRight` + `order` | Find substring index (ci) |
|
|
164
169
|
|
|
165
170
|
---
|
|
@@ -168,7 +173,7 @@ All return **Bool**. Each takes 2-8 children unless noted.
|
|
|
168
173
|
|
|
169
174
|
All take single `node` child.
|
|
170
175
|
|
|
171
|
-
|
|
|
176
|
+
| Type | Input → Output | Description |
|
|
172
177
|
|------|---------------|-------------|
|
|
173
178
|
| `convert_number_address` | Number → Address | Numeric to Address type |
|
|
174
179
|
| `convert_address_number` | Address → U256 | Address to numeric |
|
|
@@ -186,7 +191,8 @@ All take single `node` child.
|
|
|
186
191
|
### Vector Operations (vec_*)
|
|
187
192
|
|
|
188
193
|
#### Vector Properties
|
|
189
|
-
|
|
194
|
+
|
|
195
|
+
| Type | Children | Returns | Description |
|
|
190
196
|
|------|----------|---------|-------------|
|
|
191
197
|
| `vec_length` | `node` (1) | U64 | Number of elements |
|
|
192
198
|
|
|
@@ -194,7 +200,7 @@ All take single `node` child.
|
|
|
194
200
|
|
|
195
201
|
First node = vector, remaining nodes = values to check.
|
|
196
202
|
|
|
197
|
-
|
|
|
203
|
+
| Type | Vector Type | Element Type |
|
|
198
204
|
|------|------------|--------------|
|
|
199
205
|
| `vec_contains_bool` | VecBool (9) or Value (19) | Bool (0) or Value (19) |
|
|
200
206
|
| `vec_contains_address` | VecAddress (10) or Value (19) | Address (1) or Value (19) |
|
|
@@ -204,7 +210,7 @@ First node = vector, remaining nodes = values to check.
|
|
|
204
210
|
|
|
205
211
|
#### Vector Index (return U64)
|
|
206
212
|
|
|
207
|
-
|
|
|
213
|
+
| Type | Children | Description |
|
|
208
214
|
|------|----------|-------------|
|
|
209
215
|
| `vec_indexof_bool` | `nodeLeft` + `nodeRight` + `order` | Find bool index |
|
|
210
216
|
| `vec_indexof_address` | `nodeLeft` + `nodeRight` + `order` | Find address index |
|
|
@@ -212,7 +218,7 @@ First node = vector, remaining nodes = values to check.
|
|
|
212
218
|
| `vec_indexof_string_nocase` | `nodeLeft` + `nodeRight` + `order` | Find string index (ci) |
|
|
213
219
|
| `vec_indexof_number` | `nodeLeft` + `nodeRight` + `order` | Find number index |
|
|
214
220
|
|
|
215
|
-
`order`: "forward"
|
|
221
|
+
`order`: "forward" or "backward". Not found → u64::MAX.
|
|
216
222
|
|
|
217
223
|
---
|
|
218
224
|
|
|
@@ -222,7 +228,7 @@ Query on-chain records to validate operations. All return **Bool**.
|
|
|
222
228
|
|
|
223
229
|
These nodes check historical records (orders, progress steps, rewards, treasury operations) to enforce limits.
|
|
224
230
|
|
|
225
|
-
|
|
|
231
|
+
| Type | Key Parameters | Description |
|
|
226
232
|
|------|---------------|-------------|
|
|
227
233
|
| `record_check_recipient_order` | `receipt_type` + `recipient` | Check order count/status by recipient |
|
|
228
234
|
| `record_check_recipient_progress` | `recipient` | Check progress count by recipient |
|
|
@@ -242,111 +248,104 @@ Each uses `GuardNode` sub-nodes for its parameters (e.g., `recipient` is a Guard
|
|
|
242
248
|
## Guard Design Workflow
|
|
243
249
|
|
|
244
250
|
### Step 1: Query Available Instructions
|
|
245
|
-
|
|
246
|
-
wowok_buildin_info
|
|
247
|
-
|
|
251
|
+
|
|
252
|
+
**Tool**: `wowok_buildin_info` with `info_type: "guard_instructions"`.
|
|
253
|
+
|
|
248
254
|
Discover what queries are available and their expected parameter types.
|
|
249
255
|
|
|
250
256
|
### Step 2: Query Value Types
|
|
251
|
-
|
|
252
|
-
wowok_buildin_info
|
|
253
|
-
|
|
254
|
-
Understand the ValueType enum
|
|
257
|
+
|
|
258
|
+
**Tool**: `wowok_buildin_info` with `info_type: "value_types"`.
|
|
259
|
+
|
|
260
|
+
Understand the ValueType enum:
|
|
261
|
+
- Bool=0, Address=1, String=2
|
|
262
|
+
- U8=3, U16=4, U32=5, U64=6, U128=7, U256=8
|
|
263
|
+
- VecBool=9, VecAddress=10, VecString=11
|
|
264
|
+
- VecU8=12, VecU16=13, VecU32=14, VecU64=15, VecU128=16, VecU256=17
|
|
265
|
+
- VecVecU8=18
|
|
255
266
|
|
|
256
267
|
### Step 3: Design the Table
|
|
268
|
+
|
|
257
269
|
Decide what data the Guard needs:
|
|
258
270
|
- **Submitted data** (b_submission = true): User provides at operation time
|
|
259
271
|
- **Passed data** (b_submission = false): Object provides automatically
|
|
260
272
|
|
|
261
273
|
### Step 4: Build the Root Tree
|
|
274
|
+
|
|
262
275
|
- Start with `logic_and` as the root
|
|
263
276
|
- Add child nodes for each condition
|
|
264
277
|
- Use `query` + `identifier` patterns for data fetching
|
|
265
278
|
- Use comparison nodes for validation
|
|
266
279
|
|
|
267
|
-
### Step 5: Create Guard
|
|
268
|
-
|
|
269
|
-
onchain_operations
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
})
|
|
279
|
-
```
|
|
280
|
+
### Step 5: Create Guard
|
|
281
|
+
|
|
282
|
+
**Operation**: `onchain_operations` with `operation_type: "guard"`.
|
|
283
|
+
|
|
284
|
+
**Key Fields**:
|
|
285
|
+
- `namedNew`: Guard creation options with name
|
|
286
|
+
- `description`: Guard purpose
|
|
287
|
+
- `table`: Data table array
|
|
288
|
+
- `root`: Computational tree with `type: "node"` and `node` containing the tree
|
|
289
|
+
|
|
290
|
+
Guard creation is a **one-step** operation — the `guard` operation type has no `submission` field. It either succeeds (returns transaction) or fails (returns error).
|
|
280
291
|
|
|
281
292
|
### Step 6: Export for Review
|
|
282
|
-
```
|
|
283
|
-
guard2file({ guard: "my_guard", file_path: "./my_guard.json", format: "json" })
|
|
284
|
-
```
|
|
285
293
|
|
|
286
|
-
|
|
287
|
-
|
|
294
|
+
**Tool**: `guard2file`.
|
|
295
|
+
|
|
296
|
+
**Key Fields**:
|
|
297
|
+
- `guard`: Guard ID or name
|
|
298
|
+
- `file_path`: Output file path
|
|
299
|
+
- `format`: Output format ("json" or "markdown")
|
|
300
|
+
|
|
301
|
+
### Step 7: Use Guard in Operations
|
|
302
|
+
|
|
303
|
+
The Guard is now ready to be referenced by other operations (service, machine, progress, etc.) via their `submission` field.
|
|
288
304
|
|
|
289
305
|
---
|
|
290
306
|
|
|
291
307
|
## Common Guard Patterns
|
|
292
308
|
|
|
293
309
|
### Pattern 1: Identity Check (is sender == expected address?)
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
]
|
|
301
|
-
}
|
|
302
|
-
```
|
|
310
|
+
|
|
311
|
+
**Node Structure**:
|
|
312
|
+
- Type: `logic_equal`
|
|
313
|
+
- Nodes: Two `identifier` nodes
|
|
314
|
+
- First: identifier 0 (submitted address)
|
|
315
|
+
- Second: identifier 1 (stored address)
|
|
303
316
|
|
|
304
317
|
### Pattern 2: Minimum Balance
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
{ type: "identifier", identifier: 1 } // coin_type from table[1]
|
|
315
|
-
]
|
|
316
|
-
},
|
|
317
|
-
{ type: "identifier", identifier: 2 } // minimum balance from table[2]
|
|
318
|
-
]
|
|
319
|
-
}
|
|
320
|
-
```
|
|
318
|
+
|
|
319
|
+
**Node Structure**:
|
|
320
|
+
- Type: `logic_as_u256_greater_or_equal`
|
|
321
|
+
- Nodes:
|
|
322
|
+
- First: `query` node
|
|
323
|
+
- query: "balance" (check wowok_buildin_info for correct ID)
|
|
324
|
+
- object: { identifier: 0 } (account from table[0])
|
|
325
|
+
- parameters: [ { type: "identifier", identifier: 1 } ] (coin_type from table[1])
|
|
326
|
+
- Second: `identifier` node with identifier 2 (minimum balance from table[2])
|
|
321
327
|
|
|
322
328
|
### Pattern 3: Entity Registration Count
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
},
|
|
333
|
-
{ type: "identifier", identifier: 1 } // 0 (check count > 0)
|
|
334
|
-
]
|
|
335
|
-
}
|
|
336
|
-
```
|
|
329
|
+
|
|
330
|
+
**Node Structure**:
|
|
331
|
+
- Type: `logic_as_u256_greater`
|
|
332
|
+
- Nodes:
|
|
333
|
+
- First: `query` node
|
|
334
|
+
- query: "entity_registrar_records_length"
|
|
335
|
+
- object: { identifier: 0 } (ENTITY_REGISTRAR_ADDRESS 0xaab)
|
|
336
|
+
- parameters: []
|
|
337
|
+
- Second: `identifier` node with identifier 1 (0 to check count > 0)
|
|
337
338
|
|
|
338
339
|
### Pattern 4: Rate Limiting (record check)
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
// Inverts: "has records" → false (blocked)
|
|
349
|
-
```
|
|
340
|
+
|
|
341
|
+
**Node Structure**:
|
|
342
|
+
- Type: `logic_not`
|
|
343
|
+
- Node:
|
|
344
|
+
- Type: `record_check_recipient_order`
|
|
345
|
+
- receipt_type: "specific_value"
|
|
346
|
+
- recipient: { type: "identifier", identifier: 0 }
|
|
347
|
+
|
|
348
|
+
Inverts: "has records" → false (blocked)
|
|
350
349
|
|
|
351
350
|
---
|
|
352
351
|
|
|
@@ -371,4 +370,32 @@ Add `submission` after confirming the dry-run result.
|
|
|
371
370
|
| "type mismatch" | Wrong ValueType in table | Match table type to actual value type |
|
|
372
371
|
| "table field required" | Missing table array | Guards MUST have `table[]` |
|
|
373
372
|
| "guard validation failed" | Logic error | Export with `guard2file`, review logic |
|
|
374
|
-
| "object not found" | Wrong query object | Verify object addresses/identifiers |
|
|
373
|
+
| "object not found" | Wrong query object | Verify object addresses/identifiers |
|
|
374
|
+
|
|
375
|
+
---
|
|
376
|
+
|
|
377
|
+
## Query Witness Conversion Types
|
|
378
|
+
|
|
379
|
+
When using a `query` node's `convert_witness` field, the following numeric IDs allow cross-object type conversion — accessing a related object from the current context:
|
|
380
|
+
|
|
381
|
+
| Conversion | ID | Description |
|
|
382
|
+
|-----------|-----|-------------|
|
|
383
|
+
| TypeOrderProgress | 100 | From Order, get its Progress |
|
|
384
|
+
| TypeOrderMachine | 101 | From Order, get its Machine |
|
|
385
|
+
| TypeOrderService | 102 | From Order, get its Service |
|
|
386
|
+
| TypeProgressMachine | 103 | From Progress, get its Machine |
|
|
387
|
+
| TypeArbOrder | 104 | From Arb, get its Order |
|
|
388
|
+
|
|
389
|
+
---
|
|
390
|
+
|
|
391
|
+
## Schema Reference
|
|
392
|
+
|
|
393
|
+
| Purpose | Schema Name |
|
|
394
|
+
|---------|-------------|
|
|
395
|
+
| Guard operations | `onchain_operations_guard` |
|
|
396
|
+
| General on-chain operations | `onchain_operations` |
|
|
397
|
+
| Build-in info | `wowok_buildin_info` |
|
|
398
|
+
|
|
399
|
+
**Query Schema**: `schema_query({ action: "get", name: "<schema_name>" })`
|
|
400
|
+
|
|
401
|
+
**Related Skills**: [wowok-machine](../wowok-machine/SKILL.md) | [wowok-order](../wowok-order/SKILL.md) | [wowok-provider](../wowok-provider/SKILL.md)
|