agent-framework-core 1.21.0__tar.gz → 1.22.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/PKG-INFO +37 -30
  2. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/README.md +6 -1
  3. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/__init__.py +6 -0
  4. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/__init__.pyi +6 -0
  5. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_agents.py +2 -2
  6. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_compaction.py +3 -5
  7. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_file_access.py +5 -6
  8. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_memory.py +2 -2
  9. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_tool_approval.py +35 -4
  10. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_mcp.py +379 -101
  11. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_serialization.py +9 -3
  12. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_sessions.py +2 -1
  13. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_skills.py +5 -6
  14. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_tools.py +434 -39
  15. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_types.py +620 -87
  16. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_agent.py +34 -26
  17. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_agent_executor.py +1 -1
  18. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_edge.py +2 -1
  19. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_events.py +7 -5
  20. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_executor.py +7 -1
  21. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_functional.py +651 -53
  22. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_runner.py +45 -38
  23. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_typing_utils.py +23 -2
  24. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_viz.py +82 -33
  25. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_workflow.py +12 -5
  26. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_workflow_builder.py +5 -3
  27. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_workflow_executor.py +15 -0
  28. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/observability.py +73 -28
  29. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/security.py +6 -6
  30. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/pyproject.toml +30 -29
  31. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/LICENSE +0 -0
  32. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_agent_hooks.py +0 -0
  33. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_clients.py +0 -0
  34. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_docstrings.py +0 -0
  35. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_evaluation.py +0 -0
  36. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_feature_stage.py +0 -0
  37. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_filesystem.py +0 -0
  38. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/__init__.py +0 -0
  39. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_agent.py +0 -0
  40. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_agent.pyi +0 -0
  41. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_background_agents.py +0 -0
  42. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_file_memory.py +0 -0
  43. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_loop.py +0 -0
  44. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_mode.py +0 -0
  45. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_harness/_todo.py +0 -0
  46. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_in_memory.py +0 -0
  47. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_middleware.py +0 -0
  48. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_settings.py +0 -0
  49. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_telemetry.py +0 -0
  50. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_vector_filters.py +0 -0
  51. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_vectors.py +0 -0
  52. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/__init__.py +0 -0
  53. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_agent_utils.py +0 -0
  54. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_checkpoint.py +0 -0
  55. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_checkpoint_encoding.py +0 -0
  56. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_const.py +0 -0
  57. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_conversation_history.py +0 -0
  58. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_edge_runner.py +0 -0
  59. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_function_executor.py +0 -0
  60. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_message_utils.py +0 -0
  61. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_model_utils.py +0 -0
  62. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_request_info_mixin.py +0 -0
  63. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_runner_context.py +0 -0
  64. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_state.py +0 -0
  65. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_validation.py +0 -0
  66. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/_workflows/_workflow_context.py +0 -0
  67. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/a2a/__init__.py +0 -0
  68. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/a2a/__init__.pyi +0 -0
  69. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/ag_ui/__init__.py +0 -0
  70. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/ag_ui/__init__.pyi +0 -0
  71. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/amazon/__init__.py +0 -0
  72. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/amazon/__init__.pyi +0 -0
  73. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/anthropic/__init__.py +0 -0
  74. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/anthropic/__init__.pyi +0 -0
  75. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/azure/__init__.py +0 -0
  76. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/azure/__init__.pyi +0 -0
  77. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/chatkit/__init__.py +0 -0
  78. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/chatkit/__init__.pyi +0 -0
  79. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/declarative/__init__.py +0 -0
  80. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/declarative/__init__.pyi +0 -0
  81. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/devui/__init__.py +0 -0
  82. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/devui/__init__.pyi +0 -0
  83. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/exceptions.py +0 -0
  84. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/foundry/__init__.py +0 -0
  85. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/foundry/__init__.pyi +0 -0
  86. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/gemini/__init__.py +0 -0
  87. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/gemini/__init__.pyi +0 -0
  88. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/github/__init__.py +0 -0
  89. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/github/__init__.pyi +0 -0
  90. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/google/__init__.py +0 -0
  91. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/google/__init__.pyi +0 -0
  92. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/hyperlight/__init__.py +0 -0
  93. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/lab/__init__.py +0 -0
  94. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/mem0/__init__.py +0 -0
  95. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/mem0/__init__.pyi +0 -0
  96. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/microsoft/__init__.py +0 -0
  97. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/microsoft/__init__.pyi +0 -0
  98. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/mistral/__init__.py +0 -0
  99. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/mistral/__init__.pyi +0 -0
  100. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/monty/__init__.py +0 -0
  101. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/monty/__init__.pyi +0 -0
  102. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/ollama/__init__.py +0 -0
  103. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/ollama/__init__.pyi +0 -0
  104. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/openai/__init__.py +0 -0
  105. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/openai/__init__.pyi +0 -0
  106. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/orchestrations/__init__.py +0 -0
  107. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/orchestrations/__init__.pyi +0 -0
  108. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/py.typed +0 -0
  109. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/redis/__init__.py +0 -0
  110. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/redis/__init__.pyi +0 -0
  111. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/tools/__init__.py +0 -0
  112. {agent_framework_core-1.21.0 → agent_framework_core-1.22.0}/agent_framework/tools/__init__.pyi +0 -0
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.4
1
+ Metadata-Version: 2.5
2
2
  Name: agent-framework-core
