# Drzewo myśli (Tree of Thoughts)

EN: **Tree of Thoughts** · id `treeofthoughts`

Path: [AI Atlas](https://aiatlasgraph.com/llms.txt) › [Sieci i modele generatywne](https://aiatlasgraph.com/t/neural.md) › [Rozumowanie w modelach językowych](https://aiatlasgraph.com/t/reasoningmodels.md) › [Łańcuch myśli (chain-of-thought)](https://aiatlasgraph.com/t/cot.md) › Drzewo myśli (Tree of Thoughts)

## Description

- PL: Model rozwija kilka alternatywnych ścieżek rozumowania, sam ocenia ich obiecujące fragmenty i może się cofać — jak przeszukiwanie drzewa zamiast jednej linii myśli.
- EN: The model expands several alternative reasoning paths, evaluates which look promising and can backtrack — tree search instead of one line of thought.

## In one sentence

- PL: To szukanie rozwiązania przez rozwijanie kilku możliwych ścieżek i wracanie z tych, które nie pomagają.
- EN: This searches for a solution by exploring several possible paths and backing away from unhelpful ones.

## Problem it solves

- PL: Jedna błędna decyzja na początku może poprowadzić całe rozwiązanie w złą stronę.
- EN: One wrong early decision can send the entire solution down an unhelpful path.

## What it does

- PL: Model proponuje alternatywne kroki, ocenia ich obiecujące fragmenty i rozwija wybrane gałęzie zamiast jednej nieprzerwanej odpowiedzi.
- EN: A model proposes alternative steps, assesses promising partial solutions and develops selected branches rather than one uninterrupted response.

## Everyday example

- PL: Układając plan dostaw, model próbuje różnych pierwszych przystanków i wraca do innego wariantu, gdy trasa narusza ograniczenie czasu.
- EN: While planning deliveries, a model tries different first stops and returns to another option when a route violates a time constraint.

## This concerns you if you…

- PL: rozwiązanie wymaga wyboru między wariantami
- PL: możesz poświęcić obliczenia na sprawdzanie kilku ścieżek
- EN: need to choose among solution alternatives
- EN: can spend computation exploring several paths

## Keywords

thought branching · BFS · DFS · self-evaluation · branch pruning · Game of 24

## How it works

- PL: Generator proponuje kilka kolejnych fragmentów rozwiązania, a ocena wybiera ścieżki do rozwinięcia. Sterownik przeszukiwania utrzymuje alternatywy, przycina słabe gałęzie i może wracać do wcześniejszych stanów zamiast kontynuować jedną sekwencję.
- EN: A generator proposes several next solution fragments, and evaluation selects paths for expansion. A search controller retains alternatives, prunes weak branches and can return to earlier states instead of continuing one sequence.

## Limits

- PL: Koszt rośnie z liczbą gałęzi i ocen. Błędna heurystyka może odrzucić poprawną ścieżkę; pozornie różne próby bywają silnie skorelowane.
- EN: Costs increase with branches and evaluations. Incorrect heuristics can discard valid paths; apparently different attempts can be strongly correlated.

## Key terms

- PL: **frontier**: Zbiór częściowych rozwiązań oczekujących na dalsze rozwinięcie.
- PL: **przycinanie gałęzi**: Odrzucanie ścieżek uznanych za zbyt słabe względem innych.
- EN: **frontier**: Partial solutions awaiting further expansion.
- EN: **branch pruning**: Discarding paths considered too weak compared with alternatives.

## Know first

- [Przeszukiwanie lokalne (wspinaczka, wyżarzanie) (Local search (hill climbing, simulated annealing))](https://aiatlasgraph.com/t/localsearch.md)
- [Zbiory testowe i regresje (Evaluation datasets and regression tests)](https://aiatlasgraph.com/t/evalsets.md)

## Examples

- PL: BFS/DFS po myślach · samoocena kroków · Game of 24
- EN: BFS/DFS over thoughts · self-evaluation of steps · Game of 24

## Related topics

Untyped, symmetric "see also" links.

- [Przeszukiwanie i planowanie (Search and planning)](https://aiatlasgraph.com/t/search.md)

## Sources

- [Tree of Thoughts: Deliberate Problem Solving with Large Language Models](<https://arxiv.org/abs/2305.10601>) `yao-tree-of-thoughts-2023` · by Shunyu Yao, Dian Yu, Jeffrey Zhao, Izhak Shafran, Thomas L. Griffiths, Yuan Cao, Karthik Narasimhan

---

AI Atlas revision 122 (2026-10-30) · HTML: https://aiatlasgraph.com/t/treeofthoughts · index: https://aiatlasgraph.com/llms.txt · everything: https://aiatlasgraph.com/llms-full.txt · updated 2026-10-30
