sil-openclaw 0.6.0 → 0.8.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.
Files changed (53) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/EXAMPLES.md +93 -0
  3. package/README.md +58 -120
  4. package/SECURITY.md +12 -9
  5. package/assets/banner-dark.svg +15 -0
  6. package/assets/banner.svg +15 -0
  7. package/dist/gateway/screen.js +174 -0
  8. package/dist/index.js +5 -9
  9. package/dist/lib/answers.js +59 -0
  10. package/dist/lib/screen-log.js +13 -0
  11. package/dist/lib/shopping-call.js +27 -28
  12. package/dist/lib/sil-client.js +49 -66
  13. package/dist/lib/tool-result.js +1 -1
  14. package/dist/tools/catalog.js +113 -272
  15. package/dist/tools/identity.js +79 -88
  16. package/openclaw.plugin.json +12 -7
  17. package/package.json +4 -2
  18. package/schema/PROVENANCE.md +7 -4
  19. package/schema/shopping-brief-read-request.schema.json +2 -1
  20. package/schema/shopping-brief-read-response.schema.json +98 -50
  21. package/schema/shopping-brief-write-request.schema.json +322 -0
  22. package/schema/{shopping-brief-create-response.schema.json → shopping-brief-write-response.schema.json} +3 -3
  23. package/schema/shopping-content-request.schema.json +12 -31
  24. package/schema/shopping-content-response.schema.json +14 -95
  25. package/schema/shopping-domain-get-request.schema.json +24 -1
  26. package/schema/shopping-domain-get-response.schema.json +23 -421
  27. package/schema/shopping-domain-search-request.schema.json +3 -3
  28. package/schema/shopping-domain-search-response.schema.json +3 -56
  29. package/schema/shopping-offers-request.schema.json +14 -9
  30. package/schema/shopping-offers-response.schema.json +368 -91
  31. package/schema/shopping-product-get-request.schema.json +4 -3
  32. package/schema/shopping-product-get-response.schema.json +347 -46
  33. package/schema/shopping-search-request.schema.json +53 -40
  34. package/schema/shopping-search-response.schema.json +408 -116
  35. package/schema/shopping-seller-get-request.schema.json +13 -1
  36. package/schema/shopping-seller-get-response.schema.json +594 -225
  37. package/schema/shopping-user-forget-request.schema.json +43 -0
  38. package/schema/shopping-user-forget-response.schema.json +74 -0
  39. package/schema/shopping-user-read-request.schema.json +37 -0
  40. package/schema/shopping-user-read-response.schema.json +372 -0
  41. package/schema/shopping-user-remember-request.schema.json +341 -0
  42. package/schema/shopping-user-remember-response.schema.json +66 -0
  43. package/schema/sil-whoami-request.schema.json +8 -0
  44. package/schema/sil-whoami-response.schema.json +99 -0
  45. package/sil-shopping/SKILL.md +149 -208
  46. package/dist/gateway/search-results.js +0 -99
  47. package/dist/lib/search-results-log.js +0 -23
  48. package/dist/lib/search-results-store.js +0 -116
  49. package/schema/shopping-brief-create-request.schema.json +0 -98
  50. package/schema/shopping-brief-edit-request.schema.json +0 -125
  51. package/schema/shopping-brief-edit-response.schema.json +0 -24
  52. package/schema/shopping-profile-edit-request.schema.json +0 -97
  53. package/schema/shopping-profile-edit-response.schema.json +0 -17