3
- Version: 1.21.0
3
+ Version: 1.22.0
4
4
  Summary: Microsoft Agent Framework for building AI Agents with Python. This is the core package that has all the core abstractions and implementations.
5
5
  Author-email: Microsoft <af-support@microsoft.com>
6
6
  Requires-Python: >=3.10
@@ -14,6 +14,7 @@ Classifier: Programming Language :: Python :: 3.11
14
14
  Classifier: Programming Language :: Python :: 3.12
15
15
  Classifier: Programming Language :: Python :: 3.13
16
16
  Classifier: Programming Language :: Python :: 3.14
17
+ Classifier: Programming Language :: Python :: 3.15
17
18
  Classifier: Typing :: Typed
18
19
  License-File: LICENSE
19
20
  Requires-Dist: msgspec>=0.20.0,<0.23
@@ -24,40 +25,41 @@ Requires-Dist: opentelemetry-api>=1.39.0,<2
24
25
  Requires-Dist: pyyaml>=6.0,<7.0
25
26
  Requires-Dist: regex>=2024.11.6
26
27
  Requires-Dist: mcp>=1.24.0,<2 ; extra == "all"
27
- Requires-Dist: agent-framework-a2a>=1.0.0b261002,<2 ; extra == "all"
28
- Requires-Dist: agent-framework-ag-ui>=1.5.1,<2 ; extra == "all"
29
- Requires-Dist: agent-framework-anthropic>=1.0.0b261008,<2 ; extra == "all"
30
- Requires-Dist: agent-framework-azure-ai-search>=1.0.0b261002,<2 ; extra == "all"
31
- Requires-Dist: agent-framework-azure-contentunderstanding>=1.0.0b261008,<2 ; extra == "all"
32
- Requires-Dist: agent-framework-azure-cosmos>=1.0.0b261002,<2 ; extra == "all"
28
+ Requires-Dist: agent-framework-a2a>=1.0.0b261015,<2 ; extra == "all"
29
+ Requires-Dist: agent-framework-ag-ui>=1.6.0,<2 ; extra == "all"
30
+ Requires-Dist: agent-framework-anthropic>=1.0.0b261015,<2 ; extra == "all"
31
+ Requires-Dist: agent-framework-azure-ai-search>=1.0.0b261015,<2 ; extra == "all"
32
+ Requires-Dist: agent-framework-azure-contentunderstanding>=1.0.0b261015,<2 ; extra == "all"
33
+ Requires-Dist: agent-framework-azure-cosmos>=1.0.0b261015,<2 ; extra == "all"
33
34
  Requires-Dist: agent-framework-azurefunctions>=1.0.0b260922,<2 ; extra == "all"
34
- Requires-Dist: agent-framework-bedrock>=1.0.0b261008,<2 ; extra == "all"
35
- Requires-Dist: agent-framework-chatkit>=1.0.0b261002,<2 ; extra == "all"
36
- Requires-Dist: agent-framework-claude>=1.0.0b261002,<2 ; extra == "all"
37
- Requires-Dist: agent-framework-copilotstudio>=1.0.0b261002,<2 ; extra == "all"
38
- Requires-Dist: agent-framework-declarative>=1.2.1,<2 ; extra == "all"
39
- Requires-Dist: agent-framework-devui>=1.0.0b261008,<2 ; extra == "all"
35
+ Requires-Dist: agent-framework-bedrock>=1.0.0b261015,<2 ; extra == "all"
36
+ Requires-Dist: agent-framework-chatkit>=1.0.0b261015,<2 ; extra == "all"
37
+ Requires-Dist: agent-framework-claude>=1.0.0b261015,<2 ; extra == "all"
38
+ Requires-Dist: agent-framework-copilotstudio>=1.0.0b261015,<2 ; extra == "all"
39
+ Requires-Dist: agent-framework-declarative>=1.3.0,<2 ; extra == "all"
40
+ Requires-Dist: agent-framework-devui>=1.0.0b261015,<2 ; extra == "all"
40
41
  Requires-Dist: agent-framework-durabletask>=1.0.0b260922,<2 ; extra == "all"
