Skip to content
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

Emerging data models #39

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 28 additions & 1 deletion Platforms/Emerging/Registration.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,34 @@ The domain ontology outlines the structure of interconnected entities within the
## Creating an Entity
To instantiate a new entity, the first step is to create or reference an existing Protocol. This Protocol defines the class and common properties that all entities of this class inherit. Each entity document specifies its class under the `@context` field, with a key "class" and value like `did:ixo:entity:abc123`.

To create a new entity, follow the [Creating an Entity implementation guide](../../Implementation-Guides/Create-Query-Entity.md).
To create a new entity, use the function `msgCreateEntity`. The structure of this message is as follows:

```
[type MsgCreateEntity struct {
EntityType string
EntityStatus int32
Controller []string
Context []*types.Context
Verification []*types.Verification
Service []*types.Service
AccordedRight []*types.AccordedRight
LinkedResource []*types.LinkedResource
LinkedEntity []*types.LinkedEntity
StartDate *time.Time
EndDate *time.Time
RelayerNode string
Credentials []string
OwnerDid DIDFragment
OwnerAddress string
Data encoding_json.RawMessage
AlsoKnownAs string
LinkedClaim []*types.LinkedClaim
}]
```

Other chain services include:
- **msgEditEntity**: To edit an existing entity.
- **msgTransferEntity**: To transfer ownership of an entity.

