-
Notifications
You must be signed in to change notification settings - Fork 6
feat: Claim and Attestation schemas for claims engine interop #53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| id: Attestation | ||
| name: Attestation | ||
| prefixes: | ||
| linkml: https://w3id.org/linkml/ | ||
| rfs: https://framework.regen.network/schema/ | ||
| rft: https://framework.regen.network/taxonomy/ | ||
|
|
||
| imports: | ||
| - linkml:types | ||
| - core | ||
| - taxonomy | ||
| - Entity | ||
|
|
||
| default_prefix: rfs | ||
| default_range: string | ||
|
|
||
| classes: | ||
| Attestation: | ||
| description: >- | ||
| A reviewer's attestation about a Claim. Maps to the KOI | ||
| claim_attestations table and aligns with on-chain MsgAttest | ||
| and Ethereum Attestation Service (EAS) attestation patterns. | ||
| slots: | ||
| - name | ||
| - description | ||
| attributes: | ||
| attestsClaim: | ||
| slot_uri: rfs:attestsClaim | ||
| description: >- | ||
| Reference to the Claim being attested, by RID or IRI. | ||
| range: string | ||
| required: true | ||
| hasReviewer: | ||
| slot_uri: rfs:hasReviewer | ||
| description: >- | ||
| The entity providing the attestation. Must have a registered | ||
| identity (KOI entity URI and/or wallet address). | ||
| range: Entity | ||
| required: true | ||
| inlined: true | ||
| hasVerdict: | ||
| slot_uri: rfs:hasVerdict | ||
| description: >- | ||
| The reviewer's verdict on the claim. | ||
| range: VerdictType | ||
| required: true | ||
| rationale: | ||
| slot_uri: rfs:rationale | ||
| description: >- | ||
| Free-text explanation of the verdict, including any conditions | ||
| or caveats noted during review. | ||
| range: string | ||
| evidenceReviewed: | ||
| slot_uri: rfs:evidenceReviewed | ||
| description: >- | ||
| URIs of evidence documents, datasets, or field observations | ||
| reviewed as part of this attestation. | ||
| range: uri | ||
| multivalued: true | ||
| attestationDate: | ||
| slot_uri: rfs:attestationDate | ||
| description: Date when the attestation was made. | ||
| range: date | ||
| contentHash: | ||
| slot_uri: rfs:contentHash | ||
| description: >- | ||
| BLAKE2b-256 content hash of the canonical attestation | ||
| representation, used for on-chain anchoring. | ||
| range: string | ||
| graphIri: | ||
| slot_uri: rfs:graphIri | ||
| description: >- | ||
| On-chain graph IRI from Regen Data Module MsgAttest, | ||
| using ContentHash.Graph encoding. | ||
| range: uri | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,136 @@ | ||
| id: Claim | ||
| name: Claim | ||
| prefixes: | ||
| linkml: https://w3id.org/linkml/ | ||
| rfs: https://framework.regen.network/schema/ | ||
| rft: https://framework.regen.network/taxonomy/ | ||
| schema: http://schema.org/ | ||
| qudt: http://qudt.org/schema/qudt/ | ||
| unit: http://qudt.org/vocab/unit/ | ||
|
|
||
| imports: | ||
| - linkml:types | ||
| - core | ||
| - taxonomy | ||
| - Entity | ||
| - Impact | ||
| - SDG | ||
| - Methodology | ||
|
|
||
| default_prefix: rfs | ||
| default_range: string | ||
|
|
||
| classes: | ||
| Claim: | ||
| description: >- | ||
| A verifiable claim about ecological, social, or financial outcomes | ||
| associated with a place, practice, or project. Claims are the atomic | ||
| unit of the regenerative claims engine, linking a claimant's assertion | ||
| to a subject entity with typed impact and temporal bounds. | ||
| slots: | ||
| - name | ||
| - description | ||
| - url | ||
| slot_usage: | ||
| name: | ||
| required: true | ||
| description: Human-readable title of the claim. | ||
| attributes: | ||
| hasClaimType: | ||
| slot_uri: rfs:hasClaimType | ||
| description: >- | ||
| The primary category of the claim, drawn from the FWG ClaimType | ||
| taxonomy. Determines which verification pathways apply. | ||
| range: ClaimType | ||
| required: true | ||
| hasClaimant: | ||
| slot_uri: rfs:hasClaimant | ||
| description: >- | ||
| The entity making the claim. May be an individual, organization, | ||
| or community. | ||
| range: Entity | ||
| required: true | ||
| inlined: true | ||
| hasSubject: | ||
| slot_uri: rfs:hasSubject | ||
| description: >- | ||
| The entity or place about which the claim is made. Often a project, | ||
| land steward, or community. | ||
| range: Entity | ||
| required: true | ||
| inlined: true | ||
| hasOperator: | ||
| slot_uri: rfs:hasOperator | ||
| description: >- | ||
| The entity responsible for operations that produced the claimed | ||
| outcome, if different from the claimant. | ||
| range: Entity | ||
| inlined: true | ||
| hasPrimaryImpact: | ||
| slot_uri: rfs:hasPrimaryImpact | ||
| description: The primary impact claimed. | ||
| range: Impact | ||
| required: true | ||
| inlined: true | ||
| hasCoBenefits: | ||
| description: Secondary impacts or co-benefits associated with the claim. | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| range: Impact | ||
| multivalued: true | ||
| inlined: true | ||
| inlined_as_list: true | ||
| verificationStatus: | ||
| slot_uri: rfs:verificationStatus | ||
| description: >- | ||
| Current verification state of the claim, from self-reported through | ||
| ledger-anchored. | ||
| range: VerificationStatus | ||
| required: true | ||
| claimStartDate: | ||
| slot_uri: schema:startDate | ||
| description: The start date of the period covered by this claim. | ||
| range: date | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| claimEndDate: | ||
| slot_uri: schema:endDate | ||
| description: The end date of the period covered by this claim. | ||
| range: date | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
| quantity: | ||
| slot_uri: rfs:quantity | ||
| description: >- | ||
| Numeric quantity associated with the claim (e.g., tonnes CO2e, | ||
| hectares restored). | ||
| range: float | ||
| quantityUnit: | ||
| slot_uri: qudt:unit | ||
| description: >- | ||
| Unit of measurement for the quantity (e.g., unit:TON, unit:HA). | ||
| range: string | ||
|
Comment on lines
+96
to
+106
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The For example, you could define a new # In a shared file like core.yaml or a new Quantity.yaml
classes:
Quantity:
attributes:
value:
range: float
required: true
description: "The numeric value of the quantity."
unit:
range: string
required: true
description: "The unit of measurement."
slot_uri: qudt:unitAnd then use it in # In Claim.yaml
quantity:
range: Quantity
inlined: true
description: >-
Numeric quantity associated with the claim (e.g., tonnes CO2e,
hectares restored). |
||
| usesMethodology: | ||
| description: The methodology used to measure or verify the claimed outcome. | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For consistency with other attributes in this schema that explicitly define a slot_uri: rfs:usesMethodology
description: The methodology used to measure or verify the claimed outcome. |
||
| range: Methodology | ||
| multivalued: true | ||
| inlined: true | ||
| inlined_as_list: true | ||
| hasCreditClass: | ||
| slot_uri: rfs:hasCreditClass | ||
| description: >- | ||
| Credit class identifier (e.g., C01, C06) linking this claim to | ||
| a registered credit class on Regen Ledger. | ||
| range: string | ||
| contentHash: | ||
| slot_uri: rfs:contentHash | ||
| description: >- | ||
| BLAKE2b-256 content hash of the canonical claim representation, | ||
| used for on-chain anchoring via Regen Data Module. | ||
| range: string | ||
| dataIri: | ||
| slot_uri: rfs:dataIri | ||
| description: >- | ||
| Regen Data Module IRI derived from the content hash. Bridges the | ||
| off-chain claim to its on-chain anchor. | ||
| range: uri | ||
| supersedes: | ||
| slot_uri: rfs:supersedes | ||
| description: >- | ||
| IRI or RID of a previous claim that this claim supersedes, | ||
| forming a version chain. | ||
| range: uri | ||
|
Comment on lines
+134
to
+136
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Useful? React with 👍 / 👎. |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
attestationDateis a crucial piece of information for an attestation, but it's currently optional. To ensure data integrity and completeness, consider making it a required field.