- DO NOT PUSH
datasets/TO GITHUB. IT'LL BE TOO MUCH TOO PUSH. - If you are importing a new library, just let Allen know :).
- To fetch an api route, call the
api()function.-
POSTmethods require a second argument (request) -
An example of
GETmethod fetched from React:fetch(api("/testget")) .then( response => response.json() // convert to json ).then( responseJSON => { /* some logic */ } )
-
An example of
POSTmethod fetched from React:let request = { method: 'POST', headers: { 'Content-Type': 'application/json', }, body: JSON.stringify(echo) } fetch(api("/echo"), request) .then( res => res.json() ).then( response => response.json() // convert to json ).then( responseJSON => { /* some logic */ } )
-
- Frontend will use Material UI (https://mui.com/material-ui). Find pre-made components to use. in frontend. They also provide playground for you to change up the component, and you can copy paste into codebase.
- Twitter API is way too expensive. Instead, we will down pre-existing Twitter datasets (https://github.com/shaypal5/awesome-twitter-data) into
datasets/folder and train models from there.
- client/: contains the react frontend
- flask-server/: contains the Python backend
- nlp-model/: ALL work pertaining to NLP predictive models
- datasets/: stores all our datasets for building NLP application
git clone https://github.com/AllenCaoo/MediaPilot.git- Ensure:
Python >= 3.9 pip install -r requirements.txt(trypip3ifpipdoesn't work)cd clientnpm installcd ..cd nlp-servergit clone https://github.com/mindsdb/mindsdb.gitpython setup.py developpython -m mindsdb- Fin!
cd flask-serverpython server.py(trypython3ifpythondoesn't work)- The Flask backend server will run on
http://localhost:5000
cd clientnpm start- The React frontend will run on
http://localhost:3000
docker run -p 47334:47334 -p 47335:47335 mindsdb/mindsdbhttp://127.0.0.1:47334/- Afterwards:
- powershell ->
wsl --shutdown
- powershell ->