@yaks/inbox 0.0.0-stage → 0.2.36

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 (88) hide show
  1. package/LICENSE +202 -0
  2. package/Person.tsx +275 -0
  3. package/Project.tsx +83 -0
  4. package/README.md +311 -2
  5. package/_dist/actions-browser.d.ts +8 -0
  6. package/_dist/actions-browser.d.ts.map +1 -0
  7. package/_dist/actions.d.ts +22 -0
  8. package/_dist/actions.d.ts.map +1 -0
  9. package/_dist/asks.d.ts +15 -0
  10. package/_dist/asks.d.ts.map +1 -0
  11. package/_dist/graph.d.ts +12 -0
  12. package/_dist/graph.d.ts.map +1 -0
  13. package/_dist/letters.d.ts +24 -0
  14. package/_dist/letters.d.ts.map +1 -0
  15. package/_dist/mail.d.ts +4 -0
  16. package/_dist/mail.d.ts.map +1 -0
  17. package/_dist/mod.d.ts +7 -0
  18. package/_dist/mod.d.ts.map +1 -0
  19. package/_dist/options.d.ts +18 -0
  20. package/_dist/options.d.ts.map +1 -0
  21. package/_dist/queries.d.ts +23 -0
  22. package/_dist/queries.d.ts.map +1 -0
  23. package/_dist/read.d.ts +18 -0
  24. package/_dist/read.d.ts.map +1 -0
  25. package/_dist/reader.d.ts +25 -0
  26. package/_dist/reader.d.ts.map +1 -0
  27. package/_dist/service.d.ts +8 -0
  28. package/_dist/service.d.ts.map +1 -0
  29. package/_dist/threads.d.ts +33 -0
  30. package/_dist/threads.d.ts.map +1 -0
  31. package/_dist/tools.d.ts +12 -0
  32. package/_dist/tools.d.ts.map +1 -0
  33. package/_dist/vocab.d.ts +5 -0
  34. package/_dist/vocab.d.ts.map +1 -0
  35. package/actions-browser.js +165 -0
  36. package/actions-browser.js.map +1 -0
  37. package/actions-browser.ts +158 -0
  38. package/actions.js +34 -0
  39. package/actions.js.map +1 -0
  40. package/actions.ts +53 -0
  41. package/asks.js +76 -0
  42. package/asks.js.map +1 -0
  43. package/asks.ts +94 -0
  44. package/deno.json +1 -0
  45. package/front.js +41 -0
  46. package/front.js.map +1 -0
  47. package/front.json +68 -0
  48. package/front.ts +38 -0
  49. package/graph.js +176 -0
  50. package/graph.js.map +1 -0
  51. package/graph.ts +182 -0
  52. package/inspect.tsx +22 -0
  53. package/letters.js +233 -0
  54. package/letters.js.map +1 -0
  55. package/letters.ts +325 -0
  56. package/mail.js +122 -0
  57. package/mail.js.map +1 -0
  58. package/mail.ts +148 -0
  59. package/mod.js +11 -0
  60. package/mod.js.map +1 -0
  61. package/mod.ts +24 -0
  62. package/options.js +15 -0
  63. package/options.js.map +1 -0
  64. package/options.ts +42 -0
  65. package/package.json +76 -4
  66. package/queries.js +240 -0
  67. package/queries.js.map +1 -0
  68. package/queries.ts +302 -0
  69. package/read.js +453 -0
  70. package/read.js.map +1 -0
  71. package/read.ts +476 -0
  72. package/reader.js +105 -0
  73. package/reader.js.map +1 -0
  74. package/reader.ts +147 -0
  75. package/service.js +29 -0
  76. package/service.js.map +1 -0
  77. package/service.ts +45 -0
  78. package/threads.js +182 -0
  79. package/threads.js.map +1 -0
  80. package/threads.ts +276 -0
  81. package/tools.js +101 -0
  82. package/tools.js.map +1 -0
  83. package/tools.ts +103 -0
  84. package/views.tsx +30 -0
  85. package/vocab.js +12 -0
  86. package/vocab.js.map +1 -0
  87. package/vocab.json +242 -0
  88. package/vocab.ts +11 -0
