Metadata-Version: 2.4
Name: pageindex-mcts
Version: 0.1.0
Summary: MCTS based PageIndex search library
Author: PageIndexMCTS Team
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: aiohappyeyeballs==2.6.1
Requires-Dist: aiohttp==3.13.2
Requires-Dist: aiosignal==1.4.0
Requires-Dist: annotated-types==0.7.0
Requires-Dist: anyio==4.12.0
Requires-Dist: attrs==25.4.0
Requires-Dist: certifi==2025.11.12
Requires-Dist: cffi==2.0.0
Requires-Dist: charset-normalizer==3.4.4
Requires-Dist: colorama==0.4.6
Requires-Dist: cryptography==46.0.3
Requires-Dist: dashscope==1.25.5
Requires-Dist: distro==1.9.0
Requires-Dist: frozenlist==1.8.0
Requires-Dist: h11==0.16.0
Requires-Dist: httpcore==1.0.9
Requires-Dist: httpx==0.28.1
Requires-Dist: idna==3.11
Requires-Dist: jiter==0.12.0
Requires-Dist: multidict==6.7.0
Requires-Dist: openai==1.101.0
Requires-Dist: pageindex==0.2.2
Requires-Dist: propcache==0.4.1
Requires-Dist: pycparser==2.23
Requires-Dist: pydantic==2.12.5
Requires-Dist: pydantic_core==2.41.5
Requires-Dist: PyMuPDF==1.26.4
Requires-Dist: PyPDF2==3.0.1
Requires-Dist: python-dotenv==1.1.0
Requires-Dist: PyYAML==6.0.2
Requires-Dist: regex==2025.11.3
Requires-Dist: requests==2.32.5
Requires-Dist: setuptools==80.9.0
Requires-Dist: sniffio==1.3.1
Requires-Dist: tiktoken==0.11.0
Requires-Dist: tqdm==4.67.1
Requires-Dist: typing-inspection==0.4.2
Requires-Dist: typing_extensions==4.15.0
Requires-Dist: urllib3==2.6.2
Requires-Dist: websocket-client==1.9.0
Requires-Dist: wheel==0.45.1
Requires-Dist: yarl==1.22.0
Dynamic: author
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# PageIndexMCTS

PageIndexMCTS is a Python library that implements Monte Carlo Tree Search (MCTS) for efficient page indexing and retrieval, integrated with Large Language Models (LLMs).

## Features

- **MCTS Implementation**: Includes standard MCTS and Hybrid MCTS (PUCT) algorithms.
- **LLM Integration**: Supports using LLMs (like ChatGPT) for value estimation and policy priors.
- **Parallel Search**: Optimized for performance with parallel simulation steps.
- **Document Indexing**: Tools for indexing PDF and Markdown documents.

## Installation

You can install the package directly from source:

```bash
pip install .
```

## Usage

See the `example` directory for usage demonstrations.

### Basic MCTS Search

```python
from search.tree.mcts import PageIndexMCTS

# Initialize your structure and query
# ...
search = PageIndexMCTS(structure, query, use_llm=True, n_threads=4)
search.run_search(iterations=50)
results = search.get_top_results(n=3)
```

## License

This project is licensed under the MIT License - see the LICENSE file for details.
