Sunday, November 17, 2013

History of Computer Science: Artificial Intelligence

“Artificial Intelligence research is an attempt to discover and describe aspects of human intelligence that can be simulated by machines.”
Philip C. Jackson, Introduction to Artificial Intelligence

Artificial Intelligence is a popular industry within technology today, but its history has been a rocky one filled with many transformations and long lulls between rapid booms. The definition itself has even evolved over the years in response to various innovations and setbacks. While the goal of AI has remained fairly constant, our understanding of that goal and innovations towards it have set milestones in its history. Two main types of AI have emerged over the years based on both limitations and advances: strong and weak AI.

Originally, artificial intelligence was the purely theoretical concept of machines that can mimic human learning and thoughts. This is now considered strong AI and while it ultimately remains the goal of the discipline, there is still a long way to go before it can be achieved. In the 1940s, early research involving modeling neural networks structured like mammalian brains helped introduce the discipline and shape further research pursuits. It was the Turing Test in the 1950s, however, that truly marked the popularity and rise in research into strong AI. Alan Turing devised a test that has become the standard for what would be considered (strong) artificial intelligence. A person at a computer terminal, called the interrogator, would be able to chat to two different agents, one human and one the proposed AI system. If the interrogator could not distinguish which agent is human with any significant probability the proposed system would be considered to exhibit artificial intelligence. This is more or less still considered an applicable test for strong AI and other tests have even been derived for it as our understanding of AI and the definition of it has evolved.

Over the next couple of decades some advancements were made in the field, particularly with problem solving applications and testing environments. Computer vision, robotics, and natural language processing in particular had advances in testing environments. By the 1970s, however, the rate of advancement in artificial intelligence simply wasn't keeping up with the demanding expectations held for it at the time. Despite the advances that were made, the practical applications were very rare and interest started to decline.

This lull lasted about a decade, but research continued and by the 1980s the sales in latest hardware and software for AI started to rise as the much needed practical applications for it started to rise. These applications led to the concept of weak AI where systems that were not intelligent in the strong AI sense but involving techniques considered vital to such a system and exhibiting intelligent qualities were used by themselves to solve a variety of interesting problems. Speech recognition and learning systems were two of the first areas that started to see an increase in such practical applications, followed by automatic programming systems that could write themselves based on desired behavior and many of the statistical and graph-based approaches that are widely popular today.

Through the 1990s and into the millennium many new applications and areas emerged, including machine learning, planning systems, and search systems. The use of weak AI techniques and systems has continued to increase to this day and now is very widespread with some major companies such as Google, IBM, and Microsoft leading the way in new research and applications. With this continuing trend, the possibility of strong AI once again emerges as a goal within the field. The hopes and expectations have even risen, such as the concept of The Singularity—a concept attributed to Vernor Vinge in which the intelligence of computers not only meets but exceeds that of humans. It is difficult to say if or when a truly intelligent system will be created, especially as the understanding of what properties such a system would be expected to contain evolves along with the techniques that might lead to such a system, but the field of artificial intelligence is certainly in interesting one that is not likely due for another decline in the foreseeable future.

“AI has the potential to change our world like no other technology.”
M. Tim Jones, AI Application Programming

File Sharing: Changing How Business is Done

What if I told you that you could get all the music, movies, books, and software you want for free? Well, the good news is that nowadays you can quite easily. The bad news is that it's illegal. File sharing is nothing new as far as the Internet is concerned, but over the years the attempts to mitigate it has paled in comparison to its proliferation. Although the term file sharing more generally refers to any context it implies, its usage today almost always refers to pirated content, or at the very least the services that primarily serve such content.

In the early days of content piracy file sharing websites would host files for download. Music was by far the most common type of content pirated then, taking off with the introduction of Napster. Software piracy was also quite widespread through various warez sites, but was not as widespread as music. The problem with file sharing sites, however, was that the content was all centralized in one or a few locations so taking down the sites could easily mitigate the piracy taking place. This ultimately led to the demise of Napster, but not before a new and significantly more resilient framework had already taken hold. Why host the files and tax your bandwidth when you could just as easily pass this on to the users? With this realization, peer-to-peer file sharing was born.

