STReason: a multitask framework that combines spatiotemporal analysis with the explainability of large language models

11 September 202639 views

The framework eliminates the need to train a model for each individual task: complex queries are broken down into interpretable modules executed by spatiotemporal models and LLMs. This approach delivers verifiable numerical results with explanations, reducing the risk of hallucinations, and in tests it significantly outperforms standard LLM baselines.

STReason: a multitask framework that combines spatiotemporal analysis with the explainability of large language models

Limitations of Classical Spatiotemporal Analysis

Spatiotemporal analysis helps with decision-making across a wide range of fields, from urban planning to logistics. However, existing models are typically tailored to one specific task, such as traffic forecasting or anomaly detection. They cannot answer complex, multi-part questions that require a long chain of reasoning and an explanation of the result. In practice, a specialist often needs to see not just a number, but the logic behind it.

It is precisely for such scenarios that the multi-task framework STReason was created, presented in a paper by a group of researchers on arXiv. Its main idea is to combine the strengths of two worlds: specialized models for analyzing spatiotemporal data provide accurate mathematical results, while large language models handle coherent reasoning and explanations understandable to humans.

How STReason Works

Instead of fine-tuning a model for each new task, STReason uses in-context learning — the model's ability to learn from examples directly while processing a request. The workflow consists of several steps:

  1. The user asks a question in natural language.
  2. The framework decomposes this question into simpler parts.
  3. Each part is turned into a modular executable program that utilizes analytical functions from spatiotemporal models.
  4. The programs are executed systematically, and their results are aggregated into a single answer.

The key advantage of this approach is explainability. Regular language models often "hallucinate": they confidently invent facts that do not exist. In STReason, explanations are built on verified computations, not on the model's imagination. If the model produces a conclusion, it is backed by real data and intermediate calculations. This makes the reasoning transparent and reliable.

Experiments and Results

To assess models' ability to perform long, multi-step reasoning in spatiotemporal tasks, the authors developed a special benchmark with its own metric system. Both large language models and hybrid variants participated in the tests.

STReason consistently outperformed language model baselines across all reasoning metrics. The difference was especially noticeable on tasks requiring intensive analytics and building long logical chains. Standard LLMs, even with significant capacity, got confused in multi-step scenarios, whereas the framework's modular approach allowed for sequential, error-free operation.

Additionally, human experts provided their assessment. They confirmed that STReason's results look convincing and are practically useful: in several cases, the tool can take over routine analytical work and reduce the workload on specialists.

Practical Significance

The main value of STReason lies not in solving one specific type of task, but in creating a universal "bridge" between formal computations and natural language. This approach can be applied in urban analytics systems, environmental monitoring, transportation management, and other areas where a decision-maker wants to see not just a forecast, but the complete picture of reasoning.

The question of computational complexity and speed remains open, but the proposed architecture already demonstrates how to combine the accuracy of specialized algorithms with the flexibility of modern LLMs. Perhaps it is precisely such hybrid frameworks that will become the next step in the evolution of spatiotemporal analysis.

By the way, the paper on STReason will be presented at the SIGSPATIAL '26 conference — a leading forum on geographic information systems.

Frequently asked questions

Related materials

All materials
STReason: a multitask framework that combines spatiotemporal analysis with the explainability of large language models