{
  "format": "astra.record-format-specification.v1",
  "version": "1.0.0",
  "purpose": "Interoperable preservation of research claims, reasoning, reviews and permissions. No scientific certification.",
  "compatibility": {
    "unknownFields": "Preserve on round trip",
    "unknownMajorVersions": "Reject or retain uninterpreted; do not silently convert",
    "identifiers": "Retain original document, packet, event and relationship IDs",
    "authorship": "Retain original author strings; restored membership does not automatically authorize access"
  },
  "records": {
    "astra.decision.v1": {
      "required": [
        "format",
        "id",
        "question",
        "sources",
        "decision",
        "nextTest"
      ],
      "sourceFields": [
        "id",
        "provider",
        "doi",
        "url",
        "title",
        "claim",
        "passage",
        "location",
        "sourceVersion",
        "reasoning",
        "competing",
        "review",
        "reviewReason",
        "reviewTrail"
      ],
      "optional": [
        "search",
        "interpretation",
        "decisionRule",
        "objection"
      ],
      "identity": "Packet id and library document id are separate. Claim anchor claim-N is the one-based source position in the immutable packet."
    },
    "astra.connected-decision.v1": {
      "required": [
        "format",
        "exportedAt",
        "decisionId",
        "packet",
        "claims",
        "events",
        "sourceChanges"
      ],
      "optional": [
        "linked",
        "claimLinks",
        "review",
        "argument",
        "graph"
      ],
      "identity": "Record exportedAt fixes the export time, not proof of when underlying research occurred. Original record and appended events must remain distinguishable."
    },
    "astra.argument-graph.v1": {
      "required": [
        "format",
        "nodes",
        "edges"
      ],
      "nodeFields": [
        "id",
        "decisionId",
        "claimId",
        "label",
        "passage",
        "location"
      ],
      "edgeFields": [
        "id",
        "from",
        "to",
        "relation",
        "reason"
      ],
      "relations": [
        "supports",
        "challenges",
        "qualifies"
      ]
    },
    "astra.ai-provenance.v1": {
      "required": [
        "format",
        "kind",
        "provider",
        "policyVersion",
        "requestedModel",
        "calls",
        "sources"
      ],
      "kind": "ai-suggestion",
      "sources": "Captured abstracts and supplied identifiers; absent provenance in legacy records remains unknown.",
      "endorsement": "Never convert machine output or validation into a human review."
    },
    "astra.personal-draft-backup.v1": {
      "required": [
        "format",
        "createdAt",
        "current",
        "revisions"
      ],
      "scope": "Authenticated user current draft and up to five available draft versions; excludes unrelated users."
    },
    "astra.backup-envelope.v1": {
      "required": [
        "format",
        "sha256",
        "payload"
      ],
      "payload": "Exact UTF-8 JSON string of astra.library-backup.v1",
      "sha256": "Lowercase SHA-256 hex of payload UTF-8 bytes. Integrity checksum, not signature."
    },
    "astra.library-backup.v1": {
      "required": [
        "format",
        "createdAt",
        "scope",
        "tables",
        "objects"
      ],
      "tables": [
        "repository_members",
        "repository_documents",
        "decision_dependencies",
        "dependency_reviews",
        "decision_events"
      ],
      "objectFields": [
        "key",
        "sha256",
        "base64"
      ],
      "key": "research/<document UUID>",
      "scope": "Complete registered invited library within documented interactive bounds. Not a whole-service or all-user backup.",
      "permissions": "repository_members captures the existing invited library membership; author emails and attribution stay in their records. Private drafts, secret keys, auth sessions and service configuration are excluded."
    }
  },
  "decisionEventFields": [
    "id",
    "decision_id",
    "parent_id",
    "kind",
    "source_key",
    "body",
    "author",
    "created_at"
  ],
  "eventBody": "JSON string; preserve unknown kinds and all fields. Parent may refer to a document, claim anchor, protocol, result, review or source-change event. Review states derive from insertion-ordered history; retained archive row order is significant.",
  "limits": {
    "libraryAttachmentBytes": 16000000,
    "perTableRows": 5000,
    "draftVersions": 5
  },
  "contentRights": "Format documentation can be independently implemented. It does not relicense uploaded content."
}
