Skip to content

Commit d40200b

Browse files
feat(deps)!: split ADK/server deps into optional [adk]/[cli]/[observability] extras
Bare `pip install agentex-sdk` now installs only the 6 deps the Stainless-generated REST client actually needs (`httpx`, `pydantic`, `typing-extensions`, `anyio`, `distro`, `sniffio`). Everything used by the `agentex.lib.*` surface — CLI, ACP server, Temporal workflows, LLM provider integrations, observability — moves to optional extras. Three extras for different consumer slices: - `[cli]` (11 deps) — `agentex.lib.cli.*`, `agentex.lib.sdk.config.*`, and the `agentex` CLI entry point. For tools like sgpctl that need the CLI helpers without temporal/fastapi/redis. - `[observability]` (4 deps) — `agentex.lib.core.tracing.*`, `agentex.lib.core.observability.*`. For consumers that only attach the SGP/Datadog/OTel tracing processors. - `[adk]` (31 deps) — union of [cli] + [observability] + ACP server + Temporal + Redis + MCP + LLM providers. Full agent authoring. The current install behavior is recoverable with `pip install agentex-sdk[adk]`. CLI templates (`agentex init`) are updated to pin `agentex-sdk[adk]` so newly bootstrapped agents work out of the box. BREAKING CHANGE: consumers who rely on `agentex.lib.*` must pin one of the new extras instead of bare `agentex-sdk`. The REST client surface (`from agentex import Agentex, AsyncAgentex`) is unchanged and still works with a bare install. Verified by building the wheel locally: - `Requires-Dist` (base): 6 - `Requires-Dist; extra == 'cli'`: 11 - `Requires-Dist; extra == 'observability'`: 4 - `Requires-Dist; extra == 'adk'`: 31 Stacked on AGX1-292 / #367 (drop unused deps). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent b100da2 commit d40200b

21 files changed

Lines changed: 81 additions & 52 deletions

File tree

pyproject.toml

Lines changed: 61 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -8,44 +8,16 @@ authors = [
88
{ name = "Agentex", email = "roxanne.farhad@scale.com" },
99
]
1010

11+
# Bare client surface only — the Stainless-generated REST client
12+
# (`from agentex import Agentex, AsyncAgentex`). Everything else lives
13+
# under the `[adk]` extra; see [project.optional-dependencies] below.
1114
dependencies = [
1215
"httpx>=0.28.1,<0.29",
1316
"pydantic>=2.0.0, <3",
1417
"typing-extensions>=4.14, <5",
1518
"anyio>=3.5.0, <5",
1619
"distro>=1.7.0, <2",
1720
"sniffio",
18-
"typer>=0.16,<0.17",
19-
"questionary>=2.0.1,<3",
20-
"rich>=13.9.2,<14",
21-
"fastapi>=0.115.0",
22-
"starlette>=0.49.1",
23-
"uvicorn>=0.31.1",
24-
"watchfiles>=0.24.0,<1.0",
25-
"python-on-whales>=0.73.0,<0.74",
26-
"pyyaml>=6.0.2,<7",
27-
"jsonschema>=4.23.0,<5",
28-
"jsonref>=1.1.0,<2",
29-
"temporalio>=1.26.0,<2",
30-
"aiohttp>=3.10.10,<4",
31-
"redis>=5.2.0,<8",
32-
"litellm>=1.83.7,<2",
33-
"kubernetes>=25.0.0,<36.0.0",
34-
"jinja2>=3.1.3,<4",
35-
"mcp>=1.4.1",
36-
"scale-gp>=0.1.0a59",
37-
"openai-agents==0.14.1",
38-
"pydantic-ai-slim>=1.0,<2",
39-
"json_log_formatter>=1.1.1",
40-
"scale-gp-beta>=0.2.0",
41-
"openai>=2.2,<3", # Required by openai-agents; litellm now supports openai 2.x (issue #13711 resolved: https://github.com/BerriAI/litellm/issues/13711)
42-
"cloudpickle>=3.1.1",
43-
"ddtrace>=3.13.0",
44-
"yaspin>=3.1.0",
45-
"claude-agent-sdk>=0.1.0",
46-
"langgraph-checkpoint>=2.0.0",
47-
"opentelemetry-sdk>=1.20.0",
48-
"opentelemetry-api>=1.20.0",
4921
]
5022

5123
requires-python = ">= 3.11,<4"
@@ -70,7 +42,64 @@ Homepage = "https://github.com/scaleapi/scale-agentex-python"
7042
Repository = "https://github.com/scaleapi/scale-agentex-python"
7143

