Friday, June 14, 2013

14th June

As expected, today was indeed my weekly evaluation. I showed them the improved version of the page and made Prateek sir log in via his LinkedIn account and add his skills to the database. It worked. He liked it, at least the functioning of it (There's a long way till it comes out looking like something he'd love and endorse).
Nevertheless it was nice to see a smile on his face. Once again, signs of progress are showing. According to them, I had little or no knowledge of coding when I first stepped into this office, which is not entirely true. But I'll go with it because I know much more of it now.


First page (Still in alpha stage)

Skills being displayed for the user

Now that I'm not the only intern working on this project (Enter Manbir Cheema- MCA , Thapar University), all the code related to it has to be synchronized  between both our systems. Kind of like, we will be simultaneously reading and writing the files.
Also, a staging server needs to be set up for testing and revising the web pages before they can go live.
Also, I need to bring Manbir up to date with all the work I've done so far, and make sure all the necessary software to run my webpages has been installed in his system as well.

All this might sound boring from a third person's perspective, but you can't argue that some of the posts are very well written, and subtly informative to some!

This concludes week 3. There's still a long way to go, however...


A moment to stop and think

One of my professors in college told me that doing an internship this summer won't do me any good. She would say, "Look at your paper, you've only lost marks in theory. During a job interview you'll be asked theory only. Nobody will see whether or not you can write code. Jabtak aapko peheli cheez nahi aati, doosri cheez kaise karogey? Aagey kaise badhogey?"
The truth is, I only lost marks because I didn't study at all. And there's no way I could read books full of concepts and theory all summer. I wasn't feeling too good about the prospect of Computer Science and Engineering either, I was scared that maybe I made a big mistake by opting for it. That is, until I got a slight glimpse of what all I can do with such knowledge, when two of my friends and I worked on a database project last semester. We made something like a search engine. It was refreshing, finally applying what you've learnt, rather than learn more and do nothing with it. That is exactly what I'm doing this summer- Applying my knowledge in the real world, and actually making my contribution count. And that's why I believe that I've learnt more in 3 weeks here than I've done mugging up definitions and writing useless SML and Prolog code snippets in during my 2 years in college...


Look at all those skills! Didn't get them from just reading books, I assure you.

Wednesday, June 12, 2013

13th June

As per the previous post, I had done till part 3) of the problem discussed.

However, I had started experiencing unexpected problems from part 1) itself.
The page wasn't functioning correctly. The user gets authenticated, his/her skills are extracted from LinkedIn and dispayed on the page with options to edit(check/uncheck so far. Planning to incorporate an 'Add More' button)  and submit them. But as soon as the page finishes loading, the CSS would disappear. I know for sure it has got something to do with the API's. I found a way around it. It turns out that the script overrides the CSS settings and displays basic HTML. So instead, I made the script write the CSS file call onto the body of the document, using document.write(). In hindi, such a fix is called  'जुगाड़'! 
Also, when I had made the dummy skills page earlier(you would know if you're following the blog correctly), I had already written the PHP code for storing the selected skills in the database. So I used the same code, barring a few modifications such as table definitions and variables, to store the data. I was modifying it run perfectly earlier in the day. I've defined the database tables now-
  • User, consisting of the user's id (auto-incremented), his first and last names, and his LinkedIn profile URL.
  • Skill, consisting of the skill's id (auto-incremented), and the skill name.
  • user_skills, consisting of the combination of user and skill id's which determines which skills are related to a particular user.
I ran the simulation on different systems, and it seemed to be running fine, but I won't guarantee the database's reliability yet.

My next step would be to make a separate page that lets users (who are NOT visiting the web page for the first time) view their stored skills and add/remove them as per their wish.

The web page requires lots of tuning on the display front. It shows how much I still have to master CSS.

Sushil sir introduced me to loads of new fonts made available through Google Fonts API
They don't work, however. Some settings need to be changed on the server, which I won't be doing any time soon.

Tomorrow is progress evaluation day, I think, like Friday. I hope I haven't made any huge error or mistake for which i might be scolded. No guitars for tomorrow, though, since I didn't receive any song suggestions from my fellow colleagues.
Nonetheless, I personally think I've made great progress under my mentors here at NCR. 

12th June

I was having some trouble coding the predictive skills page using peopleSearch(). Besides, I was reaching the throttle limit way too often.

Hence, I decided to start working on a user-authenticated skills page.
The idea is simple-

  1. The user opens the page.
  2. He/she authenticates by signing in with LinkedIn.
  3. The page makes a call to the IN.Profile() API that returns the data of the user (including skills).
  4. The dummy page is presented with the skills, along with an option to add more.
  5. The selected skills can now submitted to update the database.

I've done till part 3 as of 12:47 on my clock. I should be able to do the rest without any major difficulty, having already done something similar last week.

Week 3 - 11th June

I might have overdone the page testing with the API key. The page is refusing to make any more calls to the IN.peopleSearch() API now.
It happened yesterday as well, but got fixed on its own this morning. This led me to believe that there is some sort of daily limit on how often you can use LinkedIn's API features.
I researched a bit online, and found out, that there is a throttle limit on every API key, used to ensure the best experience for all users.

At least I'll be more cautious with the testing now onwards.
Well, owing to this limit, I've been able to get back up to date with regards to blogging!

Also, I found a way to increase the throttle limit. There are a total of 100000 calls allowed. And each unique user is allowed a small fraction of this everyday(Say 100). I'm using my mom's LinkedIn Id as well now for the testing, which has helped me double the limit of calls I can make on the APIs!

Week 3 - 10th June

The idea was to create a web application, that authenticates users automatically through NCR's own Common Authentication application. During authentication, the user's first name and last name would be extracted and used in calling the LinkedIN API peopleSearch(). The matched first and last name strings that work for NCR (assuming and hoping, that the combination of first and last name is unique for each employee) would be returned and processed as per need.

Road-block: A road-block was encountered in the form of realization that, 'skills' is a full profile field which, unlike basic profile fields, cannot be accessed by unauthenticated LinkedIn users. Moreover, there has to be an authenticated user for the API to even run. Technicality aside, we're unable to fetch and store the skills of  employees without them doing it themselves.

New Objective: Create a predictive dummy skills page, that displays a tentative list of skills for a particular employee, on the basis of his/her LinkedIn basic profile fields like headline, summary, specialties.



*Point to note: Keep front end and back end as detached as possible, so as to incorporate the possibility of interchangeable layout and design of the webpage.
*Programming languages familiarized with so far: HTML, CSS, JavaScript, jQuery, PHP, MySQL.

Tuesday, June 11, 2013

Week 2 - 7th June

Project Progress Presentation today.


  • Dummy page was shown and simulated in front of Prateek Sir. He didn't like the layout and design.
  • Started working on webpage with LinkedIn's REST APIs.