diff --git a/.gitbook/assets/data-farming/Rewards-Tab.png b/.gitbook/assets/data-farming/Rewards-Tab.png deleted file mode 100644 index fbf1dd5f..00000000 Binary files a/.gitbook/assets/data-farming/Rewards-Tab.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/allocations.png b/.gitbook/assets/data-farming/allocations.png deleted file mode 100644 index 223ada1b..00000000 Binary files a/.gitbook/assets/data-farming/allocations.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/claim-rewards.png b/.gitbook/assets/data-farming/claim-rewards.png deleted file mode 100644 index 0352c9b9..00000000 Binary files a/.gitbook/assets/data-farming/claim-rewards.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/curate-datasets.png b/.gitbook/assets/data-farming/curate-datasets.png deleted file mode 100644 index 8798483b..00000000 Binary files a/.gitbook/assets/data-farming/curate-datasets.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/df_rewards_page.png b/.gitbook/assets/data-farming/df_rewards_page.png deleted file mode 100644 index be961b33..00000000 Binary files a/.gitbook/assets/data-farming/df_rewards_page.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/emissions_first_20years.png b/.gitbook/assets/data-farming/emissions_first_20years.png deleted file mode 100644 index f5a0ef85..00000000 Binary files a/.gitbook/assets/data-farming/emissions_first_20years.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/emissions_first_5years.png b/.gitbook/assets/data-farming/emissions_first_5years.png deleted file mode 100644 index d2d75131..00000000 Binary files a/.gitbook/assets/data-farming/emissions_first_5years.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/emissions_lifetime.png b/.gitbook/assets/data-farming/emissions_lifetime.png deleted file mode 100644 index f19f6520..00000000 Binary files a/.gitbook/assets/data-farming/emissions_lifetime.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/example_apys.png b/.gitbook/assets/data-farming/example_apys.png deleted file mode 100644 index 89b1cf7c..00000000 Binary files a/.gitbook/assets/data-farming/example_apys.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/flow_of_value.png b/.gitbook/assets/data-farming/flow_of_value.png deleted file mode 100644 index e7a44ff0..00000000 Binary files a/.gitbook/assets/data-farming/flow_of_value.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/predictoordf_main.png b/.gitbook/assets/data-farming/predictoordf_main.png deleted file mode 100644 index df12e030..00000000 Binary files a/.gitbook/assets/data-farming/predictoordf_main.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/ranked_rewards_study.png b/.gitbook/assets/data-farming/ranked_rewards_study.png deleted file mode 100644 index 1dd344c3..00000000 Binary files a/.gitbook/assets/data-farming/ranked_rewards_study.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/reward_schedule.png b/.gitbook/assets/data-farming/reward_schedule.png deleted file mode 100644 index 3bcbe97e..00000000 Binary files a/.gitbook/assets/data-farming/reward_schedule.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/update-allocations.png b/.gitbook/assets/data-farming/update-allocations.png deleted file mode 100644 index aa7dca35..00000000 Binary files a/.gitbook/assets/data-farming/update-allocations.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/veOCEAN-Delegation.png b/.gitbook/assets/data-farming/veOCEAN-Delegation.png deleted file mode 100644 index 423f12f5..00000000 Binary files a/.gitbook/assets/data-farming/veOCEAN-Delegation.png and /dev/null differ diff --git a/.gitbook/assets/data-farming/volumeDF-page.png b/.gitbook/assets/data-farming/volumeDF-page.png deleted file mode 100644 index e4a9535f..00000000 Binary files a/.gitbook/assets/data-farming/volumeDF-page.png and /dev/null differ diff --git a/SUMMARY.md b/SUMMARY.md index a3aef554..012808b5 100644 --- a/SUMMARY.md +++ b/SUMMARY.md @@ -14,11 +14,7 @@ - [Using Wallets](user-guides/wallets/README.md) - [Set Up MetaMask](user-guides/wallets/metamask-setup.md) - [Manage Your OCEAN](user-guides/wallets/wallets-and-ocean.md) - - [Compute-to-Data in Ocean Market](user-guides/compute-to-data/README.md) - - [Make a Boss C2D Algorithm](user-guides/compute-to-data/make-a-boss-c2d-algorithm.md) - - [Publish a C2D Algorithm NFT](user-guides/compute-to-data/publish-a-c2d-algorithm-nft.md) - - [Publish a C2D Data NFT](user-guides/compute-to-data/publish-a-c2d-data-nft.md) - - [Host Assets](user-guides/asset-hosting/README.md) + - [Data Storage](user-guides/asset-hosting/README.md) - [Uploader](user-guides/asset-hosting/uploader.md) - [Arweave](user-guides/asset-hosting/arweave.md) - [AWS](user-guides/asset-hosting/aws.md) @@ -108,21 +104,6 @@ - [Data Value-Creation Loop](data-scientists/the-data-value-creation-loop.md) - [What data is valuable?](data-scientists/data-engineers.md) * [👀 Predictoor](predictoor/README.md) -* [💰 Data Farming](data-farming/README.md) - * [Passive DF (and veOCEAN)](data-farming/passivedf.md) - * [Guide to Passive DF](data-farming/passivedf-guide.md) - * [Liquid Staking](data-farming/liquid-staking.md) - * [Volume DF](data-farming/volumedf.md) - * [Guide to Volume DF](data-farming/volumedf-guide.md) - * [Delegation in Volume DF](data-farming/delegate.md) - * [Predictoor DF](data-farming/predictoordf.md) - * [Guide to Predictoor DF](data-farming/predictoordf-guide.md) - * [Claim Rewards](data-farming/claim-rewards.md) - * [Reward Schedule](data-farming/reward-schedule.md) - * [APYs](data-farming/apys.md) - * [Estimated APY vs Time](data-farming/apys-plot.md) - * [Guide to Estimating APY](data-farming/apys-guide.md) - * [FAQ](data-farming/faq.md) * [🔨 Infrastructure](infrastructure/README.md) * [Set Up a Server](infrastructure/setup-server.md) * [Deploy Aquarius](infrastructure/deploying-aquarius.md) diff --git a/data-farming/README.md b/data-farming/README.md deleted file mode 100644 index 5d950684..00000000 --- a/data-farming/README.md +++ /dev/null @@ -1,64 +0,0 @@ ---- -description: Earn OCEAN rewards by predicting (and more streams to come). -cover: ../.gitbook/assets/cover/data_farming_banner.png -coverY: 0 ---- - -# What is Data Farming? - -**Data Farming (DF) is Ocean's incentive program.** It rewards OCEAN to participants who make predictions (and more streams to come). - -**[The DF webapp](https://df.oceandao.org)** is where users perform most DF actions. - - -## Current DF Streams & Budgets - -DF currently has one stream: - -- **[Predictoor DF](predictoordf.md).** Run prediction bots to earn continuously. 37,500 OCEAN/week + ROSE rewards. - -All streams repeat **weekly** that start on Thursdays 00:00 at UTC and end on Wed at 23:59 UTC. - -DF Streams evolve over time. The next two sections cover past & future DF streams. - -## Past DF Streams - -In **Passive DF**, users locked OCEAN for veOCEAN. In **Active DF**, users allocated veOCEAN to curate data assets. -- veOCEAN, Passive DF, and Active DF were [retired](https://blog.oceanprotocol.com/passive-volume-data-farming-airdrop-has-completed-they-are-now-retired-6933520b5fcb) on May 3, 2024, alongside an an airdrop to veOCEAN holders. -- **veOCEAN holders can claim airdrop & past rewards at [df.oceandao.org/rewards](https://df.oceandao.org/rewards)**. -- The locked OCEAN will unlock according to its schedule (up to 4 years) -- [This article](https://blog.oceanprotocol.com/passive-volume-data-farming-airdrop-has-completed-they-are-now-retired-6933520b5fcb) has details. - -In **Challenge DF**, users did weekly one-off predictions. It was [retired](https://blog.oceanprotocol.com/df62-completes-and-df63-launches-predictoor-df-is-here-081fc78ceb70) on Nov 30, 2023. - -For further details, the ["Data Farming Series" article](https://blog.oceanprotocol.com/ocean-data-farming-series-c7922f1d0e45) chronicles week-by-week rewards and DF evolution. - - -## Future DF Streams - -Potential DF evolution includes: -- Scaling up Predictoor DF rewards. [Details](https://blog.oceanprotocol.com/ocean-protocol-update-2024-e463bf855b03#4da0). -- New stream: run Unified Backend nodes. [Details](https://blog.oceanprotocol.com/ocean-protocol-update-2024-e463bf855b03#f779). -- New stream: decentralized model training for world-world models. [Details]([Details](https://blog.oceanprotocol.com/ocean-protocol-update-2024-e463bf855b03#4da0).) - -## Networks - -To engage in Predictoor DF, users submit Predictions on Oasis Sapphire. Rewards for Predictoor DF are on Oasis Sapphire as well (it's intertwined). - -Passive DF and Volume DF reward payouts are on Ethereum network. - -The [networks docs](../discover/networks/README.md) have more info. - -## Further resources - -- The **[DF FAQ](faq.md)** answers more questions. -- Main DF github repos: [df-py (backend)](https://github.com/oceanprotocol/df-py), [df-web (frontend)](https://github.com/oceanprotocol/df-web) -- The [Ocean Data Farming Series](https://blog.oceanprotocol.com/ocean-data-farming-series-c7922f1d0e45) article has a chronological account of all Data Farming activities since its inception. It links to related blog posts. - - ----- - -_Next: [Predictoor DF](predictoordf.md)_ - -_Back: [Docs main](../README.md)_ - diff --git a/data-farming/faq.md b/data-farming/faq.md deleted file mode 100644 index 76a31865..00000000 --- a/data-farming/faq.md +++ /dev/null @@ -1,72 +0,0 @@ ---- -title: Data Farming FAQ -description: Frequently Asked Questions about Data Farming ---- -## Data Farming FAQ - -### Staking and Risk - -
- -What does "staking" mean in an Ocean context? - -Its precise meaning depends on the DF stream. - -- Predictoor DF: put OCEAN into a prediction transaction - -
- -
- -Are there any risks associated with DF? - -As with any system, inherent risks exist. We try to minimize them, as follows. - -- Predictoor DF: you stake a small amount of OCEAN in each epoch (eg every 5min). If issues arise, you can get out quickly. - -
- -
- -Is there any impermanent loss (IL) in my staking? - -No. IL is typically associated with providing liquidity to decentralized exchange or pools. There are no pools involved in any of the DF streams [1]. -
- - -### Rewards Payout - -
- -What APYs can I expect? - -For Predictoor DF, it varies a lot based on your prediction accuracy, and more. - -
- -
- -Can the DF rewards change during a given week? - -No. At the beginning of a new DF round, rules are laid out, either implicitly if no change from the previous round, or explicitly in a blog post if there are new rules. - -Caveat: it’s "no" at least in theory! Sometimes there may be tweaks if there is community consensus or a bug. - -
- -
- -Where do I learn more about Predictoor DF? - -In its [docs page](predictoordf.md). -
- - - -Congrats! You've completed reading Data Farming docs. - -_Next: Jump to [DF main](README.md)._ - -_Or: Jump to [Docs main](../README.md) and click on your interest._ - -_Back: [Predictoor DF Guide](predictoordf-guide.md)_ diff --git a/data-farming/predictoordf-guide.md b/data-farming/predictoordf-guide.md deleted file mode 100644 index fed32b71..00000000 --- a/data-farming/predictoordf-guide.md +++ /dev/null @@ -1,34 +0,0 @@ ---- -description: >- - How to earn $ via predictoor DF ---- - -# Guide to Predictoor DF - -
- -In Predictoor DF (and Predictoor proper), you run prediction bots to earn continuously. This guide describes how to become eligible for OCEAN rewards and claim them; and the same for Oasis ROSE rewards. And of course first thing you need to do is become a predictoor. - -## How to become a predictoor - -- Play with the dapp: http://predictoor.ai -- Then go through "How to earn as a Predictoor" in [Predictoor docs](https://docs.predictoor.ai) -- Or, go straight to the [quickstart README](https://github.com/oceanprotocol/pdr-backend/blob/main/READMEs/predictoor.md) :) 🏎️ - -## On OCEAN Rewards in Predictoor DF - -- **Duration:** ongoing -- **To be eligible:** predictoors are automatically eligible 🧘 -- **To claim:** recall that the OCEAN rewards act as more sales coming to you (as a predictoor). So you claim your OCEAN from sales in the usual way, by running the OCEAN payout script. See the [payout README](https://github.com/oceanprotocol/pdr-backend/blob/main/READMEs/payout.md) for specific instructions. - - -## On ROSE rewards in Predictoor DF - -- ⚠️ **To be eligible** for a given DF round: you MUST run [OCEAN payout script](https://github.com/oceanprotocol/pdr-backend/blob/main/READMEs/payout.md) <= 4 days after the round ends, i.e. between Thu 00:00 UTC & Sun 11:59 PM UTC -- **To claim:** See the [payout README](https://github.com/oceanprotocol/pdr-backend/blob/main/READMEs/payout.md) for specific instructions. - ----- - -_Next: Jump to [DF FAQ](faq.md)._ - -_Back: [Predictoor DF](predictoordf.md)_ diff --git a/data-farming/predictoordf.md b/data-farming/predictoordf.md deleted file mode 100644 index 9991cb37..00000000 --- a/data-farming/predictoordf.md +++ /dev/null @@ -1,55 +0,0 @@ ---- -description: >- - Baseline sales for predictoors ---- - -
- -**This page** is about Predictoor DF, and [this page](predictoordf-guide.md) is a guide. - -# Predictoor DF Overview - -**Predictoor DF** is a DF stream that amplifies predictoors’ earnings, via extra sales to Ocean Predictoor data feeds. - -Predictoor DF has 37,500 OCEAN weekly rewards (ongoing) and 20,000 ROSE weekly rewards (throughout 2024). - -## Introduction - -**[Ocean Predictoor](../predictoor/README.md)** data feeds predict whether BTC, ETH etc will rise or fall 5min or 1h into the future. These feeds are crowdsourced by “predictoors”: people running AI-powered prediction bots. - -**[Data Farming (DF)](../data-farming/README.md)** is Ocean’s incentive program, that rewards OCEAN to people who lock OCEAN or do active DF activities. - -You should be familiar with both Predictoor and DF before reading on. - -## Predictoor DF Timing - -Predictoor DF started counting on Nov 9, 2023, at the beginning of Data Farming Round 63 (DF63). It runs indefinitely. - -## Predictoor DF Rewards - -Predictoor DF has two components: [OCEAN](https://oceanprotocol.com/about-us/ocean-token) rewards and [Oasis ROSE](https://www.coingecko.com/en/coins/oasis-network) rewards. - -### OCEAN Rewards - -- A special “DF buyer” bot purchases Predictoor feeds. It started operating on Nov 9, 2023. Every day, it spends 1/7 of the weekly Predictoor OCEAN budget for another 24h subscription. It spends an equal amount per feed. (Currently there are feeds: 10 x 5min, 10 x 1h.) -- The OCEAN comes from the Ocean DF budget, and specifically, the Active DF budget. - -### ROSE Rewards - -- Payout happens on Mondays, 4 days after the end of the DF round. -- ⚠️ To be counted for ROSE rewards of a given DF round, you must claim your OCEAN rewards for that DF round. See [Predictoor DF user guide](predictoordf-guide.md). -- Payout for a given predictoor is pro-rata to the net earnings of that predictoor over that DF round, specifically (total sales $ to the predictoor) minus (predictoor stake slashed due to being wrong). -- The ROSE comes from a generous contribution of[ Oasis Protocol Foundation](https://oasisprotocol.org/) 👪🙏. - - -## How to Earn $ Via Predictoor DF - -**Running a predictoor bot will automatically make you eligible for Predictoor DF rewards.** - -The [Predictoor DF user guide](predictoordf-guide.md) tells how to get started as a predictoor, and how to claim rewards. - ----- - -_Next: [Predictoor DF Guide](predictoordf-guide.md)_ - -_Back: [DF Main](README.md)_ diff --git a/developers/retrieve-datatoken-address.md b/developers/retrieve-datatoken-address.md deleted file mode 100644 index 855ed174..00000000 --- a/developers/retrieve-datatoken-address.md +++ /dev/null @@ -1,57 +0,0 @@ ---- -description: >- - Use these steps to reveal the information contained within an asset's DID and - list the buyers of a datatoken ---- - -# Retrieve datatoken/data NFT addresses & Chain ID - -### How to find the network, datatoken address, and data NFT address from an Ocean Market link? - -If you are given an Ocean Market link, then the network and datatoken address for the asset is visible on the Ocean Market webpage. For example, given this asset's Ocean Market link: [https://odc.oceanprotocol.com/asset/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1](https://odc.oceanprotocol.com/asset/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1) the webpage shows that this asset is hosted on the Mumbai network, and one simply clicks the datatoken's hyperlink to reveal the datatoken's address as shown in the screenshot below: - -

