1
Stannford OpenIEトリプレットに基づくファイルから文を抽出しようとしています。私はjsonファイルの形でそれを持っています。Json形式のスタンフォードオープンIEトリプレットに基づくファイルの文の抽出
"openie": [
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive back to",
"relationSpan": [3, 6],
"object": "Missouri night",
"objectSpan": [6, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive back to",
"relationSpan": [3, 6],
"object": "Missouri",
"objectSpan": [6, 7]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive back to Missouri night",
"objectSpan": [3, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive back to",
"relationSpan": [3, 6],
"object": "Missouri same night",
"objectSpan": [6, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive to",
"relationSpan": [3, 6],
"object": "Missouri",
"objectSpan": [6, 7]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive to Missouri",
"objectSpan": [3, 7]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive back to Missouri",
"objectSpan": [3, 7]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive to Missouri same night",
"objectSpan": [3, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive to",
"relationSpan": [3, 6],
"object": "Missouri same night",
"objectSpan": [6, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive to Missouri night",
"objectSpan": [3, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive",
"objectSpan": [3, 4]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive back to Missouri same night",
"objectSpan": [3, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "decided",
"relationSpan": [1, 2],
"object": "drive back",
"objectSpan": [3, 5]
},
{
"subject": "Missouri",
"subjectSpan": [6, 7],
"relation": "is at_time",
"relationSpan": [9, 10],
"object": "night",
"objectSpan": [9, 10]
},
{
"subject": "We",
"subjectSpan": [0, 1],
"relation": "drive to",
"relationSpan": [3, 6],
"object": "Missouri night",
"objectSpan": [6, 10]
}
],
このjsonが抽出されたテキストファイルからこの特定の文章を抽出する必要があります。 私はテキスト要約をしようとしています。
助けてください。スタンフォードCoreNLP出力が各センテンスにopenie
出力を添付し、事前
原文を解決するには、この構造では十分な情報がありません。具体的には、「to」の1つのインスタンスと「the」は両方とも欠落しており、推論される必要があります。 –
これはCoreNLPの出力からですか? 'openie'リストを文JSONに付けるべきではありませんか?コマンドラインから呼び出す場合:リバーブの出力形式が最も冗長で、その中に文章のテキストが含まれます。 –