{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/all-but-the-top-simple-and-effective","title":"All-but-the-Top: Simple and Effective Postprocessing for Word Representations","arxiv_id":"1702.01417","date":"2017-02-05","proceeding":"ICLR 2018 1","authors":["Jiaqi Mu","Suma Bhat","Pramod Viswanath"],"abstract":"Real-valued word representations have transformed NLP applications; popular\nexamples are word2vec and GloVe, recognized for their ability to capture\nlinguistic regularities. In this paper, we demonstrate a {\\em very simple}, and\nyet counter-intuitive, postprocessing technique -- eliminate the common mean\nvector and a few top dominating directions from the word vectors -- that\nrenders off-the-shelf representations {\\em even stronger}. The postprocessing\nis empirically validated on a variety of lexical-level intrinsic tasks (word\nsimilarity, concept categorization, word analogy) and sentence-level tasks\n(semantic textural similarity and { text classification}) on multiple datasets\nand with a variety of representation methods and hyperparameter choices in\nmultiple languages; in each case, the processed representations are\nconsistently better than the original ones.","url_abs":"http://arxiv.org/abs/1702.01417v2","url_pdf":"http://arxiv.org/pdf/1702.01417v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"all-but-the-top-simple-and-effective","repo_url":"https://github.com/lgalke/vec4ir","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"all-but-the-top-simple-and-effective","repo_url":"https://github.com/nlpAThits/WOMBAT","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok"}},{"paper_slug":"all-but-the-top-simple-and-effective","repo_url":"https://github.com/woctezuma/steam-descriptions","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"all-but-the-top-simple-and-effective","repo_url":"https://github.com/s1998/All-but-the-top","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"tf","reach":{"status":"ok"}}],"tasks":[{"task_slug":"all","task_name":"All"},{"task_slug":"classification","task_name":"General Classification"},{"task_slug":"sentence","task_name":"Sentence"},{"task_slug":"sentiment-analysis","task_name":"Sentiment Analysis"},{"task_slug":"subjectivity-analysis","task_name":"Subjectivity Analysis"},{"task_slug":"text-classification","task_name":"Text Classification"},{"task_slug":"word-similarity","task_name":"Word Similarity"}],"methods":[{"method_slug":"glove","method_name":"GloVe"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/sentiment-analysis-on-mr","task":"Sentiment Analysis","dataset":"MR","model":"GRU-RNN-WORD2VEC","rank_in_archive_order":11,"of":19,"metrics":{"Accuracy":"78.26"},"uses_additional_data":false},{"leaderboard":"/sota/sentiment-analysis-on-sst-5-fine-grained","task":"Sentiment Analysis","dataset":"SST-5 Fine-grained classification","model":"GRU-RNN-WORD2VEC","rank_in_archive_order":25,"of":31,"metrics":{"Accuracy":"45.02"},"uses_additional_data":false},{"leaderboard":"/sota/subjectivity-analysis-on-subj","task":"Subjectivity Analysis","dataset":"SUBJ","model":"GRU-RNN-GLOVE","rank_in_archive_order":15,"of":19,"metrics":{"Accuracy":"91.85"},"uses_additional_data":false},{"leaderboard":"/sota/text-classification-on-trec-6","task":"Text Classification","dataset":"TREC-6","model":"GRU-RNN-GLOVE","rank_in_archive_order":13,"of":19,"metrics":{"Error":"7.0"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1702.01417","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1702.01417"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/woctezuma/steam-descriptions","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/nlpAThits/WOMBAT","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/lgalke/vec4ir","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/s1998/All-but-the-top","reach":{"status":"ok"}}],"summary":{"ran":2,"unverified":24},"by_repo_kind":{"listed":{"samples":26,"ran":2,"repositories":2}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"65bd69884cbfbdc9","entry":"mean_reciprocal_rank","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/rank_metrics.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/rank_metrics.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"65bd69884cbfbdc9"}},{"code_sha256_prefix":"1c940d569262c1bb","entry":"r_precision","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/rank_metrics.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/rank_metrics.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"1c940d569262c1bb"}},{"code_sha256_prefix":"b283385e4542d942","entry":"aggregate_dicts","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/combination.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/combination.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"b283385e4542d942"}},{"code_sha256_prefix":"5d4fdb7bf9b69030","entry":"all_but_the_top","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/postprocessing.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/postprocessing.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"5d4fdb7bf9b69030"}},{"code_sha256_prefix":"da8430897fe9994d","entry":"compute_pc","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"SIF_embedding.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/SIF_embedding.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"da8430897fe9994d"}},{"code_sha256_prefix":"c956460114b027c7","entry":"compute_retrieval_score","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"hard_coded_ground_truth.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/hard_coded_ground_truth.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c956460114b027c7"}},{"code_sha256_prefix":"d8ff6aad1114d84f","entry":"compute_retrieval_score_based_on_sharing_meta_data","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"steam_spy_based_ground_truth.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/steam_spy_based_ground_truth.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d8ff6aad1114d84f"}},{"code_sha256_prefix":"9b9bf22b3f9692b7","entry":"delta","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/eqlm.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/eqlm.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"9b9bf22b3f9692b7"}},{"code_sha256_prefix":"3514fb2cdfab561d","entry":"eqe1","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/eqlm.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/eqlm.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"3514fb2cdfab561d"}},{"code_sha256_prefix":"3c032c9ef0a071ed","entry":"expand","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/eqlm.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/eqlm.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"3c032c9ef0a071ed"}},{"code_sha256_prefix":"4e503c5d0be1ac1c","entry":"f1_score","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/base.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/base.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4e503c5d0be1ac1c"}},{"code_sha256_prefix":"f3932c5856a22a48","entry":"filter_none","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/base.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/base.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"f3932c5856a22a48"}},{"code_sha256_prefix":"ff6ad3cdd392ee59","entry":"filter_out_words_not_in_vocabulary","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"sentence_models.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/sentence_models.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ff6ad3cdd392ee59"}},{"code_sha256_prefix":"14985f458b636e07","entry":"fuzzy_or","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/combination.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/combination.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"14985f458b636e07"}},{"code_sha256_prefix":"89ab94b0acec1f01","entry":"get_small_banner_url","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"find_unique_games.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/find_unique_games.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"89ab94b0acec1f01"}},{"code_sha256_prefix":"d8940449fdc20406","entry":"get_store_url","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"benchmark_utils.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/benchmark_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d8940449fdc20406"}},{"code_sha256_prefix":"dd93a92c0ff9a838","entry":"get_store_url_as_bb_code","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"sentence_models.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/sentence_models.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"dd93a92c0ff9a838"}},{"code_sha256_prefix":"026881372c1acba1","entry":"get_weighted_average","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"SIF_embedding.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/SIF_embedding.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"026881372c1acba1"}},{"code_sha256_prefix":"74ad04dddaa20e30","entry":"get_word_model_vocabulary","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"word_model.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/word_model.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"74ad04dddaa20e30"}},{"code_sha256_prefix":"007dc399b4466aa1","entry":"harvest","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/base.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/base.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"007dc399b4466aa1"}},{"code_sha256_prefix":"6affee200375e11e","entry":"harvest_docs","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/datasets.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/datasets.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"6affee200375e11e"}},{"code_sha256_prefix":"8292abe95b52ea1c","entry":"mine_gold","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/datasets.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/datasets.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8292abe95b52ea1c"}},{"code_sha256_prefix":"0b5204fbf39cb428","entry":"precision_at_k","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/rank_metrics.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/rank_metrics.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0b5204fbf39cb428"}},{"code_sha256_prefix":"84d9ddc54e992bf6","entry":"remove_pc","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"SIF_embedding.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/SIF_embedding.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"84d9ddc54e992bf6"}},{"code_sha256_prefix":"0ee5810d2cce719e","entry":"synthesize_topics","repo":"lgalke/vec4ir","repo_kind":"listed","path":"vec4ir/datasets.py","file_url":"https://github.com/lgalke/vec4ir/blob/HEAD/vec4ir/datasets.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0ee5810d2cce719e"}},{"code_sha256_prefix":"d4b5206c822ba5a1","entry":"test_word","repo":"woctezuma/steam-descriptions","repo_kind":"listed","path":"word_model.py","file_url":"https://github.com/woctezuma/steam-descriptions/blob/HEAD/word_model.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d4b5206c822ba5a1"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}