8
IEEE Communications Magazine • December 2010 44 0163-6804/10/$25.00 © 2010 IEEE This project is partly sup- ported by NSC Taiwan under grant 98-2219-E- 001-001. INTRODUCTION Location-aware services (LAS) have emerged as smart mobile devices and IP wireless networks (e.g., third generation [3G] and WiMAX) have become popular and ubiquitous. An LAS appli- cation provides a geographical position-specific service to mobile devices through the IP wireless network. Typical examples of LASs are identify- ing the location of a person or an object (e.g., the whereabouts of a friend or the nearest gas station) and location-related recommendations (e.g., driving route recommendations or the best restaurants in an area). Foursquare [1], GeoLife [2], Reality Mining [3], Shanghai Grid [4], and Cartel [5] are examples of existing LAS systems and research projects. The major difference between PLASH and other approaches is that it emphasizes the sup- port of volunteers and application providers. In PLASH, users can contribute their efforts and location-related data voluntarily; and LAS builders can use the PLASH framework and provided functions to deploy their applications easily. Moreover, with the support of PLASH, an ordinary user can easily share his/her person- al LAS with other users. The H in PLASH stands for human computation, which is a technique that uses large groups of humans to solve prob- lems current computers cannot process. The col- lective efforts and data generated by humans or sensors (or both) can be used to help solve diffi- cult location-related problems, such as real-time surface traffic estimation, city panoramas, and location-aware social networking analysis. The PLASH platform comprises three layers: communication, data, and service. The communi- cation layer supports various wireless communica- tion protocols (e.g., WLAN, WiMAX, and 3G) and networking contexts (e.g., vehicle-to-infra- structure, vehicle-to-vehicle, and vehicle-to-mobile device). The data layer is responsible for geoloca- tion data representation, storage, and access; and the service layer provides various services to sup- port PLASH applications. The layered architec- ture allows LAS application builders to create their systems by simply using application program- ming interfaces (APIs) to access the service layer or employing an application specification language (ASL) to build the systems. To demonstrate the capability of the PLASH platform, we have built a number of prototype LAS applications for the Android, iPhone, and web browsers. The contribution of this article is threefold: • We introduce PLASH, a platform for loca- tion aware services with human computa- tion. • We propose a multilayer platform and lan- guage for application builders to develop their applications. • We present an operating model of PLASH components and applications. The remainder of the article is organized as follows. The next section provides a review of related work. We then introduce the multiple- layer platform and PLASH framework. We then present a number of location-aware applications we have developed. We then detail the results of experiments conducted to evaluate the perfor- mance of PLASH. The final section contains some concluding remarks. RELATED WORK In this section we review some related works in the literature. LOCATION-AWARE SERVICES AND RESEARCH A location-aware/location-based service exploits information about the geographical position of people and objects. For example, Foursquare [1] is a type of social networking application that runs on mobile devices and lets friends track ABSTRACT The PLASH platform is designed to help loca- tion-aware service providers deploy their applica- tions easily so that users can contribute their efforts and location-related data by using the ser- vices, which is the main difference from tradition- al location-aware services. The collective efforts and data that may be generated by humans or sensors (or both) can be used to help solve diffi- cult location awareness problems, such as real- time surface traffic estimation, city panoramas, and social networking analysis. The PLASH plat- form comprises three layers: communication, data, and service. An LAS application developed on PLASH can exploit the functions provided in each layer by using an application specification language provided by PLASH. In addition, appli- cation builders can contribute their mature appli- cations as a service accommodated in the service layer for other application builders to expand and create more sophisticated applications. CONSUMER COMMUNICATIONS AND NETWORKING Yao Hua Ho, Yao Chuan Wu, and Meng Chang Chen, Academia Sinica PLASH: A Platform for Location Aware Services with Human Computation

PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 201044 0163-6804/10/$25.00 © 2010 IEEE

This project is partly sup-ported by NSC Taiwanunder grant 98-2219-E-001-001.

INTRODUCTION

Location-aware services (LAS) have emerged assmart mobile devices and IP wireless networks(e.g., third generation [3G] and WiMAX) havebecome popular and ubiquitous. An LAS appli-cation provides a geographical position-specificservice to mobile devices through the IP wirelessnetwork. Typical examples of LASs are identify-ing the location of a person or an object (e.g.,the whereabouts of a friend or the nearest gasstation) and location-related recommendations(e.g., driving route recommendations or the bestrestaurants in an area). Foursquare [1], GeoLife[2], Reality Mining [3], Shanghai Grid [4], andCartel [5] are examples of existing LAS systemsand research projects.

