Category Archives: Projects

Phil 10.8.15

8:00 – 4:00 SR

  • Noticed yesterday that the time it takes for the map to center is just too long. When I tried increasing the speed I got a lot of jitter because I was testing for proximity to goal. I wound up changing so that the goal is reached when the distance to the goal is increasing.
  • Add editing of Rating and linkSelected
  • Make sure that items with only one link that are not ‘force visible’ are not shown in lists
  • Bold selected items in lists
  • Change the query list to be the ‘visible’ list
  • Trim the length of the list items so the containing box sizes don’t go crazy.
  • Look for floating panel CSS?

Phil 10.7.15

8:00 – 6:00 SR

  • Gina’s still having problems logging on
  • Write up the DB and programming test for Lenny, since the next interview(?) won’t have me along
  • Banged away at PageRank and finally have it working. The matricies were evaporating, so I wound up layering inbound and outbound links over an identity matrix. That worked great. I need to think about why though.
  • Meeting with Dr. Pan and Dr. Lutters at 4:00(?). Went well.
    • One thing that came up in the discussion was how to feed in enough information to make the analytics work. Dr. Pan suggested using Politifact, since it’s well formatted ground truth that references a source. In essence, I could build a small java program that could iterate over all the PF reports and build a network for each of the Entities (or concepts) referenced. Once nice side effect is that this could be a ‘seed set’ of vetted data that could be used to inform other searches.
    • The other item discussed is whether this is what kind of view this is. Dr. Lutters suggested that this might be the analyst’s (development) view, while a consumer’s view would be more like a traditional  news feed, like inkl.com

Phil 10.6.15

8:00 – 5:00 SR

  • The FA and RA apps are not working right with 2016 data. Pinged Dong.He says he can take a look tonight.
  • After installing Win10, I had a heart stopping moment where Apache wasn’t starting, with an error message of “Problem detected! Port 80 in use by “Unable to open process” with PID 4!” Stack Overflow suggested that this was the “World Wide Web Publishing Service” and you have to stop it. Here’s a screenshot: Services
  • Other than that, Win10 seems just fine. I love the menu bar for each monitor.
  • Figuring out how to add the network to the Ranking code…
    • Will need to sort the array based on the ranking. Doesn’t look like a problem.
    • Added weight to ITarget
    • Reworked Rating.ts so that everything is initialized to a square matrix of zeros. You now have to create the Rankings.PageRank class (appropriately sized), then populate it, then calculate and get results.
    • Construction of the matrix from the network is nearly done. Finish tomorrow.

Phil 9.30.15

8:00 – 4:00

Phil 9.10.15

8:00 – 2:30 SR

  • Taking tomorrow off
  • No progress on dev machine admin
  • Added page rank function to PhilsUtils
  • Discovered that I still needed to pull fresh meta
  • Make it so that a shift-click on a BaseComponent selects all the items that the item is directly connected to. Done.  Bonus points for each shift-click selects an additional hop. TODO
  • Got my first linkage!

DriverF1

  • Next is some automated culling, and then adding rating/pagerank. TODO

Phil 9.8.15

8:00 – 4:00 SR

  • Off yesterday for Labor Day.
  • More dev justification
  • Google Cloud platform java – https://cloud.google.com/appengine/docs/java/. The goal of this would be to calculate overall page ranks
  • Added Save for networks. In reality, this only Creates a network that is then ‘saved live’. TODO: Need to make that more clear
  • Work on correlation of concepts, keywords, etc. Start with ‘horse’ and ‘rider’?  TODO
  • Work on support/dispute 
  • PageRank in PHP 

Phil 9.1.15

