Lastest post

ipad announcement

On the announcement of iPad, Steve Jobs spoke harshly against netbook which has brought up a lot of talks of iPad vs Netbook. While many believe than Netbooks is still better than iPad which I also agree. Somehow I believe iPad will eat some of the netbooks market share, and netbooks manufacturers has to come up with something to stay competitive against the iPad. Making netbooks more personal and usable is the challenge here.

Instant OS

Many times I stay away from a desktop or a laptop and go with my iPod Touch if I want to have a quick look on the web, that's because I have to wait for the OS to load up. While many focuses on how much time you save for waiting with instant boot OS, actually this will bring the user experience into a whole new level. Web has been part of our life, and being able to have a quick access on it from time to time matters a lot. Not only the web, but we really do a lot stuff now with it. Its not only about time and speed, but usability. We have already a number of OS with fast boot time, but a windows version will really give netbooks a new image. I like linux, but the fact that many (big percentage) users are more comfortable using windows than linux. Linux could be an option if Google Chrome OS could deliver.

Battery Life

If netbooks could have a battery life like of average mobile phones it will make netbooks more useful than ever. On mobile phones, its battery life are measured in two factors the stand by hours and talk time hours. If this scheme is put into the design of making the netbooks hardware along with the OS it will surely make netbooks more portable & usable. The standby mode is the key here for a good baterry life. A re-work standby mode that behaves like mobile phone which will put you online whenever there's a connection more will bring make the netbooks tough to beat.

More things to consider

  • SSD should be the standard for netbooks. No more worries on how you handle or move with your netbooks.

  • Better integrated GPU for nice video playback. To match the video capabilites of iPad.

  • HDMI output. A real nice features to have, and a nice way to show off your netbooks.

  • Web video and voice call capable.

  • Last but the most important. Price below $499.

Am I expecting too much?

Update: More blog engine on App Engine

There are a lots of blog providers to choose from, some are really nice and provides almost everything a blog software should have. But creating your own blog is something cool and will give you more flexibility either you want a very simple one or the complicated on. With Google App Engine and a number of open source blog software you can now create you own blog site easily and fast.

Here are some of the nice App Engine based blog software

Pico Blog

pico blog

Bloog

bloog

Bloog - Thom Nichols Tweak version

bloog2

Bloggart

bloggart

Blog by JoeyB.org

Joeyb

Cpedia

cpedia

If you have other GAE based blog software not included on the list, comment on it. Happy coding and blogging!

Web application development in App Engine is still a new thing especially for me. While most of us are coming from the SQL type database, one of the most challenging work is to perform search.

Unlike SQL, you can't do START WITH or CONTAINS search, which I usually do in SQL for much user friendly search. There's also a limited inequality search you can do. Good thing is that there's a number of solution which could solve these shortcomings like the Searchable Model and Simple Full Text Search by Bill Katz.

Using the Searchable Model is really nice for short StringProperty you want to search on so you can be sure that you won't reach the 5,000 index entries cap. While is doesn't really imitates what the SQL START WITH and CONTAINS do, it is much better than the filter option provided. By default the Searchable Model index all the StringProperty you have in your model. To keep your Entries small and quick, you can specify which property gets index.

class Person(search.SearchableModel):
    first_name = db.SringProperty()
    last_name = db.SringProperty()

    @classmethod
    def SearchableProperties(cls):
        return [['first_name'], ['last_name']]

This will make a index on first_name and last_name separately, and you use it this way

query = Person.all().search('john', properties=['first_name']).order('frist_name')
query = Person.all().search('smith', properties=['last_name']).order('last_name')

You can also declare multiple fields to be in one index to perform search on multiple property search.

@classmethod
    def SearchableProperties(cls):
        return [['first_name', 'last_name']]

And use it like this.

query = Person.all().search('john', properties=['first_name', 'last_name']).order('frist_name')

Using the Simple Full Text Search by Bill Katz is best for searching TextProperty, to do what we did with Searchable Models, will be like this

class Person(db.Model, Searchable):
    first_name = db.SringProperty()
    last_name = db.SringProperty()

    INDEX_ONLY = ['first_name', 'last_name']

And performing search could be as easy as

query = Person.search('john')

While both implementation seems to very similar here's a simple comparision showing how different they are.

Searchable Model Simple Full Text Search
Stemming No Yes
Multi-word Some how Yes
Result Returns a query object wherein you can perform additional operation like filter and order Returns a list of match entities which you can't perform any filter or order, unless you're going to manipulate the list returned.
Implementation Adds a StringListProperty to your model (__searchable_text_index). This kind of implementation bounds you to the 5,000 index entries cap. Using another Model (StemmingIndex) to store the indexs of your model and links them by the Parent-child relationship. This approach is nice without modifying your model plus you're not bound to the 5,000 index entries cap.
Update When you update you entity, the index also gets updated. After updating your model, you have to manually update the index by performing a ancestor search on the StemmingIndex, delete it and create a new one to make the search perform right.

While there are still some limitation on these solutions, I still think they're great solution for now. Good news is we might have a Full Text Search API coming.

I found this interesting book on Guido's blog, the name of the book translates to "Lovely Python" which really suits as we all love working with this language. I really love book cover on this one, so nice and lovely. I think its the best book cover for python I've ever seen, and maybe more python logo could come out from this inspiration.

Lovely Python

Python being introduce to a billion population nation, imagine that!