Twitter ODLs的Tweet元语法

Twitter ODLs的Tweet元语法,twitter,syntax,health-monitoring,Twitter,Syntax,Health Monitoring,我对使用Tweets/SMS/Identica或其他短文本状态更新系统跟踪日常生活观察(或ODL)的想法很感兴趣。基本概念是,您可以向Twitter或Identi.ca发送状态更新,或者只发送一条SMS消息或其他格式的信息,这些信息可以在以后进行挖掘以显示模式 你可以用它来追踪运动,饮食,你的电影喜好,任何你喜欢的东西 要做到这一点,您需要有一个语法,允许人类和计算机轻松解析您的状态更新。语法应该是密集的,这支持低字符数,但仍然是人类可读的 这个想法并不新鲜,现在有很多twitter应用程序用于

我对使用Tweets/SMS/Identica或其他短文本状态更新系统跟踪日常生活观察(或ODL)的想法很感兴趣。基本概念是,您可以向Twitter或Identi.ca发送状态更新,或者只发送一条SMS消息或其他格式的信息,这些信息可以在以后进行挖掘以显示模式

你可以用它来追踪运动,饮食,你的电影喜好,任何你喜欢的东西

要做到这一点,您需要有一个语法,允许人类和计算机轻松解析您的状态更新。语法应该是密集的,这支持低字符数,但仍然是人类可读的

这个想法并不新鲜,现在有很多twitter应用程序用于跟踪运动和饮食习惯。Twitter本质上已经是一种短文本ODL媒体,你可以通过查看搜索到的感觉很容易地看到它 或者搜索#heats或旨在挖掘已经进入twitter的大量ODL数据的应用程序:

通过使用Twitter跟踪ODL,你可以停止强迫人们使用专门为此创建的特定集成引擎(如Google Health和HealthVault),而是专注于提高人们已经在使用的ODL跟踪系统(如Facebook或Twitter)的价值。但要做到这一点,您需要一种通用的方法来输入ODL并对这些条目进行数据挖掘,这样您就可以在更高或至少不同的层次上获得意义

还有一些语法可以推广使用Twitter跟踪你喜欢的任何东西的方法。这些是我最感兴趣的。到目前为止,我知道几个:

。它使用直接消息,如下所示:

d daytum item : amount 
// simple data label and value
d daytum item [category, category] : amount
// same thing but with tagging...
。它还使用直接消息传递

// yfd works with "action" and "value" pairs
d yfd weigh 160
d yfd exercised arms
d yfd watched Back to the Future
// but can be made more complex with units
d yfd drank 2 water
d yfd drank 1 coke
// and timestamps 
d yfd played xbox at 20:00
d yfd goodnight at 11:00pm
d yfd goodnight at 11pm
对于每个操作,yfd将询问您有关数据类型的一些信息,要求您在以下选项中进行选择:

分类-如果你对不同单位的相同行为感兴趣,例如吃玉米 事件-如果关注点是某事发生时,例如晚安或大便 柜台-如果你最感兴趣的是你做某事的总次数,例如抽了5支烟 测量-如果您希望看到某个值随时间的变化趋势,例如体重160或血压170

很聪明不是吗

我所知道的最后一件事是。到目前为止,这是一个非常简洁的概念,因为它以一种非常聪明的方式使用了hashtags

//hashtag with comma separated tags
#mood(happy,elated,drunk)
#mood(sad,sober)
// scales, like not busy
#busy(1)
// very busy
#busy(5)
//straight up numbers
#lbs(250)
#worked(10)
此外,还可以让你包括你吃了什么,以及包括卡路里/脂肪/积分跟踪。所以语法看起来像

d tyeats #breakfast One bowl of cereal *c500
// the *c500 marks the tweet as 500 calories
当然,重要的是要注意已经登录到twitter的不同ODL生成软件所使用的非常常见的自然语言模式,如runkeeper,它通常会生成以下内容:

@meattwitter Just completed a 4.50 km run with @runkeeper. Check it out! http://rnkpr.com/aaaaa #RunKeeper
那么现在我的问题是什么

我还忽略了什么其他重要的ODL语法? DM是进行数据收集的正确方法还是应该关注hashtags? 除了runkeeper等,还有哪些重要的“自然”ODL正在发生? 有人知道关于这个问题的任何正式研究吗(社交媒体状态更新中的ODL语法)? 有人知道有任何现有的开源项目实现了这种类型的东西吗

更新:Paul指出OMHE项目就是这样做的。下面是OMHE语法,它已经有了一个基于python的解析器

#The basic OMHE syntax follows this basic format"
[COMMAND_NAME]<VALUE><#[TAG]>

# Reporting WEIGHT (This is correct):
wt123.4

# In the previous example, COMMAND_NAME=wt and VALUE=123.4

# Reporting WEIGHT (Also Correct):
wt=123.4

# In the previous example, COMMAND_NAME=wt and VALUE=123.4