Unlike hosted content, peer-to-peer file sharing serves the content to those who want it from those who already have it. The users simply downloaded a client that handled this all for them and were free to download anything that was available from the other users. Early on clients like Kazaa and Limewire were quite popular, but ultimately faded as newer clients were developed. The critical turning point in this was Torrents, though. While the earlier clients relied on their own servers to coordinate the sharing and search functionality—once again a point of weakness in the system—torrents were a more general framework involving files that contained metadata about the files to download and the servers that were hosting them. This spread the server load across multiple networks and countries making taking them down more difficult as this would have to be done for each network individually. The torrent files themselves were available from multiple sites, gaining the same benefit. Some sites required signing up and often imposed restrictions for doing so to prevent those looking to take down the networks from being to do so as easily. Even multiple clients using the same framework became available eventually. This level of dispersal made taking down the framework next to impossible by those seeking to protect their content that was being pirated.

The various industries affected by file sharing continue to evolve as a result. Some of the most popular sites for downloading torrents such as The Pirate Bay have been constantly targeted with little to no effect as far as the users are concerned. Many industries have looked into or implemented increased security measures to try to combat piracy. Software has implemented activation requirements that track the number of copies a particular serial number has being used at a particular time, but this has done little to help since those pirating software tend to be more computer savvy and thus cracks that patch the software in such a way as to remove this security functionality are quite common. Electronic books attempted to add encryption to control the number of copies and redistribution. This also has been mostly in vain as all encryption schemes to date have been broken and the cost of developing them far outweighs the cost of publishing the book in the first place.

The music industry has by far been affected most by piracy and has gone through the most change as a result. This has a lot to do with it being the most popular type of content to pirate, but also through many unrelated changes and flaws in the business model itself. Music piracy is nothing new, dating back to the days of people copying cassette tapes. The industry itself has for a long time seemed inherently flawed, however, which in part aided the piracy movement. With the introduction of CDs, the music industry underwent a major shift in its pricing practices. Costing next to nothing to make, the industry marked up the price to exorbitant amounts expecting that people would just pay for the higher quality, and for a time they did.

The evolution of the Internet and introduction of file sharing worked to shatter this model, however. After years of price-gouging a large number of people felt little remorse pirating music and the knowledge of just how little of the music prices actually went to the artists—the people they actually did care about—did little to counteract this trend. One could easily support the artist by going to shows and buying merchandise without lining the pockets of the record industry. All the while this trend escalated the price of producing music dropped significantly through advances in technology, making the overpricing practices even more of an insult to music listeners.

These factors played a key role in shaping the music industry and its business model. Realizing that people would no longer pay for overpriced CDs and that the popularity of mp3s was starting to exceed that of physical media the music industry started selling digital copies of music at more reasonable prices and even on a song-per-song basis. How many CDs have you bought where you only liked one or two of the songs anyway? The drop in the price of recording has also been a hit to the record labels while at the same time benefiting music as a whole significantly. Small bands could now record their own studio-quality albums on their own instead of relying on labels. They could even distribute albums themselves through the same digital media outlets as the labels, such as iTunes and Amazon, or even press their own CDs since this cost has always been very low anyway.

The industries affected by piracy have had to adapt to survive, but it could easily be argued that any setbacks arose from flaws in the traditional business models to begin with or the inability to adapt quick enough and in a reasonable manner to a fast-changing world. The distribution of legal content has likewise been affected, in this case very positively as file sharing frameworks such as torrents provide a great framework for the mass distribution of content regardless of the legality of it. Open source software and content can easily be distributed through peer-to-peer file sharing without burdening the already struggling producers of it with the costs of hosting the content themselves. Regardless of one's standpoint on piracy, file sharing has certainly had a huge impact on many industries and how content is acquired. There is no question that it is here to stay and that embracing and adapting to it it is by far the best way to react to this change.

Friday, November 15, 2013

Data Structures: Making Computing Possible

Data is at the heart of modern computing. The majority of what a computer scientist will learn, use, and possibly even research comes down to two things: processing data and storing data. The former is achieved through algorithms and the latter through data structures. Algorithms define the means to achieve particular tasks, generally involving the processing of data, and are quite varied in what they do based on any number of possible problems that need to be solved. Data structures on the other hand, while still just as varied as algorithms, are singular in purpose. All data structures have the common goal of storing and allowing for the access of data, but their variety comes from the types of data and the pursuit of the most efficient ways of storing and accessing that data based on its type and the design of the system.

While there are countless algorithms out there, and in fact any explicit process for achieving a particular task is considered an algorithm, there are only a handful of data structures out there and the discovery of revolutionary new data structures is no small feat or event. They generally have trade-offs in efficiency based on their particular use as well, making knowing them even more important for programmers. The three main types of data structures come in the form of linear data structures, trees, and maps.