8:00 – 5:00 SR

  • No news on my dev box admin.
  • Build the ‘openUrl’ query
    • Send the url to Alchemy for title, Author, text, and image. Take the responses and build the html description that the
      <item>
      
      <title>Obama to Call for More Icebreakers in Arctic as US Seeks Foothold - New York Times</title>
      
      <link>http://news.google.com/news/url?sa=t&fd=R&ct2=us&usg=AFQjCNEzISdc_7dbACNLX7SfwLZaa1UXBQ&clid=c3a7d30bb8a4878e06b80cf16b898331&cid=52778940195490&ei=hJjlVfCYMcvH3gGGs57IDw&url=http://www.nytimes.com/2015/09/02/us/politics/obama-to-call-for-more-icebreakers-in-arctic-as-us-seeks-foothold.html</link>
      
      <guid isPermaLink="false">tag:news.google.com,2005:cluster=52778940195490</guid>
      
      <category>Top Stories</category>
      
      <pubDate>Tue, 01 Sep 2015 11:15:00 GMT</pubDate>
      
      <description><table border="0" cellpadding="2" cellspacing="7" style="vertical-align:top;"><tr><td width="80" align="center" valign="top"><font style="font-size:85%;font-family:arial,sans-serif"><a href="http://news.google.com/news/url?sa=t&fd=R&ct2=us&usg=AFQjCNEzISdc_7dbACNLX7SfwLZaa1UXBQ&clid=c3a7d30bb8a4878e06b80cf16b898331&cid=52778940195490&ei=hJjlVfCYMcvH3gGGs57IDw&url=http://www.nytimes.com/2015/09/02/us/politics/obama-to-call-for-more-icebreakers-in-arctic-as-us-seeks-foothold.html"><img src="//t0.gstatic.com/images?q=tbn:ANd9GcTb8poiCV7-c6L52plHslVILC4Ti7eb_asJZjOiu7lRPrMAiViJFVC7YHxXBbLyaV2YQthpDI8" alt="" border="1" width="80" height="80"><br><font size="-2">New York Times</font></a></font></div></font></td></tr></table></description>
      
      </item>
    • Obviously, the description part is the trickiest, but it doesn’t have to be as rich in content
    • Tutorial on RSS
    • Encoding and decoding html using PHP
    • In looking at the above, I think the first thing to do is to build the template for displaying the output, then encode it and see if it can be displayed. Here’s an example of a GoogleNews item:
      <table border="0" cellpadding="2" cellspacing="7" style="vertical-align:top;">
      
      <tr>
      
      <td width="80" align="center" valign="top">
      
      <font style="font-size:85%;font-family:arial,sans-serif">
      
      <a href="http://news.google.com/news/url?sa=t&fd=R&ct2=us&usg=AFQjCNEzISdc_7dbACNLX7SfwLZaa1UXBQ&clid=c3a7d30bb8a4878e06b80cf16b898331&cid=52778940195490&ei=hJjlVfCYMcvH3gGGs57IDw&url=http://www.nytimes.com/2015/09/02/us/politics/obama-to-call-for-more-icebreakers-in-arctic-as-us-seeks-foothold.html">
      
      <img src="//t0.gstatic.com/images?q=tbn:ANd9GcTb8poiCV7-c6L52plHslVILC4Ti7eb_asJZjOiu7lRPrMAiViJFVC7YHxXBbLyaV2YQthpDI8" alt="" border="1" width="80" height="80">
      
      <br>
      
      <font size="-2">New York Times</font>
      
      </a>
      
      </font>
      
      </td></tr></table>
    • Ran into problems with Imagick that seem to be legendary. Rather than dealing with it on the dev box, and since it seems to be there on the main server, I’m using this hacky workaround and just ignoring it for now. What I want is thumbnails so that the asset folder doesn’t get crushed. But that’s not critical right now.
    • Finished building the itemHtml
      private function constructHtml(){
       $htmlStr = '<table border="0" cellpadding="2" cellspacing="7" style="vertical-align:top;" width="100%"><tr><td width="80" align="center" valign="top">';
       $htmlStr .= '<a href="'.$this->rssLink.'">';
       $htmlStr .= '<img src="assets/'.$this->rssImage.'"height="80"></a></td>';
       $htmlStr .= '<td width="80%" align="left" valign="top"><span style="font-size:85%;font-family:arial,sans-serif">';
       $htmlStr .= '<a href="'.$this->rssLink.'">'.$this->rssTitle.'</a>';
       $htmlStr .= '<p>'.$this->rssDescription.'</p>';
       $htmlStr .= '</span></td></tr></table>';
       $this->rssDescription = $htmlStr;
       }
    • Tomorrow we’ll wire it up so that http and https ‘queries’ get handled from the client

