Skip to main content

Interface: Annotation

Defined in: src/types/models/annotation.ts:398

Complete annotation structure following W3C Web Annotation model.

Remarks

Annotations are stored in the user's PDS and indexed by Chive. They combine:

  • Target: What text span is being annotated (optional for general reviews)
  • Entity Link: What entity the span represents (optional)
  • Body: Rich text comment with embedded references
  • Motivation: Why the annotation was made
  • Threading: Link to parent annotation for replies

Properties

body

readonly body: AnnotationBody

Defined in: src/types/models/annotation.ts:415

Rich text body with references


cid

readonly cid: CID

Defined in: src/types/models/annotation.ts:403

Content hash (CID) for verification


createdAt

readonly createdAt: Timestamp

Defined in: src/types/models/annotation.ts:427

Annotation creation timestamp


creator

readonly creator: DID

Defined in: src/types/models/annotation.ts:424

DID of the annotation creator


readonly optional entityLink: EntityLinkType

Defined in: src/types/models/annotation.ts:412

Entity link for the span (optional)


motivation

readonly motivation: AnnotationMotivation

Defined in: src/types/models/annotation.ts:418

Why the annotation was made


parentAnnotationUri?

readonly optional parentAnnotationUri: AtUri

Defined in: src/types/models/annotation.ts:421

Parent annotation URI for threading


preprintUri

readonly preprintUri: AtUri

Defined in: src/types/models/annotation.ts:406

AT-URI of the annotated preprint


target?

readonly optional target: TextSpanTarget

Defined in: src/types/models/annotation.ts:409

Target text span (undefined for general reviews)


updatedAt?

readonly optional updatedAt: Timestamp

Defined in: src/types/models/annotation.ts:430

Last update timestamp


uri

readonly uri: AtUri

Defined in: src/types/models/annotation.ts:400

AT-URI of the annotation in the user's PDS