[15.10.20] Headers
This commit is contained in:
parent
83841ef6b2
commit
f5f3a4edd7
@ -18,8 +18,9 @@ analyser = sentimentAnalyser.get_sentiment()
|
|||||||
@app.route('/sentiment', methods=['GET'])
|
@app.route('/sentiment', methods=['GET'])
|
||||||
def tweetPredict():
|
def tweetPredict():
|
||||||
tweet = request.args.get('tweet')
|
tweet = request.args.get('tweet')
|
||||||
|
syncId = request.headers.get('X-CRYPTO-Sync-ID')
|
||||||
|
|
||||||
log("Receiving Tweet to classify [{}]".format(tweet), 'INFO')
|
log("Receiving Tweet to classify [{}] for [{}]".format(tweet, syncId), 'INFO')
|
||||||
|
|
||||||
result = analyser.get_vader_sentiment(tweet)
|
result = analyser.get_vader_sentiment(tweet)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user