You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Add linting files.
* Install an older version of eslint so that it's compatible with the one in the client folder.
* Add some manual testing steps.
* Make minor clean-ups in setup scripts.
* README: Make minor clarifications.
Copy file name to clipboardexpand all lines: demo/README.md
+43-12
Original file line number
Diff line number
Diff line change
@@ -18,11 +18,25 @@ This section explains how to set up locally on Linux/WSL, alternatively, you can
18
18
The following steps are made for Linux/WSL and require `npm` with `node` version 10.
19
19
Other later versions of node might work too but some node-gyp issues occurred with version 14.
20
20
21
+
You will need to have `make` installed.
22
+
On Debian (e.g. Ubuntu) you can do:
23
+
```bash
24
+
sudo apt install build-essential
25
+
```
26
+
21
27
Run
22
28
```bash
23
29
./setup.sh
24
30
```
25
31
32
+
## Troubleshooting Setup
33
+
If you have problems running the setup steps related to node-gyp, then you might need to set Python 2.7 to be your default (just during the installation).
34
+
Recommendation: Temporarily set up a Python 2.7 Conda environment (just for the installation) and activate it:
(Microsoft Devs) To update the production website, see the instructions at the top of [service.Dockerfile](./service.Dockerfile).
71
85
72
-
## Troubleshooting Setup
73
-
If you have problems running the setup steps related to node-gyp, then you might need to set Python 2.7 to be your default. Recommendation: Set up a Python 2.7 Conda environment and activate it.
74
-
75
86
## Update
76
87
To update dependencies after already setting up:
77
88
```bash
@@ -82,7 +93,10 @@ To update dependencies after already setting up:
82
93
There is a video example showing how to deploy <ahref="https://aka.ms/0xDeCA10B-deploy"target="_blank">here</a>.
83
94
84
95
## Blockchain
85
-
Start the blockchain (Ganache) in one terminal.
96
+
Models and data are stored on a local blockchain.
97
+
98
+
99
+
Start the blockchain (uses `ganache-cli`) in one terminal.
86
100
Run:
87
101
```bash
88
102
yarn blockchain
@@ -95,7 +109,9 @@ Do once:
95
109
* Use that private key to create a new account in MetaMask.
96
110
97
111
## Server
98
-
This is used by default in development mode but not in production.
112
+
(Optional) The server is used to store model meta-data and original data when for training models.
113
+
114
+
The server is used by default in development mode but not in production mode.
99
115
100
116
If you want to store meta-data in a local database file instead of just within the browser, then start the server in one terminal.
101
117
This step allows you to see models listed when you open the dashboard for the first time.
@@ -108,7 +124,9 @@ yarn server
108
124
```
109
125
110
126
## Client
111
-
Then in another terminal.
127
+
The website is the "client", it allows you to interract with the blockchain and optional server.
128
+
129
+
In another terminal.
112
130
Run:
113
131
```bash
114
132
yarn client
@@ -156,13 +174,25 @@ If you get the spinning issue again, then also try following the steps above wit
A local blockchain will be started and stopped so it's best not to have a blockchain running at the same address and port (e.g. one running through `yarn blockchain`).
165
183
184
+
## Manual Testing
185
+
Not all tests are automated (yet, maybe one we'll automate them all).
186
+
Some things that should be manually tested in the UI after completing the deployment:
187
+
* Pick a model
188
+
* PREDICT: Verify that you can use the model to classify some data
189
+
* TRAIN: Add "incorrect" data as user "Bad"
190
+
* Add "correct" data as user "Good"
191
+
* REFUND: Verify that "Good" can get a refund for the "correct" data
192
+
* REWARD: Verify that "Good" can report "Bad"'s "incorrect" data
193
+
* Add a new model
194
+
195
+
166
196
## Running Specific Tests
167
197
To run specific smart contract tests and save time by not waiting for Truffle migrations:
168
198
* In one terminal, start a blockchain: `yarn blockchain`
0 commit comments