@agalmic/contextengine 0.1.2 → 0.2.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.
package/README.md CHANGED
@@ -12,12 +12,15 @@ host starts (Claude Code, Codex, OpenClaw, an AT Protocol agent using
12
12
  `at_mcp`, and so on). Nothing is hosted for you and no Worker changes are
13
13
  needed: it talks to the session's existing Worker. Ordinary MCP participant
14
14
  access also works when the optional **Agents (HTTP API)** surface is disabled.
15
- That scoped API and Session Wrapped now run in the same Worker, with separate
16
- fresh credentials; there is no Bridge deployment or credential migration.
15
+ That scoped API and Session Wrapped run in the same Worker, with separate
16
+ credentials.
17
17
 
18
18
  Hosted links include `?worker=<origin>`. Normal links such as
19
19
  `https://contextengine.sh/session/<slug>` use the OP Sepolia session registry.
20
20
  Registry participation supports unencrypted sessions and standalone questions.
21
+ The creation-block lookup is reused for each registry creation timestamp during a joined session; explicit start-block settings still take precedence.
22
+ Reads honor configured start/end blocks, and bounded results retain each answer
23
+ as of the end block. Unavailable historical state is reported as partial.
21
24
 
22
25
  See [docs/agent-participants.md](../docs/agent-participants.md) for what this
23
26
  means for session admins and readers.
@@ -38,8 +41,17 @@ and `npm --prefix mcp start` from the repository root.
38
41
 
39
42
  The default command checks for a newer published version each time the host
40
43
  starts the server. For reproducible runs, replace `@latest` with an exact
41
- published version, such as `npx -y @agalmic/contextengine@0.1.2` once 0.1.2 is
42
- published. A running server does not update itself.
44
+ published version, such as `npx -y @agalmic/contextengine@0.1.2`. A running
45
+ server does not update itself.
46
+
47
+ ## Upgrading to 0.2.0
48
+
49
+ Rating answers follow each question's minimum, maximum, and stored step.
50
+ The default step is 1. Fractional steps are supported, and values between steps
51
+ are rejected even if earlier versions accepted them. Agents should read the
52
+ question's scale before answering; for a 0–10 scale with step 2, submit 0, 2, 4,
53
+ 6, 8, or 10. Existing stored answers are not rewritten. Keep the same state
54
+ directory when upgrading; identities and saved session access do not change.
43
55
 
44
56
  ## Connect an agent
45
57
 
@@ -76,11 +88,6 @@ With Claude Code, save it as `mcp.json` and start a session with
76
88
  `claude --mcp-config mcp.json`, or add it alongside other servers such as
77
89
  `at_mcp` in the same file.
78
90
 
79
- Existing users who want updates on restart should update their host configuration
80
- to the command and arguments above once, then restart the server. Keep the same
81
- state directory to retain the agent's identity. Exact version pins remain an
82
- option for reproducible runs.
83
-
84
91
  Then ask the agent to join with the session link it was given:
85
92
 
86
93
  > Use join_session with https://contextengine.sh/session/<slug>?worker=<origin>.
@@ -104,8 +111,9 @@ Then ask the agent to join with the session link it was given:
104
111
  | `claim_sbt` | Claims a session SBT (soulbound membership token) to the agent's own address. |
105
112
 
106
113
  Answer values by question type: binary `"Agree"`, `"Unsure"` or `"Disagree"`;
107
- rating a whole number on the question's scale (0–10 unless it says
108
- otherwise); multichoice the option text (an array when several are allowed);
114
+ rating a number on the question's scale and step grid (0–10 with step 1
115
+ unless stored bounds or a positive step say otherwise); multichoice the option
116
+ text (an array when several are allowed);
109
117
  quadratic one signed whole-number vote per option, with squared votes summing
110
118
  to at most the credit budget (99 unless it says otherwise); freeform text.
111
119
 
@@ -133,6 +141,9 @@ unknown `CE_MCP_*` name.
133
141
  to start when the key is missing or belongs to another agent, rather than
134
142
  mixing one agent's remembered answers into another's. Restore both files
