Continuing to integrate netlify

This commit is contained in:
NunoSempere 2021-04-09 00:17:10 +02:00
parent b86d95778c
commit 2f6c8daaca
2 changed files with 12 additions and 3 deletions

View File

@ -14,8 +14,17 @@ I also created a search engine using Elicit's IDE, which uses GPT-3 to deliver v
``git clone https://github.com/QURIresearch/metaforecasts``
### 2. Enter your own cookies
Private session cookies are necessary to query CSET-foretell, Good Judgment Open and Hypermind. You can get these cookies by creating an account in said platforms and then making and inspecting a request (e.g., by making a prediction, or browsing questions). After doing this, you should create a `src/privatekeys.json`, in the same format as `src/privatekeys_example.json`
### 2. Enter your own process.env variables
The following environment variables are currently needed to run the `master` branch:
- `MONGODB_URL`, a string in the format `"mongodb+srv://<username>:<password>@<mongodburl>/?retryWrites=true&w=majority&useNewUrlParser=true&useUnifiedTopology=true"`
- `REBUIDNETLIFYHOOKURL`, a string in the format `"https://api.netlify.com/build_hooks/someprivatestring"`
- `CSETFORETELL_COOKIE`
- `GOODJUDGMENTOPENCOOKIE`
- `HYPERMINDCOOKIE`
The cookie formats can be found in `src/input/privatekeys_example.json`; these session cookies are necessary to query CSET-foretell, Good Judgment Open and Hypermind. You can get these cookies by creating an account in said platforms and then making and inspecting a request (e.g., by making a prediction, or browsing questions). After doing this, you should create the environment variables.
Alternatively, for fewer complications, have a look at the `commandlineinterface` branch, which instead of requiring environment variables only requires a `src/privatekeys.json`, in the same format as its `src/privatekeys_example.json`. Its disadvantages are that the command line tool in the `commandlineinterface` is more difficult to integrate with other services.
### 3. Actually run

View File

@ -13,8 +13,8 @@ import {predictit} from "../platforms/predictit-fetch.js"
import {omen} from "../platforms/omen-fetch.js"
import {smarkets} from "../platforms/smarkets-fetch.js"
import {williamhill} from "../platforms/williamhill-fetch.js"
import {rebuildNetlifySiteWithNewData} from "./rebuildNetliftySiteWithNewData.js"
import {mergeEverything} from "./mergeEverything.js"
import {rebuildNetlifySiteWithNewData} from "./rebuildNetliftySiteWithNewData.js"
/* Do everything */