A Canvas for Thought

July 18, 2007

Facebook: the ultimate P2P darknet enabler?

Filed under: ideas,wild speculation — vednis @ 6:16 am

Could Facebook be used as the catalyst for a new generation of Peer-to-Peer darknet applications?

Briefly, a darknet is a private virtual network where users only connect to people they trust.  This is very similar to the networks that Facebook builds. Trust is the key.  You connect to close friends and relatives, giving them access to personal content not privy to your larger network as a whole.

Facebook could become an enabler for these networks, in that it provides a common point in the network through which you may connect with those trusted people.  Not directly, but via Facebook’s new applications interface, or via exisiting network tools that Facebook supports directly, such as MSN, Gmail, etc.

One such darknet application may be Peer-to-Peer shared backups.  Imagine making an agreement with your relatives, that you would each devote 2GB of hard-drive space to keeping the family photo pool backed up.  Some clever Open Source software could keep the photo pool maintained, distributed among all of your computers.  The sharing tool could use a Facebook application for peer discovery.

You could even route new content over existing tools.  I wonder, if you could install the iLike application, could you use it to publish new content for your friends, and hook an Open Source content sharing tool into the iLike interface to handle the transfer?  iLike publishes what’s new, Facebook publishes your content share points, and the Open Source tool handles the data.

Using Facebook to publish content discovery and sharing points opens the door to federated services, allowing you to get your network out of the hands of commercial parties.  If I could publish the address of a personal server on Facebook (a server that I own, running my own services), then I could start building networks and sharing with others outside of Facebook.  And I would once again have control of my identity within those networks – I won’t have to rely on the Facebook privacy controls, or anything like that.

Just some ideas.


July 13, 2007

Setting a custom Ruby GEM_HOME on Ubuntu Feisty

Filed under: Uncategorized — vednis @ 1:23 pm

Here is a quick and painless solution for setting your own Ruby GEM_HOME in Ubuntu Feisty.

First, I’ll assume that you have installed the ruby and rubygems packages, and set your new GEM_HOME:

$ sudo apt-get install ruby rubygems
$ mkdir -p /home/mars/lib/ruby/gems
$ export GEM_HOME=/home/mars/lib/ruby/gems

All looks well, until we try to install something with the ‘gem’ command:

mars@sol:~/tmp$ gem install rake
/usr/lib/ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require': no such file to load -- sources (LoadError)
    from /usr/lib/ruby/1.8/rubygems/custom_require.rb:27:in `require'
    from /usr/lib/ruby/1.8/rubygems/remote_installer.rb:462:in `sources'
    from /usr/lib/ruby/1.8/rubygems/remote_installer.rb:472:in `source_index_hash'
    from /usr/lib/ruby/1.8/rubygems/remote_installer.rb:436:in `install'
    from /usr/lib/ruby/1.8/rubygems/gem_commands.rb:263:in `execute'
    from /usr/lib/ruby/1.8/rubygems/gem_commands.rb:225:in `each'
    from /usr/lib/ruby/1.8/rubygems/gem_commands.rb:225:in `execute'
    from /usr/lib/ruby/1.8/rubygems/command.rb:69:in `invoke'
    from /usr/lib/ruby/1.8/rubygems/cmd_manager.rb:117:in `process_args'
    from /usr/lib/ruby/1.8/rubygems/cmd_manager.rb:88:in `run'
    from /usr/lib/ruby/1.8/rubygems/gem_runner.rb:28:in `run'
    from /usr/bin/gem:23

Oops.  We are missing a file called ‘sources.rb’.  That file, curiously enough, is contained in the ‘sources’ gem.

So, we try this:

mars@sol:~/tmp$ gem install sources
/usr/lib/ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require': no such file to load -- sources (LoadError)

Same error. Drat!

Thankfully, there is a simple solution.  The sources gem was installed in feisty’s default gem cache:

mars@sol:~/tmp$ locate sources.rb

mars@sol:~/tmp$ ls /var/lib/gems/1.8/cache/

We can install the original gem into our new GEM_HOME.  Just make sure that you pass the ‘–local’ switch to the gem command, so that it doesn’t check for remote sources!

mars@sol:~/tmp$ gem install --local /var/lib/gems/1.8/gems/cache/sources-0.0.1.gem
Successfully installed sources, version 0.0.1

Now everything works as expected; we can install gems without using sudo:

mars@sol:~/tmp$ gem install rake
Bulk updating Gem source index for: http://gems.rubyforge.org
Successfully installed rake-0.7.3

P.S. Don’t forget to set your PATH!

$ export PATH=$GEM_HOME/bin:$PATH

July 12, 2007

Possibly the best software I have ever used

Filed under: cool,ideas — vednis @ 9:07 pm

My wife has been wanting to relearn French for a while, and she has wanted to try Rosetta Stone.  After seeing and playing around with the Flash demo, all I can say is, WOW.  This is probably the best-designed software I have ever used.

The interface is so simple, a four-year old could easily use it.  The content used to teach the lessons is spectacular.  And, best of all, the software places no barriers in front of the user.  The lessons have a flow, but you are not required to follow it – you can move forward or back, change the difficulty, time yourself, score yourself, but only at your own request.

I can’t stress that last point enough: You are in complete control of the software.

This is the way learning should be.  Structured by the learner, for the learner.  The goals you set for yourself while using the software are personal, based on your comfort level and motivation.  The consequences are profound: you are motivated to set goals higher, because there is no fear of failure, no consequences.  Being motivated means you actually learn.  Teaching a language by rote memorization doesn’t even compare!

Ok, time for some wild speculation: the technique used to present the language is conversational, repetitive, immediately applicable, and predictable.  The language constructs follow each other logically, weaving in and out, building on what came before.

So the question is: could we apply the Rosetta techniques to learning computer languages? :)

Some of the bases are already covered: we learn “hello world”, and move on from there, picking up the patterns along the way: here’s a procedure, this is a data structure, this is binding and scope.  But this is picked up slowly, by reading about it, often a chapter (or an example) at a time.  Could we speed things up, improve retention, quickly getting a feel for the flavour of the language?

I have already come across some interesting techniques for learning a new language, example programs worth porting, and such.  But I still think we could do better.

I’ll post more on this later.  Stay tuned!

Create a free website or blog at WordPress.com.