Skip to content

Commit

Permalink
added basic text analysis
Browse files Browse the repository at this point in the history
  • Loading branch information
mikpanko committed Dec 24, 2013
1 parent 2b5dcbb commit 2659e37
Show file tree
Hide file tree
Showing 9 changed files with 9,923 additions and 3 deletions.
Empty file added __init__.py
Empty file.
13 changes: 11 additions & 2 deletions expresso.py
@@ -1,4 +1,6 @@
from flask import Flask, render_template
from flask import Flask, render_template, request, jsonify
import jinja2
from text_analysis import analyze_text

app = Flask(__name__)

Expand All @@ -8,5 +10,12 @@ def expresso():
return render_template('expresso.html')


@app.route('/analyze-text', methods=['POST'])
def analyze():
text = request.form.get('text', '', type=str)
analyzed_text = analyze_text(text)
return jsonify(analyzed_text)


if __name__ == '__main__':
app.run()
app.run(debug=True)
File renamed without changes.
6 changes: 5 additions & 1 deletion static/css/expresso.css
@@ -1,3 +1,7 @@
.text-large {
font-size: 18px;
}
}

#results-table {
margin-top: 50px;
}

0 comments on commit 2659e37

Please sign in to comment.