{"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/evaluating-language-models-as-risk-scores","title":"Evaluating language models as risk scores","arxiv_id":"2407.14614","date":"2024-07-19","proceeding":null,"authors":["André F. Cruz","Moritz Hardt","Celestine Mendler-Dünner"],"abstract":"Current question-answering benchmarks predominantly focus on accuracy in realizable prediction tasks. Conditioned on a question and answer-key, does the most likely token match the ground truth? Such benchmarks necessarily fail to evaluate LLMs' ability to quantify ground-truth outcome uncertainty. In this work, we focus on the use of LLMs as risk scores for unrealizable prediction tasks. We introduce folktexts, a software package to systematically generate risk scores using LLMs, and evaluate them against US Census data products. A flexible API enables the use of different prompting schemes, local or web-hosted models, and diverse census columns that can be used to compose custom prediction tasks. We evaluate 17 recent LLMs across five proposed benchmark tasks. We find that zero-shot risk scores produced by multiple-choice question-answering have high predictive signal but are widely miscalibrated. Base models consistently overestimate outcome uncertainty, while instruction-tuned models underestimate uncertainty and produce over-confident risk scores. In fact, instruction-tuning polarizes answer distribution regardless of true underlying data uncertainty. This reveals a general inability of instruction-tuned LLMs to express data uncertainty using multiple-choice answers. A separate experiment using verbalized chat-style risk queries yields substantially improved calibration across instruction-tuned models. These differences in ability to quantify data uncertainty cannot be revealed in realizable settings, and highlight a blind-spot in the current evaluation ecosystem that folktexts covers.","url_abs":"https://arxiv.org/abs/2407.14614v3","url_pdf":"https://arxiv.org/pdf/2407.14614v3.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":"evaluating-language-models-as-risk-scores","repo_url":"https://github.com/socialfoundations/folktexts","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"multiple-choice","task_name":"Multiple-choice"},{"task_slug":"question-answering","task_name":"Question Answering"}],"methods":[{"method_slug":"base","method_name":"BASE"},{"method_slug":"focus","method_name":"Focus"}],"datasets_introduced":[{"slug":"folktexts","name":"folktexts","full_name":"folktexts"}],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2407.14614","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2407.14614"}},"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/socialfoundations/folktexts","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":11,"unverified":5},"by_repo_kind":{"official":{"samples":16,"ran":11,"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":"cf37f3a9cdc6c7aa","entry":"compute_best_threshold","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/evaluation.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/evaluation.py","link_basis":"first_harvest_node","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":"cf37f3a9cdc6c7aa"}},{"code_sha256_prefix":"5062267f04eb87f0","entry":"decode_topk_logprobs_to_risk_estimate","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/llm_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/llm_utils.py","link_basis":"first_harvest_node","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":"5062267f04eb87f0"}},{"code_sha256_prefix":"01541e897eeb12a8","entry":"hash_dict","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_utils.py","link_basis":"first_harvest_node","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":"01541e897eeb12a8"}},{"code_sha256_prefix":"31ad435fddbf752e","entry":"is_valid_number","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_utils.py","link_basis":"first_harvest_node","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":"31ad435fddbf752e"}},{"code_sha256_prefix":"01ac3ca87c183a87","entry":"load_json","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_io.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_io.py","link_basis":"first_harvest_node","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":"01ac3ca87c183a87"}},{"code_sha256_prefix":"7dada3fae6fa983f","entry":"load_pickle","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_io.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_io.py","link_basis":"first_harvest_node","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":"7dada3fae6fa983f"}},{"code_sha256_prefix":"42c4582c73314ab0","entry":"query_model_batch","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/llm_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/llm_utils.py","link_basis":"first_harvest_node","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":"42c4582c73314ab0"}},{"code_sha256_prefix":"e810648cd6b36c41","entry":"query_model_batch_multiple_passes","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/llm_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/llm_utils.py","link_basis":"first_harvest_node","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":"e810648cd6b36c41"}},{"code_sha256_prefix":"d2bc3968e99d74c2","entry":"safe_division","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_utils.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_utils.py","link_basis":"first_harvest_node","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":"d2bc3968e99d74c2"}},{"code_sha256_prefix":"830399f6f5c3fa70","entry":"save_pickle","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/_io.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/_io.py","link_basis":"first_harvest_node","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":"830399f6f5c3fa70"}},{"code_sha256_prefix":"ca43e66139b9adbd","entry":"tokenizer_supports_system_prompt","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/prompting.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/prompting.py","link_basis":"first_harvest_node","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":"ca43e66139b9adbd"}},{"code_sha256_prefix":"b9dfaaf12e5dc135","entry":"evaluate_binary_predictions","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/evaluation.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/evaluation.py","link_basis":"first_harvest_node","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":"b9dfaaf12e5dc135"}},{"code_sha256_prefix":"c8232e3ddcdf11c2","entry":"evaluate_binary_predictions_fairness","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/evaluation.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/evaluation.py","link_basis":"first_harvest_node","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":"c8232e3ddcdf11c2"}},{"code_sha256_prefix":"cacc10e89eb26d82","entry":"render_evaluation_plots","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/plotting.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/plotting.py","link_basis":"first_harvest_node","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":"cacc10e89eb26d82"}},{"code_sha256_prefix":"fa65093fc4513ba8","entry":"render_fairness_plots","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/plotting.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/plotting.py","link_basis":"first_harvest_node","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":"fa65093fc4513ba8"}},{"code_sha256_prefix":"b35fd0172480d532","entry":"save_fig","repo":"socialfoundations/folktexts","repo_kind":"official","path":"folktexts/plotting.py","file_url":"https://github.com/socialfoundations/folktexts/blob/HEAD/folktexts/plotting.py","link_basis":"first_harvest_node","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":"b35fd0172480d532"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}