Skip to content

Instantly share code, notes, and snippets.

@Vineeth-Mohan
Created August 8, 2012 08:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Vineeth-Mohan/3293432 to your computer and use it in GitHub Desktop.
Save Vineeth-Mohan/3293432 to your computer and use it in GitHub Desktop.
vineeth@vineeth-XPS-L501X:~/temp$ cat jo
<a href=\"http://economictimes.indiatimes.com/news/international-business/barack-obama-tightens-sanctions-on-banks-helping-iran-sell-oil/articleshow/15306729.cms/topic/Barack-Obama\" >Barack Obama</a>
vineeth@vineeth-XPS-L501X:~/temp$ curl -XGET 'localhost:9200/algotree/_analyze?field=Content' -d @jo | python -mjson.tool
{
"tokens": [
{
"end_offset": 190,
"position": 1,
"start_offset": 184,
"token": "barack",
"type": "<ALPHANUM>"
},
{
"end_offset": 200,
"position": 2,
"start_offset": 191,
"token": "obama",
"type": "<ALPHANUM>"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment