Papers › ToM: Leveraging Tree-oriented MapReduce for Long-Context Reasoning in Large Language Models

ToM: Leveraging Tree-oriented MapReduce for Long-Context Reasoning in Large Language Models

1 Nov 2025EMNLParXiv:2511.00489added by Syntology

Jiani Guo, Zuchao Li, Jie Wu, Qianren Wang, Yun Li, Lefei Zhang, Hai Zhao, Yujiu Yang

Title, abstract, authors and date from arXiv's metadata (CC0); this paper is not in the Papers with Code archive (frozen 2025-07-28).

Large Language Models (LLMs), constrained by limited context windows, often face significant performance degradation when reasoning over long contexts. To address this, Retrieval-Augmented Generation (RAG) retrieves and reasons over chunks but frequently sacrifices logical coherence due to its reliance on similarity-based rankings. Similarly, divide-and-conquer frameworks (DCF) split documents into small chunks for independent reasoning and aggregation. While effective for local reasoning, DCF struggles to capture long-range dependencies and risks inducing conflicts by processing chunks in isolation. To overcome these limitations, we propose ToM, a novel Tree-oriented MapReduce framework for long-context reasoning. ToM leverages the inherent hierarchical structure of long documents (e.g., main headings and subheadings) by constructing a DocTree through hierarchical semantic parsing and performing bottom-up aggregation. Using a Tree MapReduce approach, ToM enables recursive reasoning: in the Map step, rationales are generated at child nodes; in the Reduce step, these rationales are aggregated across sibling nodes to resolve conflicts or reach consensus at parent nodes. Experimental results on 70B+ LLMs show that ToM significantly outperforms existing divide-and-conquer frameworks and retrieval-augmented generation methods, achieving better logical coherence and long-context reasoning. Our code is available at https://github.com/gjn12-31/ToM .

PaperPDFCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2511.00489")

Code

Syntology Ran 3 of 7 code samples harvested from 1 repository linked to this paper; 4 have no recorded run. Of those that ran: 2 ran · our draft was wrong; 1 ran with no contract checked.

By repository: found in paper text by Syntology: 7 samples from 1 repository, 3 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

gjn12-31/ToM found in paper text by Syntology report

Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

7 samples harvested; 3 ran; 0 honoured the contract we drafted; 4 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

2ran · our draft was wrong
1ran
4unverified

Licence: 7 of the 7 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from gjn12-31/ToM. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: 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. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

TreeNode gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology ran · metamorphic tier: deterministic no licence file found · pointer only · 8004b7e3471e60b3 · report
format_map_prompt gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology ran · our draft was wrong fingerprinted no licence file found · pointer only · f3b33cd4aa2de1c4 · report
format_reduce_prompt gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology ran · our draft was wrong fingerprinted no licence file found · pointer only · ec81b029a4ec13b4 · report
AsyncMapReducePipeline gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology unverified no licence file found · pointer only · 14ea15e38475d993 · report
get_model_inference gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology unverified no licence file found · pointer only · 9f26e8649c5c2094 · report
run_batch_inference gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology unverified no licence file found · pointer only · 5261d227a1e9714f · report
run_inference gjn12-31/ToM/Reasoning/pipeline.py found in paper text by Syntology unverified no licence file found · pointer only · 89b2fef50c90d00f · report

Results from the paper

The Papers with Code archive ends with its 2025-07-28 snapshot. This paper's arXiv identifier, 2511.00489, was issued in November 2025, after that date, so the archive has no leaderboard rows for it.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections