<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	
	xmlns:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	>

<channel>
	<title>computers &#8211; kingofnovember.com</title>
	<atom:link href="https://kingofnovember.com/tag/computers/feed/" rel="self" type="application/rss+xml" />
	<link>https://kingofnovember.com</link>
	<description>I&#039;ve had some whiskey, and I&#039;ve been thinkin&#039;.</description>
	<lastBuildDate>Wed, 22 Apr 2015 00:31:21 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.3</generator>

<image>
	<url>https://kingofnovember.com/wp-content/uploads/2018/06/cropped-jormungandr-shape-1-32x32.png</url>
	<title>computers &#8211; kingofnovember.com</title>
	<link>https://kingofnovember.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">12939687</site>	<item>
		<title>Seraphim and Artificial Intelligence in Music</title>
		<link>https://kingofnovember.com/2009/09/seraphim-and-artificial-intelligence-in-music/</link>
					<comments>https://kingofnovember.com/2009/09/seraphim-and-artificial-intelligence-in-music/#comments</comments>
		
		<dc:creator><![CDATA[jorm]]></dc:creator>
		<pubDate>Sun, 06 Sep 2009 07:33:00 +0000</pubDate>
				<category><![CDATA[Creative]]></category>
		<category><![CDATA[Media]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[computers]]></category>
		<guid isPermaLink="false">https://kingofnovember.com/?p=593</guid>

					<description><![CDATA[Wherein I wax nostalgic about an artificially intelligent disk jockey I once wrote.]]></description>
										<content:encoded><![CDATA[<p>Many, many moons (circa 2001) ago I wrote a program called <i>Seraphim</i>.  Seraphim was, for lack of better terms, a &#8220;user-programmable internet radio station.&#8221;  It was a bit more than that &#8211; quite a bit more actually.</p>
<p>The problem I was trying to solve was this:  I had about 2,000 albums worth of music, and I wanted something that would stream music to my internal stereo.  I wanted it to be able to perform the following functions:</p>
<p>1) Allow me (or others) to add single songs or whole albums to the music queue;<br />
2) Track which songs, albums, or artists were the most popular;<br />
3) Have a &#8220;smart&#8221; Artificial Intelligence disk jockey that could spin music on its own.</p>
<p>The program I wrote succeeded in this regard in all aspects.  Sure, sure, the code itself was ugly as shit (and written in Perl).  Were I to re-write it today, I would do a ton of things differently.  But I had about 8 years less experience writing stuff, so I forgive myself.</p>
<p>At any rate, Seraphim itself became an example of <i>emergent behavior</i> on several levels.  Not just in the AI of the DJ, but also in the way that people <i>used the system</i>.</p>
<p>This was in the early days of internet music.  Before the dark times.  Before the MPAA.  I made this radio station and a way to interact with it, and then we plugged it into AOL&#8217;s network (I won&#8217;t discuss how that happened because there may be legal ramifications for the people involved).  Suffice to say, suddenly a computer in my house was streaming music to hundreds (possibly thousands) of people.</p>
<p>If you had an account on the system, you could do any of the following:</p>
<p>1) Upload your own library of mp3s so that they were available for play<br />
2) Modify the metadata for any song, artist, or album (genres, etc.)<br />
3) Add songs to the system&#8217;s &#8220;queue&#8221; &#8211; the music it was playing.</p>
<p>(If you were a super-user, you could kill songs from the queue or mark them as &#8220;never play&#8221;).</p>
<p>People would listen to the station rather than their own personal libraries because there was a significant degree of fun involved in being a disk jockey.  Perhaps my most favorite emergent <i>user</i> behavior was when someone would start a musical &#8220;theme&#8221; and the various DJs would try to one-up each other following said theme.</p>
<p>For example, someone might say &#8220;the theme is <i>fire</i>&#8220;.  Then, we&#8217;d see a bunch of &#8220;fire&#8221; related songs show up (&#8220;Burning Down the House&#8221;, etc.).  There was a game made of the music.  It was a glorious amount of fun.</p>
<p>Each song, artist, and album had a &#8220;karma&#8221; score.  The more often it was requested, the higher the karma.  Picking a single song gave a +1 to each song, artist, and album.  That way the system understood popularity (though the scales were different for each [song, artist, album]).</p>
<p>However, the most interesting part of the system (to me) was that if no one put anything into the queue, Seraphim would &#8220;auto dj&#8221;.  And, having lived with it for a year or so, it became . . . <i>exceptionally creepy</i> in how smart of a disk jockey it became.</p>
<p>I wrote the artificial intelligence routines as a lark, to be honest.  But this is an example of awesome emergent behavior.  </p>
<p>The first thing I did in the system was to &#8220;fix&#8221; a weakness in the MP3 file format.  MP3s have a &#8220;genre&#8221; tag but that&#8217;s very limited.   It doesn&#8217;t say a lot; it&#8217;s a single dimension.  So I wrote a large matrix called &#8220;Genre Brethren&#8221;.  </p>
<p>For example, &#8220;Rap&#8221; is a genre brother to &#8220;Gangster Rap&#8221; and to &#8220;Hip-Hop.&#8221;  &#8220;Speed Metal&#8221; is brother to &#8220;Death Metal&#8221; and &#8220;Heavy Metal&#8221;.  (The system was far more complex, usually seeing 3-6 brethren).  Albums, artists, and songs could be tagged with multiple genres.   </p>
<p>When in &#8220;Auto DJ&#8221; mode, Seraphim would start with the most current song and then make choices.  Did it stay in the current genre? This was maybe 50/50. If it decided to <i>change</i> genres, it would only move to one of the brethren genres (thus, we don&#8217;t move from <i>Slayer</i> to <i>Michael Bolton</i>).  We keep a continuity of musical style.</p>
<p>Once it picked a genre, it had to choose a song.  But that&#8217;s a trick, right?  Obviously, we don&#8217;t want to pick songs that suck.  And that&#8217;s where I wrote this thing that worked and worked well.  To this day, though, I&#8217;m not sure how I arrived at the system.</p>
<p>Cheaply, you can just choose the song in the genre with the most karma.  That works <i>once</i>.  Ideally, though, you&#8217;ll spread out.  So I wrote this complicated system whereby it would pick songs.  If I recall correctly (and I could pull up the source to see, but fuck that), it went like this:</p>
<p>1) Choose between Song, Artist, or Album in genre.<br />
2) Within that subset, take the top 50 karma values as a grouping.<br />
3) Within that grouping, weigh each one.  Those within the top 5 get +5 within 6-10 get +4, within 11-20 get +3, within 21-30 get +2, everyone else +1.<br />
4) Select within that set based on weight.<br />
5) If &#8220;songs&#8221;, play that song.  Done.<br />
6) If &#8220;albums&#8221;, repeat step 3 based on songs in album. Pick song; play; done.<br />
7) If &#8220;artists&#8221;, repeat step 3 based on albums, then go to step 6.</p>
<p>I injected a degree of &#8220;fuzziness&#8221; into the AI routine, too.  Without the fuzziness, it might play the same shit over and over again (like, all of <i>Nevermind</i> on repeat).  While the <i>ideal</i> was the highest karma value in a given set, there was logic to ignore that aspect and just pull from lower in the stack (there was a routine to drop out of &#8220;standard top 50 of type&#8221; mode and pull from wherever, or to overweigh to the bottom of the stack).</p>
<p>As it played songs, it marked when things were last played.  Thus, no repeats within 6 hours or so.  It also did crazy-ass shit like &#8220;look for songs that have a positive karma value that haven&#8217;t been played in 5 days&#8221; and then give those songs extra weight.</p>
<p>What happened was this:  I ended up with a disturbing, creepily good disk jockey.  My ex-wife and I had multiple conversations about this.  We&#8217;d be listening to it all day and there would be strange stretches of excellent music choices.  So we&#8217;d go look and see who had been programming it, and it nearly always turned out to be the machine itself.</p>
<p>I write this only because I&#8217;m thinking about writing artificial intelligence routines and Seraphim was one of my first attempts at doing &#8220;smart&#8221; AI.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://kingofnovember.com/2009/09/seraphim-and-artificial-intelligence-in-music/feed/</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">593</post-id>	</item>
		<item>
		<title>On Wikis and Living Documents</title>
		<link>https://kingofnovember.com/2009/08/on-wikis-and-living-documents/</link>
					<comments>https://kingofnovember.com/2009/08/on-wikis-and-living-documents/#comments</comments>
		
		<dc:creator><![CDATA[jorm]]></dc:creator>
		<pubDate>Fri, 14 Aug 2009 19:21:00 +0000</pubDate>
				<category><![CDATA[Tech]]></category>
		<category><![CDATA[computers]]></category>
		<guid isPermaLink="false">https://kingofnovember.com/?p=586</guid>

					<description><![CDATA[Wherein I exhort you to stop using Word for technical documentation.]]></description>
										<content:encoded><![CDATA[<p>This morning a friend made a comment about how frustrated he was with the way his company handles design documents and changes.  He said he started the day being told &#8220;we forgot to include this feature. It&#8217;s on the 3rd page of the 4th brief.&#8221;   The frustration here is that there are at <i>least</i> four briefs, and it appears that they are continual amendments to a core document.</p>
<p>This is a totally unacceptable way to work.  The idea of a &#8220;living document&#8221; is an easy one to understand but I&#8217;ve never, ever seen anyone get them <i>right</i>.  When the process fails, it seems to die not with a bang but with a whimper as individuals slowly stop making edits to some insanely complicated Microsoft Word file and it withers on the vine.  Oh well, at least it wasn&#8217;t loud.</p>
<p>Only thing:  there <i>will</i> be a bang.  The bang will be the sound of engineering departments getting thrown under a bus because features get missed and clients get pissed.</p>
<p>So, why do we have living documents?  Because a bunch of people like using words like &#8220;agile development&#8221; or &#8220;aggressive schedule&#8221; or &#8220;plug-n-play featureset&#8221;.  So what you&#8217;re working on, as a team (or even as a single engineer) often changes not only from week to week but <i>day to day</i>.  That, combined with the fact that there are usually 3 or more people who will be authors of a document, shows a clear need.</p>
<p>But why do they fail?  What causes the wax to melt on the wings?</p>
<p>Well.  Lots of things, but they can be broken down into three broad categories: cultural, workflow, and technical.  We&#8217;ll bullet point, because that&#8217;s organization!</p>
<p><b>Choice of Document Format</b>.</p>
<p>This is a big one, because it can cause all sorts of problems.  The most popular choice for living documents is going to be Microsoft Word, hands down &#8211; though I&#8217;ve been places that use Excel for everything.  Plain text is also popular, as is HTML (I personally will use HTML because I can do formatting in it and I <i>loathe</i> Word).</p>
<p>The first problem we have here is a cultural one.</p>
<p>Program managers, project managers, and suits like Word.  They know it, they&#8217;re familiar with it.  The machines they work with are likely to be laptops running a kind of Windows (they spend a lot of time in meetings and have to be mobile).  Since they use Word constantly for other purposes, it&#8217;s a natural choice for them.</p>
<p>Engineers, however, don&#8217;t think that way.  I know a lot of engineers, and only a scant handful know how to use Word and are frankly baffled by it&#8217;s startlingly bad usability and overwhelming featureset.  When I first started playing with Word for a game I wrote, I made a total mess of the file trying to use formatting rules and display modes and so on and so forth.  I&#8217;m not a stupid guy, but the word processing program got in the way of me processing words.  Word documents are <i>binary</i> files.  They can&#8217;t be grepped or diffed.  They can&#8217;t be parsed in perl, they can&#8217;t be smartly integrated into version control.  </p>
<p>Further, many engineers will be working from machines that are <i>not</i> Windows.  They&#8217;ll have Linux boxes or (rarely now) Solaris.  And they don&#8217;t have Microsoft Word &#8211; only a shitty &#8220;Open Office&#8221; version (and if you&#8217;ve ever shared a Word doc between a Windows box and Open Office, you&#8217;ll know how badly it goofs up formatting).</p>
<p><i>Clearly</i> the choice of Word is a poor choice for engineers.</p>
<p>Excel spreadsheets have nearly the exact same problems as Word, so we&#8217;ll skip that (aside from sorting abilities, they don&#8217;t bring a lot to the table).</p>
<p>Plain text and HTML versions of documents bring a similar set of problems to the mix, only from the opposite side.  Engineers love plain text, but it suffers in that it is unable to support nifty things like auto-generated tables of context, text formatting, or, well, anything except words.  HTML solves a lot of these problems, but you fall into the trap where by non-engineers won&#8217;t touch it: it&#8217;s difficult to edit if you don&#8217;t know what you&#8217;re doing, too easy to screw up even if you do, and the document becomes unweildy after a certain size.</p>
<p>There is a sort of half-way solution here, though, and that is to use Google Docs.  But I&#8217;ll get to that in more detail in a bit.</p>
<p><b>Version Control</b></p>
<p>Issues with document version control are the second biggest.  This is also a workflow problem.  Here is a common scenario:</p>
<p>The PM writes a Word document, <i>Tech Spec v. 1.0.doc</i>.  Sends it out for review.  The archictect makes some changes and mails out <i>Tech Spec v. 1.1.doc</i>.  At the same time, the interaction designer makes some changes and sends out a document also titled <i>Tech Spec v. 1.1.doc</i>, which, of course, does not have the architect&#8217;s changes in it.  Bam! Version drift.  </p>
<p>So the solution then is that the PM will painstakingly try to figure out what the changes are (he can&#8217;t run &#8216;diff&#8217; on the files, mind you).  Then he sends out <i>Tech Spec v. 1.1-real.doc</i>.  Over the next week, we&#8217;ll get 12 versions of the document, an <i>none of them will say what has been changed</i>.</p>
<p>Since reading a 20 page technical specification 4 times a day is a waste of my time, I&#8217;ll go on the most recent one I have open, while the latest one may have changed requirements on work I have <i>already completed</i> and thus don&#8217;t re-read.</p>
<p>Part of this is workflow.  It can be offset by having a single point of contact for the document author (which slows things down), and a summary page of &#8220;version changes&#8221;.  But that&#8217;s not a great solution.</p>
<p>Further, we&#8217;re passing information around via EMAIL.  Ugh.  This is the fastest way to get me to ignore a document: I get hundreds and hundreds of mails a day and everything gets lost in a morass of garbage.</p>
<p>Solution!  Post the documents to Sharepoint or something similar.  Okay, great!  But, you know, again, if I&#8217;m going to get notifications that it has changed, I&#8217;m still getting spammed with mail that I will ignore.  It&#8217;s nice that there&#8217;s a single central place for the most recent document, but we&#8217;re also dealing with Sharepoint or some similar product, and they all suck, by and large.</p>
<p>Okay, so let&#8217;s check it into a revision control system (CVS, Perforce, whatever).  Now everyone has to know how to use an RCS (hah!).  Plus, documents should then be in text formats for best results (so that versions can be merged and we can have multiple concurrent editors).  We&#8217;re back to cultural problems here.</p>
<p><b>My Solution</b></p>
<p>Wikis.  Plain and simple.  Wiki software (like MediaWiki, which Wikipedia runs on) brings the following to the table <i>out of the box</i>:</p>
<p>* Free<br />
* 2 Hour set up time (less if you know what you&#8217;re doing)<br />
* Easy to use/learn text formatting system that supports all manner of object embedding (diagrams, pictures, etc.)<br />
* Multiple, concurrent authors can work on the same document &#8211; or even <i>shards</i> of a document &#8211; at the same time.<br />
* Provides instant access to what exactly changed in the document (this is my favorite thing, ever).<br />
* Revision control<br />
* Access control (read/edit)<br />
* Document Search and Indexing<br />
* Auto-generated goodies (Tables of Contents, Categories, etc.)<br />
* End-User machine agnostic (runs in a browser)</p>
<p>Now, Google docs brings a lot of that to the table but it has what I consider to be two glaring flaws:  </p>
<p>* It is externally hosted.  Good luck convincing the security officers of a large company to host your top-secret project design with a third party.  You can&#8217;t lock it down behind the firewall, safe as houses in your intranet.<br />
* It requires that you make a Google account.  Again, this is a security thing but it&#8217;s also a pain in the ass thing.  I like to keep my work and personal stuff separate.  I have a Google account but I don&#8217;t use it (and don&#8217;t really want to). A company I used to work for did all their stuff on Google docs.  It was a pain in the ass for me to have to constantly remember this weird password that I put in there just to update my estimated hours on a stinkin&#8217; spreadsheet.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://kingofnovember.com/2009/08/on-wikis-and-living-documents/feed/</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">586</post-id>	</item>
	</channel>
</rss>
