Skip to content

Instantly share code, notes, and snippets.

@wfaler
wfaler / entities.json
Created December 12, 2011 18:11
entities.json
[{"ref":{"id":"334fee29c0a8000215a00d2579292428","accountId":"194ad084c0a80002274b8c218ea70268","dateTime":"2011-12-12T17:26:43Z","documentTime":"2011-12-12T17:26:46Z"},"name":"last week","label":"DATE","occurences":2},{"ref":{"id":"334fee29c0a8000215a00d2579292428","accountId":"194ad084c0a80002274b8c218ea70268","dateTime":"2011-12-12T17:26:43Z","documentTime":"2011-12-12T17:26:46Z"},"name":"Tim O\u2019Reilly","label":"PERSON","occurences":1}]
@wfaler
wfaler / response.json
Created December 12, 2011 17:51
response.json
{"correlation":{"requestId":"334fee29c0a8000215a00d2579292428"},"title":"Recursivity - TextMinr Progress Update","paragraphs":[{"sentences":[{"sentence":"29 <subject>Nov</subject> 11 TextMinr Progress Update"}]},{"sentences":[{"sentence":"Since <subject>I</subject> announced TextMinr, the Text mining as a service platform <name label=\"DATE\">last week</name> - the interest has been overwhelming: it got to the top 3 of Hackernews, it got retweeted by <name label=\"PERSON\">Tim O\u2019Reilly</name> of O\u2019Reilly media and many other influential people in the tech scene."}]},{"sentences":[{"sentence":"<subject>Progress</subject> over the <subject><name label=\"DATE\">last week</name></subject> has been good, the public API is coming along and it\u2019s quite likely we will start to dripfeed invitations to the beta towards the end of next week."},{"sentence":"<subject>I</subject> say \u201cdripfeed\u201d, because there are so many people who have declared interest that we\u2019ll have to do it slowly to scale
@wfaler
wfaler / request.json
Created December 12, 2011 17:32
request.json
{"source":{"sourceType":"url","source":"http://blog.recursivity.com/post/13499141271/textminr-progress-update"},"processors":[{"name":"entityrecognition"},{"name":"subjectidentification"},{"name":"contextsearch","config":["beta"]}],"requestGroup":"32d3a8c5c0a8000215a00d255fe8f937"}
@wfaler
wfaler / requestref.json
Created December 12, 2011 17:27
requestref.json
{"id":"334fee29c0a8000215a00d2579292428","accountId":"194ad084c0a80002274b8c218ea70268","dateTime":"2011-12-12T17:26:43Z"}
@wfaler
wfaler / requestgroups.json
Created December 12, 2011 15:11
requestgroups.json
{"count":2,
"items":[
{"id":"32d39011c0a8000215a00d2538fd9c0c","accountId":"194ad084c0a80002274b8c218ea70268","name":"Group1"},
{"id":"32d3a8c5c0a8000215a00d255fe8f937","accountId":"194ad084c0a80002274b8c218ea70268","name":"Group2"}]}
@wfaler
wfaler / plugins.scala
Created October 26, 2011 09:43
mixed-plugin-deps
libraryDependencies <+= sbtVersion(v => "com.github.siasia" %% "xsbt-web-plugin" % (v+"-0.2.7"))
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.7.1")
@wfaler
wfaler / Applewhois.txt
Created October 4, 2011 19:27
Applewhois.txt
$ whois apple.com
Whois Server Version 2.0
Domain names in the .com and .net domains can now be registered
with many different competing registrars. Go to http://www.internic.net
for detailed information.
APPLE.COM.WWW.BEYONDWHOIS.COM
APPLE.COM.WAS.PWNED.BY.M1CROSOFT.COM
@wfaler
wfaler / IOClientCode.scala
Created September 13, 2011 10:05
IOClientCode.scala
def writeToRemoteFilesystem(input: MyDataStructure,
writer: (SomeOutput) => Unit = defaultWriter(_)): Unit{
//do something with the datastructure
writer(output)
}
def defaultWriter(output: SomeOutput) = remoteFs.write("/somepath", output)
// in your test class:
def testWriter(output: SomeOutput) = addToSomethingThatYourTestHasAHandleTo(output)
@wfaler
wfaler / IOClientCode.java
Created September 13, 2011 09:53
IOClientCode.java
public void writeToRemoteFilesystem(MyDataStructure input){
//do something with the datastructure
remoteFs.write("/somepath", output);
}
@wfaler
wfaler / casbah_and_salat_imports.scala
Created August 7, 2011 13:06
casbah_and_salat_imports.scala
// such a great setup, but so many damned imports - little note to make me remember.
import com.recursivity.mongo.Mongo
import com.novus.salat.global._
import com.novus.salat._
import com.mongodb.casbah.commons.MongoDBObject
import com.mongodb.casbah.MongoConnection._
import com.mongodb.casbah.MongoConnection
import com.mongodb.casbah.commons.Imports.DBObject
import com.mongodb.casbah.Imports._
import org.joda.time.DateTime