Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Add keyword and regular expression "suggestions" for tags.

branch: master

This add on module allows you to easily associate keywords and regular
expressions with a Tag object. This is useful to help keep your database
from getting filled up with several similar tags that really represent the 
same thing or concept.

For example, if your site is a humor site you might want to collapse all of
#fun, #funny, #funnies, #hilarious, #rofl, and #lol into one tag #funny.  The
``suggest_tags()`` function in ``taggit_suggest.utils`` will give you a
list of tags that seem appropriate for the text content given to it.

Unlike the rest of ``django-taggit``, ``taggit_suggest`` requires Django 1.2.


Put ``'taggit_suggest'`` into ``INSTALLED_APPS`` and run a syncdb to
create the necessary models.  This will add ``Keywords`` and
``Regular Expression`` inlines to the default ``django-taggit`` admin.  Once
you've populated those based on your site you can do a simple:

.. sourcecode:: python

    from taggit_suggest.utils import suggest_tags

    tags = suggest_tags(content='Some textual content...')


* In a later version I hope to a simple way to help determine keywords for you
  automatically, by learning from your past tags and content.
Something went wrong with that request. Please try again.