# Reporting WEIGHT with _TAGS_ (Also Correct) :
wt=123.4#mytag#myothertag

# The previous example has two tags: 'mytag' and 'myothertag'

# Weight is a command that requires a value (Incorrect):
wt

#You can never have an equal sign without a value. (Also Incorrect):
wt=

# Here is an OMHE string with two commands separated by white space " ".
# Says the command 'wt' (weight) has a value of '195' and blood glucose is 150.
wt195 bg=150

# Report the start of a menstrual cycle (correct):
# (Correct) mcycle is a command where value is not required 
mcycle

# Report the first day of a menstrual cycle:
# Notice we can still add tags even if no value is given 
mc

# Report the start of a menstrual cycle (Incorrect):
# You can't provide an equals "=" sign without a value: 
mc=

# Report the adherence to a health directive such as taking medication (correct):
# (Correct) did is a command where value is not required 
did

# Report the adherence to a health directive  to stretch arm (correct):
did=ARMSTRETCH

# Send Blood Glucose Level:
bg125

# Send Blood Pressure:
bp100d120p65

# Send Blood Pressure using the equals sign style:
bp=100d120p65

# Send Weight:
wt145
wt=145 #Express weight using the equals sign style
w78k   #Express weight in kilograms
wt145l  #Explicit express weight in pounds (lbs)
wt245.8 #Express fractional weight
wt245p8 #Another way to express fractional weight

# Send blood glucose, patient identifier, a note, and the date:
bg145 id213762732467234 nAllGood d20090117

# Sending blood glucose with a simple note tag (with spaces):
bg145#I'm*feeling*very*tired*today

# Report the start of a menstrual cycle:
mcycle

# Get a copy of your health benefits/insurance card:
gethc

# Send a copy of your health benefits card to someone via fax:
sendhc=6509840982#fax

# Send a copy of your health benefits card as a pdf to someone via email:
sendhc=nurse@mydoc.com#pdf

# Get a copy of your personal health record:
getphr

# Get a copy of your personal health record as a pdf:
getphr#pdf

# Get a copy of your personal health record in CCD format:
getphr#ccd

# Send a copy of your personal health record to someone in CCR format:
sendphrnurse@mydoc.com#ccr

# Send a copy of your personal health record to someone in XML microformat:
sendphr=nurse@mydoc.com#microformat
#基本OMHE语法遵循此基本格式”
[命令名称]
#报告重量(这是正确的):
wt123.4
#在上一个示例中,命令名为wt,值为123.4
#报告重量(同样正确):
wt=123.4
#在上一个示例中,命令名为wt,值为123.4
#使用_标签报告重量(同样正确):
wt=123.4#我的标签#我的标签
#上一个示例有两个标记:“mytag”和“myothertag”
#权重是一个需要值的命令(不正确):
wt
#如果没有值,则永远不能有等号。(也不正确):
wt=
#这是一个OMHE字符串,其中有两个命令,用空格“”分隔。
#表示命令“wt”(重量)的值为“195”,血糖为150。
wt195 bg=150
#报告月经周期的开始(正确):
#(正确)mcycle是一个不需要值的命令
麦凯勒
#报告月经周期的第一天:
#注意,即使没有给出值,我们仍然可以添加标记
司仪
#报告月经周期的开始(不正确):
#如果没有值,则不能提供等于“=”的符号:
司仪=
#报告对健康指令的遵守情况,如服用药物(正确):
#(正确)did是不需要值的命令
做
#报告对伸展手臂健康指令的遵守情况(正确):
手臂伸展
#发送血糖水平:
bg125
#发送血压:
bp100d120p65
#使用等号样式发送血压:
bp=100d120p65
#发送重量:
wt145
wt=145#使用等号样式表示重量
w78k#以千克表示重量
wt145l#明确表示重量(磅)
wt245.8#表示分数重量
wt245p8#表示分数权重的另一种方法
#发送血糖、患者识别码、便条和日期:
bg145 ID213762747234 nAllGood d20090117
#发送带有简单便笺标签的血糖(带空格):
bg145#我今天感觉很累
#报告月经周期的开始:
麦凯勒
#获取您的健康福利/保险卡副本:
gethc
#通过传真向某人发送您的健康福利卡副本:
sendhc=6509840982#传真
#通过电子邮件将您的健康福利卡副本以pdf格式发送给某人:
sendhc=nurse@mydoc.com#pdf
#获取您的个人健康记录副本:
格弗
#以pdf格式获取您的个人健康记录副本:
getphr#pdf
#获取CCD格式的个人健康记录副本:
getphr#ccd
#以CCR格式向某人发送您的个人健康记录副本:
sendphrnurse@mydoc.com#ccr
#以XML微格式向某人发送您的个人健康记录副本:
森弗尔=nurse@mydoc.com#微格式
我的目标是在开源环境下编写解析器和数据显示工具