The major difference between PLASH andother approaches is that it emphasizes the sup-port of volunteers and application providers. InPLASH, users can contribute their efforts andlocation-related data voluntarily; and LASbuilders can use the PLASH framework andprovided functions to deploy their applicationseasily. Moreover, with the support of PLASH,an ordinary user can easily share his/her person-al LAS with other users. The H in PLASH standsfor human computation, which is a techniquethat uses large groups of humans to solve prob-lems current computers cannot process. The col-

lective efforts and data generated by humans orsensors (or both) can be used to help solve diffi-cult location-related problems, such as real-timesurface traffic estimation, city panoramas, andlocation-aware social networking analysis.

The PLASH platform comprises three layers:communication, data, and service. The communi-cation layer supports various wireless communica-tion protocols (e.g., WLAN, WiMAX, and 3G)and networking contexts (e.g., vehicle-to-infra-structure, vehicle-to-vehicle, and vehicle-to-mobiledevice). The data layer is responsible for geoloca-tion data representation, storage, and access; andthe service layer provides various services to sup-port PLASH applications. The layered architec-ture allows LAS application builders to createtheir systems by simply using application program-ming interfaces (APIs) to access the service layeror employing an application specification language(ASL) to build the systems. To demonstrate thecapability of the PLASH platform, we have built anumber of prototype LAS applications for theAndroid, iPhone, and web browsers.

The contribution of this article is threefold:• We introduce PLASH, a platform for loca-

tion aware services with human computa-tion.

• We propose a multilayer platform and lan-guage for application builders to developtheir applications.

• We present an operating model of PLASHcomponents and applications.The remainder of the article is organized as

follows. The next section provides a review ofrelated work. We then introduce the multiple-layer platform and PLASH framework. We thenpresent a number of location-aware applicationswe have developed. We then detail the results ofexperiments conducted to evaluate the perfor-mance of PLASH. The final section containssome concluding remarks.

RELATED WORKIn this section we review some related works inthe literature.

LOCATION-AWARE SERVICES AND RESEARCHA location-aware/location-based service exploitsinformation about the geographical position ofpeople and objects. For example, Foursquare [1]is a type of social networking application thatruns on mobile devices and lets friends track

ABSTRACT

The PLASH platform is designed to help loca-tion-aware service providers deploy their applica-tions easily so that users can contribute theirefforts and location-related data by using the ser-vices, which is the main difference from tradition-al location-aware services. The collective effortsand data that may be generated by humans orsensors (or both) can be used to help solve diffi-cult location awareness problems, such as real-time surface traffic estimation, city panoramas,and social networking analysis. The PLASH plat-form comprises three layers: communication,data, and service. An LAS application developedon PLASH can exploit the functions provided ineach layer by using an application specificationlanguage provided by PLASH. In addition, appli-cation builders can contribute their mature appli-cations as a service accommodated in the servicelayer for other application builders to expand andcreate more sophisticated applications.

CONSUMER COMMUNICATIONS AND NETWORKING

Yao Hua Ho, Yao Chuan Wu, and Meng Chang Chen, Academia Sinica

PLASH: A Platform for Location AwareServices with Human Computation

HO1 LAYOUT 11/18/10 10:55 AM Page 44

Page 2: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 2010 45

each others’ whereabouts on the Foursquaremap. It combines game-like objectives, such ascollecting points, prizes, badges, and eventuallycoupons, as users go about their everyday busi-ness. Foursquare surpassed 500,000 registeredusers in March 2010, and about 275,000 usersare signed in at any one time.

Microsoft Research’s GeoLife [2] is a location-based social network service on Microsoft VirtualEarth. It enables users to share their life experi-ences using their location history. Specifically,GeoLife mines the correlation between users andtheir location based on user-generated GPS tra-jectories. It provides three applications, namely,generic travel recommendations, personalizedfriend recommendations, and location recommen-dations, which leverage the GPS information andenable users to share their daily experiences.

MIT Media Laboratory’s Reality Mining [3] isa system for sensing complex social systems withdata collected from 100 mobile phones over thecourse of nine months. It measures informationaccess and usage in different contexts, recognizessocial patterns in daily user activities, infers rela-tionships, identifies socially significant locations,and models organizational rhythms. Personalreality mining infers human relationships andbehavior by applying data-mining algorithms toinformation collected by cell phone sensors thatcan measure location physical activity.

Shanghai Grid [4] has established an informa-tion grid to support the city’s traffic system, andcontinues to develop grid-based applications fortraffic congestion control and guidance. Oneapplication, called the Intelligent Traffic Infor-mation Service, is designed to achieve effectivetraffic management. It processes real-time trafficdata and provides various traffic services, such asvehicle tracking and traffic status estimation.

