<commit_before>Free Music Ninja API
====================

Requirements
------------

This project requires `Python 3`_ and `PostgreSQL`_.


Installation
------------

First install Python and PostgreSQL:

.. code-block:: bash

    $ sudo apt-get install python3-dev libpq-dev postgresql postgresql-contrib


Install Python dependencies (in a virtualenv preferably):

.. code-block:: bash

    $ pip install -r django/requirements.txt


Environment Variables
---------------------

This project uses environment variables for configuration.

1. ``ECHONEST_API_KEY``: Credentials for `The Echo Nest API`_
2. ``JAMENDO_CLIENT_ID``: Credentials for `Jamendo API`_
3. ``FMA_API_KEY``: Credentials for `FreeMusicArchive API`_
4. ``SECRET_KEY``: `Secret key`_ for cryptographic signing
5. ``DATABASE_URL``: URL for database connection (see `database URL schema`_)



Running the Server
------------------

To start the Django server:

.. code-block:: bash

    $ ./django/manage.py runserver

Now visit http://localhost:3200/ in your browser.


.. _database url schema: https://github.com/kennethreitz/dj-database-url#url-schema
.. _freemusicarchive api: http://freemusicarchive.org/api/
.. _jamendo api: https://developer.jamendo.com/
.. _postgresql: https://www.python.org/downloads/
.. _python 3: https://www.python.org/downloads/
.. _secret key: https://docs.djangoproject.com/en/1.7/ref/settings/#std:setting-SECRET_KEY
.. _the echo nest api: https://developer.echonest.com/<commit_msg>Make Django README independent of root directory<commit_after>Free Music Ninja API
====================

Requirements
------------

This project requires `Python 3`_ and `PostgreSQL`_:

.. code-block:: bash

    $ sudo apt-get install python3-dev libpq-dev postgresql postgresql-contrib


Installation
------------

Install Python dependencies (in a virtualenv preferably):

.. code-block:: bash

    $ pip install -r requirements.txt


Environment Variables
---------------------

This project uses environment variables for configuration.

1. ``ECHONEST_API_KEY``: Credentials for `The Echo Nest API`_
2. ``JAMENDO_CLIENT_ID``: Credentials for `Jamendo API`_
3. ``FMA_API_KEY``: Credentials for `FreeMusicArchive API`_
4. ``SECRET_KEY``: `Secret key`_ for cryptographic signing
5. ``DATABASE_URL``: URL for database connection (see `database URL schema`_)



Running the Server
------------------

To start the Django server:

.. code-block:: bash

    $ ./manage.py runserver

Now visit http://localhost:3200/ in your browser.


.. _database url schema: https://github.com/kennethreitz/dj-database-url#url-schema
.. _freemusicarchive api: http://freemusicarchive.org/api/
.. _jamendo api: https://developer.jamendo.com/
.. _postgresql: https://www.python.org/downloads/
.. _python 3: https://www.python.org/downloads/
.. _secret key: https://docs.djangoproject.com/en/1.7/ref/settings/#std:setting-SECRET_KEY
.. _the echo nest api: https://developer.echonest.com/
{'fraction_non_alphanumeric': 0.16915254237288135, 'fraction_numerical': 0.009491525423728813, 'mean_word_length': 3.437593984962406, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 12, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '184287', 'n_tokens_mistral': 976, 'n_tokens_neox': 900, 'n_words': 254}