<commit_before>Getting started quick guide
===========================

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

Use easy_install::

    $> easy_install django-moderation

Or download source code from http://github.com/dominno/django-moderation and run
installation script::

    $> python setup.py install


Updating existing projects to Django 1.7
----------------------------------------

If you are updating an existing project which uses ``django-moderation`` to Django 1.7 you need to follow these simple steps:

1. Remove ``'south'`` from your ``INSTALLED_APPS`` if present.
2. Run ``python manage.py migrate``.

That's it!


Configuration
-------------

1. Add to your INSTALLED_APPS in your settings.py:

    ``moderation``
2. Run command ``manage.py syncdb``


Usage
-----

To start using ``django-moderation`` follow these steps:

1. Create your models by extending ``moderation.db.ModeratedModel``::

    from moderation.db import ModeratedModel

    class MyModel(ModeratedModel):
         my_field = models.TextField()


2. To customize ``Moderator`` settings create ``class Moderator`` within your model definition::

    from django.db import models
    from moderation.db import ModeratedModel
<commit_msg>update docs (getting_started): add ModeratedModel info, restructure document, fixed typo<commit_after>Getting started quick guide
===========================

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

Use easy_install::

    $> easy_install django-moderation

Or download source code from http://github.com/dominno/django-moderation and run
installation script::

    $> python setup.py install


Updating existing projects to Django 1.7
----------------------------------------

If you are updating an existing project which uses ``django-moderation`` to Django 1.7 you need to follow these simple steps:

1. Remove ``'south'`` from your ``INSTALLED_APPS`` if present.
2. Run ``python manage.py migrate``.

That's it!


Configuration
-------------

1. Add to your INSTALLED_APPS in your settings.py:

    ``moderation``
2. Run command ``manage.py syncdb``


Usage
-----

To start using ``django-moderation`` follow these steps:

1. Create your models by extending ``moderation.db.ModeratedModel``::

    from django.db import models
    from moderation.db import ModeratedModel

    class MyModel(ModeratedModel):
         my_field = models.TextField()


2. To customize ``Moderator`` settings create ``class Moderator`` within your model definition::

    from django.db import models
    from moderation.db import ModeratedModel

{'fraction_non_alphanumeric': 0.15676959619952494, 'fraction_numerical': 0.00791765637371338, 'mean_word_length': 3.2470588235294118, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5490460', 'n_tokens_mistral': 728, 'n_tokens_neox': 655, 'n_words': 255}