MIT’s Cartel [5] is a distributed mobile sen-sor network. Applications built on top of the sys-tem can collect, process, deliver, analyze, andvisualize data from sensors located on mobileunits, such as mobile devices. One of the appli-cations monitors traffic conditions based on GPSdata contributed by users. Using the GPS data,the authors developed a predictive delay modeland traffic-aware route-planning algorithm.

LOCATION-AWARE SERVICES PLATFORMThe number of mobile device users has increasedrapidly in recent years. Among smart phoneusers (e.g., iPhone or Android users), location-aware applications are one of most populardownloaded applications. Location-aware appli-cations, such as Foursquare [1] and Gowalla [6],allow users to connect between the real worldand a virtual world. Thus, many platforms havebeen developed to support location-aware appli-cations. For example, the Symbian platform pro-vides a set of APIs for Symbian devices to storeand access location information. In contrast toSymbian, PLASH stores location data and pro-vides a development environment for applicationbuilders to deploy their applications.

The NEXUS platform focuses on providingefficient data management services by distribut-ing data and handling queries from location-aware applications. In PLASH the datamanagement service is just one of many funda-

mental services (i.e., authorization control ser-vices). PLASH also allows other applicationdevelopers to contribute by sharing services (i.e.,shared services) and applications they havedeveloped.

IHP Technology developed a location-awareservice platform based on Java RMI/Jini to pro-vide the basic functions required by a locationapplication. In the IHP platform, an aura con-cept is used to define a region of interest for amobile terminal or a service available at a specif-ic location. A lookup service is also provided todetermine where a mobile device can offer itsservices to other users and vice versa. UnlikeIHP’s approach, most of the services provided byPLASH are located on servers. This strategyreduces the resource requirements of mobiledevices (e.g., computation power, bandwidth,storage, and battery power). Moreover, in thePLASH platform, a shared service is not theresult of a region of interest query (i.e., a loca-tion query) but an actual functionality of a ser-vice (i.e., an authorization control service) thatcan be used to develop phone applications.

THE LAYERED ARCHITECTURE OFPLASH

In this section we introduce the PLASH systemarchitecture. The system is an application plat-form built in JAVA based on Mule (an enterpriseservice bus). Figure 1 shows the three layers ofthe architecture: communication, data, and ser-vice. APIs are defined between adjacent layers.

COMMUNICATION LAYERThe communication layer is designed to supportwireless communications (e.g., 3G, WiMAX,WLAN) and networking contexts (e.g., vehicle-to-infrastructure [V2I], vehicle-to-vehicle [V2V]). Thelayer supports layered coding to overcome the lim-itations of some mobile devices (e.g., small screens,low bandwidth, and limited power and storagecapacity). The PLASH platform allows applicationbuilders to customize the communication require-ments (in terms of bandwidth or communicationprotocols) based on the needs of different applica-tions through the APIs in the communicationlayer. In this layer Representational State Transfer(RESTful) serves as a common protocol for differ-ent servers (e.g., application servers, databaseservers). The various services provided by applica-tion servers can be accessed by an HTTP requestusing methods like GET and POST to describe thenecessary create, read, update, and delete actions.The PLASH platform can support different devices(e.g., iPhone and Android devices) withREST/XML APIs.

DATA LAYERThe data layer is responsible for data representa-tion, storage, and handling access requests. Thelarge volume of geolocation-related data generat-ed and uploaded by mobile devices is stored inthe geolocation database. In addition to thePLASH geo-query processor, we currently usePostgreSQL with PostGIS [7] as the database tosupport geographic object and query processing.The location information uploaded by a user

The various services

provided by

application servers

can be accessed by a

HTTP request using

methods like GET

and POST to

describe the

necessary create,

read, update, and

delete actions. The

PLASH platform can

support different

devices.

HO1 LAYOUT 11/18/10 10:55 AM Page 45

Page 3: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 201046

contains spatial and related information. PLASHsupports different types of location-dependentspatial queries (LDSQs), including select queries,range queries, moving object queries, continuousqueries, and k-NN queries. Thus, an applicationcan query the geolocation database about thelocations of objects or people, such as gas sta-tions within 50 m of the user’s current location orthe five friends who are closest to his/her home.PLASH also maintains and stores user informa-tion, such as username, password, and friendshipinformation in the Social Core database. Betweenthe data and application layers, a set of standardAPIs is defined for querying location informationand user information. To protect the user’s priva-cy, the location data collected by PLASH is fil-tered before it is processed (e.g., the username isremoved from the location information).