See the Network and Datatoken Address for an Ocean Market asset by visiting the asset's Ocean Market page.

- -#### More Detailed Info: - -You can access all the information for the Ocean Market asset also by **enabling Debug mode**. To do this, follow these steps: - -**Step 1** - Click the Settings button in the top right corner of the Ocean Market - -

Click the Settings button

- -**Step 2** - Check the Activate Debug Mode box in the dropdown menu - -

Check 'Active Debug Mode'

- -**Step 3** - Go to the page for the asset you would like to examine, and scroll through the DDO information to find the NFT address, datatoken address, chain ID, and other information. - -
- -### How to use Aquarius to find the chainID and datatoken address from a DID? - -If you know the DID:op but you don't know the source link, then you can use Ocean Aquarius to resolve the metadata for the DID:op to find the `chainId`+ `datatoken address` of the asset. Simply enter in your browser "[https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/](https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1)\" to fetch the metadata. - -For example, for the following DID:op: "did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1" the Ocean Aquarius URL can be modified to add the DID:op and resolve its metadata. Simply add "[https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/](https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1)" to the beginning of the DID:op and enter the link in your browser like this: [https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1](https://v4.aquarius.oceanprotocol.com/api/aquarius/assets/ddo/did:op:1b26eda361c6b6d307c8a139c4aaf36aa74411215c31b751cad42e59881f92c1) - -

