# Open-SWE Dependencies: Complete Guide to Runtime and Development Requirements

> Discover Open-SWE dependencies for runtime and development. Learn about LangChain, FastAPI, and pytest requirements in our comprehensive guide.

- Repository: [LangChain/open-swe](https://github.com/langchain-ai/open-swe)
- Tags: guide
- Published: 2026-03-19

---

**Open-SWE declares all runtime and development dependencies in [`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml), including the LangChain ecosystem, FastAPI for the web server, and pytest for testing.**

Open-SWE is a Python-based agent framework for software engineering tasks, and understanding its dependency structure is essential for deployment and contribution. All open-swe dependencies are centrally managed in the repository's [`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml) file, which separates runtime requirements from development tools.

## Runtime Dependencies in Open-SWE

The runtime open-swe dependencies power the agent's LLM workflows, HTTP server, authentication, and integrations. These are defined under the `dependencies` table in [`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml) and are required for the agent to execute software engineering tasks.

### Core LangChain Ecosystem

The foundation of Open-SWE relies on the LangChain ecosystem for LLM orchestration and graph-based workflows:

- **`langchain>=1.2.9`** – Core framework for chaining LLM calls
- **`langgraph>=1.0.8`** – Library for building stateful, multi-actor applications
- **`langgraph-sdk>=0.1.0`** – SDK for interacting with LangGraph deployments
- **`langgraph-cli[inmem]>=0.4.12`** – CLI tools for running in-memory graph instances
- **`langsmith>=0.7.1`** – Observability and tracing platform integration

Provider-specific integrations include:
- **`langchain-openai==1.1.10`** – OpenAI models (pinned to exact version)
- **`langchain-anthropic>1.1.0`** – Anthropic Claude models
- **`langchain-daytona>=0.0.3`**, **`langchain-modal>=0.0.2`**, **`langchain-runloop>=0.0.3`** – Infrastructure provider integrations

### Web Server and HTTP Clients

Open-SWE exposes its agent capabilities via a FastAPI web server defined in [`agent/webapp.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/webapp.py):

- **`fastapi>=0.104.0`** – Modern, fast web framework for building APIs
- **`uvicorn>=0.24.0`** – ASGI server to run the FastAPI application
- **`httpx>=0.25.0`** – Modern HTTP client used in utility modules like [`agent/utils/github.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/utils/github.py) for outbound API calls

### Authentication and Security

The agent handles secure authentication with external services through:

- **`PyJWT>=2.8.0`** – JSON Web Token implementation for authentication flows
- **`cryptography>=41.0.0`** – Cryptographic recipes and primitives for secure communications

### Agent Framework and Utilities

Additional specialized dependencies include:

- **`deepagents>=0.4.3`** – The underlying agent framework that powers Open-SWE's software engineering capabilities
- **`markdownify>=1.2.2`** – Utility for converting HTML to Markdown, used in content processing workflows

## Development Dependencies

Development open-swe dependencies are optional and defined under `[project.optional-dependencies]` in [`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml). Install these when contributing to the codebase or running the test suite.

The development stack includes:

- **`pytest>=7.0.0`** – Testing framework for the test suite located in the `tests/` directory
- **`pytest-asyncio>=0.21.0`** – Plugin for testing async code patterns used throughout the agent
- **`ruff>=0.1.0`** – Modern Python linter and formatter for code quality enforcement

## Installing Open-SWE Dependencies

To set up the project locally, use the following commands based on your needs.

Install runtime dependencies only:

```bash
pip install -e .

```

Install with development dependencies for testing and linting:

```bash
pip install -e ".[dev]"

```

Verify the installation by running the FastAPI server:

```bash
python -m agent.server

```

## How Dependencies Power the Open-SWE Agent

The open-swe dependencies directly enable specific functionality across the codebase:

- **[`agent/webapp.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/webapp.py)** uses **FastAPI** and **Uvicorn** to expose LangGraph endpoints as HTTP routes
- **[`agent/utils/github.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/utils/github.py)** relies on **httpx** for GitHub API calls and **PyJWT**/**cryptography** for authentication
- **[`agent/tools/github_comment.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/tools/github_comment.py)** integrates with the LangChain ecosystem to post AI-generated comments on issues
- **[`agent/prompt.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/prompt.py)** utilizes **langchain** and **deepagents** to construct LLM prompt templates
- **[`agent/server.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/server.py)** orchestrates the startup process, binding all dependencies together

The pinned versions ensure compatibility between **langchain-openai** (exactly `1.1.10`) and the broader LangGraph ecosystem, preventing breaking changes from upstream updates.

## Summary

- Open-SWE manages all dependencies through **[`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml)**, separating runtime requirements from optional development tools.
- **Runtime dependencies** include the LangChain ecosystem (langchain, langgraph, langchain-openai), FastAPI for the web server, httpx for HTTP clients, and deepagents for the agent framework.
- **Development dependencies** include pytest, pytest-asyncio, and ruff for testing and code quality.
- Specific files like [`agent/webapp.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/webapp.py), [`agent/utils/github.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/utils/github.py), and [`agent/server.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/server.py) directly utilize these dependencies for API serving, authentication, and agent orchestration.

## Frequently Asked Questions

### What are the core LangChain dependencies required for Open-SWE?

The core LangChain dependencies include `langchain>=1.2.9`, `langgraph>=1.0.8`, and provider-specific packages like `langchain-openai==1.1.10` (pinned exactly) and `langchain-anthropic>1.1.0`. These packages power the LLM workflows and graph-based agent architecture in [`agent/prompt.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/prompt.py) and related modules.

### How do I install development dependencies for contributing to Open-SWE?

Install development dependencies by running `pip install -e ".[dev]"` from the repository root. This installs the optional dependency group defined in [`pyproject.toml`](https://github.com/langchain-ai/open-swe/blob/main/pyproject.toml) under `[project.optional-dependencies]`, which includes `pytest>=7.0.0`, `pytest-asyncio>=0.21.0`, and `ruff>=0.1.0` for testing and linting.

### Which web server framework does Open-SWE use and why?

Open-SWE uses **FastAPI** (`fastapi>=0.104.0`) served by **Uvicorn** (`uvicorn>=0.24.0`) to expose its LangGraph agent as an HTTP API. This combination is defined in [`agent/webapp.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/webapp.py) and [`agent/server.py`](https://github.com/langchain-ai/open-swe/blob/main/agent/server.py), providing async request handling and automatic API documentation generation for the agent endpoints.

### Are Open-SWE dependencies pinned to specific versions?

Yes, most runtime dependencies specify minimum versions (e.g., `langchain>=1.2.9`), while some like `langchain-openai` are pinned to exact versions (`==1.1.10`) to ensure compatibility across the LangChain ecosystem. Development dependencies in the `dev` optional group also specify minimum versions to guarantee consistent testing and linting behavior.