User:Aashish.mittal/GSoC Application

Identity
Name: Aashish Mittal Email: ashishmittal [DOT] mail [AT] gmail.com Project title: Put a whole Wikisource/Wikibook "book" on your watchlist

Contact/working info
Timezone: GMT +5.5 (India) Typical working hours: 10am - 10pm (flexible work time) IRC or IM networks/handle(s): aashishmittal

Project summary
The basic gist of this project - Create a way to have “books” for wikisource/wikibooks is that users of Wikimedia projects (Wikibooks, Wikisource, etc.) should be provided with a way to organize and use multiple pages which are related together, as Books and give them the facilities to operate all these pages as a single unit. There are extensions (ex. BookManager, Collection, etc) which attempt to achieve some of these functionalities and the aim of this project is to improve/extend these extensions to add a more capabilities to them. This feature has been a wish of Wikimedia community since a long time and after discussing and interacting with developers interested in this idea, we have been able to get a good understanding of what has been achieved till now and what needs to be implemented this summer.

The corresponding ticket maintained for this project is Bug-15071 and the various features of this project are marked individually under the tickets mentioned here. This project aims to successfully implement all the mentioned features listed. I have created a space for discussing the project goals and implementation details: Books.

In the past few weeks, I have interacted with the project mentor (Mr. Raylton) regarding this project and have taken his advice and help for getting a clear picture on how to implement this as a complete project. Under his guidance, we have assembled a list of features that we plan to implement as a part of this project which are listed under ‘deliverables’. Given an opportunity to implement this project, I am sure it would be a great addition to the existing extensions and would prove useful to lot of Wikimedians and book lovers.

Deliverables
After receiving feedbacks and discussing with the developers, I have thought upon an initial list of deliverables to be implemented in this extension. The deliverables are classified as Editing related and Reading related. The project mainly focuses on completing the editing functionalities for the books and eventually provide a good reading experience by completing the reading related deliverables.

The deliverables are as follows:

Required deliverables

 * Create a book
 * Create chapters
 * Arrange order of pages in a book
 * Table of contents for a book
 * Recent changes for each book
 * Protect/watchlist/move/delete all pages of a book
 * Read a book (creation of a Navbar)

If time permits

 * Export book metadata (export the book details containing all page links to a file which can be saved by user, similar to MetaBooks)
 * Export entire book to HTML/Pdf/etc
 * Search in a book
 * Automatic Bookshelves, where the books of a wiki could be organized according to their metadata.

Of the deliverable, some of them are explained in brief below:


 * 1) Create a book: This refers to creating a book with certain number of book pages. This can be implemented by using a suffix/prefix (ex. ‘Book/’) as implemented in BookManager.
 * 2) Read a book (include a Navbar): As described by Mr. Raylton, we need to maintain a linear order of page accesses in comparison to Random accesses (such as in Wikipedia) to allow reading of books by the users. This would also include creation of a navigation bar (similar to what is present in BookManager) to provide user with links to next/previous pages in the book, list of chapters of the book and the metadata of the book. This would enable the user to navigate and read the books created efficiently.
 * 3) Recent changes for each book: Maintain a list of recent changes to a book made by its authors to allow readers and authors of that book be updated with any new additions/changes.
 * 4) Arrange order of pages in a book: Provide the book user with some kind of an interface (Special page) which he can use to arrange the order of chapters in a book. For this we need to maintain an entry of order in the database (possibly Categorylinks table) and update the order on change (ex. Using jQuery sortable).
 * 5) Protect/watchlist/move/delete all pages of a book: A functionality to provide an option to perform an operation on all/selected pages of the book at once. The action can be to protect/watch/move/delete etc. The user can be provided with a special page to select specific pages of the book (similar to Gmail) and perform an action on them. This can be implemented by getting names of all the pages present in a book and repeatedly performing action on each of them.
 * 6) Export entire book to HTML/PDF: Provide ability to export the book to pdf/html format as implemented in Collections and BookManager extensions.
 * 7) Search in a Book: Search for a particular content/page in a book and return all matching elements.

For the implementation of the above mentioned points in the extension, I will be maintaining a design draft (similar to this).

Project schedule
I have been in regular discussions with Mr. Raylton, the proposed mentor for this project. Based on his guidance, I came up with an analysis and a flow of the project which is described below. I have given an approach towards the project in a time-line basis.

What we currently have: The BookManager/Collections extension with basic functionalities of Book reading incorporated.

What we aim to acheive by the end of GSoC term: An extension to the current extensions to enable the user to create books containing various (not necessarily existing) wiki pages, perform operations on all pages of the book in a single click and include more features for efficient Book reading.

The proposed project flow is as follows:

Step 1 (23rd April – 20th May): Study of existing extensions in depth and understanding the enhancements that are needed to be made on top of existing base. This would include planning the various aspects of project and creating blueprint, wireframes, mockups and technical notes.

21st May: Official date of commencement.

Step 2 (1st week): Start with implementation of mentioned deliverables. I plan to start with implementing the basic function in this extension, i.e. to create a book (using suffix/prefix for a book representation)

