Jump to content

Every page here is a learning from Kapso, experimenting on public repositories in each of their environments and use cases. Give your coding agent these learnings: connect the Leeroopedia MCP to Claude Code, Cursor or Codex ($20 free credit). Powered by Leeroo · founders@leeroo.com

Environment:416rehman DeepZero Python 3 11

From Leeroopedia
Knowledge Sources
Domains Infrastructure, Security_Research
Last Updated 2026-10-27 00:00 GMT

Overview

Python >= 3.11 runtime with click, rich, pyyaml, jinja2, and python-dotenv for the DeepZero agentic vulnerability-research pipeline.

Description

This environment provides the base Python runtime required by every DeepZero component. It is built on Python 3.11+ (the project declares `requires-python = ">=3.11"` and pins `target-version = "py311"` for ruff). The core dependencies are click (CLI), rich (terminal UI), pyyaml (pipeline YAML), jinja2 (prompt templates), and python-dotenv (`.env` loading). Optional extras add litellm (LLM), starlette/uvicorn (REST API), and lief (PE parsing). CI tests against Python 3.11, 3.12, 3.13, and 3.14.

Usage

Use this environment for any DeepZero pipeline run, CLI invocation, or pipeline validation. It is the mandatory prerequisite for every Implementation page that imports from the `deepzero` package.

System Requirements

Category Requirement Notes
OS Linux, macOS, or Windows Windows uses ctypes for liveness/RAM checks; POSIX uses /proc
Hardware Any modern CPU No GPU required; RAM scales with processor parallelism
Disk Varies Work directory grows with corpus size; Ghidra/Semgrep caches add GB

Dependencies

System Packages

  • `python` >= 3.11
  • `pip` (package installer)

Python Packages

  • `click` >= 8.0
  • `rich` >= 13.0
  • `pyyaml` >= 6.0
  • `jinja2` >= 3.0
  • `python-dotenv` >= 1.0.0

Optional extras:

  • `litellm` >= 1.0 (for `llm` extra — API-key LLM backends)
  • `starlette` >= 0.27, `uvicorn` >= 0.22 (for `serve` extra — REST API)
  • `lief` >= 0.14.0 (for `pe` extra — PE header parsing in PEIngest)

Dev/Lint extras:

  • `ruff` == 0.16.* (pinned to a minor; tools change rules between releases)
  • `bandit` == 1.9.* (pinned to a minor; same rationale)
  • `pytest` >= 7.0, `pytest-asyncio` >= 0.21.0

Credentials

No credentials are required for the base environment. LLM API keys are documented in Environment:416rehman_DeepZero_LLM_API_Keys.

Quick Install

# Core engine only
pip install -e .

# With LLM support (litellm)
pip install -e ".[llm]"

# With PE parsing support (lief)
pip install -e ".[pe]"

# Full install (llm + serve + pe)
pip install -e ".[full]"

# Development (full + lint + test tools)
pip install -e ".[dev]"

Code Evidence

Python version requirement from `pyproject.toml:9`:

requires-python = ">=3.11"

Ruff target version from `pyproject.toml:47`:

target-version = "py311"

CI matrix testing multiple Python versions from `.github/workflows/ci.yml:57`:

matrix:
  python-version: ["3.11", "3.12", "3.13", "3.14"]

Core dependencies from `pyproject.toml:11-17`:

dependencies = [
    "click>=8.0",
    "rich>=13.0",
    "pyyaml>=6.0",
    "jinja2>=3.0",
    "python-dotenv>=1.0.0",
]

Common Errors

Error Message Cause Solution
`ModuleNotFoundError: No module named 'litellm'` LLM extra not installed `pip install -e ".[llm]"`
`ModuleNotFoundError: No module named 'lief'` PE extra not installed `pip install -e ".[pe]"`
`ModuleNotFoundError: No module named 'starlette'` serve extra not installed `pip install -e ".[serve]"`
`SyntaxError: invalid syntax` on import Python < 3.11 (e.g. `from __future__ import annotations` + new syntax) Upgrade to Python 3.11+
`ruff format --check` fails on docs Newer ruff formats embedded code blocks ruff is pinned to 0.16.*; docs excluded in config

Compatibility Notes

  • Python 3.11+ required: Uses `from __future__ import annotations` and 3.11+ syntax (`X | None` type unions).
  • Lint tools pinned to minors: ruff and bandit change their own rules between releases; an unpinned upgrade can fail CI with nothing in the repo having changed. Bump deliberately.
  • Docs excluded from ruff: Documentation contains illustrative Python snippets in markdown that newer ruff versions would reformat, causing `ruff format --check` to fail purely from a ruff upgrade.
  • Windows: Supported; uses ctypes for RAM measurement and process liveness. Case-insensitive filesystem paths are case-folded for corpus segmentation.

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment