Websites which offer some form of social sharing are becoming more and more popular. These social sites allow members to share various objects of interest from photos (Picasa Web Albums, Panoramio, Flikr), videos (YouTube), movie reviews (Rotten Tomatoes), book/product reviews (Amazon), blogs/journals (WordPress, LiveJournal) and finally to the minutiae of their everyday lives (Facebook).
Social sharing sites also share some common features. A social object is shared with the community to which members can attach metadata: tags, reviews, rankings, etc. This type of socially shared metadata enables sites to “add value” by providing features such as recommendation systems (Amazon), object rankings (Rotten Tomatoes), number of views (YouTube), find related objects by tag or member (Picasa Web Albums). This “added value” makes the sharing experience richer and helps to connect members no matter where they are geographically.
Goals:
I'm not planning on linking to other social sharing sites or their content. I want to build a Social Object module that would allow SilverStripe sites to implement social sharing similar to what is available on Rotten Tomatoes or Amazon etc.
For example, say a SilverStripe developer is building a site for Australian motorcycle enthusiasts who want to share their photos of their trips along with their opinions of the best trip routes or the best cafes to stop at. Maybe these members come from all over Australia so they might want to connect with a member from another state with similar interests if they're planning a big trip.
A Social Object module will provide a basic building block which the developer can enhance for his specific implementation. It will already have a basic social object class (linked to the member who added it), with the setup to link metadata to it: tags, reviews/ratings, etc. The metadata must also be linked to the member who added it. The module will include various algorithms to compute similarity coefficients which is the foundation for providing a recommendation system or any more advanced social network analysis. The Social Object module will allow the developer to make the connections between similar objects, between objects and members and between similar members. These similarity connections enable the value adding features like finding similar objects or members with similar interests.
Have you thought about using a decorator (http://doc.silverstripe.org/sapphire/en/reference/dataobjectdecorator) instead of extending a data object?
IMHO it would be important to further specify the kind of metadata as this will have a big impact on both scope and recommender.
Have you thought about using a decorator (http://doc.silverstripe.org/sapphire/en/reference/dataobjectdecorator) instead of extending a data object?
Thanks for the suggestion regarding using a decorator for the DataObject. I have actually used a decorator for my MemberRole class. I extended it to accommodate extra fields, and has_ relationships, etc. But for my Article (my Publications) and LibraryItem ,etc classes I just extended the DataObject class. I based my MemberRole class on Aram's SSbits tutorial 'Registering Users and allowing them to edit their details' but I didn't really understand all of the underlying code behind it.
I think that is part of the main problem I've had using SilverStripe - I've found various tutorials which help me but I don't always get all of the underlying architecture choices.IMHO it would be important to further specify the kind of metadata as this will have a big impact on both scope and recommender.
Specifying the initial metadata is key. But there are almost endless choices - most dependent on specific implementation needs. I'm wondering how complex I make the initial module. Would it be better to provide for the most popular metadata choices, to be determined, in a basic module that can then be extended/adapted by the user using decorators? Can you use a decorator on a decorator? For example, if the SocialMember and SocialObject extend DataObjectDecorator with basic data and methods will a user be able to easily extend them?
Also some of the metadata will also be DOs - tags, reviews, etc which will need to have a many_many relationship to both the SocialMember and the SocialObject. I'm not sure if each of these will need to be there own separate module? I'm using the tagfield module now. Is it being updated for SS3, do you know?
I also noticed that the tagfield module says to create a tag DO that extends the DataObject rather than using a decorator. Is there a tutorial or something somewhere that I can read that can explain when its best to extend a class and when its best to use a decorator?