@@ -1,98 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://schemas.sil.com/shopping-brief-create-request.schema.json",
4
- "title": "sil shopping_brief_create — request",
5
- "type": "object",
6
- "required": [
7
- "title",
8
- "narrative"
9
- ],
10
- "properties": {
11
- "title": {
12
- "type": "string",
13
- "minLength": 1,
14
- "maxLength": 128,
15
- "description": "Names the job in a few words, so the buyer picks it out of their list."
16
- },
17
- "narrative": {
18
- "type": "string",
19
- "minLength": 1,
20
- "maxLength": 2000,
21
- "description": "Writes what a good buy looks like for THIS buyer, in their own terms — what they are after, what it has to do for them, and what would make it a bad buy. It is the spec of the job, so a want no keyed spec can carry stays here and still counts."
22
- },
23
- "domain": {
24
- "type": "string",
25
- "pattern": "^[a-z0-9_]+(\\.[a-z0-9_]+)*$",
26
- "maxLength": 255,
27
- "description": "Names the domain the specs below sit under: a domain path for product specs, `seller` for the seller specs, which belong to the whole brief."
28
- },
29
- "specs": {
30
- "type": "array",
31
- "items": {
32
- "type": "object",
33
- "required": [
34
- "key",
35
- "op",
36
- "value"
37
- ],
38
- "properties": {
39
- "key": {
40
- "type": "string",
41
- "minLength": 1,
42
- "maxLength": 64,
43
- "description": "Names the key from the domain read; `price` is a key every domain has."
44
- },
45
- "op": {
46
- "anyOf": [
47
- {
48
- "type": "string",
49
- "const": "eq"
50
- },
51
- {
52
- "type": "string",
53
- "const": "neq"
54
- },
55
- {
56
- "type": "string",
57
- "const": "gte"
58
- },
59
- {
60
- "type": "string",
61
- "const": "lte"
62
- },
63
- {
64
- "type": "string",
65
- "const": "in"
66
- },
67
- {
68
- "type": "string",
69
- "const": "nin"
70
- }
71
- ],
72
- "description": "Sends the operator the domain read listed for this key."
73
- },
74
- "value": {
75
- "description": "Sends the desired value, typed by the key's type."
76
- },
77
- "currency": {
78
- "type": "string",
79
- "pattern": "^[A-Z]{3}$",
80
- "minLength": 3,
81
- "maxLength": 3,
82
- "description": "On money, the currency the bound is tested in: sil holds no exchange rate, so it is tested against offers in this currency only. Leave it out to mean the buyer's own currency, as `sil_whoami` answers it."
83
- },
84
- "reason": {
85
- "type": "string",
86
- "minLength": 1,
87
- "maxLength": 256,
88
- "description": "Quotes the buyer's own words behind the spec, in English — translated, never a paraphrase, never a sentence they did not say; a spec derived from a measurement quotes the measurement. Reads them back before proposing to relax it."
89
- }
90
- },
91
- "additionalProperties": false
92
- },
93
- "maxItems": 32,
94
- "description": "Writes the wants it can already express, keyed and typed by the domain read."
95
- }
96
- },
97
- "additionalProperties": false
98
- }
@@ -1,125 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://schemas.sil.com/shopping-brief-edit-request.schema.json",
4
- "title": "sil shopping_brief_edit — request",
5
- "type": "object",
6
- "required": [
7
- "id"
8
- ],
9
- "properties": {
10
- "id": {
11
- "type": "string",
12
- "minLength": 1,
13
- "maxLength": 256,
14
- "description": "Names the brief to write to; one that is not the buyer's answers `not_found`."
15
- },
16
- "title": {
17
- "type": "string",
18
- "minLength": 1,
19
- "maxLength": 128,
20
- "description": "Renames the job."
21
- },
22
- "narrative": {
23
- "type": "string",
24
- "minLength": 1,
25
- "maxLength": 2000,
26
- "description": "Replaces the whole narrative, never appends to it."
27
- },
28
- "domain": {
29
- "type": "string",
30
- "pattern": "^[a-z0-9_]+(\\.[a-z0-9_]+)*$",
31
- "maxLength": 255,
32
- "description": "Names the domain `specs` and `remove` below sit under."
33
- },
34
- "specs": {
35
- "type": "array",
36
- "items": {
37
- "type": "object",
38
- "required": [
39
- "key",
40
- "op",
41
- "value"
42
- ],
43
- "properties": {
44
- "key": {
45
- "type": "string",
46
- "minLength": 1,
47
- "maxLength": 64,
48
- "description": "Names the key from the domain read; `price` is a key every domain has."
49
- },
50
- "op": {
51
- "anyOf": [
52
- {
53
- "type": "string",
54
- "const": "eq"
55
- },
56
- {
57
- "type": "string",
58
- "const": "neq"
59
- },
60
- {
61
- "type": "string",
62
- "const": "gte"
63
- },
64
- {
65
- "type": "string",
66
- "const": "lte"
67
- },
68
- {
69
- "type": "string",
70
- "const": "in"
71
- },
72
- {
73
- "type": "string",
74
- "const": "nin"
75
- }
76
- ],
77
- "description": "Sends the operator the domain read listed for this key."
78
- },
79
- "value": {
80
- "description": "Sends the desired value, typed by the key's type."
81
- },
82
- "currency": {
83
- "type": "string",
84
- "pattern": "^[A-Z]{3}$",
85
- "minLength": 3,
86
- "maxLength": 3,
87
- "description": "On money, the currency the bound is tested in: sil holds no exchange rate, so it is tested against offers in this currency only. Leave it out to mean the buyer's own currency, as `sil_whoami` answers it."
88
- },
89
- "reason": {
90
- "type": "string",
91
- "minLength": 1,
92
- "maxLength": 256,
93
- "description": "Quotes the buyer's own words behind the spec, in English — translated, never a paraphrase, never a sentence they did not say; a spec derived from a measurement quotes the measurement. Reads them back before proposing to relax it."
94
- }
95
- },
96
- "additionalProperties": false
97
- },
98
- "maxItems": 32,
99
- "description": "Replaces every spec on the keys they name under that domain; a range is the two rows on its key."
100
- },
101
- "remove": {
102
- "type": "array",
103
- "items": {
104
- "type": "string",
105
- "minLength": 1,
106
- "maxLength": 64,
107
- "description": "Names a key whose specs go."
108
- },
109
- "maxItems": 32,
110
- "description": "Drops the specs on these keys when the buyer gives a row up."
111
- },
112
- "decision": {
113
- "type": "string",
114
- "minLength": 1,
115
- "maxLength": 512,
116
- "description": "Logs in one sentence what the buyer changed and why; sil stamps it with the time, and the next session reads the reasoning rather than re-asking."
117
- },
118
- "status": {
119
- "type": "string",
120
- "const": "closed",
121
- "description": "Closes the brief when the job is over."
122
- }
123
- },
124
- "additionalProperties": false
125
- }
@@ -1,24 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://schemas.sil.com/shopping-brief-edit-response.schema.json",
4
- "title": "sil shopping_brief_edit — response",
5
- "type": "object",
6
- "required": [
7
- "status",
8
- "id"
9
- ],
10
- "properties": {
11
- "status": {
12
- "type": "string",
13
- "const": "ok",
14
- "description": "Reads the answer. Every other status arrives as an error body carrying recovery."
15
- },
16
- "id": {
17
- "type": "string",
18
- "minLength": 1,
19
- "maxLength": 256,
20
- "description": "Confirms which brief was written."
21
- }
22
- },
23
- "additionalProperties": false
24
- }
@@ -1,97 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://schemas.sil.com/shopping-profile-edit-request.schema.json",
4
- "title": "sil shopping_profile_edit — request",
5
- "type": "object",
6
- "properties": {
7
- "currency": {
8
- "type": "string",
9
- "pattern": "^[A-Z]{3}$",
10
- "minLength": 3,
11
- "maxLength": 3,
12
- "description": "Writes the currency the buyer prices in; every money row that names none means this one. sil converts nothing."
13
- },
14
- "measurements": {
15
- "type": "array",
16
- "items": {
17
- "type": "object",
18
- "required": [
19
- "name",
20
- "value"
21
- ],
22
- "properties": {
23
- "name": {
24
- "type": "string",
25
- "pattern": "^[a-z0-9_]+$",
26
- "minLength": 1,
27
- "maxLength": 64,
28
- "description": "Names the measurement in lower snake_case (`foot_length`, never \"foot length\"); writing the same name again replaces it."
29
- },
30
- "value": {
31
- "anyOf": [
32
- {
33
- "type": "number"
34
- },
35
- {
36
- "type": "string",
37
- "minLength": 1,
38
- "maxLength": 128
39
- }
40
- ],
41
- "description": "Reads a number to translate through the guide, or a size as it is printed."
42
- },
43
- "unit": {
44
- "type": "string",
45
- "minLength": 1,
46
- "maxLength": 16,
47
- "description": "Reads which unit the number is in before comparing it with a spec."
48
- }
49
- },
50
- "additionalProperties": false
51
- },
52
- "maxItems": 32,
53
- "description": "Writes what the buyer said about their body before the next search; an entry replaces the one of the same `name`."
54
- },
55
- "preferences": {
56
- "type": "array",
57
- "items": {
58
- "type": "object",
59
- "required": [
60
- "name",
61
- "value"
62
- ],
63
- "properties": {
64
- "name": {
65
- "type": "string",
66
- "pattern": "^[a-z0-9_]+$",
67
- "minLength": 1,
68
- "maxLength": 64,
69
- "description": "Names the preference in lower snake_case (`boot_closure`, never \"boot closure\"); writing the same name again replaces it."
70
- },
71
- "value": {
72
- "type": "string",
73
- "minLength": 1,
74
- "maxLength": 256,
75
- "description": "Reads the taste in the buyer's own words, and never asks what it answers."
76
- }
77
- },
78
- "additionalProperties": false
79
- },
80
- "maxItems": 32,
81
- "description": "Writes a taste that will still be true next session, in the buyer’s words."
82
- },
83
- "remove": {
84
- "type": "array",
85
- "items": {
86
- "type": "string",
87
- "pattern": "^[a-z0-9_]+$",
88
- "minLength": 1,
89
- "maxLength": 64,
90
- "description": "Names an entry that goes."
91
- },
92
- "maxItems": 32,
93
- "description": "Drops what stopped being true of the buyer."
94
- }
95
- },
96
- "additionalProperties": false
97
- }
@@ -1,17 +0,0 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://schemas.sil.com/shopping-profile-edit-response.schema.json",
4
- "title": "sil shopping_profile_edit — response",
5
- "type": "object",
6
- "required": [
7
- "status"
8
- ],
9
- "properties": {
10
- "status": {
11
- "type": "string",
12
- "const": "ok",
13
- "description": "Reads the answer. Every other status arrives as an error body carrying recovery."
14
- }
15
- },
16
- "additionalProperties": false
17
- }