{"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/prototransformer-a-meta-learning-approach-to","title":"ProtoTransformer: A Meta-Learning Approach to Providing Student Feedback","arxiv_id":"2107.14035","date":"2021-07-23","proceeding":null,"authors":["Mike Wu","Noah Goodman","Chris Piech","Chelsea Finn"],"abstract":"High-quality computer science education is limited by the difficulty of providing instructor feedback to students at scale. While this feedback could in principle be automated, supervised approaches to predicting the correct feedback are bottlenecked by the intractability of annotating large quantities of student code. In this paper, we instead frame the problem of providing feedback as few-shot classification, where a meta-learner adapts to give feedback to student code on a new programming question from just a few examples annotated by instructors. Because data for meta-training is limited, we propose a number of amendments to the typical few-shot learning framework, including task augmentation to create synthetic tasks, and additional side information to build stronger priors about each task. These additions are combined with a transformer architecture to embed discrete sequences (e.g. code) to a prototypical representation of a feedback class label. On a suite of few-shot natural language processing tasks, we match or outperform state-of-the-art performance. Then, on a collection of student solutions to exam questions from an introductory university course, we show that our approach reaches an average precision of 88% on unseen questions, surpassing the 82% precision of teaching assistants. Our approach was successfully deployed to deliver feedback to 16,000 student exam-solutions in a programming course offered by a tier 1 university. This is, to the best of our knowledge, the first successful deployment of a machine learning based feedback to open-ended student code.","url_abs":"https://arxiv.org/abs/2107.14035v2","url_pdf":"https://arxiv.org/pdf/2107.14035v2.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":"prototransformer-a-meta-learning-approach-to","repo_url":"https://github.com/mhw32/prototransformer-public","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"few-shot-learning","task_name":"Few-Shot Learning"},{"task_slug":"meta-learning","task_name":"Meta-Learning"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2107.14035","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2107.14035"}},"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/mhw32/prototransformer-public","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":7},"by_repo_kind":{"listed":{"samples":7,"ran":0,"repositories":1}},"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":"f2e7fb4c01d6ee3b","entry":"build_equivalences","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/feedback.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/feedback.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":"f2e7fb4c01d6ee3b"}},{"code_sha256_prefix":"26c93f0afd519a05","entry":"build_many_equivalences","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/feedback.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/feedback.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":"26c93f0afd519a05"}},{"code_sha256_prefix":"3976dab6c53b60b0","entry":"create_position_ids_from_input_ids","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/models/monkeypatch.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/models/monkeypatch.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":"3976dab6c53b60b0"}},{"code_sha256_prefix":"eee82740fe209a0f","entry":"get_domains","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/amazon.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/amazon.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":"eee82740fe209a0f"}},{"code_sha256_prefix":"5d2535cee5f10524","entry":"get_test_data","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/amazon.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/amazon.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":"5d2535cee5f10524"}},{"code_sha256_prefix":"b86bcfe377f853aa","entry":"get_train_data","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/amazon.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/amazon.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":"b86bcfe377f853aa"}},{"code_sha256_prefix":"759155413ac913f5","entry":"make_rubrics_float","repo":"mhw32/prototransformer-public","repo_kind":"listed","path":"src/datasets/feedback.py","file_url":"https://github.com/mhw32/prototransformer-public/blob/HEAD/src/datasets/feedback.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":"759155413ac913f5"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}