Skip to content

harjinder-hari/fabric8-analytics-recommender

 
 

Repository files navigation

Fabric8-Analytics Analytics

Note on naming: The Fabric8-Analytics project has evolved from 2 different projects called "cucos" and "bayesian". We’re currently in process of renaming the modules and updating documentation. Until that is completed, please consider "cucos" and "bayesian" to be synonyms of "Fabric8-Analytics".

Clone Fabric8-Analytics Analytics repository

git clone [email protected]:bayesian/Analytics.git
cd Analytics/models

Each model accounts for offline/online analytics jobs. Accordingly the folder structure has been setup. Offline model is all about training the analytics model. Online model is then about scoring based on an input.

Running the recommendation service standalone

$ cd <your_model_of_choice> #in this case we only have `similarity_with_frequent_patterns`
$ virtualenv --system-site-packages env
$ source env/bin/activate
$ pip install -r deployment/requirements.txt

Copy src/scoring/config.py.template to src/scoring/config.py and update the configuration in src/scoring/config.py

Start the server now

$ gunicorn --pythonpath src/scoring -b 0.0.0.0:5000 -t 300 ghazab_app:app

Call Recommendation API Endpoint

$ curl -XPOST "packagejson=@tests/data/sample.json" "http://127.0.0.1:5000/api/v1.0/recommendation"

Tests

How to run tests?

$ cd <your_model_of_choice>/src/unittest/scripts
$ source virtual_test.sh

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 98.2%
  • Shell 1.8%