41
- Requires-Dist: agent-framework-foundry>=1.14.1,<2 ; extra == "all"
42
- Requires-Dist: agent-framework-foundry-hosting>=1.0.0b261008,<2 ; extra == "all"
43
- Requires-Dist: agent-framework-foundry-local>=1.0.0b260730,<2 ; extra == "all"
44
- Requires-Dist: agent-framework-gemini>=1.0.0b261008,<2 ; extra == "all"
45
- Requires-Dist: agent-framework-github-copilot>=2.0.2,<3 ; extra == "all" and ( python_version >= '3.11')
46
- Requires-Dist: agent-framework-hyperlight>=1.0.0b261008,<2 ; extra == "all" and ( python_version < '3.15' and ((sys_platform == 'linux' and platform_machine == 'x86_64') or (sys_platform == 'win32' and platform_machine == 'AMD64')))
47
- Requires-Dist: agent-framework-mem0>=1.0.0b261002,<2 ; extra == "all"
48
- Requires-Dist: agent-framework-mistral>=1.0.0b260918,<2 ; extra == "all"
49
- Requires-Dist: agent-framework-monty>=1.0.0b261008,<2 ; extra == "all"
50
- Requires-Dist: agent-framework-ollama>=1.0.0b261008,<2 ; extra == "all"
51
- Requires-Dist: agent-framework-openai>=1.16.0,<2 ; extra == "all"
52
- Requires-Dist: agent-framework-orchestrations>=1.3.1,<2 ; extra == "all"
53
- Requires-Dist: agent-framework-purview>=1.0.0b261008,<2 ; extra == "all"
54
- Requires-Dist: agent-framework-redis>=1.0.0b261002,<2 ; extra == "all" and ( python_version < '3.15')
55
- Requires-Dist: agent-framework-tools>=1.0.0b261008,<2 ; extra == "all"
42
+ Requires-Dist: agent-framework-foundry>=1.15.0,<2 ; extra == "all"
43
+ Requires-Dist: agent-framework-foundry-hosting>=1.0.0b261015,<2 ; extra == "all"
44
+ Requires-Dist: agent-framework-foundry-local>=1.0.0b261015,<2 ; extra == "all"
45
+ Requires-Dist: agent-framework-gemini>=1.0.0b261015,<2 ; extra == "all"
46
+ Requires-Dist: agent-framework-github-copilot>=2.1.0,<3 ; extra == "all" and ( python_version >= '3.11')
47
+ Requires-Dist: agent-framework-hyperlight>=1.0.0b261015,<2 ; extra == "all" and ( python_version < '3.15' and ((sys_platform == 'linux' and platform_machine == 'x86_64') or (sys_platform == 'win32' and platform_machine == 'AMD64')))
48
+ Requires-Dist: agent-framework-mem0>=1.0.0b261015,<2 ; extra == "all"
49
+ Requires-Dist: agent-framework-mistral>=1.0.0b261015,<2 ; extra == "all"
50
+ Requires-Dist: agent-framework-monty>=1.0.0b261015,<2 ; extra == "all"
51
+ Requires-Dist: agent-framework-ollama>=1.0.0b261015,<2 ; extra == "all"
52
+ Requires-Dist: agent-framework-openai>=1.17.0,<2 ; extra == "all"
53
+ Requires-Dist: agent-framework-orchestrations>=1.3.2,<2 ; extra == "all"
54
+ Requires-Dist: agent-framework-purview>=1.0.0b261015,<2 ; extra == "all"
55
+ Requires-Dist: agent-framework-redis>=1.0.0b261015,<2 ; extra == "all" and ( python_version < '3.15')
56
+ Requires-Dist: agent-framework-tools>=1.0.0b261015,<2 ; extra == "all"
56
57
  Project-URL: homepage, https://aka.ms/agent-framework
