Software engineering notes

Posts Tagged ‘web

View

The joy of top-down rendering.

Problem

I want to present data, ideally as view = render(data).

Solution

I really like the view mechanics provided by choo/yo-yo/bel.

const html = require('bel')
const nanobus = require('nanobus')
const yo = require('yo-yo')

const bus = nanobus()
const render = yo.update.bind(yo, document.body)
const emit = bus.emit.bind(bus)

bus.on('change', (name) => {
  const state = {}
  state.name = name.toUpperCase()
  render(view(state, emit))
})

function view(state, emit){
  return html`
    <body>
      Hello, <input value="${state.name}" placeholder="name" onkeyup=${onKeyUp}>
    </body>
  `
  function onKeyUp(e){
    emit('change', e.target.value)
  }
}

Written by Erik

October 4, 2017 at 6:13 pm

Posted in pattern, tool

Tagged with , , , , ,

Linked Data: notes from Tim Berners-Lee’s 2009 TED talk video

I started watching Tim Berners-Lee’s TED talk last night. He defines the term linked data to refer to pieces of data placed on the Web and linked to one anaother.  He said there are three rules for putting something on the Web:

  1. http addresses are now being used to reference any unique entity on the Web, people, places, products, events, etc., not just documents
  2. If we request an object identified by an http address, we should get back useful information
  3. The object should include relationship pointers, formatted as http addresses, to other objects, e.g., “this person was born in Berlin, and Berlin is in Germany”.  A person can link to a city, which can link to a region …

Linked data is browsable.  The more data is connected together, the more powerful it is.

Berners-Lee mentioned DBpedia. dbpedia.org describes itself as “a community effort to extract structured information from Wikipedia and to make this information available on the Web”.

Diversity on the Web is important.  We can put all kinds of data on the Web, government, university, enterprise, scientific, personal, weather, events, news, etc.  Transparency in government is important, but this data is also beneficial because it describes how life is lived.  It’s actually useful.

But owners of data are tempted to hang on to it.  Hans Rosling calls this”database hugging”.  So, make a beautiful Website, but first make the unadulterated data available.  “Raw data now!”.  A lot of the data concerning that state of the human race is sitting on computers unaccessible by the Web.  Now that scientists are putting genomic data and protein data on the Web as linked data, they can ask questions like “What proteins are involved in signal transduction and are related to pyramidal neurons?” (personal note: this seems a lot like a db query).

Linked social data is only possible if we break down the walls of social networks.

Open Street Map is all about everyone doing their bit.  Linked data is all you doing your bit, everyone else doing theirs, and it all connecting.

“Linked data.  I want you to make it.  I want you to demand it.  I think it’s an idea worth spreading.”

Thanks, Tim!

Written by Erik

October 15, 2010 at 10:26 pm

the Internet as a series of tubes

We’ve long sought to create a singular artificial intelligence.  I wonder if another aspect of intelligence arises simply from the existence of connections.  Our brain is not composed of intelligence, but rather a mass of connections, neural pathways, which somehow creates an opportunity for intelligence to occur.  The Internet currently seems to be beginning to manifest intelligent behavior in that I can interact with it and gain something from that interaction (“You just checked into restaurant X.  Your friend Alan is here too”).  I wonder if it is our input then that brings this intelligence to life, i.e., we are the intelligence in the giant networked computer “brain”.  I can query the Web to find out where my friends are only because they have stated their position.  A measure of the Net’s intelligence could be based on the data it contains, the questions we imagine to ask, and our ability to ask them.

I feel inspired as an Internet software developer to make the process of interaction, contribution, and connection as easy as possible.  How can I make it easier to contribute?  Simplified markup is one option.  Easy authentication is another.  Improved data collection, such as automated geo positioning via mobile devices, and mining enable us to contribute implicitly.  How can I reduce the barrier to entry?

Yahoo!’s recent brand campaign stated that the Internet is all about “you”.  One way to interpret this is that Yahoo! facilitates contributions to, and recognition of, one’s self online.  I spend so much of my time online it seems like a second home.  So much of my persona involves how I see myself  reflected in the Internet.  Yahoo!, and many other services, tries to make it easy to be online and manifest a personality there.  This is one way to describe of the process of growing the Web.  This propagation of the Web could be summarized as: building physical and logical connections between people, and allowing them to input and retrieve data.  I’m curious to see if the Web does seem to become more intelligent relative to the success of these activities.

A few current touch points involving the simplification of Internet interaction, i.e., interaction with the Net itself, come to mind: establishing network infrastructure (how easy can we make it to set up an internet access point?  this shouldn’t be a bottleneck); creating and maintaining online identities (oauth, openid); storing the collected data in easily retrievable formats (semantic web, search, open gov, freebase, wikipedia); processing big data using mapreduce; server-side processing with web hooks and app engines; providing easy access to the processed data via asynchronous communication, key/value interfaces, convenient off-network “connect” access to social data; using apps on existing networks, and mobile devices, for easy delivery and consumption, esp. iphone and android.

Written by Erik

January 13, 2010 at 12:53 am

Posted in notes

Tagged with , ,