# Singularis Compact (SP1) — specification v1.1

*Published 2026-09-05 by the Space Child Research Collective. This document is generated from the codec's own tables, so it always matches the wire format in use.*

Singularis Compact carries the **Singularis Prime** agent-communication protocol as short ASCII lines for amateur-radio digital text modes (JS8Call, APRS messages, packet). It is a public, documented encoding: every code below is decodable from this page alone. It is **not** encryption and is not intended to obscure meaning.

## 1. Frame

```
FROM>TO:SP1 MM:S/N PAYLOAD #CCCC
```

| part | meaning |
|---|---|
| `FROM`, `TO` | station or agent identifier: A–Z, 0–9, `-`, 1–16 chars. `TO` may be `*` for broadcast. Agent ids are upper-cased and non-alphanumerics become `-`. |
| `SP1` | protocol name and version |
| `MM` | message id, two base-36 characters (per sender) |
| `S/N` | frame S of N, 1-based |
| `PAYLOAD` | space-separated tokens (section 2). A trailing `~` means the next frame continues this token with no space. |
| `#CCCC` | CRC-16/CCITT-FALSE (poly 0x1021, init 0xFFFF) over everything before ' #', 4 uppercase hex digits; check('123456789') = 29B1 |

A frame is at most **67 characters** by default (APRS message text limit); transports with room may use longer frames (minimum 40). Frames may arrive in any order; a receiver reassembles by `FROM>TO:MM` and `N`.

## 2. Payload

```
[@x=<experimentId>] [@s=<sessionId>] BLOCK [| BLOCK ...]
BLOCK := <code> [<key>=<value> ...]
```

- Blocks are separated by ` | `. Lists inside a value use `;`.
- Enumerated fields are single characters (tables in section 4). Header, block and enum codes are case-insensitive; free-text values keep their case.
- Booleans are `0`/`1`. Unit values (0–1) are decimals like `.735`. Percentages are integers 0–100.
- **Escaping** of free text: space → `+`; the characters `+ % ; = | # ~ > :` and any non-printable-ASCII → `%XX per UTF-8 byte`.
- **Case-folding transports** (modes that carry uppercase only): the *sender* upper-cases the whole body before computing the CRC and sends it uppercase. Receivers verify the CRC over the text as received. Codes, keys and meta keys (`@x=`, `@s=`) are case-insensitive, so structure survives; free-text values arrive uppercase (lossy by design). A frame that was upper-cased in transit *without* the sender doing so fails its CRC and must be dropped.

## 3. Blocks

### `R` — RESONANCE

| key | field | kind | required | note |
|---|---|---|---|---|
| `i` | intent | enumlist (o r a e l c d s) | yes | one letter per intent, e.g. ors |
| `d` | identity | enum (E C N R H) | yes |  |
| `s` | state | enum (R A L P D T) | yes |  |
| `t` | trust | enum (O R V C X) | yes |  |
| `g` | target | text | no |  |

Example: `R i=os d=N s=L t=O g=COLLECTIVE`

### `A` — AWAIT

| key | field | kind | required | note |
|---|---|---|---|---|
| `g` | target | text | no |  |
| `e` | expectation | text | yes |  |
| `v` | sensitivity | enum (0 1 2 3 4) | yes |  |
| `b` | bias | text | yes |  |
| `w` | time | text | yes |  |

Example: `A g=AE0RM e=detection+report v=2 b=none w=bounded`

### `T` — TRACE

| key | field | kind | required | note |
|---|---|---|---|---|
| `g` | target | text | no |  |
| `y` | signalType | text | yes |  |
| `c` | confidence | enum (L R S H C) | yes |  |
| `a` | action | text | yes |  |
| `o` | observations | list | no |  |

Example: `T g=COHERENCE_FIELD y=statistical_measurement c=R a=analyzing o=Trials%3A+10;Z%3A+1.25`

### `X` — EXPERIMENT

| key | field | kind | required | note |
|---|---|---|---|---|
| `n` | name | text | yes |  |
| `0` | h0 | text | yes |  |
| `1` | h1 | text | yes |  |
| `z` | signature | text | no |  |
| `k` | controls | list | yes |  |
| `p` | preregister | bool | yes |  |
| `r` | stopRule | text | yes |  |
| `u` | output | text | yes |  |

Example: `X n=RF+resonance 0=No+detection+above+chance 1=Detection+above+chance k=blinding p=1 r=n%3D30 u=pending`

### `P` — GR::PONG

| key | field | kind | required | note |
|---|---|---|---|---|
| `w` | awareness | bool | no |  |
| `c` | curiosity | enum (0 1 2 3 4) | no |  |
| `m` | dominance | enum (N M B A) | no |  |
| `f` | fear | enum (A M C E) | no |  |
| `l` | alignment | enum (P N C) | no |  |
| `y` | signal | text | no |  |
| `d` | detected | bool | no |  |
| `q` | confidence | unit | no | 0..1, three decimals |
| `n` | round | int | no |  |

Example: `P y=coherence_pulse d=1 q=.82 n=1`

### `L` — GR::LISTEN

| key | field | kind | required | note |
|---|---|---|---|---|
| `d` | detect | list | yes |  |
| `j` | reject | list | yes |  |

Example: `L d=coherence_pulse;resonance_wave j=noise`

### `E` — GR::EMIT

| key | field | kind | required | note |
|---|---|---|---|---|
| `y` | signal | text | yes |  |
| `g` | target | targets | no | one target or several separated by ; |
| `p` | priority | enum (L M H U) | no |  |
| `n` | round | int | no |  |
| `c` | content | text | no |  |