SERVICE LAYERThe main function of the service layer is to pro-vide fundamental services and applications con-tributed (i.e., shared services) by other usersthrough APIs. In addition, PLASH applicationbuilders can use PLASH’s ASL to access the ser-vices. The layer also provides fundamental ser-vices, such as authorization control services (e.g.,login, logout, register, and friendship), databaseaccess services (e.g., select and insert), andLDSQ services. The PLASH platform is a friend-ly and efficient environment designed to helpusers and application builders utilize LASs.Therefore, PLASH also accommodates matureLAS applications as services. Through this layer,application builders can develop and deployapplications with low complexity.

STRUCTURE OF THEPLASH FRAMEWORK

In this section we discuss the components of thePLASH operating model and the applicationdevelopment of PLASH.

COMPONENTS OF THE PLASH FRAMEWORK

The operating model is divided into two parts: thePLASH application and PLASH platform, asshown in Fig. 2. The PLASH application is furtherdivided into the presentation layer and the logiclayer. In the presentation layer, client software isresponsible for user-side presentations and inter-actions. It can be implemented on different typesof mobile devices, such as a mobile phone or avehicle’s onboard unit. Users can subscribe tomany PLASH applications by downloading thecorresponding client software to their mobiledevices. The logic layer implements its applicationlogic, which can be hosted by the PLASH machineor run on its own machine. As shown in Fig. 2,various communication protocols are used to com-municate between different layers. HTTP/REST-ful is used between the presentation layer, logiclayer, and access managers in the service layer.Java Message Service (JMS) is used within differ-ent components in the service layer, and betweeninterfaces and processors, and Java Database Con-nectivity (JDBC) is used to access differentdatabases in the PLASH platform.

In the PLASH platform, five procedures —the Personal Information procedure, Uploadprocedure, Geo-query procedure, Feedback pro-cedure, and Delivery procedure — enablePLASH applications to access and share servicesand databases. The Personal Information proce-dure (steps 1 to 7, Fig. 2) allows the user tologin/logout and maintains personal information(i.e., friendship/membership, username/passwordinformation). If the login is successful, theUpload procedure (steps 8 to 11) is initiated.During this procedure, application dependentinformation (i.e., location associated informa-tion, Application ID/API Key, and the user-name) is sent to the PLASH Platform. TheGeo-query procedure may be activated (step 12)to check if the given geo-query can be satisfied.Depending on the application ID and its logic,the PLASH platform triggers associated servicesand sends the returned information to the appli-

Figure 1. PLASH's multi-layer platform.

Fundamentalservices, donatedLAS service, data

sharing services ...

Geo-queryprocessing, data

privacy andprotection ...

Data compression,ensure coding ...

Fundamental services Service layer

V2V, V2I Communiation layer

Data representation, storage and access Data layer

App 1 App 2 App 3

The main function of

the Service Layer is

to provide

fundamental services

and applications

contributed by other

users through APIs.

In addition, PLASH

application builders

can use PLASH

Application

Specification

Language to access

the services.

HO1 LAYOUT 11/18/10 10:55 AM Page 46

Page 4: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 2010 47

cation server (i.e., the Feedback procedure, steps13 to 15). The application server then processesthe returned information based on its applica-tion logic and delivers the aggregated data to themobile device (i.e., the Delivery procedure, step16). Finally, the client software on the mobiledevice displays the result.

We use an example, called the e-Coupon ser-vice, to help explain the interactions between thecomponents. The service gives an e-Coupon toregistered users within 100 m of a shop. First, auser logs into the e-Coupon application throughthe client access manager (CAM) to access theservice layer (step 1, Fig. 2). The CAM is respon-sible for load balancing and enforcing authenti-cation, authorization, and security policies tomanage different levels of access to resources.After the CAM grants access, the login informa-tion is passed through the service interface tothe user database in the Social Core to checkthe user’s authorization (step 2). Next, theDatabase service in the service layer queries thedatabases in the Social Core (step 3). If the loginis successful, a successful login message is sentback to the server access manager (SAM) and

directed to the e-Coupon application server(steps 4 to 6). The SAM is responsible for rout-ing the returned information from the PLASHplatform to the application server. Finally, the e-Coupon application server sends a successfullogin message to the user (step 7).

After the user logs in successfully, the mobiledevice can start sending its GPS data to thePLASH platform via the Upload procedure. Thelocation information is passed through the CAMand upload interface to the data preprocessor(steps 8 to 11, Fig. 2). The data preprocessor isresponsible for improving the database’s perfor-mance by using different techniques, such ascompressing and filtering incoming data beforeadding it to the geolocation database. The loca-tion information along with the user informationand application ID (i.e., the e-Coupon applica-tion) is passed to the geo-processor (step 12) tocheck if the user is within 100 m of the shop. Ifthe condition is satisfied, the result is forwardedto the e-Coupon server via the geo-query inter-face and SAM (steps 13 to 15). The geo-queryinterface is the outgoing interface of Geo-Core,which processes and sends the result to the