57
58
  Project-URL: issues, https://github.com/microsoft/agent-framework/issues
58
59
  Project-URL: release_notes, https://github.com/microsoft/agent-framework/releases?q=tag%3Apython-1&expanded=true
59
60
  Project-URL: source, https://github.com/microsoft/agent-framework/tree/main/python
60
61
  Provides-Extra: all
62
+ Import-Name: agent_framework
61
63
 
62
64
  # Get Started with Microsoft Agent Framework
63
65
 
@@ -83,9 +85,14 @@ pip install agent-framework-openai
83
85
 
84
86
  Supported Platforms:
85
87
 
86
- - Python: 3.10+
88
+ - Python: 3.10–3.15
87
89
  - OS: Windows, macOS, Linux
88
90
 
91
+ Python 3.10 remains supported and tested for this release, but it is deprecated
92
+ because upstream Python 3.10 has reached end of life. New environments should
93
+ use Python 3.11 or later. Removing Python 3.10 support will be handled in a
94
+ future release rather than by this compatibility update.
95
+
89
96
  ## 1. Setup API Keys
90
97
 
91
98
  Depending on the client you want to use, there are various environment variables you can set to configure the chat clients. This can be done in the environment itself, or with a `.env` file in your project root, some examples of environment variables include:
@@ -22,9 +22,14 @@ pip install agent-framework-openai
22
22
 
23
23
  Supported Platforms:
24
24
 
25
- - Python: 3.10+
25
+ - Python: 3.10–3.15
26
26
  - OS: Windows, macOS, Linux
27
27
 
28
+ Python 3.10 remains supported and tested for this release, but it is deprecated
29
+ because upstream Python 3.10 has reached end of life. New environments should
30
+ use Python 3.11 or later. Removing Python 3.10 support will be handled in a
31
+ future release rather than by this compatibility update.
32
+
28
33
  ## 1. Setup API Keys
29
34
 
30
35
  Depending on the client you want to use, there are various environment variables you can set to configure the chat clients. This can be done in the environment itself, or with a `.env` file in your project root, some examples of environment variables include:
@@ -277,12 +277,15 @@ _LAZY_MODULE_EXPORTS: Final[Mapping[str, tuple[str, ...]]] = {
277
277
  "UsageDetails",
278
278
  "add_usage_details",
279
279
  "detect_media_type_from_base64",
280
+ "get_namespaced_value",
280
281
  "map_chat_to_agent_update",
282
+ "merge_additional_properties",
281
283
  "merge_chat_options",
282
284
  "normalize_messages",
283
285
  "normalize_tools",
284
286
  "prepend_instructions_to_messages",
285
287
  "validate_chat_options",
288
+ "with_namespaced_value",
286
289
  "validate_tool_mode",
287
290
  "validate_tools",
288
291
  ),