The metadata printout for this DID:op with the network's Chain ID and datatoken address circled in red

- -Here are the networks and their corresponding chain IDs: - -```json -"mumbai: 80001" -"polygon: 137" -"bsc: 56" -"energyweb: 246" -"moonriver: 1285" -"mainnet: 1" -"goerli: 5" -"polygonedge: 81001" -"gaiaxtestnet: 2021000" -"alfajores: 44787" -"gen-x-testnet: 100" -"filecointestnet: 3141" -"oasis_saphire_testnet: 23295" -"development: 8996" -``` - diff --git a/user-guides/README.md b/user-guides/README.md index 6616afcb..0f876c5c 100644 --- a/user-guides/README.md +++ b/user-guides/README.md @@ -12,8 +12,6 @@ coverY: 0 **Contents:** - Basic concepts - Using wallets -- Using Ocean Market -- C2D in Ocean Market - Host assets Let's dive in! @@ -36,28 +34,7 @@ For blockchain beginners [wallets/metamask-setup.md](wallets/metamask-setup.md) {% endcontent-ref %} - -## Using Ocean Market - -{% content-ref url="using-ocean-market.md" %} -[using-ocean-market.md](using-ocean-market.md) -{% endcontent-ref %} - -{% content-ref url="publish-data-nfts.md" %} -[publish-data-nfts.md](publish-data-nfts.md) -{% endcontent-ref %} - -{% content-ref url="buy-data-nfts.md" %} -[buy-data-nfts.md](buy-data-nfts.md) -{% endcontent-ref %} - -## C2D in Ocean Market - -{% content-ref url="compute-to-data/" %} -[compute-to-data](compute-to-data/README.md) -{% endcontent-ref %} - -## Host Assets +## Data Storage {% content-ref url="asset-hosting/" %} [asset-hosting](asset-hosting/README.md) diff --git a/user-guides/compute-to-data/README.md b/user-guides/compute-to-data/README.md deleted file mode 100644 index 2983438b..00000000 --- a/user-guides/compute-to-data/README.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -description: >- - How to sell compute jobs on your datasets while keeping your data and - algorithms private ---- - -# Sell NFT Computations (Compute-to-Data) - -### Introducing, The Problem - -{% embed url="https://media0.giphy.com/media/v1.Y2lkPTc5MGI3NjExNjNmMTc3MjFjNTg2MjQwZTQyY2VkNzFiNjk1YzM5ZmJkM2NjMzA4ZiZlcD12MV9pbnRlcm5hbF9naWZzX2dpZklkJmN0PWc/17FxSFyYNOgThnonDK/giphy.gif" fullWidth="false" %} - -**Anyone could buy your data on the Ocean Market and then publicly share it all over the internet.** Pretty scary, right? But what if there was a way that buyers could access valuable insights from your data and algorithms without actually \*seeing\* the data or algorithms themselves? We have a solution for that! - -Enter, **Compute-to-Data** (also lovingly called C2D 🥰). Ocean Protocol's C2D feature enables you to monetize the OUTPUT of compute jobs on your datasets without revealing the contents of the data/algorithms themselves. Let's dive in how! - -## How to Compute-to-Data 💃 - -You will need to accomplish **3 main steps** in establishing a compute-to-data flow: [create an algorithm](make-a-boss-c2d-algorithm.md) that's compatible with C2D, [publish your C2D-specific algorithm NFT](publish-a-c2d-algorithm-nft.md), then [publish your data NFT with C2D configurations](publish-a-c2d-data-nft.md) allowing the algorithm to compute on it. That's it! Then you'll be able to sell compute jobs 🤩 Read the steps in this section's three subpages to create & sell a compute job from start to finish. 💪😃 - -Or you could watch this video tutorial about it below: - -{% embed url="https://youtu.be/2AF9mkqlf5Y" %} - diff --git a/user-guides/compute-to-data/make-a-boss-c2d-algorithm.md b/user-guides/compute-to-data/make-a-boss-c2d-algorithm.md deleted file mode 100644 index e83d80ca..00000000 --- a/user-guides/compute-to-data/make-a-boss-c2d-algorithm.md +++ /dev/null @@ -1,98 +0,0 @@ ---- -description: >- - How to construct the beginnings of an awesome algorithm for C2D compute jobs - on datasets ---- - -# Make a Boss C2D Algorithm - -
- -The beginning of any algorithm for Compute-to-Data starts by loading the dataset correctly. Read on, anon 👨🏻‍💻 - -### Open the local dataset file - -This code goes at the top of your algorithm file for your algorithm NFT asset to use with Compute-to-Data. It references your data NFT asset file on the Docker container you selected. - -{% tabs %} -{% tab title="Python" %} -```python -import csv -import json -import os - -def get_input(local=False): - - dids = os.getenv("DIDS", None) - - if not dids: - print("No DIDs found in the environment. Aborting.") - return - - dids = json.loads(dids) - - for did in dids: - filename = f"data/inputs/{did}/0" # 0 for metadata service - print(f"Reading asset file {filename}.") - return filename - -# Get the input filename using the get_input function -input_filename = get_input() - -if not input_filename: - # No input filename returned - exit() - -# Open the file & run your code -with open(input_filename, 'r') as file: - # Read the CSV file - csv_reader = csv.DictReader(file) - - -``` -{% endtab %} - -{% tab title="Javascript" %} -```javascript -const fs = require("fs"); - -var input_folder = "/data/inputs"; -var output_folder = "/data/outputs"; - -async function processfolder(Path) { - var files = fs.readdirSync(Path); - for (var i =0; i < files.length; i++) { - var file = files[i]; - var fullpath = Path + "/" + file; - if (fs.statSync(fullpath).isDirectory()) { - await processfolder(fullpath); - } else { - - } - } -} - - - -// Open the file & run your code -processfolder(input_folder); - -``` -{% endtab %} -{% endtabs %} - -**Note:** Here are the following Python libraries that you can use in your code: - -```python -// Python modules -numpy==1.16.3 -pandas==0.24.2 -python-dateutil==2.8.0 -pytz==2019.1 -six==1.12.0 -sklearn -xlrd == 1.2.0 -openpyxl >= 3.0.3 -wheel -matplotlib -``` diff --git a/user-guides/compute-to-data/publish-a-c2d-algorithm-nft.md b/user-guides/compute-to-data/publish-a-c2d-algorithm-nft.md deleted file mode 100644 index 910e1ba6..00000000 --- a/user-guides/compute-to-data/publish-a-c2d-algorithm-nft.md +++ /dev/null @@ -1,63 +0,0 @@ ---- -description: How to publish a C2D algorithm NFT on the Ocean Market ---- - -# Publish a C2D Algorithm NFT - -