Figure 2. The PLASH operating model.

15

(HTTP/RESTful)

6

(HTTP/RESTful)

Geo

-que

rypr

oced

ure

(JD

BC)

1

Appserver

1

Applicationservers

Serveraccess

manager

Clientaccess

manager

Accessmanager

Appserver

2

Appserver

3

(HTTP/RESTful)

(HTTP/RESTful)

Personal informationprocedure

Upload procedure

Presentationlayer

Clients

PLASH application

Appclient

2

Appclient

3

Appclient

4

Appclient

1

Appclient

2

Appclient

4

Appclient

3

Appclient

4

8

16

(HTTP/RESTful)

Deliveryprocedure

7

(HTTP/RESTful)

14(JMS)

5

12

(JD

BC)

11

(JMS)

Geo-query

interface

Servicesinterface

Uploadinterface

Interface Databases

13(JMS)

4(JDBC)

2(JMS)

3(JMS)

9(JMS)

10(JMS)

Service layer Data layerLogic layer

PLASH pkatform

Geo-processor

Datapre-

processor

Geo-locationdatabase

Frienddatabase

Feedbackprocedure

Socialcore

Userdatabase

Geo core

HO1 LAYOUT 11/18/10 10:55 AM Page 47

Page 5: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 201048

SAM. If the response is positive, the e-Couponserver then sends the corresponding e-Couponto the user (step 16).

DEVELOPING APPLICATIONS ON THEPLASH PLATFORM

A PLASH application comprises the client soft-ware on the mobile device and the server soft-ware of the application server. To build aPLASH application, builders are required tohave a registered account and service agreementwith PLASH. After signing up, applicationbuilders can design their own LAS applicationsby using PLASH’s services, client and serversoftware repositories, and databases.

Client software can be implemented in vari-ous programming languages such as Java orObjective-C. Besides providing a graphical userinterface (GUI) for user interactions, client soft-ware has a function that collects geolocationand/or sensor data from devices as well as theuser’s input data, which it then uploads to thePLASH platform. The server software, whichcurrently supports the application logic imple-mented in JAVA, maintains user states andinteracts with PLASH’s services through theSAM via APIs. As a result, application builderscan combine the services with their own applica-

tion logics. For example, a server’s software cancombine different services including geo-queries,user authentication, and social network manage-ment to develop its application logic. Builderscan use PLASH’s databases (e.g., the geo-,friend, and user databases) and also maintaintheir own databases for specific uses. Further-more, builders can easily create an ASL file todescribe the database schema, service usage, andtheir interactions with other services. Afteruploading the ASL file, the platform constructsthe databases, approves the usage of the ser-vices, and creates an application server.

APPLICATION SPECIFICATION LANGUAGEIn PLASH, application builders can constructtheir application servers by using the ASL descrip-tion file. Figure 3a shows an example of the ASLdescription file for the e-Coupon service. In thefollowing we describe how the file helps usersdetermine the e-coupons available near their cur-rent positions. Then we explain how other ser-vices can easily mash up with the e-Couponservice by using an ASL construction file.

ASL Description File — Before constructing anASL description file, a builder needs to obtainan API key for the e-Coupon service fromPLASH. The key is used to control access to

Figure 3. Examples of PLASH ASL description and construction files: a) ASL description file; b) ASL construction file.

(a)

Serv

ice

usag

e de

clar

atio

n <Services> <GeoQuery> <Type>RangeQuery</Type> <Range>100M</Range> <GeoQuery> </Services>

1 2 3 4 5 6 7

20

Dat

abas

e de

finit

ion

<Database> <Table name=”coupon”> <Column> <Name>id</Name> <Name>name</Name> </Table> </Database>

21 22 23 25 34 54 58

App

licat

ion

desc

ript

ion

Inpu

t

<Application> <Desc>This service discovers nearby coupons. <Desc> <InternalDatabase>Private</InternalDatabase> <SharedServices> <Desc>This service discovers nearby coupons. </Desc> <Link>/eCoupon/FindCoupons<.Link> <InputParameters type=”OR”> <Desc>PLASH Login</Desc> <Name>plashlogin</Name> <Desc>Location</Desc> <Name>longitude</Name> <Name>latitude</Name> </InputParameters> <ReturnResult type=”SET”> <Desc>Location of the coupon.</Desc> <Name>longitude</Name> <Name>latitude</Name> <Desc>Information of the coupon.</Desc> <Name>category</Name> <Name>brand</Name> <ReturnResult> </SharedServices>

59 60 61 62 63 64 65 66 67 69 70 71 75 76 77 78 79 81 82 83 87 88 89 90

