{"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/a-geometric-notion-of-causal-probing","title":"A Geometric Notion of Causal Probing","arxiv_id":"2307.15054","date":"2023-07-27","proceeding":null,"authors":["Clément Guerner","Tianyu Liu","Anej Svete","Alexander Warstadt","Ryan Cotterell"],"abstract":"The linear subspace hypothesis (Bolukbasi et al., 2016) states that, in a language model's representation space, all information about a concept such as verbal number is encoded in a linear subspace. Prior work has relied on auxiliary classification tasks to identify and evaluate candidate subspaces that might give support for this hypothesis. We instead give a set of intrinsic criteria which characterize an ideal linear concept subspace and enable us to identify the subspace using only the language model distribution. Our information-theoretic framework accounts for spuriously correlated features in the representation space (Kumar et al., 2022) by reconciling the statistical notion of concept information and the geometric notion of how concepts are encoded in the representation space. As a byproduct of this analysis, we hypothesize a causal process for how a language model might leverage concepts during generation. Empirically, we find that linear concept erasure is successful in erasing most concept information under our framework for verbal number as well as some complex aspect-level sentiment concepts from a restaurant review dataset. Our causal intervention for controlled generation shows that, for at least one concept across two languages models, the concept subspace can be used to manipulate the concept value of the generated word with precision.","url_abs":"https://arxiv.org/abs/2307.15054v4","url_pdf":"https://arxiv.org/pdf/2307.15054v4.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":"a-geometric-notion-of-causal-probing","repo_url":"https://github.com/rycolab/causalgeom","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[{"task_slug":"language-modeling","task_name":"Language Modeling"},{"task_slug":"language-modelling","task_name":"Language Modelling"},{"task_slug":null,"task_name":"counterfactual"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2307.15054","atlas_url":"https://app.syntology.ai/?focus=2307.15054","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2307.15054"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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/rycolab/causalgeom","reach":{"status":"ok"}}],"summary":{"ran":7},"by_repo_kind":{"official":{"samples":7,"ran":7,"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":7,"samples":[{"code_sha256_prefix":"df5b05910dab9b1a","entry":"compute_p_c","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/mi_computer_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/mi_computer_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"df5b05910dab9b1a"}},{"code_sha256_prefix":"d1561934a8b4cd21","entry":"compute_p_h","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/mi_computer_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/mi_computer_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"d1561934a8b4cd21"}},{"code_sha256_prefix":"10b5875559acd6e6","entry":"compute_p_h_c","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/mi_computer_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/mi_computer_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"10b5875559acd6e6"}},{"code_sha256_prefix":"2b8954785d15209e","entry":"get_probs","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/eval_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/eval_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"2b8954785d15209e"}},{"code_sha256_prefix":"03863db1628b9c64","entry":"get_res_file_paths","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/agg_mi_evals.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/agg_mi_evals.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"03863db1628b9c64"}},{"code_sha256_prefix":"22100853f97eb614","entry":"load_run_Ps","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/eval_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/eval_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"22100853f97eb614"}},{"code_sha256_prefix":"2999995e330b6535","entry":"load_run_output","repo":"rycolab/causalgeom","repo_kind":"official","path":"src/evals/eval_utils.py","file_url":"https://github.com/rycolab/causalgeom/blob/HEAD/src/evals/eval_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"2999995e330b6535"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}