You're an algorithm guru after all!

- -### Publish Your Algorithm NFT - -#### Step 1 - Navigate to the Ocean Market - -* Go to [https://market.oceanprotocol.com](https://market.oceanprotocol.com) - -#### Step 2 - Connect your wallet - -* Click the top right Connect Wallet button to connect your self-custody wallet to the Ocean Market - -

Connect your self-custody wallet

- -#### Step 3 - Click the Publish link in the top left corner of the page - -* Click the Publish link - -

Navigate to the Publish page

- -#### Step 4 - Enter the metadata - -* Enter the metadata for your algorithm NFT paying special attention to select the Algorithm asset type button: - -

Be sure to select the Algorithm asset type

- -* Select the appropriate Docker image to run your code - most algorithms are written in Javascript or Python, so you can use either of these Docker images or your own custom image! - -

Select the appropriate Docker image for your algorithm type

- -#### Step 5 - Enter the Access information - -* Make sure to keep this option checked! ✅ - -

Keep this option checked for Compute-to-Data

- -#### Step 6 - Set a price, Fixed or Free, for your algorithm - -* It is recommended that you set a fixed price since the price that you choose for your algorithm will be charged any time that someone selects to run your algorithm on a dataset, including datasets that aren't yours! - -

Set a price for your C2D algorithm NFT