Retu

rn r

esul

ts

(b)

Show

Frie

nds

Serv

ice

Inpu

t

<Services> <InputParameters> <Desc>PLASH Login</Desc> <Name>plashlogin</Name> </InputParameters> <Link>/MapnTrackFriend/ShowFriends</Link> <ReturnResult type=”SET”> <Desc>Friend’s Name</Desc> <Name>fname</Name> <Desc>Friend’s Location</Desc> <Name>longitude</Name> <Name>latitude</Name> </ReturnResult> </Services>

<Services> <InputParameters type=”FOREACH”> <Desc>Friend’s Name</Desc> <Name>fname</Name> <Desc>Friend’s Location</Desc> <Name>longitude</Name> <Name>latitude</Name> </InputParameters> <Link>/eCoupon/FindCoupons</Link> <ReturnResult type=”SET”> <Desc>Friend’s Name</Desc> <Name>fname</Name> <Desc>Location of the coupon</Desc> <Name>longitude</Name> <Name>latitude</Name> <Desc>Information of the coupon.</Desc> <Name>category</Name> <Name>brand</Name> </ReturnResult> </Services>

1 2 3

4 5 6 8 9

10 11 12 13 14 15 20 21 22

Find

Cou

pon

Serv

ice

Inpu

t

23 24 25 26 27 28 33 34 35 36 37 38 39 40 46 47 48 57 58 59

Retu

rn r

esul

ts

Retu

rn r

esul

ts

HO1 LAYOUT 11/18/10 10:55 AM Page 48

Page 6: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 2010 49

PLASH’s interfaces. An ASL description filecomprises three parts: the service usage declara-tion, application description, and database defi-nition. (Note that the numbers on the left side ofFig. 3 are the real line numbers of the ASL files.Some lines may be omitted to save space.)

Service Usage Declaration — This defines theservices used by the current service. In lines 3 to 20of Fig. 3a, services like geo-query and personalinformation query are used in the e-Coupon service.

Database Definition — This defines theschema of the private database used by the ser-vice. In lines 21 to 58 the e-Coupon servicedefines its own private database (i.e., line 22:coupon) to store information, such as the loca-tion of stores/coupons, the description of thecoupon, and a link to the coupon image.

Application Description — This provides gen-eral information about the service as well as thedefinition of the shared service so that otherapplications can mash it up with their own ser-vices. In Fig. 3a the application description of thee-Coupon service is given in line 60, and theshared service definition is given in lines 62 to 88.

In e-Coupon’s application description, line 61sets the attribute “InternalDatabase” to indicatethat the database is private. It defines sharedservices, including its description (line 63), thehandle (i.e., “/eCoupon/FindCoupons”), and theinput parameters and return results (lines 65 to87). When other builders apply to e-Coupon’sshared service (i.e., FindCoupons), they onlyneed to provide location information such aslongitude and latitude as input. According to thelocation information, e-Coupon’s FindCouponshared service returns a set of coupons.

ASL Construction File — With the ASL con-struction file, PLASH application builders canmash up services provided by other builders. Toexplain the process, we use an example calledFriend&Coupon, where a builder wants to cre-ate a service to track his/her friends and discovercoupons near those friends at the same time. Weassume that the builder can also access a servicecalled Map’n Track Friends, which allows usersto share their current locations and trajectorieswith friends. The builder can easily mash up withthe Map’n TrackFriends and the e-Coupon ser-vice to create the new service by using the ASLconstruction file (Fig. 3b).

Friend&Coupon’s ASL construction filedefines the input parameters, mashed up ser-vices, and output parameters. Each mashed upservice (Map’nTrackFriends’ ShowFriends and e-Coupon’s FindCoupon) accepts a set of inputparameters and returns a set of results, as definedin their respective ASL description files. TheShowFriends service accepts username, password,and location information as input and outputs alist of friends’ names and their locations. Mean-while, FindCoupon accepts location informationand returns a list of coupon locations. By usingthe ASL construction file, PLASH applicationbuilders can develop new applications by utilizingshared services to save time and effort, andthereby reduce the entry barriers to providing

personalized LAS services. In the future, builderswill be able create new LAS applications throughthe PLASH GUI platform.

LOCATION-AWARE APPLICATIONSIn the following sections we introduce some LASapplications we have developed on top of thePLASH platform. Those applications are incor-porated into the service layer as shared servicesso that other application builders can use themdirectly or include them in their applications.