Phil 8.31.15

8:00 – 4:30 SR

  • Status report – Done
  • Timesheets! – Done
  • Get selected items showing up in the feed panel. Done! looks good. Commented out the default addition to the feed. It did make me realize that I need to add a ‘filter network’. Selections should highlight in the GUI and list in the feed.
    • By text search – searching title, description and query
    • By Date range
    • Other?
  • Got the selection working. Query-ish items go in the query box where they are combined into a single query, URL-ish items are listed in the feed section.
  • Get parsing of webpages working so so that they fit into the googleNewsFeed object. This should be just using the Alchemy object with some additional parsing.
  • Deployed to the server, and verified that the page works with Chrome, FF, Edge and IE11

Phil 8.28.15

8:00 – 5:00 SR

  • Commuting in the reverse order. Don’t forget to pick up energy drink mix too!
  • 3:00 meeting with Ronda to work on the servers
  • Adding isAssociation() and isItem() methods to the rssFeed directive. Done. Will probably add isRating() and isTouch() once they start getting used.
  • Deleting ComponentNetwork class from rssController – Done
  • Deleting pendingQueryArray and queryHistory from rSSController. The history can be pulled from the items in the DataProvider. Which works.
    • Add some test QUERY types to validate – Done – replaced the ENTITIES in tn_items. Worked with no other changes.
  • Setting items if their associated queries are clicked and setting the query if a query item in the chart is clicked. Done!
  • Deploying new version to the server.
  • And I am done for the day. Next week needs the following
    • Add items, which will (should?) return the whole data provider. Only differences (additions and deletions) should cause an effect.
    • Have selected items (only?) show up in the list.
    • Have the ‘query’ task change it’s behavior based on what’s sitting in the field. If it’s an url, open it in a new tab.If it’s text (can be multiple queries) combine all the text into a new query and run it.
    • Continue to flesh out the types.
    • Save, Save As, reload (clear and load) models. Verify! Test!

Phil 8.27.15

7:30 – 5:00 SR

    • Ranted about JavaScript’s design (evolution?) flaws here.
    • Adding items to the environment
      • Need to compare the data provider to see what’s in the model but not in the DP and delete it
      • Need to change the data format to include all the tn_types – started
      • Link the pulled-down data to the chart data. Going to try just assigning pointers first.
      • Hey! It loaded from the DB and rendered! Need to anchor the network root. Done. For the time being I’m using the lowest id_index, which will equate to the earliest entry.

loadedNetwork

      • Need to verify that all the connections are good too.
      • Attached the data object.
      • The view that produced the query results was wrong. Fixed now:

loadedNetwork

  • Up on the server and tested in all browsers. Had a heart stoppage when the tn_view_network_items didn’t get added. But it’s all good now.  For tomorrow, try adding items and modifying the network structure with only the new items.

Phil 8.24.15

8:00 – 3:00 SR

  • Still working the Zeno’s Administrator problem.
  • Had a good discussion with Lenny about Low Threshold/High Ceiling coding and also about functional vs declarative programming and how ExtJS and AngularJS relate to those concepts.
  • Adding items to the live network and then bring down and parse the data object. This means pulling out the code that loads before the DB call.
  • Added queries and associations to any query that is not “__topNews__”

Phil 8.21.15

8:00 – 4:30 SR

  • Still no admin, but we’re at the last step. I think.
  • Meeting with the GMO folks. They have an ExtJS framework (YUI-based!?) for all their user IO.
  • We will *not* be abandoning Angular: xtJsVsAngularJs
  • Long discussion with Mark and Lenny about next steps. Maybe integrate all the efforts? I made the point that what we have is an information navigation system, but the info is questionable. Wheat we need is a data/inference system
  • More housekeeping for network logging in. Cleaned up the add network code on the client and server. Everything seems to be working as it’s supposed to. Next step will be to add items to the live network and then bring down and parse the data object.
  • I also realized that the best way to show the items is to have the master list populated by sublists. So the status item would be loaded first, then the selected items, then the search results. Then the various sublists can be managed separately and the other lists won’t care.

Phil 8.19.15

