fd5af0ca2b8e7655c777e66f5f512c7ebc60b120
Deep Agent – Search + Virtual Files
This repository contains a minimal deep agent implementation based on the "Deep Agents from Scratch" course. The agent can:
- Search the web (simple Bing wrapper).
- Create and modify files in an in‑memory virtual file system.
- Read those virtual files.
- Dump the virtual file system to the real disk at the end of the run.
Setup
# Create a virtual environment (optional but recommended)
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt
Prerequisite – An Ollama server must be running locally with a model such as
llama3.1available.
Usage
python agent.py
You will be prompted to type questions. The agent will decide which tool to
use. When you are finished, type exit.
The virtual files are stored in memory. To persist them, use the DumpVirtualFS
tool or call dump_virtual_fs_tool("output") from within the agent.
Files
agent.py– Main agent implementation.virtual_fs.py– Simple in‑memory file system.requirements.txt– Python dependencies.README.md– This documentation.
Languages
Python
100%