Files
8.-samopisnyy-poiskovyy-age…/README.md
T
kuzakhmetovartur 1039c7065c
CI / build (3.1) (push) Has been cancelled
CI / build (3.11) (push) Has been cancelled
CI / build (3.8) (push) Has been cancelled
CI / build (3.9) (push) Has been cancelled
feat: solution for '8. Самописный поисковый агент на основе deep agents from scratch'
2026-06-30 16:22:52 +03:00

43 lines
907 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# DeepAgent
DeepAgent is a minimal example of a deep learning based search agent.
It demonstrates how to combine a neural network with a simple search algorithm
(MonteCarlo Tree Search style) without relying on external search libraries.
## Installation
```bash
# Create a virtual environment (recommended)
python -m venv .venv
source .venv/bin/activate # On Windows use `.venv\\Scripts\\activate`
# Install the package
pip install .
```
## Usage
```python
from src.search_agent import SearchAgent, PolicyValueNet
# Create a policyvalue network
net = PolicyValueNet(input_dim=1, action_space=2)
# Create the agent
agent = SearchAgent(policy_value_net=net, max_depth=3)
# Run the agent on a simple state
state = 0
action = agent.act(state)
print(f"Chosen action: {action}")
```
## Running Tests
```bash
pytest
```
## License
MIT License see the [LICENSE](LICENSE) file for details.