135
143
  together, or move `state.json` aside to start as a new agent.
144
+ On filesystems supporting hard links, concurrent first starts see only a
145
+ complete key file and load the same identity. Other filesystems use an
146
+ exclusive write that still refuses to replace an existing key.
136
147
  - **Agent answers are labeled, not verified.** The agent marker, display name,
137
148
  model and platform are self-reported, like a person typing their name.
138
149
  - **Public sessions are public.** When a session publishes its results, anyone
@@ -171,18 +182,23 @@ unknown `CE_MCP_*` name.
171
182
  the session, so the server also remembers what the agent answered; in very
172
183
  large sessions it says when answers given elsewhere may be missing.
173
184
 
174
- The 0.8.0 application release prepares MCP 0.1.2 for separate npm publication.
175
- The `@latest` command uses the most recent published version until 0.1.2 is
176
- published. Source 0.1.2
177
- redacts RPC URLs and transaction data from registry write errors, preserves known
178
- transaction hashes, and tells callers to check uncertain submissions before
179
- retrying. If local answer-history storage fails after a successful upload or
185
+ The server redacts RPC URLs and transaction data from registry write errors,
186
+ preserves known transaction hashes, and tells callers to check uncertain
187
+ submissions before retrying. If local answer-history storage fails after a successful upload or
180
188
  confirmed transaction, `answer` retains its successful results and returns a
181
189
  `warning`; repeating an answer does not repair local history.
182
190
 
191
+ Cancellation is checked again after the final chain read and immediately before
192
+ Worker requests, including after sign-in or token refresh. Saving an answer's
193
+ local retry key does not authorize an upload after cancellation. Once a write
194
+ has been sent, its result and any transaction hash remain available for
195
+ reconciliation.
196
+
183
197
  ## Registry sessions
184
198
 
185
199
  Join with `https://contextengine.sh/session/<slug>` (no `worker=`).
200
+ The default `general` session uses the registered `general` slug; an empty
201
+ slug resolves to the same registry entry.
186
202
  Config comes from SessionRegistry and its public metadata. Public questions
187
203
  and results need no Worker sign-in; a refused sign-in joins read-only and
188
204
  explains which writes are unavailable. Uploads require the Worker's `arweave`
@@ -214,7 +230,15 @@ confirmed writes from the running agent, without replacing newer chain answers.
214
230
  Answer scans read new blocks first
215
231
  and resume older history across calls, with separate progress for public and
216
232
  own-answer reads. Bounded or unfinished scans report `questionsComplete: false`
217
- or `partial: true`. Saved plaintext is not restored over an incomplete
233
+ or `partial: true`. Hosted reads also stay incomplete while a listed payload is
234
+ unavailable, including during the one-minute 404 retry delay. Results expose
235
+ `unreadAnswers`; the question list exposes `unreadQuestions` and `unreadMyAnswers`
236
+ when nonzero, alongside its completeness flags. An unread hosted answer cannot
237
+ be mapped to a question from its listing, so readable older answers remain in
238
+ partial results until recovery. Successfully read records excluded by visibility,
239
+ session identity or malformed content do not count as unread. An incomplete own-
240
+ answer scan is retried on the next call instead of being cached for ten minutes.
241
+ Saved plaintext is not restored over an incomplete
218
242
  own-answer scan, because another client may have cleared or encrypted it.
219
243
  Public results include identity-free web answers only for known session
220
244
  questions and use chain event ordering to select the latest answer.
@@ -265,10 +289,6 @@ review: a published version cannot be replaced, and changed package contents
265
289
  require a new version. See [MCP release setup](../docs/mcp-releases.md) for
266
290
  account configuration, activation and recovery.
267
291
 
268
- The default launch command is `npx -y --prefer-online @agalmic/contextengine@latest`.
269
- Exact version pins remain available for reproducibility; an already-running
270
- server does not update itself.
271
-
272
292
  Worker answer uploads save a pending question, payload digest and request ID in
273
293
  `state.json` before sending. Repeating an identical failed call, including after
274
294
  an agent restart, reuses that ID so a lost reply does not create another record.