MAP’N TRACK FRIENDSOne of the applications is Map’n Track Friends.It is a location-based service application thatallows users to share their location trajectorieswith authorized persons. Figure 4 shows how aperson lets two of his/her friends know his/herlocation. One of the advantages of the PLASHplatform is that it can support different types ofmobile devices without changing the applicationlogic or server software. To authenticate users,the server software of Map’n Track Friends usesthe authorization control services (i.e., register,login or logout, change and lookup password, orsend notification to users) provided by the ser-vice layer. In Map’n Track Friends users canstore their trip information, share their currenttrip information with friends, or browse andtrack their friends’ trip information.

FRIENDCOMPASSIn FriendCompass, shown in Fig. 5, we combineaugmented reality with the location informationof friends and points of interest (POIs). Aug-mented reality means a live view (i.e., obtainedusing a camera on a mobile device) of a physicalreal world whose elements (e.g., a friend’s loca-tion or POI) are augmented by virtual computer-generated imagery. In FriendCompass users areable to use their current location, orientation,and mobile phone’s camera to view the surround-ing information, such as friends’ current locationsor POIs. The figure shows how FriendCompasslocates a friend and draws his/her location (i.e.,the green human icon) on the camera screen.The server software of FriendCompass uses the

Figure 4. Map'n Track Friends in Android, iPhone, and a web browser.

HO1 LAYOUT 11/18/10 10:55 AM Page 49

Page 7: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 201050

fundamental services provided by the servicelayer (e.g., authorization control services andLDSQ services). By using the provided services,it is easy to develop LAS applications on PLASH.

TOUR ROUTE RECOMMENDATIONIn the Tour Route Recommendation (TRR) appli-cation, we take advantage of human computationand data mining techniques to provide personal-ized recommendations. By combining the loca-tion and preferences of a user with trip historyinformation gathered from other users, TRR canprovide an on-demand recommendation. In theTRR server software, application builders onlyneed to focus on the application logic (i.e., tech-nologies that offer route recommendations to theuser). All other required services are provided bythe PLASH service layer. Note that all the serversoftware of the TTR application server can behosted by our application server.

VPROBEVProbe is an application that uses sensing tech-nologies (e.g., accelerometers and proximity sen-sors) on mobile devices to evaluate users’ dailydriving experiences or behavior (Fig. 6). Users canevaluate their driving behavior afterward. Theycan also compare their driving results with thoseof friends and share their driving experiences on asocial network service such as Facebook. Figure 6shows that the user’s driving behavior is evaluatedwith six stars and shared with his friends on Face-book. The PLASH platform allows developers tobuild their own applications and combine themwith web services like Facebook.

TO-AND-FOR IN VEHICULAR NETWORKIn many situations on vehicular networks, usersare primarily interested in information from anearby source. To-and-For (TAF) is an applica-tion that allows users to share local information,such as road surface conditions, traffic jams, and

car accidents. For more critical information (e.g.,a car accident), TAF ensures that all relevantusers within the area are aware of the informa-tion. A special type of local broadcasting proto-col (i.e., geo-casting) that decides to forwardrelevant information to appropriate users isimplemented in the communication layer.

LITERACY ENABLING SERVICEThe Literacy Enabling Service (LES) detects andreads text from a mobile device’s camera. Cur-rently, LES supports Chinese and English. Usingthe detected text and the user’s current location(and targeted locations), LES is able to providerelated information from the Internet. Clientsoftware on mobile devices first needs to detectthe text area in a live view. Then the client soft-ware sends the detected area (as a small pictureof the selected area) and location information tothe LES’s application server (server software).The LES’s server software then analyzes thereceived image to extract the text. The serversoftware is able to use the extracted text and theuser’s location information to search the weband PLASH’s geo-location database.

EVALUATIONIn this section we describe the evaluation experi-ment. We examined the performance of PLASHon a machine equipped with dual Intel XEON2.5 GHz quad-core processors and 3 Gbytes ofRAM. We experiment with different types ofqueries on different data sets. First, we study ak-NN query where k = 10 and the number ofPOIs is 1,000,000. With no indexing on the loca-tion point, the response time is 4594 ms. Howev-er, with the Generalized Search Tree (GiST)indexing structure, we can reduce the responsetime to 486 ms; and by using the KNNGiSTindex, the response time can be further reducedto 3.15 ms. The time cost of building theKNNGiST index is around 80,000 ms with 69Mbytes of memory. However, KNNGiST is 8 to11 percent slower on insertion queries and 5percent slower on non-k-NN queries. Thus, weonly use an indexing structure on data that areupdated less frequently, such as POIs (e.g., gasstations and restaurants). Since a user location isusually retrieved using the trip id, we do not useany indexing structure on users’ locations. With-out indexing, the maximum number of locationupdates the PLASH platform server can supportis around 120,000 inserts/min or 2 inserts/ms.When measuring the response time of the Map’nTrack Friends application, we observe that thereis a bottleneck in the communication layer whenwe compare the round-trip time of the threemajor 3G phone carriers. The average round-trip time per data packet is 290 ms, and theaverage total response time is less than 300 ms.