Step 3 (2nd week): Next would be creating necessary database structures and PHP variables to support addition and storage of pages in a particular book. Once the pages are added to a book, the details would be maintained in the database number of chapters/pages, index page of the book, next/previous page of the current page, chapter name, etc.

Step 4 (3rd - 4th week): Adding support for creating chapters without content (similar to existing one in MediaWiki where the links are shown in red color). Allowing the chapters to be edited and creating new ones without leaving the page. Also maintaining a list of recent changes to the chapters by the authors.

Step 5 (5th – 7th week): Start working on the custom ordering of pages/chapters inside a particular book. This would include creation of special pages which would display the user a list of available chapters. The user can create a sortable order using jQuery. A separate field would be needed to be maintained in the database (maybe categorylinks table) which would be manipulated by this jQuery sortable and would store the order of chapters.

Step 6 (8th – 9th week): Adding functionality to allow users with the appropriate rights to perform operations on multiple pages of the book together (such as watch/delete/move all). This can be done by getting the list of all chapters of the book from the database and then creating a PHP script to perform the action for all pages.

Step 7 (10th – 11th week): Creation of Navigation bar and other basic reading functionality. This would include studying the existing Navigation bar implementation (such as one in BookManager) and working to extend it.

Step 8 (12th – 13th week): Documenting and testing all implemented work and code.

Step 9: If time permits, I will also try completing the other deliverables related to reading of books such as export of books to other formats, search in a book, etc.

August 20: Pencils down.

''Kindly note, the above flow has been built on my understanding and preliminary discussions with the mentor. It is flexible and any necessary changes can be included and acted upon. I will be taking suggestions from my mentor and the community and any new feature requested would be adjusted in the project timeline.''

Anticipated Challenges:

Non-Technical:
 * The system should be built such that it is accepted and liked by all Wikimedia developers.
 * The final extension should be complete to the level it can be released and ready for use.

Technical:
 * Covering all the required features in the extension and adhering to Mediawiki standards.
 * Try to include the reading features in the extension to give a full-fledged experience to book readers such as provided by Google Books, iBooks, etc.

About me
I am Aashish Mittal and am a student of Computer Science pursuing final year of Bachelor of Engineering from University of Mumbai, India. I have been a reader of Wikipedia (one of Wikimedia projects) since ever and have always wished to contribute back. I love working with web technologies and hacking into long lines of code. While exploring projects for development, I came across many great implementation ideas provided by MediaWiki, and this particularly fascinates me because this extension focuses mainly on providing the users of Wikimedia projects an essential functionality of reading collections of pages (books) efficiently and provides them with a great usage experience.

In case I am selected in Google Summer of Code and MediaWiki gives me a chance to continue my contributions and development, I would love to keep contributing to MediaWiki even after the SoC term-end.

I will be comfortable with all means of contact:


 * Email (ashishmittal.mail@gmail.com)
 * IRC (nick: aashishmittal)
 * Skype (id: ashishmittal91)
 * Phone (+91-9930820950).

My preferred means of contact is via email and IRC.

Participation
I have started working with MediaWiki development by getting familiar with the coding practices and filing patches for some introductory tickets. I am confident of giving my best and of creating all features as per the existing scope of the project.

I will be in constant touch with my mentor and other developers on mailing list informing them of my progress and ask for help when I find it essential. I will be taking suggestions from them at all stages on how to improve the implementation and how to make the most out of this project. The necessary learning part will be done well before the project coding starts along with chunks of implementation. Coding phase will be used for rest of coding implementation and solving of bugs along with the necessary documentation.

Past open source experience
I have solved some introductory bugs such as 33997, 29135 and 33545.

I have been participating in Google Summer of Code since the past two years.

In Google Summer of Code 2011, I worked with Code for America which is affiliated with the Government of United States to create a system for use by various cities like Philadelphia, Seattle, etc. The project targeted mainly on those cities which could not produce the revenue to set up expensive call centers and CRMs. Under the guidance of their developers, I created a software product which would cut down the cost of physical resources and would provide the interface to manage and use the city data and perform major functions of a call center. In the process, I was connected with some of the lead developers of US (including Tim O’Rielly) and gained an insight into the operations and obtained immense deal of knowledge. I received great feedback from them and my work was commended by the CEO of OpenDynamics. More can viewed about the project at http://codeforamerica.org/2011/09/09/ashishs-cfa-summer-starting-the-open311-center.

In Google Summer of Code 2010, I worked with Sakai Foundation. I was working with the CTO of University of Cambridge to develop a system which focused to solve the user-event management problem in their software. The software is deployed in major universities such as NYU, Cambridge, Georgia Tech, etc. It faced a major problem of storage and management of these events due to extensive amount of user-events generated in the software by users (students and staff) of entire university. My role was to solve the problem by designing scalable and reliable management system using cutting edge software such as Apache Cassandra and Hadoop (which are used in high scale applications life facebook and google) for their software. It was a major milestone in my achievements since it gave me immense practical knowledge of solving real time problems and creating highly scalable systems. More can be viewed at https://confluence.sakaiproject.org/display/KERNDOC/KERN-717+Event+Explorer.

Any other info
I am maintaining Books for defining all the details relevant to this project and for receiving any feebacks and suggestions pertaining to this project.