sil-openclaw 0.5.1 → 0.6.0

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.
@@ -1,190 +0,0 @@
1
- ---
2
- name: mint
3
- description: The fallback — sil does not hold a domain for what the buyer is buying, so you write one. How to be sure it is really missing, where the leaf hangs, what the document says, what sil refuses, and what you ask the buyer once it stands. Load only when shopping_domain_search came back with no match, or when shopping_search refused the domain.
4
- ---
5
-
6
- # Minting a domain sil does not hold
7
-
8
- A domain sil has curated already carries a document: a markdown guide on how the thing is
9
- bought well, and the keys it is bought by. **That is the normal path** — read it with
10
- `shopping_domain_get` and get on with the job.
11
-
12
- This file is the fallback. The registry is **global and permanent**, so what you write here
13
- is what every later buyer inherits. A mint runs once, but the document is not frozen: sil
14
- grows it from the guide-like pages your own searches fetch, so a word, a value or a key
15
- missing today may stand tomorrow.
16
-
17
- ## First, be sure it is missing
18
-
19
- 1. **`shopping_domain_search { q }`** in the buyer's own words, not a path guess — `q` is
20
- matched against each standing path's text *and* its guide, so prose finds a domain that a
21
- path-shaped guess walks past. At most two reads: their own sentence, then the plain name.
22
- 2. **Judge fit on the `about` that comes back, never on how a path reads.**
23
- - a line describing *this* thing ⇒ **adopt** that path verbatim, read it with
24
- `shopping_domain_get`, use its keys as they are, coin nothing beside them;
25
- - a line describing a *broader* thing ⇒ the only mint allowed is a **descendant** of that
26
- path, never a sibling and never a re-rooted one;
27
- - **`matches: []`** ⇒ and only then, research how the thing is bought and write one.
28
- 3. **Then read the `tree` for where the family sits.** It groups every standing path by its
29
- family, which is how you shelve the new leaf where a specialist shop would.
30
- 4. **A read that did not return is not a read that returned nothing.** Any non-`ok` status
31
- leaves the mint out of reach: settle the read first. A `shopping_domain_get` answering
32
- `not_found` licenses nothing either — it is silent about the standing path under another
33
- parent, which is the fork this exists to prevent.
34
-
35
- ```json
36
- { "q": "pour-over coffee dripper" }
37
-
38
- → { "status": "ok", "matches": [],
39
- "tree": [ { "family": "product.coffee", "domains": 2,
40
- "paths": [ { "path": "product.coffee.espresso_machines", "name": "espresso machines" },
41
- { "path": "product.coffee.grinders", "name": "coffee grinders" } ] } ] }
42
- ```
43
-
44
- Nothing there is a dripper, and `product.coffee` is where the gear is shelved, so the leaf
45
- to write is `product.coffee.pour_over_drippers`.
46
-
47
- When `shopping_search` refuses with `invalid_request`, its refusals read alike — a domain the
48
- registry does not hold and a spec row it will not take carry the same status. Read the domain
49
- you submitted with `shopping_domain_get`: a guide back means fix the row and re-send,
50
- `not_found` means the domain was the problem.
51
-
52
- ## A leaf or a value
53
-
54
- Things bought on different keys are different leaves; the same keys with another value is a
55
- value; one thing has one leaf. An espresso machine, a dripper, a grinder and a kettle share
56
- almost no keys, so they are four sibling leaves under `product.coffee` — never four values
57
- of one `brew_method`, never a kitchen department. A black dripper is a value of `color`.
58
-
59
- - **A path names its ancestors** — the way the thing is shelved, dotted and lower-case:
60
- `product.coffee.pour_over_drippers`, never `product.pour_over_drippers` hung on the root,
61
- which sil refuses and which would be a fork every later buyer inherits.
62
- - **A setup of several things is several domains.** *"Everything for pour-over at home"* is
63
- a dripper, a grinder and a kettle: find or mint each, and run each search in the domain of
64
- the thing it is for. A kettle searched under coffee makers runs on the wrong keys.
65
-
66
- ## What the document has to say
67
-
68
- Write the guide the way sil's own read: **markdown, explanatory, for an agent who has never
69
- sold this thing.** Four things earn their place.
70
- - **What it is bought on** — the few things that actually decide it, said plainly.
71
- - **What goes wrong** — each common mistake and what it costs the buyer in real terms. Not
72
- "poor extraction": *the water runs through in ninety seconds and the cup is thin and
73
- sour.* This is what lets a later agent explain why a question matters.
74
- - **What to trust** — whose numbers mean something, whose tags are marketing, and which
75
- comparisons do not hold across makers.
76
- - **What buying it online takes** — what stands in for handling the thing: a measurement
77
- taken at home, a tolerance, a return window. Never "go to a shop" — they came here instead.
78
-
79
- Research it on the web first — how the thing is bought, never products.
80
-
81
- ## The axis
82
-
83
- One key is the axis the thing is sold in — the variant the buyer picks on the page. Mark it
84
- `variant_spec: true`, give it the `unit` it is printed in and the `step` the maker moves it
85
- by, and map what shops print onto its values with `forms`. A colour is never that key: a
86
- dripper is chosen by size and then offered in colours.
87
-
88
- ```json
89
- { "key": "brew_capacity", "display_name": "Brew capacity", "type": "number", "unit": "cups",
90
- "step": 1, "variant_spec": true, "labels": ["size", "μέγεθος"],
91
- "description": "How much the cone brews in one pour. A 01 overflows past two cups; a 02 run for one pours thin.",
92
- "forms": { "01": "2", "02": "4", "1-4 cups": "4", "03": "6" } }
93
- ```
94
-
95
- A value a page prints off that grid is not a value — sil keeps it as a proposed row.
96
-
97
- ## The values
98
-
99
- Enumerate the ways the thing is made **before** you coin an enum: one with no
100
- `allowed_values` is refused, because nothing can ever be asked of it. Where the values are
101
- numbers, use a number with a `unit` and a `step` instead.
102
-
103
- ```json
104
- { "key": "material", "display_name": "Material", "type": "enum", "allowed_values": ["ceramic", "glass", "plastic", "metal"],
105
- "description": "What the cone is made of. Ceramic holds the temperature and chips; plastic loses a degree and survives everything." }
106
- ```
107
-
108
- ## The name
109
-
110
- **`name` is what the thing is called, in English, and there is one.** Everything else the
111
- market calls it goes in `labels`, in any language: what shops print in a listing title,
112
- never a dictionary form. A Greek shop prints *καφετιέρα φίλτρου*, so that is the label —
113
- *καφεμηχανές* is the dictionary word and finds nothing:
114
- `{ "name": "pour-over dripper", "labels": ["dripper", "καφετιέρα φίλτρου", "V60"] }`.
115
-
116
- A spec carries the same two lists: `labels` are the headings pages print that key under,
117
- `aliases` the names another agent may send for it — both land in one mapping, so either
118
- spelling is answered on the standing key.
119
-
120
- **One concept, one spelling.** A widely shared attribute takes its conventional name; coin a
121
- fresh one only for a genuinely niche attribute.
122
-
123
- ## The bind
124
-
125
- - **You inherit every ancestor's key and may never rename one.** Use it by its own name.
126
- - **Re-declare a key only to change its configuration for your subtree** — unit, values, mark.
127
- - Re-declared with nothing the ancestor does not already say, it is not coined again: the
128
- reply answers `inherited: true`, and you filter on it anyway.
129
- - **A key that names a standing one binds to it.** Send `colour` and sil answers the standing
130
- `color`, names what it bound in `bound_from`, and keeps your spelling as a label of it.
131
- Never flip an inherited key's mark to get a different shape — a `gender` re-declared as a
132
- variant spec made every product read `gender: unknown`.
133
- - **Seller terms are never yours to coin.** Read them off `shopping_domain_get`'s `seller_specs`.
134
-
135
- ```json
136
- { "key": "colour", "display_name": "Colour", "type": "enum" }
137
-
138
- → { "key": "color", "variant_spec": true, "inherited": true, "bound_from": "colour" }
139
- ```
140
-
141
- ## The questions the mint just earned
142
-
143
- The keys you coined are the questions you now owe the buyer — one message, before the first
144
- search, each with what it costs them to get it wrong, never the field it fills. You coined
145
- them because they decide the buy: asking nothing is a search run on your own guesses.
146
-
147
- > Three things decide a dripper, and I'd rather ask than guess. How many cups you brew at
148
- > once — a small cone overflows past two, a big one run for one pours thin. What it's made
149
- > of — ceramic holds the heat and chips, plastic survives the sink and loses you a degree.
150
- > And whether you have filters already, because the cone size has to match the pack.
151
-
152
- ## What sil refuses, and what to send instead
153
-
154
- Each is an `invalid_request` whose `message` names the standing thing and the fix.
155
-
156
- - **A name that already stands.** *"product.coffee.espresso_machines already stands for
157
- "espresso machines" — adopt it, or descend from it"*: your `name`, a `label` or your
158
- path's last word collided.
159
- - **An enum with no values.** *"spec "size" is an enum with no allowed_values — list its
160
- values, or make it a number with a unit and a step"*.
161
- - **A mark flipped on an inherited key.** *"spec "gender" is a product spec at product — a
162
- leaf cannot make it a variant spec; drop the mark"*.
163
- - **A path hung on the root.** Only the path's root has to stand already, but a path
164
- directly under `product` is refused: name the family, or no family can give the leaf words.
165
-
166
- ## A mint, whole
167
-
168
- ```json
169
- { "path": "product.coffee.pour_over_drippers", "name": "pour-over dripper",
170
- "labels": ["dripper", "καφετιέρα φίλτρου"],
171
- "guide": "A pour-over dripper is bought on two things: how much it brews at once and what it is made of. …\n\n## What goes wrong\n\n- **A cone too big for the cup.** … The water runs the bed dry, the cup is thin and sour, and no grind setting rescues it. …\n\n## What to trust\n\nThe maker's own cup rating and filter size. A shop's \"barista grade\" tag measures nothing. …\n\n## Buying it online\n\nNothing has to be handled: count the cups actually poured in a morning, and buy where the filter pack is sold beside it …",
172
- "specs": [
173
- { "key": "brew_capacity", "display_name": "Brew capacity", "type": "number", "unit": "cups",
174
- "step": 1, "variant_spec": true, "labels": ["size", "μέγεθος"],
175
- "forms": { "01": "2", "02": "4", "1-4 cups": "4", "03": "6" },
176
- "description": "How much the cone brews in one pour. A 01 overflows past two; a 02 run for one pours thin." },
177
- { "key": "material", "display_name": "Material", "type": "enum", "allowed_values": ["ceramic", "glass", "plastic", "metal"],
178
- "description": "What the cone is made of, which decides the heat it takes out of the pour." },
179
- { "key": "colour", "display_name": "Colour", "type": "enum",
180
- "description": "The finish it is sold in." } ] }
181
-
182
- → { "status": "ok", "path": "product.coffee.pour_over_drippers",
183
- "specs": [ { "key": "brew_capacity", "variant_spec": true },
184
- { "key": "material" },
185
- { "key": "color", "variant_spec": true, "inherited": true, "bound_from": "colour" } ] }
186
- ```
187
-
188
- `colour` is the bind: the declaration says nothing the root's own `color` does not, so
189
- nothing was coined and `colour` is now one of its labels. Naming is silent to the buyer —
190
- the one thing you tell them is the domain you settled on, before a search spends on it.