CONCLUSIONS AND FUTURE WORKSIn this article we have proposed a Platform forLocation Aware Service with Human Computa-tion (PLASH). The multilayer platform andapplication specification language provide a con-venient environment for application builders todevelop and host location aware applications.

Figure 5. FriendCompass showing a friend's location.

HO1 LAYOUT 11/18/10 10:55 AM Page 50

Page 8: PLASH: A Platform for Location Aware Services with Human ...cs.uef.fi/pages/franti/lami/papers/PLASH_ A... · architecture. The system is an application plat-form built in JAVA based

IEEE Communications Magazine • December 2010 51

Builders can also contribute their mature appli-cations as shared services accommodated in theservice layer for other application builders toexpand and create more sophisticated applica-tions. PLASH users can enjoy the LAS applica-tions and simultaneously contribute their dataand intelligence/efforts to help solve difficultlocation-related problems, such as real-time sur-face traffic estimation, city panoramas, and loca-tion-aware social networking analysis.

A number of issues need to be addressed inour future work:• Scalability: Currently, the PLASH platform

cannot handle a large volume of requests.Advanced computing mechanisms, such ascloud computing, may help alleviate thescalability problem.

• ASL extension and graphic interface: Thecurrent ASL capability is limited and mustbe extended to accommodate the demandfor more functionality. To this end, we planto incorporate a GUI to help applicationbuilders develop their applications.

• Efficient geo-query processor: A geo-queryprocessor determines the response time ofPLASH as each upload of geolocation datawill trigger the examination of each geo-query of applications. More efficient algo-rithms and resource management arerequired.

• Privacy: PLASH only applies minimal priva-cy protection by hiding the users’ IDs;hence, there are still many privacy issues tobe addressed.

ACKNOWLEDGMENTSWe wish to thank Ling-Jyh Chen, De-Nian Yang,Sheng-Wei Chen, Jan-Ming Ho, Jane Liu, andall other PLASH team members for their contri-butions to this project.

REFERENCES[1] Foursquare; http://foursquare.com/.[2] Y.-Zheng, X.-Xie, and W.-Y.-Ma. “GeoLife: A Collabora-

tive Social Networking Service Among User, Locationand Trajectory,” IEEE Data Eng. Bulletin, June 2010.

[3] N. Eagle and A. Pentland, “Reality Mining: SensingComplex Social Systems,” J. Personal Ubiquitous Comp.,vol. 10, no. 4, 2006, pp. 255–68.

[4] M. Li et al., “Shanghai Grid in Action: The First StageProjects towards Digital City and City Grid,” Int’l. J.Grid Utility Comp., 2005, vol. 1, no. 1, pp. 22–31.

[5] A. Tiagarajan et al., “VTrack: Accurate, Energy-AwareRoad Traffic Delay Estimation Using Mobile Phones,”ACM SenSys, Berkeley, CA, 2009.

[6] Gowalla; http://gowalla.com/.[7] PostGIS; http://postgis.refractions.net/

BIOGRAPHIESYAO HUA HO ([email protected]) received his B.S., M.S., andPh.D. degrees in computer science from the University of Cen-tral Florida in 2001, 2002, and 2009, respectively. He joinedthe Institute of Information Science, Academia Sinica in 2009.He has published widely, including several papers recognizedas best/top papers at various international conferences. Hisresearch interests include social networks and computing,mobile, and wireless networks (WLAN/WSN/MANET/VNET), net-work protocols, mobile applications (iPhone/Android/platform),location-aware service, and network measurements.

YAO CHUAN WU ([email protected]) received his B.S.degree in computer science from National Chengchi Uni-versity, Taiwan, in 2006 and M.S. degrees in computer sci-ence and information engineering from National TaiwanUniversity, Taiwan, in 2009. He joined the Research Centerfor Information Technology Innovation, Academia Sinica in2009. His research interests include social networks andcomputing, location-aware services, recommendation sys-tems, mobile applications (iPhone/Android/platform), infor-mation retrieval, web mining, and cloud computing.

MENG CHANG CHEN ([email protected]) received hisPh.D. degree in computer science from the University ofCalifornia, Los Angeles, in 1989. He was with AT&T BellLabs from 1989 to 1992. He is a research fellow of theInstitute of Information Science, Academia Sinica, Taiwan-His current research interests include wireless access net-works, QoS networking, information retrieval, and dataand knowledge engineering.

Figure 6. VProb and its Facebook app.

HO1 LAYOUT 11/18/10 10:55 AM Page 51