## Protocol Templates
The Emerging Platform includes a collection of Protocol Templates specific to the domain. These define schemas for claims, credentials, data models, documentation templates, and entity class properties. To view available protocols, query the Blocksync chain index database for the Emerging Market Relayer identifier and filter entities of type `Protocol`.
Expand Down
3 changes: 2 additions & 1 deletion models/Certified-Emissions-Reduction.json
Original file line number Diff line number Diff line change
Expand Up @@ -1238,5 +1238,6 @@
}
}
}
]
],
"description": "# Clean Cooking Carbon Emission Reduction Credential\n\nThis model represents a **Verifiable Credential** for documenting verified carbon emission reductions achieved through a clean cooking initiative. It captures key data points for tracking and validating the environmental impact of biomass-based cooking solutions, aligning with blockchain standards for transparency and authenticity.\n\n---\n\n## **1. Context and Structure**\n- **@context**: Integrates W3C Verifiable Credentials, IXO standards, and custom claim vocabularies to ensure interoperability.\n- **Type**: Classified as a `VerifiableCredential` with specific claims for `CarbonEmissionReduction (CER)` and `VerifiedEmissionReduction (VER)`.\n\n---\n\n## **2. Credential Overview**\n- **Credential ID**: A unique identifier (UUID) is assigned to maintain traceability.\n- **Issuer**: Authenticated using a DID (Decentralized Identifier), verifying the issuer as a trusted entity in the IXO ecosystem.\n- **Issuance Date**: Timestamped to ensure temporal validity.\n- **Proof**: Employs `Ed25519` cryptographic signatures to secure authenticity.\n\n---\n\n## **3. Credential Subject: Clean Cooking Initiative**\n- **Claim ID**: Tracks the specific `CarbonEmissionReduction` claim using the IXO protocol.\n- **Claim Type**:\n - **Main Impact**: Reduction of greenhouse gas emissions (`CarbonEmissionReduction`).\n - **Sub Impact**: Verified reductions (`VerifiedEmissionReduction`).\n- **Project**:\n - **ID**: Links to project-specific metadata stored on IPFS.\n - **Type**: Biomass gasification projects supporting clean cooking solutions.\n - **Credential**: Includes project credentials for provenance and trust.\n\n---\n\n## **4. Key Attributes**\n- **Location**: The project is domestic, implemented in Zambia, Africa.\n- **Time Period**: Specifies the active timeframe for carbon reduction activities (`May 11–28, 2022`).\n- **Measures**: Details the use of biomass pellets:\n - **Quantity**: `30 kg`\n - **Type**: `CookingFuel`, `BiomassPellets`\n - **Verified via linked claims**.\n\n---\n\n## **5. Evidence and Traceability**\n- **Fuel Purchase Evidence**:\n - Links a verified transaction as proof of purchase.\n - Details payment via a telco provider (`MTN`), including amount, method, and timestamp.\n - Supported by external references to transactions.\n- **Linked Claims**: Associates specific claims (e.g., payment transactions) with supporting evidence for a robust verification trail.\n\n---\n\n## **6. Reusability and Interoperability**\n- **Reusable Components**: Components such as `@context`, `claim`, and `proof` ensure that the model can seamlessly integrate into IXO and other blockchain ecosystems.\n- **JSON-LD**: Uses Linked Data principles to facilitate machine-readable data exchanges and decentralized verification.\n\n---\n\nThis credential model establishes a transparent, verifiable, and reusable framework for tracking and reporting clean cooking initiatives' environmental impacts, empowering stakeholders to combat climate change with integrity and accountability.\n"
}
2 changes: 1 addition & 1 deletion models/Fuel-Purchase-Claim-Schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1272,7 +1272,7 @@
"additionalProperties": false
}
},
"description": "Fuel Purchase",
"description": "# Fuel Purchase Claim\n\nThis model represents a **Claim** for documenting a fuel purchase that supports clean cooking initiatives. It verifies the procurement of biomass pellets used in environmentally sustainable cooking practices, emphasizing traceability, accountability, and authenticity in the carbon reduction process.\n\n---\n\n## **1. Context and Structure**\n- **@context**: Incorporates W3C Verifiable Credentials, IXO-specific contexts, and custom vocabularies for semantic interoperability.\n- **Type**: Classified as a `VerifiableCredential` with the specific claim of `FuelPurchase`.\n\n---\n\n## **2. Credential Overview**\n- **Credential ID**: A unique UUID to maintain traceability.\n- **Issuer**: Authenticated via a Decentralized Identifier (DID), ensuring trust in the issuer's authority.\n- **Issuance Date**: Timestamped to confirm when the credential was issued.\n- **Proof**: Secured using an `Ed25519` cryptographic signature for data integrity.\n\n---\n\n## **3. Credential Subject: Fuel Purchase**\n- **Claim ID**: Tracks the fuel purchase as part of the clean cooking initiative.\n- **Claim Type**:\n - **Main Claim**: `FuelPurchase`\n - **Project Context**: Linked to a biomass gasification project.\n- **Project**:\n - **ID**: References metadata stored on IPFS for the associated project.\n - **Type**: `GasifyingBiomass`\n - **Credential**: Verifiable credentials to confirm project authenticity and trustworthiness.\n\n---\n\n## **4. Key Attributes**\n- **Location**:\n - **Country**: Zambia\n - **Region**: Africa\n - **Setting**: Domestic\n- **Product**:\n - **ID**: References the product data stored on IPFS.\n - **Type**: `CookingFuel`, `BiomassPellets`\n - **Producer/Distributor**: Emerging Cooking Solutions Zambia\n - **Quantity**: `30 kg`\n\n---\n\n## **5. Evidence and Payment Details**\n- **Evidence**:\n - **ID**: Links to a Supamoto API endpoint that records the purchase transaction.\n - **Type**: Payment details, including transaction and price specifications.\n- **Payment Details**:\n - **Transaction Identifier**: `2994029793`\n - **Method**: Telco\n - **Provider**: MTN\n - **Amount**:\n - **Value**: `130`\n - **Currency**: ZMW (Zambian Kwacha)\n - **Date/Time**: `2022-05-11T13:15:33.000Z`\n\n---\n\n## **6. Reusability and Interoperability**\n- **Reusable Components**: Designed with `@context`, `proof`, and `claim` to allow seamless integration within IXO and related ecosystems.\n- **JSON-LD**: Leverages Linked Data principles for compatibility with decentralized systems and machine-readable verification.\n\n---\n\nThis credential model ensures transparent and verifiable documentation of fuel purchases in support of clean cooking initiatives. By enabling stakeholders to validate purchases and trace their environmental impact, it contributes to broader sustainability and carbon reduction goals.\n",
"examples": [
{
"@context": [
Expand Down
4 changes: 3 additions & 1 deletion models/Verified-Emissions-Reduction.json
Original file line number Diff line number Diff line change
Expand Up @@ -2314,5 +2314,7 @@
"jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..1eLiFElSN5SvlpiTGLRL6VyHgR_huHfmoseOl52OkHzBe7WY_Uu8AV3T5Gau3RtYACvUjZBSJq3zHNcJ6FVvBw"
}
}
]
],
"description": "# Verified Emission Reduction Credential (VER)\n\nThis model represents a **Verifiable Credential** for tracking and verifying greenhouse gas (GHG) emission reductions achieved through clean cooking initiatives. It incorporates verified methodologies, impact evaluations, and carbon reduction outcomes, ensuring high standards of transparency and accountability.\n\n---\n\n## **1. Context and Structure**\n- **@context**: Integrates W3C Verifiable Credentials, IXO contexts, and specialized vocabularies for semantic interoperability.\n- **Type**: Classified as a `VerifiableCredential` with claims related to `Verified Emission Reduction (VER)`.\n\n---\n\n## **2. Credential Overview**\n- **Credential ID**: A unique UUID for traceability.\n- **Issuer**: Authenticated using a DID, ensuring trust in the issuing entity.\n- **Issuance Date**: `2024-05-20T18:56:54.178Z`, confirming the time of credential issuance.\n- **Proof**: Secured with an `Ed25519` cryptographic signature for data integrity and authenticity.\n- **Status**: Marked as `verified`.\n\n---\n\n## **3. Credential Subject: Emission Reduction**\n- **Impact**:\n - **Claim**: `GHG Emission Reduction`\n - **Description**: Verified reduction in greenhouse gas emissions achieved through modern energy cooking devices.\n - **Location**: Zambia, Africa (Domestic).\n - **Project**:\n - **Type**: `GasifyingBiomass`\n - **Credential**: Links to project-specific metadata and credentials stored on IPFS.\n - **Issuer**: DID of the project authority.\n- **Evaluation**:\n - **Methodology**: Based on Gold Standard guidelines for energy cooking devices.\n - **Model**: `ProbabilisticModel1`\n - **Version**: `0cece87f-1d09-42e4-a629-e460f8ebb7cd`\n - **Evaluator**: Authenticated Oracle entity (DID).\n\n---\n\n## **4. Outcome**\n- **Linked Claim**:\n - **Description**: Carbon Emission Reduction (CER)\n - **Issuance Date**: `2024-05-20T17:31:07.293Z`\n - **Issuer**: Verified DID authority.\n- **Period**:\n - **Start Date**: `2023-11-06`\n - **End Date**: `2023-12-06`\n- **Calculation**:\n - **Emission Reduction Factor**: `10.94`\n - **Fuel Quantity**: `30 kg` of `Biomass Pellets`\n - **Carbon Reduction**: `328.2 kgCO2`\n - **Confidence Score**: Statistical confidence of `1` with a threshold of `0.95`.\n\n---\n\n## **5. Evidence and Traceability**\n- **Evidence**:\n - **Fuel Purchase**: Linked claim referencing prior verified purchases.\n - **IoT Data**: Monitored cooking sessions via IoT sensors.\n- **Proof**:\n - Utilizes a multibase digest for secure validation.\n\n---\n\n## **6. Reusability and Interoperability**\n- **Reusable Components**: Designed with `@context`, `proof`, and `claim` for seamless integration with IXO and related blockchain ecosystems.\n- **JSON-LD**: Adopts Linked Data principles for compatibility with decentralized systems and machine-readable verification.\n\n---\n\nThis credential model provides a robust framework for validating and documenting emission reductions, empowering stakeholders to assess the impact of clean cooking initiatives with precision and transparency.\n",
"title": ""
}