TrustedDataGraph / HackFS2023DataVerification

DataVerification and Reputation System
MIT License
1 stars 1 forks source link

7th, 8th 2 days target tasks #5

Open kozayupapa opened 1 year ago

kozayupapa commented 1 year ago
  1. Priority: High

    • [x] Obtain a JWT from the existing smart contract for identity verification.
      • Time Allocation: 1 hour
      • TODO: Investigate and implement the functionality to retrieve a JWT from the smart contract. Test the retrieval process and ensure its compatibility with the identity verification flow.
  2. Priority: Medium

    • [ ] Run the authentication flow of other projects locally to deepen the understanding.
      • Time Allocation: 1 hour
      • TODO: Set up the local environment for the authentication flow of other projects. Follow the documentation or guides provided by those projects to execute the authentication flow and gain a better understanding of the process.
  3. Priority: Medium

    • [ ] Explore the data gathered in OpSci to understand the available datasets.
      • Time Allocation: 1 hour
      • TODO: Access OpSci's data repository and browse through the available datasets. Analyze the data to gain insights into the types, formats, and potential use cases of the gathered data.
  4. Priority: Low

    • [x] Contact the administrators of OpSci.
      • Time Allocation: 30 minutes
      • TODO: Reach out to the administrators of OpSci via email or other communication channels. Inquire about any specific questions, seek guidance, or request additional information related to the project and its objectives.
  5. Priority: Low

    • [ ] Create a flowchart (using Mermaid) of the authentication process for your own project.
      • Time Allocation: 1 hour
      • TODO: Map out the authentication flow of your project using Mermaid or any other diagramming tool. Visualize the steps, user interactions, and data flows involved in the authentication process.
  6. Priority: Low

    • [x] Implement the retrieval of files based on CID locally.
      • Time Allocation: 1 hour
      • TODO: Develop a local setup to retrieve files based on their Content Identifier (CID). Use IPFS or related libraries/tools to fetch files using the CID and validate the retrieval process.
  7. Priority: Low

    • [ ] Test the retrieval of files from GitHub based on the stored CID.
      • Time Allocation: 1 hour
      • TODO: Experiment with fetching files from GitHub using the stored CID. Utilize the GitHub API or suitable libraries/tools to retrieve files based on their CID and verify the successful retrieval.
  8. Priority: Low

    • [ ] Determine whether to focus on IPFS files or Filecoin files.
      • Time Allocation: 30 minutes
      • TODO: Make a decision regarding whether to target IPFS files or Filecoin files based on the requirements and objectives of your project. Consider the advantages and constraints of each option before finalizing your choice.
kozayupapa commented 1 year ago

1: Obtain a JWT from the existing smart contract for identity verification

opsci wtf-cache: https://github.com/opscientia/wtf-cache/tree/main

I cloud run cache-updater locally and succeed to get data from contract through JsonRPC gnosis, mumbai.

(base) wtf-cache % ANKR_MUMBAI_ENDPOINT=https://rpc.ankr.com/polygon_mumbai ANKR_GNOSIS_ENDPOINT=https://rpc.ankr.com/gnosis node src/cache-updater/cache-updater.js

Using production database
env: https://rpc.ankr.com/gnosis
cache-updater pid: 64706

and then start server

(base) wtf-cache % node src/cache-server.js 
Using production database
cache-server pid: 60517
Server running in http://127.0.0.1:3001
getAllUserAddresses: Entered
getAllUserAddresses: Retrieved addresses from database. Returning.

then we can get data from contract and cache to sqlite

(base) database % curl "http://localhost:3001/api/getHolo?address=0x27b1c26c1bf6f8bee59327691b8af8d9d0953d35"
{"gnosis":{"name":"Sina Iman","bio":"Engineering @ DeSci Labs 👋😎","orcid":"","google":"","github":"","twitter":"","discord":""}}%   
kozayupapa commented 1 year ago
  1. Contact the administrators of OpSci I post DM to https://twitter.com/opscientia
Greetings I am an engineer participating in an online hackathon called HackFS 2023 at ETH GLobal.

I learned about the opensci project as an introduction to an advanced case study of collecting data in filecoin. We are looking for something to contribute to OpenData, distributed science at the HackFS event.

The idea is to create a generic mechanism to store reviews from scientists on already collected data on a distributed file system and make it available from any smart contract.

We are referring to the following code as a mechanism to prove that you are a scientist.
https://github.com/opscientia/verse

May we connect to the following smart contract in this hackathon and use the data of the scientists already gathered in the demo?
https://opsci.gitbook.io/interacting-with-the-wtf-protocol/reference/api-reference

Also, please let us know if there is a good way to add our Identity data to the contract for testing.

and also ask to support-filecoin channel on Discord.

Hi filecoin team. I learned about opsci's efforts by reading the advanced case study on filecoin. (https://fil.org/blog/case-study-opsci-how-an-open-science-commons-project-built-on-web3-infrastructure-empowers-community- discovery/)
We are thinking about what we can contribute to distributed science with this hackathon.

We refer to the following code as a mechanism to prove that you are a scientist. https://github.com/opscientia/verse

Some individual scientist proof data already exists in SmartContract, such as gnosis. 
We would like to discuss whether we can use this data in our demo, and if you know someone from OpenSci, could you introduce us?

I got a Twitter response from OpSci mainter.  To summarize what I've heard, I've heard a lot of things.

A. changed to new app uses particle network to create a wallet for a user and verify a scientist's web accounts using a simple smart contract registry. B. it is ok to use the old one for PoC

===

Candidates for how to proceed

  1. deplicate is done but try to connect with wtf.contract
    • Positive : I have a working sample.  + Negative: no future development
  2. use parcel or safe to create an AccountAbstract and create your own account registration type. Consider how to connect to the official one later. 3.
    • Positive: Expandable, can explain that we will consider to connect to OpSci in the future.  + Negative: More things to be created. 3.
  3. cooperate to add mail+wallet to the new parcel based one and use it.
    • Positive: if we can collaborate with projects that are already working, it will be a hot topic, and the moving parts are secured.  + Negative: we can cooperate together, not sure if it's OpenSource.

== I think I prefer to proceed with 2. I think it is better to proceed with 3 if we can get information directly via TwitterDM that will eliminate the negative of 3, and with 2 if we can't.

kozayupapa commented 1 year ago
  1. Run the authentication flow of other projects locally to deepen the understanding. opsci verse : local run (https://github.com/opscientia/verse) image
kozayupapa commented 1 year ago
  1. Trying data fetch with local lotus command. posted following question to filecoin support channel

    I'm trying to use local PC lotus node. I tested DL data which CID is on following site. https://datasets.filecoin.io/google-open-images?page=16 I installed lotus with brew to my macbook. original data download instructions of above site says lotus client helper retrieve XXX but it cause following error

    No help topic for 'helper'

if I cut helper option, it cause another error.

lotus client  retrieve --miner f096540 bafykbzacedojx7clth6jn6bvx6i2cpfnhvioonnodtukjolv3y6paplokynxc @/data/maris/google_full/open-images-dataset-train3/farm5.staticflickr.com/9.zip 
ERROR: could not get API info for FullNode: repo directory does not exist. Make sure your configuration is correct

Shoud I use another way to install lotus?

codypharm commented 1 year ago

I agree with going with candidate 3 however you seem more knowledgeable in this so I suggest we follow your decision.