- -#### Step 7 - Approve the preview - -* Your preview should look like the following: - -
- -#### Step 8 - Submit the transactions - -* Click the pink Submit button at the bottom of the page and sign the two transactions with your wallet. You'll have to pay for gas when you sign to publish your algorithm asset. - -

Sign and pay gas for 2 transactions on the final publishing step

- -#### Congratulations on publishing your algorithm! - -* On to the next step -> [Publish a C2D Data NFT](publish-a-c2d-data-nft.md) diff --git a/user-guides/compute-to-data/publish-a-c2d-data-nft.md b/user-guides/compute-to-data/publish-a-c2d-data-nft.md deleted file mode 100644 index fc0c0843..00000000 --- a/user-guides/compute-to-data/publish-a-c2d-data-nft.md +++ /dev/null @@ -1,91 +0,0 @@ ---- -description: How to publish a data NFT with C2D configurations ---- - -# Publish a C2D Data NFT - -
- -#### Step 1 - Navigate to the Ocean Market - -* Go to [https://market.oceanprotocol.com](https://market.oceanprotocol.com) - -#### Step 2 - Connect your wallet - -* Click the top right Connect Wallet button to connect your self-custody wallet to the Ocean Market - -

Connect your self-custody wallet

- -#### Step 3 - Click the Publish link in the top left corner of the page - -* Click the Publish link - -

