Skip to content

0.0.5: the chain document as an immutable Nostr event whose id is the chain's hash - #29

Merged
melvincarvalho merged 3 commits into
gh-pagesfrom
chain-document-event
Oct 1, 2026
Merged

melvincarvalho merged 3 commits into
gh-pagesfrom
chain-document-event

Conversation

@melvincarvalho

Copy link
Copy Markdown
Contributor

Closes #24. Spec text only; no reference-node change in this PR.

  • 3. Chain: a name row (an alias, not an identity) and a paragraph: the chain document is a Nostr event of kind 3500 (regular, immutable); its event id is the chain's hash, what the tip points at, what a client verifies the document against, and what anything that must commit to a chain uses (the peg-in tweak slot in Peg-in by taproot commitment (tweak) beside the OP_RETURN marker #23, a nested chain's parent). The event's pubkey is the signer; no signer field. Re-signing is a new chain.
  • 5. Genesis: travels inside the chain event; genesisHash stays as a cross-check; kind 33501 still read for pre-0.0.5 chains.
  • 11. Distribution: two names, two roles. The hash is the identity; the alias sidestr:<name> is the tip's d. Resolution: alias → newest tip → e tag → the event, verified by id and signature (a relay or a mirror may serve it). The alias is still a name, not a proof, now with a proof to point at. Pre-0.0.5 chains resolve as before until their signer publishes the event.
  • Appendix A: kind 3500 (regular, immutable); the tip gains e; d tags are the alias; 33501 marked pre-0.0.5.
  • Changelog 0.0.5; index.html metadata says 0.0.5.

Why regular, not addressable: an addressable event is replaceable by its signer and addressed by signer + d, so its id is not a stable hash of the chain. The tip stays addressable and points at the document.

Kind 3500 is not in the NIPs kind table (nearest regular kinds 3455 and 3512) and two relays that carry our tips hold no events of it.

…able) and its id is the chain's hash; the alias sidestr:<name> for people and tags; the tip names the document (e); the genesis travels inside it; the signer field goes; chains made before 0.0.5 read as before until their signer publishes the event (closes #24)

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The terminology migration is incomplete — Appendix A now labels the tip/document tags "chain alias" while the §8/§11 body text still calls the same tags "chain id," reintroducing the ambiguity this PR aims to remove.

Review effort: Balanced
Findings: 1 Low severity

Open (1)
What changed in this PR

This PR advances the sidestr specification from draft 0.0.4 to 0.0.5 (spec text only; no reference-node changes). It redefines the chain document as an immutable Nostr event (kind 3500, regular) whose event id is the chain's cryptographic hash, replacing the old mirror-served chain.json whose authenticity rested on a self-asserted signer field. The change splits the former single "chain id" into two roles: the hash (the verifiable identity the tip points at and that anything cryptographic commits to) and the human-facing alias sidestr:<name>. It folds the genesis into the chain event, preserves backward compatibility for pre-0.0.5 chains (kind 33501 / chain.json), and bumps site metadata. Note: README.md:7 still advertises "draft 0.0.4" and was not updated.

Changes:

  • Section 3 adds a name overlay row and defines the chain document as a regular, immutable kind-3500 event whose id is the chain's hash (no signer field).
  • Sections 5 and 11 update genesis handling (travels inside the chain event; genesisHash as cross-check) and distribution/resolution (hash vs alias, e-tag lookup, pre-0.0.5 fallback), with a matching Appendix A kinds-table update and a 0.0.5 changelog entry.
  • index.html metadata updated from 0.0.4 to 0.0.5.
File Description
SPEC.md Bumps version; adds name row and kind-3500 chain-event definition (§3); folds genesis into the event (§5); introduces hash/alias resolution (§11); updates Appendix A kinds table and adds a 0.0.5 changelog entry.
index.html Updates the description, og:title, and twitter:title metadata from draft 0.0.4 to 0.0.5.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread SPEC.md Resolved
…ocuments and the genesis's chain field (a document cannot carry its own id), the hash for a nested chain's parent and wherever a chain is committed to (Copilot review)
@melvincarvalho

Copy link
Copy Markdown
Contributor Author

Addressed: every remaining "chain id" now says which name it is. The alias in the tip's d/n, rule documents' d, the chain tag, both OP_RETURNs and the genesis's chain field (a document cannot contain its own id); the hash for a nested chain's parent and for anything that commits to a chain. The tip now also carries e = the chain event in section 11's description, matching Appendix A. Section 10 gives the first chain's alias and notes its hash follows once the signer publishes the event.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🔵 Needs a closer look

It is a foundational protocol-identity change (new event kind, folded genesis, migration semantics) that warrants human sign-off, and the version bump was not propagated to README.md.

Review effort: Balanced
Findings: None

Resolved since last review (1)

@melvincarvalho

Copy link
Copy Markdown
Contributor Author

README now says draft 0.0.5 too.

@melvincarvalho
melvincarvalho merged commit 77d4af0 into gh-pages Oct 1, 2026
1 check passed
@melvincarvalho
melvincarvalho deleted the chain-document-event branch October 1, 2026 13:21
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 1, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The chain document as a signed, immutable Nostr event with a self-certifying id

2 participants