@@ -696,6 +699,7 @@ __all__ = [
696
699
  "executor",
697
700
  "function_middleware",
698
701
  "get_agent_mode",
702
+ "get_namespaced_value",
699
703
  "get_run_context",
700
704
  "handler",
701
705
  "included_messages",
@@ -703,6 +707,7 @@ __all__ = [
703
707
  "keyword_check",
704
708
  "load_settings",
705
709
  "map_chat_to_agent_update",
710
+ "merge_additional_properties",
706
711
  "merge_chat_options",
707
712
  "normalize_function_invocation_configuration",
708
713
  "normalize_messages",
@@ -727,6 +732,7 @@ __all__ = [
727
732
  "validate_tools",
728
733
  "validate_workflow_graph",
729
734
  "vectorstoremodel",
735
+ "with_namespaced_value",
730
736
  "workflow",
731
737
  ]
732
738
 
@@ -243,7 +243,9 @@ from ._types import (
243
243
  UsageDetails,
244
244
  add_usage_details,
245
245
  detect_media_type_from_base64,
246
+ get_namespaced_value,
246
247
  map_chat_to_agent_update,
248
+ merge_additional_properties,
247
249
  merge_chat_options,
248
250
  normalize_messages,
249
251
  normalize_tools,
@@ -251,6 +253,7 @@ from ._types import (
251
253
  validate_chat_options,
252
254
  validate_tool_mode,
253
255
  validate_tools,
256
+ with_namespaced_value,
254
257
  )
255
258
  from ._vector_filters import Filter, FilterGroup, FilterGroupOperator, FilterOperator, Param
256
259
  from ._vectors import (
@@ -651,6 +654,7 @@ __all__ = [
651
654
  "executor",
652
655
  "function_middleware",
653
656
  "get_agent_mode",
657
+ "get_namespaced_value",
654
658
  "get_run_context",
655
659
  "handler",
656
660
  "included_messages",
@@ -658,6 +662,7 @@ __all__ = [
658
662
  "keyword_check",
659
663
  "load_settings",
660
664
  "map_chat_to_agent_update",
665
+ "merge_additional_properties",
661
666
  "merge_chat_options",
662
667
  "normalize_function_invocation_configuration",
663
668
  "normalize_messages",
@@ -682,5 +687,6 @@ __all__ = [
682
687
  "validate_tools",
683
688
  "validate_workflow_graph",
684
689
  "vectorstoremodel",
690
+ "with_namespaced_value",
685
691
  "workflow",
686
692
  ]
@@ -995,7 +995,7 @@ class RawAgent(BaseAgent, Generic[OptionsCoT]):
995
995
  tokenizer: TokenizerProtocol | None = None,
996
996
  additional_properties: MutableMapping[str, Any] | None = None,
997
997
  ) -> None:
998
- """Initialize a Agent instance.
998
+ """Initialize an Agent instance.
999
999
 
1000
1000
  Args:
1001
1001
  client: The chat client to use for the agent.
@@ -2104,7 +2104,7 @@ class Agent(
2104
2104
  tokenizer: TokenizerProtocol | None = None,
2105
2105
  additional_properties: MutableMapping[str, Any] | None = None,
2106
2106
  ) -> None:
2107
- """Initialize a Agent instance."""
2107
+ """Initialize an Agent instance."""
2108
2108
  super().__init__(
2109
2109
  client=client,
2110
2110
  instructions=instructions,
@@ -1013,11 +1013,9 @@ def _serialize_content(content: Content) -> dict[str, Any]:
1013
1013
  else:
1014
1014
  payload.pop("protected_data", None)
1015
1015
  additional_properties = payload.get("additional_properties")
1016
- if isinstance(additional_properties, dict) and "encrypted_content" in additional_properties:
1017
- typed_properties = cast("dict[str, Any]", additional_properties)
1018
- payload["additional_properties"] = {
1019
- key: value for key, value in typed_properties.items() if key != "encrypted_content"
1020
- }
1016
+ if isinstance(additional_properties, dict) and additional_properties:
1017
+ filtered_properties = _strip_opaque_reasoning_payload(additional_properties)
1018
+ payload["additional_properties"] = filtered_properties or {}
1021
1019
  return payload
1022
1020
 
1023
1021
 
@@ -1961,15 +1961,14 @@ class FileAccessProvider(ContextProvider):
1961
1961
  def _is_local_tool_call(function_call: Content) -> bool:
1962
1962
  """Return whether a function call targets this provider's local tools.
1963
1963
 
1964
- Hosted-tool calls carry a ``server_label`` in their
1965
- ``additional_properties`` and are a separate server-scoped approval
1964
+ Hosted-tool calls set ``hosted=True`` and are a separate server-scoped approval
1966
1965
  boundary that must be passed through untouched (see
1967
1966
  :func:`agent_framework._tools._is_hosted_tool_approval`). These rules
1968
1967
  only ever auto-approve the provider's own local tools, so any call that
1969
- carries a ``server_label`` is rejected even if its name collides with a
1968
+ is hosted is rejected even if its name collides with a
1970
1969
  file-access tool name.
1971
1970
  """
1972
- return not function_call.additional_properties.get("server_label")
1971
+ return not function_call.hosted
1973
1972
 
1974
1973
  @staticmethod
1975
1974
  def read_only_tools_auto_approval_rule(function_call: Content) -> bool:
@@ -1983,7 +1982,7 @@ class FileAccessProvider(ContextProvider):
1983
1982
  the tools that modify it (``file_access_write``, ``file_access_delete``,
1984
1983
  ``file_access_replace``, and ``file_access_replace_lines``).
1985
1984
 
1986
- Hosted-tool calls (those carrying a ``server_label``) are never
1985
+ Hosted-tool calls are never
1987
1986
  auto-approved, even when their name matches a file-access tool, so the
1988
1987
  rule stays scoped to this provider's local tools.
1989
1988
 
@@ -2020,7 +2019,7 @@ class FileAccessProvider(ContextProvider):
2020
2019
  ``file_access_delete``, ``file_access_replace``, and
2021
2020
  ``file_access_replace_lines``).
2022
2021
 
2023
- Hosted-tool calls (those carrying a ``server_label``) are never
2022
+ Hosted-tool calls are never
2024
2023
  auto-approved, even when their name matches a file-access tool, so the
2025
2024
  rule stays scoped to this provider's local tools.
2026
2025
 
@@ -506,10 +506,10 @@ class MemoryTopicRecord:
506
506
  topic = stripped[2:].strip()
507
507
  current_section = None
508
508
  continue
509
- if stripped.startswith("Updated: "):
509
+ if current_section is None and stripped.startswith("Updated: "):
510
510
  updated_at = stripped.removeprefix("Updated: ").strip()
511
511
  continue
512
- if stripped.startswith("Sessions: "):
512
+ if current_section is None and stripped.startswith("Sessions: "):
513
513
  raw_sessions = stripped.removeprefix("Sessions: ").strip()
514
514
  session_ids = (
515
515
  []
@@ -58,9 +58,12 @@ def _serialize_arguments(function_call: Content) -> dict[str, str]:
58
58
 
59
59
 
60
60
  def _server_label(function_call: Content) -> str | None:
61
- """Return the hosted-tool server boundary for a function call, if present."""
62
- value = function_call.additional_properties.get("server_label")
63
- return value if isinstance(value, str) else None
61
+ """Return the hosted-tool server boundary for a function call, if present.
62
+
63
+ Legacy ``additional_properties["server_label"]`` is normalized into first-class
64
+ ``hosted`` and ``server_name`` by Content construction and restoration.
65
+ """
66
+ return function_call.server_name if function_call.hosted else None
64
67
 
65
68
 
66
69
  def _content_from_state(value: Any) -> Content:
@@ -236,6 +239,13 @@ class ToolApprovalState(SerializationMixin):
236
239
  def create_always_approve_tool_response(request: Content, *, reason: str | None = None) -> Content:
237
240
  """Create an approval response that records a standing rule for the whole tool.
238
241
 
242
+ .. warning::
243
+ Standing rules are stored in the supplied :class:`AgentSession` and are
244
+ not tied to the agent or tool instance that created the request. Before
245
+ reusing the session with a different agent or tool set, especially one
246
+ that can load tools from an outside source such as MCP, ensure the rule
247
+ is still appropriate for every matching tool name.
248
+
239
249
  Args:
240
250
  request: The ``function_approval_request`` content to approve.
241
251
 
@@ -250,7 +260,15 @@ def create_always_approve_tool_response(request: Content, *, reason: str | None
250
260
 
251
261
 
252
262
  def create_always_approve_tool_with_arguments_response(request: Content, *, reason: str | None = None) -> Content:
253
- """Create an approval response that records a standing rule for the tool and exact arguments."""
263
+ """Create an approval response that records a standing rule for the tool and exact arguments.
264
+
265
+ .. warning::
266
+ Standing rules are stored in the supplied :class:`AgentSession` and are
267
+ not tied to the agent or tool instance that created the request. Before
268
+ reusing the session with a different agent or tool set, especially one
269
+ that can load tools from an outside source such as MCP, ensure the rule
270
+ is still appropriate for every matching tool name and argument set.
271
+ """
254
272
  return _create_always_approve_response(request, ALWAYS_APPROVE_TOOL_WITH_ARGUMENTS, reason=reason)
255
273
 
256
274
 
@@ -364,6 +382,19 @@ class ToolApprovalMiddleware(AgentMiddleware):
364
382
  This middleware is opt-in and requires callers to run the agent with an
365
383
  :class:`AgentSession`, because approval rules and queued requests are stored
366
384
  in session state.
385
+
386
+ .. warning::
387
+ **Security.** Standing approval rules persist in the supplied session
388
+ and are not tied to the agent or tool instance that recorded them.
389
+ Reusing the session with a different or rebuilt agent, or with a changed
390
+ tool set, can let another tool with the same name match an earlier rule.
391
+ This is especially important when tools can come from an outside source
392
+ such as MCP. Before passing such a session to the agent, ensure its
393
+ standing approvals are still valid for all tools the agent can use. A
394
+ changed tool does not always require a new approval. For example, an
395
+ upgraded agent may use an improved version of a tool for which the old
396
+ approval is still appropriate. The developer must decide whether each
397
+ standing approval should carry over to the changed tool.
367
398
  """
368
399
 
369
400
  def __init__(