1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
//! The [`Stream`](super::Stream)'s JSON spelling, both directions (REMOTE §3,
//! bl-73e7) — beside the type that owns it, exactly as `transcript::wire` and
//! `rail::wire` sit beside theirs: the shape of a fold *is* the folding
//! module's vocabulary, so the boundary names it rather than restating it.
//!
//! Three fields, each optional in the sense the type already gives them:
//! `text` and `thinking` are absent until a delta of that kind has landed —
//! which is not the same claim as an empty string — and `delta` names the kind
//! of the **last** one, absent while the stream has produced nothing at all
//! (§5.1 #9's "waiting for the API").
//!
//! **What the two text fields mean depends on which read spelled them, and the
//! difference is the reader's own position** (bl-3655). On a *pull* — the
//! derivation's `Stream`, and the one-shot `Query::Follow` answer an intake
//! that cannot hold a connection gets — they are the accumulated answer. On the
//! **follow lane** they are what landed since that read's previous frame. The
//! two are one rule and not two spellings: absorb every frame of a read, in
//! order, onto an empty fold, and a read of one frame lands on the accumulated
//! value. So `delta` names the kind of the last content event either way, and
//! nothing here needs a flag saying which kind of answer it is.
use ;
use ;
/// The token for each [`Delta`] arm — one table, read by both directions, so a
/// spelling cannot drift from its reading.
const TEXT: &str = "text";
const THINKING: &str = "thinking";
/// Encode one fold.
/// Read one back. Strict on a field that is present and of the wrong shape,
/// forgiving of one that is absent — the codec's own discipline: absence is a
/// reading, and a `delta` naming no arm is a codec that has drifted.
/// The token one arm is written as.