8:00 – 5:00 SR

  • Admin has been approved. Waiting for my logins to re-activate
  • Friday, 9:00-ish meeting with GAO-ish folks to talk about ingest.
  • Continue working on storing items and associations.
  • These people integrate annotations into the article, which is deeper. But in the reading of an article, this seems overwhelming
  • Bayes Server – worth getting? John G. Sandiford’s thesis.
  • Adding a UID to associations, since they need to be unique and findable. Done, and it’s for within a network.
  • Added a HOST type so that the root of the domain can be stored as an attribute as well. Of course, there was a PHP call to do this.
  • Tested creation of items and associations against this Miami Herald article.
  • Need to make sure that NLP items don’t get stored if they don’t return right.

Phil 8.18.15

8:00 – 5:00 SR

  • Still no admin
  • I forgot to save the new SQL for the truancy reports. Fixed now.
  • There is something that’s not quite right in the network physics. When an object is added, sometimes the forces get asymmetric. My guess is that the velocities have to be made non-zero each time an item is added.
  • Was getting a problem where additional information was getting stuck on the end of the image url, which was contaminating the name. Now, rather than assuming that the image name ends with the extension, I look within the image url for a reasonable extension and return that.
  • Need a query that returns the associations shared between two items. Done
  • Working on adding Alchemy NLP results as items with associations

Phil 8.17.15

8:00 – 3:00 SR

  • Still no admin
  • Given that I’m using FizzBuzz for the coding side of the SWE interview, I though I should put together a test for the database portion of the interview:
    • Create three tables:
      • One for names and salaries,
      • One for roles,
      • One that assigns a particular person to one or more roles.
    • Create a query that prints the name strings with their role strings. Extra points if it’s a view.
    • Create a query that sums the salaries.
    • Create a query that sums the salaries for a given role.
      DROP TABLE IF EXISTS test_people;
      CREATE TABLE test_people (
      	id_index 		INT AUTO_INCREMENT PRIMARY KEY NOT NULL,
      	name			varchar(255),
      	salary			BIGINT
      );
      
      insert into test_people (name, salary) values
      ('Sophia',10000000000),
      ('Emma',1000000000),
      ('Olivia',100000000),
      ('Isabella', 10000000),
      ('Jackson',1000000),
      ('Aiden',100000),
      ('Liam',10000),
      ('Noah', 1000),
      ('Charlotte', 100),
      ('Caden', 10),
      ('Harper', 1);
      
      DROP TABLE IF EXISTS test_roles;
      CREATE TABLE test_roles (
      	id_index 		INT AUTO_INCREMENT PRIMARY KEY NOT NULL,
      	role			varchar(255)
      );
      
      insert into test_roles (role) values
      ('Minion'),
      ('Worker'),
      ('Manager'),
      ('CEO'),
      ('Evil Overlord');
      
      DROP TABLE IF EXISTS test_assignments;
      CREATE TABLE test_assignments (
      	person_id 	INT,
      	role_id		INT
      );
      insert into test_assignments (person_id, role_id) values
      (1, 5),
      (2, 4),
      (3, 3),
      (4, 2),
      (5, 1),
      (6, 1),
      (7, 1),
      (8, 1);
      
      drop view IF EXISTS test_join;
      create view test_join as
      select p.name, r.role, p.salary
      	from test_assignments a
      	inner join test_people p on a.person_id = p.id_index
      	inner join test_roles r on a.role_id = r.id_index;
      
      select * from test_join;
      select sum(salary) from test_join where role = "Minion";
      
      DROP TABLE IF EXISTS test_people;
      DROP TABLE IF EXISTS test_roles;
      DROP TABLE IF EXISTS test_assignments;
      drop view IF EXISTS test_join;
  • Add the ability to save a network and then start saving one!
  • Since the mysqldump file doesn’t work on my server, spit the current schema file into three sections:
    • Table creation (incorporate DROP TABLE IF EXISTS table_name) – done
    • View creation – done
    • Tests – done
  • Using the linkFn() in ngFlyoutPanel to call getNetworks() on the load of the directive. Wasn’t sure that it would work, but it does. In Chrome, FF, and IE yet..
  • Uploaded to the main server. Works there, too!