(Redirected from F2FPlugin)

F2FWordPressPlugin

The F2F Plugin generates an XHTML/RDFa page giving a list of all OpenIDs associated with approved comments on a Wordpress blog.

See also F2FMediawikiPlugin

F2F is an experimental component of a larger ecosystem. By explicitly sharing OpenID URLs that represent active community discussions, and by using the implicit trust and credibility filtering associated with blog comment approval, we provide some basic information that can be used by reputation aggregation tools.

See blog post: Wordpress trust syndication. Excerpt:

FOAF has always had a bias towards describing social things that are shown rather than merely stated; this is particularly so in matters of trust. One way of showing basic confidence in others, is by accepting their comments on your blog or Web site. F2F is an experiment in syndicating information about these kinds of everyday public events. With F2F, others can share and re-use this sort of information too; or deal with it in aggregate to spread the risk and bring more evidence into their trust-related decisions. Or they might just use it to find interesting people’s blogs.

As a Wordpress plugin, F2F can only be used on self-hosted Wordpress installations (ie. it doesn't work with wordpress.com blogs). Also it assumes you are using the excellent openid plugin, and that people have left comments via OpenID.

For more details and background, see initial announcement and the initial Syndicating Trust blog post.

Nearby in the Web: Gerald's notes on Reputation, MIT DIG FOAF+OpenID work; chat with Dan Connolly. Also see [trust discussions] from 2002.

Previous SemWeb/Wordpress work: sparqlpress (SparqlPress,spoogle.dk)


Contents

Use Cases

Reputation

If you have a wordpress blog and use the openid plugin, it will expose a list of OpenIDs that you've accepted comments from. Similarly, if your friends and colleagues install it, you could use your knowledge of their decisions to help guide yours.

For example, you could use this kind of data to autofill Wiki permission groups:

  • if someone's openid is good enough for 3 people i work or coauthor with, ... they're trusted to edit my wiki

People Finding

Knowing that someone comments on a blog (and if this is reciprocated) can help find people, experts, and clusters of interest. You might for example install a feed aggregator like Venus and populate it with RSS/Atom feeds found via these URLs. Or OAuth-powered services like conversationlist could use such lists to remote-control your views of Twitter, StatusNet, by showing posts from the people on the list of folk who participate in your blog (or your friends blogs).

Implementation

Groups-fig1.png

The plugin is available as a work-in-progress from SVN. Seriously - use with caution! It makes several assumptions that might not be applicable in every setting. Specifically:

  • the F2F plugin will publish the full URLs of all (accepted) commentators on your blog
  • it does not obfuscate the OpenIDs in any way; ensure you and/or your users can live with this
  • it requires a Wordpress page with a URL path of /network appended to the blog's base address

The code does not use externally supplied content beyond URLs that have passed through the openid process. However it hasn't been carefully reviewed for security issues. Beware!. There isn't a lot of code; please read it before use and make up your own mind.

Code is available in the FOAF Subversion server: f2f.php ... you should be able to get something installable by doing "svn checkout http://svn.foaf-project.org/foaftown/2010/wordpress".

Live copies

These may come and go. If you install a copy and are happy with people seeing the data, please add a link here. In future we'll define better discovery mechanisms...

Installation

  • read this page and the f2f.php code; decide that this is what you want to do.
  • make sure you've got the openid plugin installed and operational, and some comments that used it
  • put f2f.php in plugins/foaf.php
  • activate the F2F plugin from within Wordpress admin screens
  • create a draft page at /network within your blog (this requirement should go away in future)
    • or at another path of your choice; edit the /network line in the php accordingly
  • an ugly html page containing a list of URLs should be visable at the /network url

Bugs and Features

Problems

  • current page formatting is horrible: it appends RDFa markup at footer of a page, and then moves it into middle of page with CSS
  • the URL path is hardcoded to /network
  • you have to (?) create a page at /network first using Wordpress
  • you have to hack your theme to use the RDFa DTD and declare FOAF's xmlns: binding
  • we don't check that the OpenID plugin is installed
  • couldn't get an options/settings page working
  • finding a nice environment for querying; eg. rdflib tests are slow

Opportunities

  • A background process should harvest data from each OpenID and store it locally; this could be done by embedding the arc2 toolkit.
  • We should find a way of setting the public path without requiring a page to be created


Design Issues

The current design only exposes a list of URIs via RDFa. Some design assumptions to discuss:

  • we use the foaf:Group construct to model this
  • for now, the only association between the 'Group' and the blog is that we say the group has a foaf:maker which is a foaf:Agent that has a foaf:weblog of the blog's base URL.
  • we also use foaf:account to relate agents to pages (blogs and weblogs)
  • for each foaf:Agent in the foaf:Group, we generate a local-to-the-page URI
  • local-to-page URIs are prefixed with /network#!foo, where the '!' is a way of making sure names don't clash with HTML IDs
  • we don't expose a list of non-approved commenting OpenID URLs
  • we don't expose any numbers
  • we don't define how to find this page, starting from the top of the blog

Sample client code

How to use the embedded RDFa?

The following Python code works with the trunk version of rdflib, which has an RDFa parser bundled. If you install with 'python setup.py develop' it will link your installation to a checked out directory from rdflib svn.

#!/usr/bin/python

import rdflib.graph
from rdflib.namespace import Namespace

FOAF = Namespace("http://xmlns.com/foaf/0.1/")
g = rdflib.graph.ConjunctiveGraph().parse('http://danbri.org/words/network')
g.bind("foaf", "http://xmlns.com/foaf/0.1/")

for s, p, o in g:
    print s, p, o

RTFMing

Some handy links to wordpress info...