Archive for the 'thesis' Category

Promiserver thesis complete!

This thesis envisions the future of trust and social commitment in a highly connected society. Starting with a distributed, democratized labor force and economies of efficient niche production and consumption, we predict radical shifts in the meaning and methods of commitment and the institutions of trust. The central experiment of this thesis is Promiserver, a web-based service and toolset for creation of lightweight contracts—dubbed promises—that are written as code. The service decouples commitment logic from specific applications, providing a generalized tool and forum for dynamic creation, binding, and evaluation of promises. The goal of Promiserver is to facilitate new models of collaboration by offering a sensible, lightweight, and agile promise system as an alternative to traditionally heavy legal commitments.

Promiserver: Procedurally Executed, Socially Enforced Microcontracts
(100 pages, 12MB PDF)

Warm nights

I’ve been ready for this warm weather. I’ve been sleeping with my window open lately, which has been great. Tonight, for the first time this year, I got home and opened my back window to hear the sound of my neighbors’ air conditioners. While I actually don’t mind it being 73 out and a little humid, it sounds like others do. I guess I can put up with a little hum, though personally I’ve generally been happier to be a little warm with quiet.

With the sunshine comes relaxation. I’m shedding my winter and springtime worries, handing over theses for signatures, and feeling a little more comfortable. It’s hard to distinguish where the sun and warm breezes end and where my own reemerging sense of satisfaction begins.

Entering the final stretch

I have a structurally complete version of my thesis now, and I’m just waiting to work on revisions based on feedback from my readers, John, Hiroshi Ishii and ML alum Brent Britton. Though I know I have some more work to straighten it up, and the deadline is coming right up this Friday, it feels really good to have all the parts in place.

The other news is that I resuscitated OPENSTUDIO today, putting it on our newer server, which also involved switching it to apache2.2 and mongrel cluster instead of fastcgi, and setting up Postgres and PHP, plus some Tomcat fiddling. Way too many technologies happening in that project.

Early Promiserver Observations & Questions

Good friend and PLW alum Burak Arikan posted a comment with some interesting questions and observations about Promiserver. I’m on full thesis mode today, and these issues are very much in line with what I’m thinking about.

1. So far promiserver people tend to write promises for themselves alone. Why do you think this happens? What would make people focus on writing contracts among themselves and other people?

This is a good, open question. It may be simply the terminology “promise” makes people think that if they write it, they are the participant. This has been a confusing point for almost everyone I’ve tested this with. A few reviewers were very confused about why they needed to put anyone in the promise at all. I don’t have any solid answers here. People may also be timid about publicly asking other people do things. I also think no one really even knows what sorts of promises to make.

2. When does promiserver evaluates/runs a promise? I see the Audit Trail evaluation list. But It is not clear what is the order or logic for these evaluations?

It evaluates active (signed by all participants) promises every 5 minutes, and also every time values are updated. Every value update is also logged, though this part of the audit trail is not yet visible.

3. I think promiserver needs ultra-light remote interfaces for entering / updating values in the contracts. This might be SMS interfaces, email commands etc.

I agree. I was working on the API for this yesterday. It is close, I just have some authentication/permissions issues. I probably won’t have time to work on it again until mid-May. Once there is a simple REST API then other interfaces can follow (widgets, email, physical/sensors, etc).

Thanks again to Burak and everyone else playing with this thing. Sorry the system still has a few bugs here and there, but we’ll work ‘em out. It’s been so rewarding seeing you all make your accounts and test it out. It is motivating me to finish writing.

And special props to Carlos Rocha for his random promise. So awesome.

How to write a Promiserver promise

This post is my first attempt to explain how to write Promiserver code. This will eventually also find its way into a Promiserver help section, but I thought I’d try it out here first.

Breach and Success

There are two reserved methods: breach and success. Each takes an optional message parameter. Your code defines the conditions under which the promise breaches or succeeds. For example, a really simply promise would be:

if condition_x
  success "it happened!"
end

The value of the condition_x variable determines whether the promise evaluates to success. When condition_x evaluates to true, the promise will be evaluated as a success, with corresponding message “it happened!”. A marginally more sophisticated promise might look like this:

if condition_x
  success "x happened!"
elsif condition_y
  breach "sorry, y happened"
end

In this one we have possibility of a breach as well, if condition_y evaluates to true.

Promise State

Those variables like condition_x and condition_y aren’t defined anywhere in this code. This means that they are free variables.

All these free variables in your promise code are extracted as you write the promise, and together form the state of the promise. When writing the promise, you can change the values of these variables to the desired initial state. Once published and signed, all participants can also change the values of these variables.

Time

Most promises are commitments with respect to some future action or event. So it may make sense to take time into account.

if document_received
  success "thanks, nice work"
elsif  Time.now > document_deadline
  breach "missed the deadline
end

Again, document_deadline and document_received become promise state variables, meaning they can be changed by the participants. If we wanted to fix the deadline and remove it from the state, we could simply add in a line.

document_deadline = Time.parse("5/11/2007 6:00pm")
if document_received
  success "thanks, nice work"
elsif  Time.now > document_deadline
  breach "missed the deadline
end

Keep in mind that Time.now evaluates differently each time the promise is evaluated. Future versions of Promiserver will have a timeline or calendar view, to try out the code for different times in the future.

Ruby Niceness

Since we’re using Ruby with some special activesupport magic, we can use some cool shortcuts. For example, say we want to allow for an extension:

...
if Time.now > (final_date = deadline + extension.days)
  breach "missed the extended deadline #{final_date}"
end
...

This is just a starting point. I have a few people using the system now, and in particular Burak has been a great tester, authoring some promises that have pushed Promiserver a little our of its comfort zone. So we’ll see how this contract-as-code idea continues to develop.

How to Make Things

Thinking about where I am with Promiserver and some mistakes I’ve made, here are two lessons:

  1. Start humble and iterate, rather than proudly setting out to build a complex system from scratch.
  2. Continually get feedback from the smart people around you. Make an effort to develop an honest rapport with your peers.

More lessons to come, I’m sure.

Promiserver ultra-alpha omega supreme

Promiserver

Check it out: promise.media.mit.edu. Borrowing the slogan from OpenCode, This is so alpha, you won’t even want to use itâ„¢

Well, it’s been a while coming, and now I have a super alpha version of Promiserver live and ready for you to make all your programmed commitments with that same desperate, wanton abandon we saw in the early field tests. It’s got bugs aplenty, as well as interface problems, but I can fix em as we find em. Tags coming soon, plus REST API for creating promises programmatically, which is where I think a lot of the applications will be. A lot of other updates too, providing I have enough time given this whole writing ordeal I’m still in the middle of (sigh).