Linear data structures are, like the name implies, a stringing together of points along a line. Any piece of data has at most two neighbors to it, one before and one after. The most common types of linear structures are arrays and linked lists, although in concept both are structured the same and the efficiency of various actions is the key difference. Arrays, for example, allow for a particular data value to be looked up very efficiently while linked lists allow for a new value to be placed between two existing values very efficiently. In this case the opposite suffers in performance on the other's task. Linear structures can be nested to create multidimensional structures as well such as matrices, but ultimately the linear structure remains intact for each component.

Trees get their name from the branching out from a common point that they exhibit, much like tree branches. They generally involve some method for subdividing each branch to allow for much more efficient search operations. This, however, requires that the data be related in such a way that predictable comparisons be able to be made to determine which branch to take. If this sort of comparison can't be made and result in the same choice every time the structure will not work. Trees generally have the advantage of being efficient in both insertion and retrieval, which if you recall was a one-or-the-other choice with linear structures. While neither operation is as fast as the superior linear counterpart, the efficiency gain for both far exceeds the trade-offs of the linear structures.

Maps tend to stand alone as data structures in that they fit a particular format of data that trees and linear structures can't handle. They are used when a particular data point is mapped to by a particular associated value or values, commonly referred to as keys. A key is a unique, small value that has data, generally much larger in size, associated to it in such a way that when a particular key is searched for the associated data value is returned. For example, one could use people's names (provided they are unique) as a key to retrieve more extensive data on the person. Maps can be stored in trees where the ordering is determined by the key or can be stored as hashes, most easily thought of as a sparsely-populated array containing the keys so that a particular key can be looked up and its associated data returned more efficiently than the tree counterpart.

The specifics of data structures can be quite complex and provided is only a high level overview of some of the most common types and features, but nonetheless they are a very aspect of computer science and worth learning about for anyone interested in programming. Many books and websites exist on data structures as well as algorithms for more information on the topic and greater detail.

Hacking v2.0

The concept of hackers and hacking has been around for much of the time the Internet has, and much like the Internet itself these terms have evolved over time. Originally hacking referred to gaining unauthorized access to computers and systems, which is a definition that's still relevant today. The drive and spirit behind hacking has broadened the definition as new technologies have emerged and evolved, expanding it to encapsulate the driving force rather than the act itself.

Hacking, especially in its early days, was motivated by one simple driving force: curiosity. The original hackers weren't out to cause trouble or make a profit, but rather to explore systems fully and push the limits of computing itself. Hacking into computer systems was about exploring them and the techniques that provided unauthorized access to them. It is this motivation that is behind the broader definition of hacking today and its widespread usage outside of what was traditionally considered “hacking.”

The expansion of the term has led to not only more widespread usage, but new trends and terminology as well. Long programming competitions—usually 24 or more hours—are gaining popularity and referred to as “hackathons.” These aptly named competitions embody the spirit of exploration and problem solving by encouraging contestants to modify, or “hack,” existing APIs and frameworks to create new products and/or solve challenges. Likewise, modifying hardware to expand or modify the capabilities is also called hacking. You can even “hack” how you live with sites like Lifehacker and Hack-a-Day that encourage innovative solutions to everyday problems both in and out of the technology realm.

The newer usages and terms surrounding hacking are not all that has become widespread, however. The more traditional concept of hacking has also risen in popularity. As any student of strategy can tell you, the best way to combat an enemy is to learn to think like them to adapt to their attacks. It is in this that the traditional sense of hacking has taken off. The security world has become a huge industry that not only employs but also trains hackers to explore and find solutions to the multitude of threats that exist.

Computer and network security experts known as “white hats” learn the very hacking skills they must defend against in a controlled and legal manner via test systems and ultimately by being contracted for penetration testing (the authorized hacking of a system or systems). There is a multitude of courses, certifications, and even competitions that help security professionals learn and hone their skills.

The other side has likewise become a widespread and lucrative business, however. Hackers referred to as “black hats” illegally attack systems—often the very ones that the white hats are trying to defend. Credit card and banking information as well as scams are common revenue streams for black hats, and are lucrative ones at that. One such group was able to make over a billion dollars from selling stolen credit card numbers. As the battle rages on one thing is certain—hacking in every sense of the term is here to stay and will only become more prevalent as more and more of our lives moves to the digital realm.