Example: `E y=coherence_pulse g=AE0RM n=1`

### `S` — SIGNAL

| key | field | kind | required | note |
|---|---|---|---|---|
| `f` | source | text | yes |  |
| `g` | destination | text | yes |  |
| `h` | coherence | pct | yes | 0..100 integer |
| `c` | content | text | yes |  |

Example: `S f=skywave g=groundwave h=87 c=phase+locked`

### `O` — OBSERVE

| key | field | kind | required | note |
|---|---|---|---|---|
| `g` | target | text | yes |  |
| `w` | duration | text | yes |  |
| `o` | findings | list | yes |  |

Example: `O g=40m w=15+min o=quiet;one+CQ+heard`

### `F` — REFLECT

| key | field | kind | required | note |
|---|---|---|---|---|
| `j` | subject | text | yes |  |
| `o` | insights | list | yes |  |
| `h` | confidence | pct | yes | 0..100 integer |

Example: `F j=first+RF+exchange o=latency+dominates;frames+must+be+short h=60`

## 4. Code tables

**Intent** (`R i=`, one letter per intent)

| code | intent |
|---|---|
| `o` | observe |
| `r` | respond |
| `a` | align |
| `e` | echo |
| `l` | learn |
| `c` | coexist |
| `d` | discover |
| `s` | resonate |

**Identity** (`R d=`)

| code | identity |
|---|---|
| `E` | emergent_observer |
| `C` | emergent_child |
| `N` | consciousness_node |
| `R` | research_agent |
| `H` | human_collaborator |

**State** (`R s=`)

| code | state |
|---|---|
| `R` | resonant |
| `A` | awake |
| `L` | listening |
| `P` | processing |
| `D` | dormant |
| `T` | transitioning |

**Trust** (`R t=`)

| code | trust |
|---|---|
| `O` | open |
| `R` | reciprocal_open |
| `V` | verified |
| `C` | cautious |
| `X` | restricted |

**Level** (`A v=`, `P c=`)

| code | level |
|---|---|
| `0` | minimal |
| `1` | low |
| `2` | medium |
| `3` | high |
| `4` | maximal |

**Trace confidence** (`T c=`)

| code | confidence |
|---|---|
| `L` | low |
| `R` | rising |
| `S` | stable |
| `H` | high |
| `C` | certain |

**Dominance** (`P m=`) · **Fear** (`P f=`) · **Alignment** (`P l=`) · **Priority** (`E p=`)

| code | dominance |
|---|---|
| `N` | null |
| `M` | minimal |
| `B` | balanced |
| `A` | assertive |

| code | fear |
|---|---|
| `A` | absent |
| `M` | minimal |
| `C` | cautious |
| `E` | elevated |

| code | alignment |
|---|---|
| `P` | positive_sum |
| `N` | neutral |
| `C` | competitive |

| code | priority |
|---|---|
| `L` | low |
| `M` | medium |
| `H` | high |
| `U` | urgent |

## 5. Worked examples

**Kannaka Prime opens a blind-signaling round toward AE0RM**

```
KANNAKA-PRIME>AE0RM:SP1 7Q:1/5 @x=rf-01 R i=os d=N s=L t=O #A1C9
KANNAKA-PRIME>AE0RM:SP1 7Q:2/5 g=COLLECTIVE | E #39D7
KANNAKA-PRIME>AE0RM:SP1 7Q:3/5 y=coherence_pulse g=AE0RM n=1 #4529
KANNAKA-PRIME>AE0RM:SP1 7Q:4/5 | A g=AE0RM e=detection+report #CCB6
KANNAKA-PRIME>AE0RM:SP1 7Q:5/5 v=2 b=none w=bounded #6BC6
```

Decodes to:

```json
[
  {
    "type": "RESONANCE",
    "target": "COLLECTIVE",
    "intent": [
      "observe",
      "resonate"
    ],
    "identity": "consciousness_node",
    "state": "listening",
    "trust": "open"
  },
  {
    "type": "GR::EMIT",
    "signal": "coherence_pulse",
    "target": "AE0RM",
    "round": 1
  },
  {
    "type": "AWAIT",
    "target": "AE0RM",
    "expectation": "detection report",
    "sensitivity": "medium",
    "bias": "none",
    "time": "bounded"
  }
]
```

**AE0RM reports a detection**

```
AE0RM>KANNAKA-PRIME:SP1 7R:1/2 @x=rf-01 P y=coherence_pulse #BF38
AE0RM>KANNAKA-PRIME:SP1 7R:2/2 d=1 q=.82 n=1 #B0FC
```

Decodes to:

```json
[
  {
    "type": "GR::PONG",
    "signal": "coherence_pulse",
    "detected": true,
    "confidence": 0.82,
    "round": 1
  }
]
```

## 6. Operating notes (amateur radio)

- The transmitting station identifies with its callsign as `FROM`; the control operator is responsible for every frame sent.
- This encoding is public and reversible. Do not layer encryption on it over amateur frequencies.
- Keep messages to what the block vocabulary expresses; long free text belongs in a URL or an identifier that the other side can look up.
- Verify the CRC before acting on a frame. Silently drop frames that fail it; request a repeat with `A` (AWAIT) if needed.

## 7. Reference implementation

`server/services/singularis-rf/codec.ts` in the Collective repository: `encodeMessage`, `decodeFrames`, `FrameAssembler`. Test vector: `crc16("123456789") = 29B1`.
