mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
Python: feat(claude): bump claude-agent-sdk to 0.2.87 (#6248)
* feat(claude): bump claude-agent-sdk to 0.2.87 Upgrade claude-agent-sdk dependency from >=0.1.36,<0.1.49 to >=0.2.87,<0.3. Changes: - Bump version pin in pyproject.toml - Add 'xhigh' effort level to ClaudeAgentOptions (Opus 4.7 specific) - Expose new upstream SDK options: skills, session_id, task_budget, include_hook_events, strict_mcp_config, continue_conversation, fork_session - Add TaskBudget type import - Update uv.lock Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * chore: lower claude-agent-sdk floor to >=0.1.36 Keep the lower bound at 0.1.36 since the 0.1→0.2 transition was additive and our code works on older versions as long as new options aren't used. This avoids forcing unnecessary upgrades on existing users. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: replace TaskBudget import with inline type for SDK compat TaskBudget was added in claude-agent-sdk 0.2.93 but does not exist in 0.2.87. Use dict[str, int] inline type instead so type checking passes against 0.2.87. Lock file pinned to 0.2.87. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
Unverified
parent
bad05a2bdc
commit
e89e745bc0
@@ -221,9 +221,31 @@ class ClaudeAgentOptions(TypedDict, total=False):
|
||||
thinking: ThinkingConfig
|
||||
"""Extended thinking configuration (adaptive, enabled, or disabled)."""
|
||||
|
||||
effort: Literal["low", "medium", "high", "max"]
|
||||
effort: Literal["low", "medium", "high", "xhigh", "max"]
|
||||
"""Effort level for thinking depth."""
|
||||
|
||||
skills: list[str] | Literal["all"]
|
||||
"""Skills to enable for the main session. Use ``"all"`` for every discovered skill,
|
||||
a list of named skills, or ``[]`` to suppress all skills."""
|
||||
|
||||
session_id: str
|
||||
"""Use a specific session ID (must be a valid UUID) instead of auto-generated."""
|
||||
|
||||
task_budget: dict[str, int]
|
||||
"""API-side task budget in tokens for pacing tool use."""
|
||||
|
||||
include_hook_events: bool
|
||||
"""When True, hook lifecycle events are emitted in the message stream."""
|
||||
|
||||
strict_mcp_config: bool
|
||||
"""When True, only use MCP servers passed via ``mcp_servers``, ignoring all others."""
|
||||
|
||||
continue_conversation: bool
|
||||
"""Continue the most recent conversation instead of starting a new one."""
|
||||
|
||||
fork_session: bool
|
||||
"""When True, resumed sessions fork to a new session ID."""
|
||||
|
||||
on_function_approval: FunctionApprovalCallback
|
||||
"""Approval callback for ``FunctionTool`` instances declared with
|
||||
``approval_mode="always_require"``. The callback is awaited (sync or async)
|
||||
|
||||
@@ -24,7 +24,7 @@ classifiers = [
|
||||
]
|
||||
dependencies = [
|
||||
"agent-framework-core>=1.6.0,<2",
|
||||
"claude-agent-sdk>=0.1.36,<0.1.49",
|
||||
"claude-agent-sdk>=0.1.36,<0.3",
|
||||
]
|
||||
|
||||
[tool.uv]
|
||||
|
||||
Reference in New Issue
Block a user