示例#1
0
def wiki_wc(search):
    result = perform_request(search)
    urls = result["url"]
    summaries = summarize(result["content"])
    counts = get_noun_frequencies(result["content"])

    return jsonify(counts=counts, summaries=summaries, urls=urls)
示例#2
0
def w_counts(search):
    return jsonify(
        query=search, description=static_results[search], counts=get_noun_frequencies(static_results[search])
    )