Navigate to the Publish page

- -#### Step 4 - Enter the metadata - -* Enter the metadata for your data NFT keeping the Dataset asset type selected by default: - -

Keep the default Dataset Asset Type selected

- -#### Step 5 - Enter the Access information - -* You must select the Compute access type in this step! - -

Make sure that you select Compute access type

- -#### Step 6 - Set a price, Fixed or Free, for your dataset - -* Toggle the tab to decide whether you want to set a fixed or free price for your dataset. - -

Set a price for your C2D data NFT

- -#### Step 7 - Approve the preview - -* Your preview should look like the following (this will change soon!): - -
- -#### Step 8 - Submit the transactions - -* Click the pink Submit button at the bottom of the page and sign the two transactions with your wallet. You'll have to pay for gas when you sign to publish your algorithm asset. - -

Sign and pay gas for 2 transactions on the final publishing step

- -**Ok, you've published a Data NFT that is \*almost\* ready for Compute-to-Data. Just a few tiny steps left and you're done!** - -#### Step 9 - Edit the asset (yes, again!) - -* On the webpage for your Data NFT, you need to click the Edit Asset link to change the C2D settings. - -

Click the Edit Asset link

- -#### Step 10 - Edit the Compute settings - -* You must select the Edit Compute Settings button to add your algorithm to the data NFT for computation. - -

Select the Edit Compute Settings tab button

- -* Then, search for your algorithm in the Selected algorithms search bar and check the box next to it to add it as an algorithm able to compute on the dataset. - -

Search for and select your algorithm to compute on your dataset

- -#### Step 11 - Submit the transactions - -* Click the pink Submit button at the bottom of the page and sign all the transactions. - -

Click the Submit button to finalize the transaction

- -#### Congratulations! You have fully finished the C2D flow. Check your work by verifying that your algorithm appears on the data NFT's page, like in the following example: - -

Your algorithm should appear now on the data NFT's page!

- -If you would like to run the compute job, then simply click the radio button to the left of the algorithm's name and click Buy Compute Job. - -

Buy the compute job to check your work!

- -The output of your algorithm's computation on the dataset will appear in the Algorithm.log output. Voilá! - -#### Now do a little dance, because you're done! - -{% embed url="https://media4.giphy.com/media/CxhWJeIicfOEynsEn6/giphy.gif?cid=ecf05e478eb1zzixmsjwbwx37a0d4e1096812j513crzr18j&ct=g&ep=v1_gifs_search&rid=giphy.gif" %}