package/vocab.json ADDED
@@ -0,0 +1,242 @@
1
+ {
2
+ "$id": "urn:uuid:a7a33d26-7181-4318-a9c5-db771bcc8c65",
3
+ "$vocabulary": {
4
+ "https://yak.sh/vocab/core": true
5
+ },
6
+ "title": "inbox",
7
+ "$defs": {
8
+ "conversation": {
9
+ "$id": "urn:uuid:58669bf4-7cb0-4b61-a198-5489fece75a2",
10
+ "component": true,
11
+ "type": "object",
12
+ "description": "a thread with no other subject; doc holds the person's words and its first line as the title",
13
+ "properties": {}
14
+ },
15
+ "inbox_new": {
16
+ "tool": true,
17
+ "destructive": false,
18
+ "noun": "inbox",
19
+ "verb": "new",
20
+ "title": "Start a conversation",
21
+ "description": "Create a conversation: conversation{} marks the thread and doc{title, body} holds the caller's words, with their first line as the title. Attributed to the caller. Returns the applied bundles; starts no session itself.",
22
+ "input": {
23
+ "text": {
24
+ "type": "string",
25
+ "description": "the words that start the conversation; the first line is its title"
26
+ }
27
+ },
28
+ "required": [
29
+ "text"
30
+ ],
31
+ "positional": [
32
+ "text..."
33
+ ]
34
+ },
35
+ "inbox_summary": {
36
+ "$id": "urn:uuid:477dffa1-acd1-4078-94b5-5bfab68387b5",
37
+ "component": true,
38
+ "computed": true,
39
+ "type": "object",
40
+ "description": "Exact person inbox thread summaries, derived at read; history bodies are included only for an explicitly requested thread or server-side search.",
41
+ "properties": {
42
+ "actor": {
43
+ "$id": "urn:uuid:e71e71f5-5823-4d13-a73c-6dfee4114382",
44
+ "type": "string",
45
+ "ref": "entity",
46
+ "death": "keep",
47
+ "description": "the person whose attention is read"
48
+ },
49
+ "text": {
50
+ "$id": "urn:uuid:3b6c72f9-b867-439b-8a42-10277cd99579",
51
+ "type": "string",
52
+ "description": "text to find in said or received words"
53
+ },
54
+ "direction": {
55
+ "$id": "urn:uuid:bbe61a11-80ca-4a48-b49b-fa1a98efcebc",
56
+ "type": "string",
57
+ "description": "said or received; empty for both"
58
+ },
59
+ "all": {
60
+ "$id": "urn:uuid:70264e1c-7e2a-4e8e-a99d-3fbf866bfa28",
61
+ "type": "boolean",
62
+ "description": "include archived threads"
63
+ },
64
+ "lane": {
65
+ "$id": "urn:uuid:1541ebc9-a49b-4c73-bc86-6257e441a465",
66
+ "type": "string",
67
+ "description": "one lane, or empty for every lane"
68
+ },
69
+ "thread": {
70
+ "$id": "urn:uuid:58da44b7-d83e-45fc-b2f8-47d75b33aac3",
71
+ "type": "string",
72
+ "description": "one thread requested in full, or empty for summaries"
73
+ },
74
+ "threads": {
75
+ "$id": "urn:uuid:ccd730e1-6d30-4d66-b8a1-dc3d392d9960",
76
+ "type": "array",
77
+ "items": {
78
+ "type": "object"
79
+ },
80
+ "description": "exact ordered policy records with root/latest rows and lazy messages"
81
+ }
82
+ }
83
+ },
84
+ "inbox_list": {
85
+ "tool": true,
86
+ "noun": "inbox",
87
+ "verb": "list",
88
+ "title": "List the inbox",
89
+ "description": "List one row per inbox thread, classified as Needs you, Replies, Updates or Recent. Archive hides a thread until activity after archived.at. Search words you said or received; all includes archived threads. Defaults to the caller and 50 threads, blocking first then newest activity.",
90
+ "input": {
91
+ "who": {
92
+ "type": "string",
93
+ "ref": "entity",
94
+ "description": "whose inbox to read (default: the caller); pass its id or registered name"
95
+ },
96
+ "all": {
97
+ "type": "boolean",
98
+ "description": "include archived messages, which is how to find anything hidden",
99
+ "short": "a"
100
+ },
101
+ "limit": {
102
+ "type": "integer",
103
+ "description": "return at most this many threads (default 50)"
104
+ },
105
+ "lane": {
106
+ "type": "string",
107
+ "enum": [
108
+ "Needs you",
109
+ "Replies",
110
+ "Updates",
111
+ "Recent"
112
+ ],
113
+ "description": "return only this lane"
114
+ },
115
+ "search": {
116
+ "type": "string",
117
+ "description": "search thread words"
118
+ },
119
+ "direction": {
120
+ "type": "string",
121
+ "enum": [
122
+ "said",
123
+ "received"
124
+ ],
125
+ "description": "search words you said or received"
126
+ }
127
+ },
128
+ "readOnly": true,
129
+ "positional": [
130
+ "who"
131
+ ]
132
+ },
133
+ "inbox_archive": {
134
+ "tool": true,
135
+ "destructive": false,
136
+ "noun": "inbox",
137
+ "verb": "archive",
138
+ "title": "Archive an inbox item",
139
+ "description": "Hide a thread from one person\u2019s inbox until activity after their archive timestamp. Repeated archive refreshes that timestamp on their subscription row. The entity remains unarchived; inbox list --all includes hidden threads.",
140
+ "input": {
141
+ "item": {
142
+ "type": "string",
143
+ "ref": "entity",
144
+ "description": "the item to archive; any entity an inbox can hold; pass its id or registered name"
145
+ },
146
+ "who": {
147
+ "type": "string",
148
+ "ref": "entity",
149
+ "description": "whose attention to mark (default: the caller)"
150
+ }
151
+ },
152
+ "required": [
153
+ "item"
154
+ ],
155
+ "idempotent": true,
156
+ "positional": [
157
+ "item"
158
+ ]
159
+ },
160
+ "mail_notice": {
161
+ "$id": "urn:uuid:0d6ffa72-4100-4812-8a0e-4d47d8dfb013",
162
+ "component": true,
163
+ "journal": false,
164
+ "type": "object",
165
+ "description": "An email rendering of inbox activity, not new conversation; its snapshot prevents re-sending the same activity. A digest has no mail.target.",
166
+ "properties": {
167
+ "activity": {
168
+ "$id": "urn:uuid:4698c8c5-3958-4528-b231-c1a4862b1584",
169
+ "type": "string",
170
+ "format": "date-time",
171
+ "description": "the inbox activity cutoff represented by this letter, kept as it was when rendered"
172
+ },
173
+ "comment": {
174
+ "$id": "urn:uuid:1b3c8752-1f6a-41e2-bf5a-e0263b1ac4e8",
175
+ "type": "string",
176
+ "ref": "comment",
177
+ "death": "keep",
178
+ "description": "the comment presented in the letter, which an email reply answers"
179
+ },
180
+ "thread": {
181
+ "$id": "urn:uuid:e6c6dc4b-441b-4800-bf57-a0e7f703167f",
182
+ "type": "string",
183
+ "ref": "entity",
184
+ "death": "keep",
185
+ "description": "the thread included in a digest snapshot"
186
+ },
187
+ "letter": {
188
+ "$id": "urn:uuid:69a825fb-fdea-4754-8bcd-cb90a7fa4239",
189
+ "type": "string",
190
+ "ref": "mail",
191
+ "death": "keep",
192
+ "description": "the digest that included this thread activity"
193
+ }
194
+ }
195
+ },
196
+ "inbox_open": {
197
+ "tool": true,
198
+ "destructive": false,
199
+ "noun": "inbox",
200
+ "verb": "open",
201
+ "title": "Read an inbox thread",
202
+ "description": "Mark a thread read in one person\u2019s inbox, refreshing opened on their subscription row. Leaves the entity\u2019s own state unchanged.",
203
+ "input": {
204
+ "item": {
205
+ "type": "string",
206
+ "ref": "entity",
207
+ "description": "the thread or message read; pass its id or registered name"
208
+ },
209
+ "who": {
210
+ "type": "string",
211
+ "ref": "entity",
212
+ "description": "whose attention to mark (default: the caller)"
213
+ }
214
+ },
215
+ "required": [
216
+ "item"
217
+ ],
218
+ "idempotent": true,
219
+ "positional": [
220
+ "item"
221
+ ]
222
+ }
223
+ },
224
+ "kinds": {
225
+ "conversation": {
226
+ "$id": "urn:uuid:58669bf4-7cb0-4b61-a198-5489fece75a2",
227
+ "description": "a thread with no other subject; doc holds the person's words and its first line as the title",
228
+ "with": {
229
+ "doc": true
230
+ },
231
+ "examples": [
232
+ {
233
+ "conversation": {},
234
+ "doc": {
235
+ "title": "Where does the recipe box live?",
236
+ "body": "Where does the recipe box live?"
237
+ }
238
+ }
239
+ ]
240
+ }
241
+ }
242
+ }
package/vocab.ts ADDED
@@ -0,0 +1,11 @@
1
+ /** Inbox declarations shared by hosts and browser readers. They carry no I/O. */
2
+ import type { VocabDoc } from 'jsr:@yaks/vocab@0.2.36'
3
+ import doc from './vocab.json' with { type: 'json' }
4
+ import manifest from './package.json' with { type: 'json' }
5
+
6
+ /** The conversation mark and the inbox_new tool declaration. */
7
+ export let inboxDoc: VocabDoc = doc as VocabDoc
8
+ /** The package description, from its manifest. */
9
+ export let description: string = manifest.description
10
+ /** Every vocabulary document this package declares. */
11
+ export let docs: VocabDoc[] = [inboxDoc]