7244
[project.optional-dependencies]
73-
aiohttp = ["aiohttp", "httpx_aiohttp>=0.1.9"]
45+
# httpx-aiohttp transport. Independent from `[adk]`.
46+
aiohttp = ["aiohttp>=3.10.10,<4", "httpx_aiohttp>=0.1.9"]
47+
48+
# CLI surface — what `agentex.lib.cli.*` and `agentex.lib.sdk.config.*` need.
49+
# Consumers that import only `agentex.lib.cli.handlers`, `agentex.lib.sdk.config`,
50+
# or use the `agentex` CLI entry point can pin `agentex-sdk[cli]` instead of the
51+
# full `[adk]` extra.
52+
cli = [
53+
"typer>=0.16,<0.17",
54+
"questionary>=2.0.1,<3",
55+
"rich>=13.9.2,<14",
56+
"yaspin>=3.1.0",
57+
"pyyaml>=6.0.2,<7",
58+
"python-on-whales>=0.73.0,<0.74",
59+
"kubernetes>=25.0.0,<36.0.0",
60+
"jsonref>=1.1.0,<2",
61+
"jsonschema>=4.23.0,<5",
62+
"jinja2>=3.1.3,<4",
63+
"watchfiles>=0.24.0,<1.0",
64+
]
65+
66+
# Tracing / observability — what `agentex.lib.core.tracing.*` and
67+
# `agentex.lib.core.observability.*` need. Consumers that only attach the
68+
# SGP/Datadog/OTel tracing processors can pin `agentex-sdk[observability]`.
69+
observability = [
70+
"ddtrace>=3.13.0",
71+
"opentelemetry-api>=1.20.0",
72+
"opentelemetry-sdk>=1.20.0",
73+
"json_log_formatter>=1.1.1",
74+
]
75+
76+
# Full ADK surface — everything under `agentex.lib.*`. Includes [cli] +
77+
# [observability] plus the ACP server, Temporal, Redis streaming, LLM provider
78+
# integrations, and MCP. Required for full agent authoring.
79+
adk = [
80+
"agentex-sdk[cli,observability]",
81+
# ACP server (FastAPI app surface)
82+
"fastapi>=0.115.0",
83+
"starlette>=0.49.1",
84+
"uvicorn>=0.31.1",
85+
"aiohttp>=3.10.10,<4",
86+
# Temporal workflows
87+
"temporalio>=1.26.0,<2",
88+
"cloudpickle>=3.1.1",
89+
# Async streaming infra
90+
"redis>=5.2.0,<8",
91+
# LLM provider integrations
92+
"litellm>=1.83.7,<2",
93+
"openai-agents==0.14.1",
94+
"openai>=2.2,<3", # Required by openai-agents; litellm now supports openai 2.x (issue #13711 resolved: https://github.com/BerriAI/litellm/issues/13711)
95+
"claude-agent-sdk>=0.1.0",
96+
"pydantic-ai-slim>=1.0,<2",
97+
"langgraph-checkpoint>=2.0.0",
98+
"scale-gp>=0.1.0a59",
99+
"scale-gp-beta>=0.2.0",
100+
"mcp>=1.4.1",
101+
]
102+
74103
dev = [
75104
"ruff>=0.3.4",
76105
]

src/agentex/lib/cli/templates/default-langgraph/pyproject.toml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version = "0.1.0"
88
description = "{{ description }}"
99
requires-python = ">=3.12"
1010
dependencies = [
11-
"agentex-sdk",
11+
"agentex-sdk[adk]",
1212
"scale-gp",
1313
"langgraph",
1414
"langchain-openai",

src/agentex/lib/cli/templates/default-langgraph/requirements.txt.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Install agentex-sdk from local path
2-
agentex-sdk
2+
agentex-sdk[adk]
33

44
# Scale GenAI Platform Python SDK
55
scale-gp

src/agentex/lib/cli/templates/default-pydantic-ai/pyproject.toml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version = "0.1.0"
88
description = "{{ description }}"
99
requires-python = ">=3.12"
1010
dependencies = [
11-
"agentex-sdk",
11+
"agentex-sdk[adk]",
1212
"scale-gp",
1313
"pydantic-ai-slim[openai]>=1.0,<2",
1414
"python-dotenv",

src/agentex/lib/cli/templates/default-pydantic-ai/requirements.txt.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Install agentex-sdk from local path
2-
agentex-sdk
2+
agentex-sdk[adk]
33

44
# Scale GenAI Platform Python SDK
55
scale-gp

src/agentex/lib/cli/templates/default/pyproject.toml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version = "0.1.0"
88
description = "{{ description }}"
99
requires-python = ">=3.12"
1010
dependencies = [
11-
"agentex-sdk",
11+
"agentex-sdk[adk]",
1212
"scale-gp",
1313
]
1414

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Install agentex-sdk from local path
2-
agentex-sdk
2+
agentex-sdk[adk]
33

44
# Scale GenAI Platform Python SDK
55
scale-gp

src/agentex/lib/cli/templates/sync-langgraph/pyproject.toml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version = "0.1.0"
88
description = "{{ description }}"
99
requires-python = ">=3.12"
1010
dependencies = [
11-
"agentex-sdk",
11+
"agentex-sdk[adk]",
1212
"scale-gp",
1313
"langgraph",
1414
"langchain-openai",

src/agentex/lib/cli/templates/sync-langgraph/requirements.txt.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Install agentex-sdk from local path
2-
agentex-sdk
2+
agentex-sdk[adk]
33

44
# Scale GenAI Platform Python SDK
55
scale-gp

src/agentex/lib/cli/templates/sync-openai-agents/pyproject.toml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ version = "0.1.0"
88
description = "{{ description }}"
99
requires-python = ">=3.12"
1010
dependencies = [
11-
"agentex-sdk",
11+
"agentex-sdk[adk]",
1212
"scale-gp",
1313
]
1414

0 commit comments

Comments
 (0)