agentenv-framework-protocol 0.1.648__tar.gz → 0.1.651__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 (263) hide show
  1. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/PKG-INFO +71 -1
  2. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/README.md +70 -0
  3. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/pyproject.toml +1 -1
  4. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/__init__.py +6 -0
  5. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/__init__.py +2 -0
  6. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_atif_copy.py +44 -9
  7. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_trajectory_log.py +7 -5
  8. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/extensions.py +23 -1
  9. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/framework.py +9 -3
  10. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/agent_env_environment.py +239 -9
  11. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/types.py +2 -0
  12. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_atif_serving.py +94 -0
  13. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_trajectory_log.py +3 -1
  14. agentenv_framework_protocol-0.1.651/tests/test_tool_defers.py +320 -0
  15. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/.gitignore +0 -0
  16. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/LICENSE +0 -0
  17. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/NOTICE +0 -0
  18. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/THIRD_PARTY_NOTICES.md +0 -0
  19. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/__init__.py +0 -0
  20. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/advanced_agent.py +0 -0
  21. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/basic_agent.py +0 -0
  22. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/custom_extensions_agent.py +0 -0
  23. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/multimodal_agent.py +0 -0
  24. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/reference_model.py +0 -0
  25. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/streaming_agent.py +0 -0
  26. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/.gitignore +0 -0
  27. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/Dockerfile +0 -0
  28. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/Dockerfile.dockerignore +0 -0
  29. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/README.md +0 -0
  30. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/data/seed.json +0 -0
  31. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/env.toml +0 -0
  32. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/site.py +0 -0
  33. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/index.html +0 -0
  34. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/package-lock.json +0 -0
  35. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/package.json +0 -0
  36. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/src/main.js +0 -0
  37. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/src/style.css +0 -0
  38. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/examples/website/notes/web/vite.config.js +0 -0
  39. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_media_spool.py +0 -0
  40. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_secrets.py +0 -0
  41. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_snapshot_state.py +0 -0
  42. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_triggers.py +0 -0
  43. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/_turn_index.py +0 -0
  44. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/clock.py +0 -0
  45. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/control_token.py +0 -0
  46. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/peer_agents.py +0 -0
  47. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/proxy.py +0 -0
  48. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/registry.py +0 -0
  49. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/staging.py +0 -0
  50. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/tasks/__init__.py +0 -0
  51. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/a2a_agent/tasks/v1.py +0 -0
  52. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/PROFILE.md +0 -0
  53. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/__init__.py +0 -0
  54. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/__main__.py +0 -0
  55. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/_image_size.py +0 -0
  56. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/adapter.py +0 -0
  57. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/builder.py +0 -0
  58. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/coding.json +0 -0
  59. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/coding.stripped.json +0 -0
  60. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/computer_use.json +0 -0
  61. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/late_result.json +0 -0
  62. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/482405b002a62efa8516c36709a7a100637507670576fa73a20ad5420d55c66f.png +0 -0
  63. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/55c64d0fcd6f9d5f7c828093857e3fdfda68478bb4e9bd24d481ef391c7804e8.heic +0 -0
  64. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/67905ad3cc2dd52b1f5f6a6d2814de0396618b29b4238b9af5207aeb69936e6d.mp4 +0 -0
  65. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/69a8aa01fe5537076d023dd5e9cc4275b39fc0434aa6483a9f58b66ef2f3c896.png +0 -0
  66. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/82e60066a2de261b6653bcdda90d1cb9a7af2f474cecd82e8d371e8384d72315.png +0 -0
  67. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/media/845e91831319e89c4d656bdb80c278ac09a7230d61e5dfd2e1b1fbb436ac8917.pdf +0 -0
  68. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/multi_agent.json +0 -0
  69. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/odd_parts.json +0 -0
  70. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/subagent.json +0 -0
  71. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/fixtures/two_turns.json +0 -0
  72. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/kit.py +0 -0
  73. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/LICENSE +0 -0
  74. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/VENDORED.md +0 -0
  75. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/__init__.py +0 -0
  76. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/agent.py +0 -0
  77. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/content.py +0 -0
  78. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/final_metrics.py +0 -0
  79. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/metrics.py +0 -0
  80. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/observation.py +0 -0
  81. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/observation_result.py +0 -0
  82. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/step.py +0 -0
  83. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/subagent_trajectory_ref.py +0 -0
  84. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/tool_call.py +0 -0
  85. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/models/trajectory.py +0 -0
  86. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/profile.py +0 -0
  87. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/reader.py +0 -0
  88. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/runner.py +0 -0
  89. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/served.py +0 -0
  90. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/atif/validator.py +0 -0
  91. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/client.py +0 -0
  92. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/__init__.py +0 -0
  93. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_declare.py +0 -0
  94. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_desktop.py +0 -0
  95. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_job.py +0 -0
  96. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_linux.py +0 -0
  97. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_load.py +0 -0
  98. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_macos.py +0 -0
  99. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_reaping.py +0 -0
  100. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_session_posix.py +0 -0
  101. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_session_windows.py +0 -0
  102. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_windows.py +0 -0
  103. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_with_fds.py +0 -0
  104. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/_x11.py +0 -0
  105. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/annotate.py +0 -0
  106. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/app.py +0 -0
  107. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/app_data.py +0 -0
  108. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/app_runtime.py +0 -0
  109. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/apps.py +0 -0
  110. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/card.py +0 -0
  111. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/checks.py +0 -0
  112. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/clock.py +0 -0
  113. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/__init__.py +0 -0
  114. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/__main__.py +0 -0
  115. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/checks.py +0 -0
  116. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/client.py +0 -0
  117. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/desk.py +0 -0
  118. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/fixture.py +0 -0
  119. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/mp4.py +0 -0
  120. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/page_fixture.py +0 -0
  121. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/report.py +0 -0
  122. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/conformance/wayland_fixture.py +0 -0
  123. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/dataplane.py +0 -0
  124. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/driver.py +0 -0
  125. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/errors.py +0 -0
  126. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/extensions.py +0 -0
  127. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/frames.py +0 -0
  128. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/keys.py +0 -0
  129. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/launch.py +0 -0
  130. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/manifest.py +0 -0
  131. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/operations.py +0 -0
  132. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/platform.py +0 -0
  133. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/prefix.py +0 -0
  134. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/queue.py +0 -0
  135. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/recording.py +0 -0
  136. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/results.py +0 -0
  137. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/run_install_step.py +0 -0
  138. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/runtime.py +0 -0
  139. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/seed.py +0 -0
  140. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/serve.py +0 -0
  141. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/serve_app.py +0 -0
  142. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/served.py +0 -0
  143. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/session.py +0 -0
  144. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/settings.py +0 -0
  145. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/skill.py +0 -0
  146. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/spaces.py +0 -0
  147. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/svc.py +0 -0
  148. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/computer/tools.py +0 -0
  149. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/errors.py +0 -0
  150. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/manifest.py +0 -0
  151. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/passthrough.py +0 -0
  152. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/preflight.py +0 -0
  153. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/tool_access.py +0 -0
  154. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/tool_client.py +0 -0
  155. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/tool_context.py +0 -0
  156. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/transfers.py +0 -0
  157. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/__init__.py +0 -0
  158. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/clock.py +0 -0
  159. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/conformance.py +0 -0
  160. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/environment.py +0 -0
  161. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/errors.py +0 -0
  162. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/forwarding.py +0 -0
  163. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/readiness.py +0 -0
  164. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/routes.py +0 -0
  165. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website/session.py +0 -0
  166. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/__init__.py +0 -0
  167. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/cdp.py +0 -0
  168. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/contexts.py +0 -0
  169. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/control.py +0 -0
  170. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/data.py +0 -0
  171. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/devtools.py +0 -0
  172. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/environment.py +0 -0
  173. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/log.py +0 -0
  174. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/network.py +0 -0
  175. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/recording.py +0 -0
  176. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/scope.py +0 -0
  177. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/shapes.py +0 -0
  178. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/src/agentenv_protocol/website_browser/stream.py +0 -0
  179. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/atif_cases.py +0 -0
  180. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/computer_fake.py +0 -0
  181. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/conftest.py +0 -0
  182. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/probe_fake.py +0 -0
  183. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_agent.py +0 -0
  184. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_agent_clock.py +0 -0
  185. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_agent_examples.py +0 -0
  186. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_atif_media.py +0 -0
  187. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_atif_prescribe.py +0 -0
  188. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_atif_scrubbing.py +0 -0
  189. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_atif_turns.py +0 -0
  190. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_cdp_config.py +0 -0
  191. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_object_transfers.py +0 -0
  192. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_peer_agents.py +0 -0
  193. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_proxy.py +0 -0
  194. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_a2a_staging.py +0 -0
  195. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_agent_env_environment.py +0 -0
  196. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_builder.py +0 -0
  197. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_fixtures.py +0 -0
  198. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_kit.py +0 -0
  199. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_profile.py +0 -0
  200. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_reader.py +0 -0
  201. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_validator.py +0 -0
  202. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_atif_vendored.py +0 -0
  203. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_cdp.py +0 -0
  204. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_contexts.py +0 -0
  205. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_data.py +0 -0
  206. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_log.py +0 -0
  207. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_network.py +0 -0
  208. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_recording.py +0 -0
  209. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_browser_state.py +0 -0
  210. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_client.py +0 -0
  211. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_app_data.py +0 -0
  212. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_app_server.py +0 -0
  213. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_clock.py +0 -0
  214. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_conformance.py +0 -0
  215. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_conformance_attempts.py +0 -0
  216. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_conformance_checks.py +0 -0
  217. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_conformance_page.py +0 -0
  218. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_conformance_recording.py +0 -0
  219. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_dataplane.py +0 -0
  220. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_declare.py +0 -0
  221. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_driver.py +0 -0
  222. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_driver_keys.py +0 -0
  223. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_extensions.py +0 -0
  224. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_frames.py +0 -0
  225. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_macos.py +0 -0
  226. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_page.py +0 -0
  227. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_queue.py +0 -0
  228. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_recording.py +0 -0
  229. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_recording_annotate.py +0 -0
  230. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_screenshot_delay.py +0 -0
  231. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_seed.py +0 -0
  232. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_serve.py +0 -0
  233. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_served.py +0 -0
  234. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_session_windows.py +0 -0
  235. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_spaces.py +0 -0
  236. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_svc_forward.py +0 -0
  237. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_tool_prefix.py +0 -0
  238. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_computer_windows_driver.py +0 -0
  239. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_control_token.py +0 -0
  240. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_data_objects.py +0 -0
  241. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_devtools_pipe.py +0 -0
  242. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_errors.py +0 -0
  243. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_extension_methods.py +0 -0
  244. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_intake.py +0 -0
  245. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_manifest.py +0 -0
  246. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_preflight.py +0 -0
  247. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_access.py +0 -0
  248. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_annotations.py +0 -0
  249. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_client.py +0 -0
  250. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_context.py +0 -0
  251. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_context_fastmcp.py +0 -0
  252. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_tool_context_injection.py +0 -0
  253. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_usage.py +0 -0
  254. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_usage_models.py +0 -0
  255. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_api.py +0 -0
  256. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_browser.py +0 -0
  257. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_conformance.py +0 -0
  258. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_environment.py +0 -0
  259. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_forwarding.py +0 -0
  260. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_live.py +0 -0
  261. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_mcp.py +0 -0
  262. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_notes_example.py +0 -0
  263. {agentenv_framework_protocol-0.1.648 → agentenv_framework_protocol-0.1.651}/tests/test_website_readiness.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: agentenv-framework-protocol
3
- Version: 0.1.648
3
+ Version: 0.1.651
4
4
  Summary: Open data-plane protocol and server SDK for agent environments.
5
5
  Project-URL: Homepage, https://www.agentenvframework.com
6
6
  Project-URL: Documentation, https://www.agentenvframework.com/docs
@@ -161,6 +161,59 @@ step names it. Steps that name it show and hide it as they do any tool. Steps fo
161
161
  that role's earlier named steps, and a full reset (`role: "*", tools: "*"`) clears all of them, so
162
162
  grant a hidden tool after such steps. Trigger tool actions call it as usual.
163
163
 
164
+ A tool's successful result can ask the gateway to call the same server later, for something the
165
+ server does at a time of its own (a scheduled message posted at its time) that no tool call would
166
+ otherwise mark. Its `_meta` `"agentenv.io/deferredCalls"` (`DEFERRED_CALLS_META_KEY`) is a list of
167
+ `{"key", "at", "call", "report_as"}`: `at` an RFC 3339 instant with an offset, `call` and
168
+ `report_as` each `{"tool", "arguments"}`. The gateway takes the key off the result, so no caller sees
169
+ it, and schedules each entry once per server and `key` (one its server declares again while pending
170
+ or done is ignored). When the gateway clock reaches `at` (its virtual time while armed, wall UTC
171
+ while not) it calls `call.tool` as the role that made the declaring call, as it makes a live call
172
+ (under the consistent mode's lock, its write attributed to it). After a transport failure it calls
173
+ again: five attempts in all, 1, 2, 4 and 8 s apart, each of which first reopens the server's session
174
+ if it must (retrying the connection for about ten seconds), so against a server that stays down the
175
+ call fails about 51 s after its first attempt (as observed). So make that tool idempotent (and
176
+ `hidden_by_default`, as plumbing). Unless the result is an error, the gateway hands its triggers that
177
+ result as that role's call of `report_as.tool` with `report_as.arguments`; a trigger action's own
178
+ call provokes no trigger, and neither does one it declares. `GET /triggers/state` lists each under
179
+ `deferred_calls` (`due` marks one the clock has reached that is still to make, which settle checks
180
+ wait for), and counts the earliest still to make in `next_event_at`. Behind no gateway, or one that
181
+ ignores the key, nothing calls it, so a server still acts by itself once the time has passed (on its
182
+ next read, say).
183
+
184
+ `@tool(..., defers=Defers(call=..., report_as=..., using=...))` builds that declaration for you, and
185
+ the tool returns its reply as before:
186
+
187
+ ```python
188
+ from agentenv_protocol import DeferredCall, Defers, tool
189
+
190
+ @tool(hidden_by_default=True)
191
+ def deliver_reminder(self, reminder_id: str) -> str: ...
192
+
193
+ @tool(defers=Defers(call="deliver_reminder", report_as="send_notification", using="_reminder_delivery"))
194
+ def schedule_reminder(self, event_id: str, remind_at: str) -> str: ...
195
+
196
+ def _reminder_delivery(self, arguments: dict, result) -> DeferredCall | list[DeferredCall] | None:
197
+ if not result.get("ok"):
198
+ return None
199
+ return DeferredCall(key=result["reminder_id"], at=result["remind_at"],
200
+ arguments={"reminder_id": result["reminder_id"]},
201
+ report_arguments={"event_id": arguments["event_id"]})
202
+ ```
203
+
204
+ After each successful call of the registered tool, the SDK calls `self.<using>(arguments, result)`
205
+ with the call's arguments and the tool's result: a JSON text reply parsed to its dict or list, a dict
206
+ as is, a `CallToolResult`'s `structuredContent` or else its text so parsed, anything else as it is.
207
+ Each `DeferredCall` it returns becomes one entry, with the named tools as its `call` and `report_as`;
208
+ `at` is an aware datetime, epoch seconds or an RFC 3339 string with an offset, declared in UTC. The
209
+ reply's content and structured content are unchanged, and the entries join any `_meta` it has. An
210
+ error reply declares nothing, and a declaration that fails (`using` raises, or returns a wrong type,
211
+ an empty key or an `at` without an offset) is logged and left out rather than breaking the reply.
212
+ The method called in process still returns its plain value. The mount raises unless `call` is a
213
+ `hidden_by_default` tool and `report_as` a tool the environment serves (by served name,
214
+ `{environment_name}` resolved), and `using` a plain method; the card lists both tools under the
215
+ tool's `defers`.
216
+
164
217
  `@tool(..., annotations={"readOnlyHint": True}, structured_output=True, meta={...})` lists the tool
165
218
  with MCP `ToolAnnotations`, an output schema and `_meta`, on mcp's FastMCP and on fastmcp alike.
166
219
  `structured_output` follows mcp's FastMCP (None derives an output schema from the return annotation
@@ -1774,6 +1827,23 @@ included:
1774
1827
  served. A sub-agent can gain steps while its task runs, so keep each one's
1775
1828
  latest copy; the page that serves a task's last step, which closes only as the
1776
1829
  task ends, carries them whole.
1830
+ - A task's cursor read may also say what the reader holds, and get only what it
1831
+ lacks:
1832
+ - `header_digest` is the digest of the header it holds (`""` for none). The
1833
+ answer names the header's `header_digest` and leaves `header` out while the
1834
+ two match.
1835
+ - `subagent_cursors` maps each sub-agent's `trajectory_id` to
1836
+ `{after, header_digest}`, the last `step_id` the reader holds of it and its
1837
+ header's digest (`{}` at first). The answer then carries each of the task's
1838
+ sub-agents by its closed steps past its cursor, whether or not the step that
1839
+ started it has closed, and its header, the trajectory without `steps`, only
1840
+ when that changed. A sub-agent with neither is left out, and
1841
+ `subagent_header_digests` names each one's header digest.
1842
+
1843
+ The card lists both fields on the task cursor read. Detect them with
1844
+ `card_request_accepts(get_request, {"task_id", "after", "format",
1845
+ "header_digest", "subagent_cursors"})`, and send them only to a card that
1846
+ takes them. A read naming neither gets the page above.
1777
1847
 
1778
1848
  Every `atif/1` answer names `schema_version` and `profile_version` beside
1779
1849
  `format`. An adapter that raises stops its context's copy, never the turn: the
@@ -90,6 +90,59 @@ step names it. Steps that name it show and hide it as they do any tool. Steps fo
90
90
  that role's earlier named steps, and a full reset (`role: "*", tools: "*"`) clears all of them, so
91
91
  grant a hidden tool after such steps. Trigger tool actions call it as usual.
92
92
 
93
+ A tool's successful result can ask the gateway to call the same server later, for something the
94
+ server does at a time of its own (a scheduled message posted at its time) that no tool call would
95
+ otherwise mark. Its `_meta` `"agentenv.io/deferredCalls"` (`DEFERRED_CALLS_META_KEY`) is a list of
96
+ `{"key", "at", "call", "report_as"}`: `at` an RFC 3339 instant with an offset, `call` and
97
+ `report_as` each `{"tool", "arguments"}`. The gateway takes the key off the result, so no caller sees
98
+ it, and schedules each entry once per server and `key` (one its server declares again while pending
99
+ or done is ignored). When the gateway clock reaches `at` (its virtual time while armed, wall UTC
100
+ while not) it calls `call.tool` as the role that made the declaring call, as it makes a live call
101
+ (under the consistent mode's lock, its write attributed to it). After a transport failure it calls
102
+ again: five attempts in all, 1, 2, 4 and 8 s apart, each of which first reopens the server's session
103
+ if it must (retrying the connection for about ten seconds), so against a server that stays down the
104
+ call fails about 51 s after its first attempt (as observed). So make that tool idempotent (and
105
+ `hidden_by_default`, as plumbing). Unless the result is an error, the gateway hands its triggers that
106
+ result as that role's call of `report_as.tool` with `report_as.arguments`; a trigger action's own
107
+ call provokes no trigger, and neither does one it declares. `GET /triggers/state` lists each under
108
+ `deferred_calls` (`due` marks one the clock has reached that is still to make, which settle checks
109
+ wait for), and counts the earliest still to make in `next_event_at`. Behind no gateway, or one that
110
+ ignores the key, nothing calls it, so a server still acts by itself once the time has passed (on its
111
+ next read, say).
112
+
113
+ `@tool(..., defers=Defers(call=..., report_as=..., using=...))` builds that declaration for you, and
114
+ the tool returns its reply as before:
115
+
116
+ ```python
117
+ from agentenv_protocol import DeferredCall, Defers, tool
118
+
119
+ @tool(hidden_by_default=True)
120
+ def deliver_reminder(self, reminder_id: str) -> str: ...
121
+
122
+ @tool(defers=Defers(call="deliver_reminder", report_as="send_notification", using="_reminder_delivery"))
123
+ def schedule_reminder(self, event_id: str, remind_at: str) -> str: ...
124
+
125
+ def _reminder_delivery(self, arguments: dict, result) -> DeferredCall | list[DeferredCall] | None:
126
+ if not result.get("ok"):
127
+ return None
128
+ return DeferredCall(key=result["reminder_id"], at=result["remind_at"],
129
+ arguments={"reminder_id": result["reminder_id"]},
130
+ report_arguments={"event_id": arguments["event_id"]})
131
+ ```
132
+
133
+ After each successful call of the registered tool, the SDK calls `self.<using>(arguments, result)`
134
+ with the call's arguments and the tool's result: a JSON text reply parsed to its dict or list, a dict
135
+ as is, a `CallToolResult`'s `structuredContent` or else its text so parsed, anything else as it is.
136
+ Each `DeferredCall` it returns becomes one entry, with the named tools as its `call` and `report_as`;
137
+ `at` is an aware datetime, epoch seconds or an RFC 3339 string with an offset, declared in UTC. The
138
+ reply's content and structured content are unchanged, and the entries join any `_meta` it has. An
139
+ error reply declares nothing, and a declaration that fails (`using` raises, or returns a wrong type,
140
+ an empty key or an `at` without an offset) is logged and left out rather than breaking the reply.
141
+ The method called in process still returns its plain value. The mount raises unless `call` is a
142
+ `hidden_by_default` tool and `report_as` a tool the environment serves (by served name,
143
+ `{environment_name}` resolved), and `using` a plain method; the card lists both tools under the
144
+ tool's `defers`.
145
+
93
146
  `@tool(..., annotations={"readOnlyHint": True}, structured_output=True, meta={...})` lists the tool
94
147
  with MCP `ToolAnnotations`, an output schema and `_meta`, on mcp's FastMCP and on fastmcp alike.
95
148
  `structured_output` follows mcp's FastMCP (None derives an output schema from the return annotation
@@ -1703,6 +1756,23 @@ included:
1703
1756
  served. A sub-agent can gain steps while its task runs, so keep each one's
1704
1757
  latest copy; the page that serves a task's last step, which closes only as the
1705
1758
  task ends, carries them whole.
1759
+ - A task's cursor read may also say what the reader holds, and get only what it
1760
+ lacks:
1761
+ - `header_digest` is the digest of the header it holds (`""` for none). The
1762
+ answer names the header's `header_digest` and leaves `header` out while the
1763
+ two match.
1764
+ - `subagent_cursors` maps each sub-agent's `trajectory_id` to
1765
+ `{after, header_digest}`, the last `step_id` the reader holds of it and its
1766
+ header's digest (`{}` at first). The answer then carries each of the task's
1767
+ sub-agents by its closed steps past its cursor, whether or not the step that
1768
+ started it has closed, and its header, the trajectory without `steps`, only
1769
+ when that changed. A sub-agent with neither is left out, and
1770
+ `subagent_header_digests` names each one's header digest.
1771
+
1772
+ The card lists both fields on the task cursor read. Detect them with
1773
+ `card_request_accepts(get_request, {"task_id", "after", "format",
1774
+ "header_digest", "subagent_cursors"})`, and send them only to a card that
1775
+ takes them. A read naming neither gets the page above.
1706
1776
 
1707
1777
  Every `atif/1` answer names `schema_version` and `profile_version` beside
1708
1778
  `format`. An adapter that raises stops its context's copy, never the turn: the
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "agentenv-framework-protocol"
3
- version = "0.1.648"
3
+ version = "0.1.651"
4
4
  description = "Open data-plane protocol and server SDK for agent environments."
5
5
  readme = "README.md"
6
6
  license = "Apache-2.0"
@@ -6,11 +6,14 @@ from .errors import Applied, AgentEnvError
6
6
  from .preflight import intake_fit_check
7
7
  from .tool_client import ToolResult, ToolSession, ToolSessionError
8
8
  from .agent_env_environment import (
9
+ DEFERRED_CALLS_META_KEY,
9
10
  HIDDEN_BY_DEFAULT_META_KEY,
10
11
  AgentEnvApplication,
11
12
  AgentEnvEnvironment,
12
13
  AgentEnvFastMCPApplication,
13
14
  AgentEnvStarletteApplication,
15
+ DeferredCall,
16
+ Defers,
14
17
  ForwardedTool,
15
18
  add_data,
16
19
  agent_skill,
@@ -114,6 +117,9 @@ __all__ = [
114
117
  "ROLE_META_KEY",
115
118
  "SESSION_META_KEY",
116
119
  "HIDDEN_BY_DEFAULT_META_KEY",
120
+ "DEFERRED_CALLS_META_KEY",
121
+ "Defers",
122
+ "DeferredCall",
117
123
  "ROLE_HEADER",
118
124
  "DEFAULT_ROLE",
119
125
  "EnvironmentCapabilities",
@@ -73,6 +73,7 @@ from .extensions import (
73
73
  SnapshotReadObjects,
74
74
  SnapshotUploadedObjects,
75
75
  SnapshotWriteObjects,
76
+ SubagentCursor,
76
77
  TaskEventsTrajectoryRequest,
77
78
  TaskObjectTrajectoryRequest,
78
79
  TaskTrajectoryRequest,
@@ -245,6 +246,7 @@ __all__ = [
245
246
  "SnapshotWriteObjects",
246
247
  "StagingStore",
247
248
  "TaskError",
249
+ "SubagentCursor",
248
250
  "TaskEventsTrajectoryRequest",
249
251
  "TaskObjectTrajectoryRequest",
250
252
  "TaskOutcome",
@@ -6,6 +6,7 @@ from __future__ import annotations
6
6
 
7
7
  import base64
8
8
  import binascii
9
+ import hashlib
9
10
  import json
10
11
  import logging
11
12
  import threading
@@ -13,13 +14,14 @@ import uuid
13
14
  from contextlib import contextmanager
14
15
  from dataclasses import dataclass, field
15
16
  from datetime import datetime, timezone
16
- from typing import Any, Callable, Iterable, Iterator, Sequence
17
+ from typing import Any, Callable, Iterable, Iterator, Mapping, Sequence
17
18
  from urllib.parse import urlsplit, urlunsplit
18
19
 
19
20
  from ..atif import FORMAT, Adapter, AdapterRun, AuxEntry, Media, ServedTurn, TurnContext
20
21
  from ..computer import clock as follower
21
22
  from ..errors import AgentEnvError
22
23
  from . import clock as agent_clock
24
+ from .extensions import SubagentCursor
23
25
  from .tasks.v1 import DataPart, FilePart, TaskError, TextPart, _thaw
24
26
 
25
27
  logger = logging.getLogger(__name__)
@@ -54,13 +56,15 @@ class _Task:
54
56
  @dataclass(frozen=True, slots=True)
55
57
  class AtifPage:
56
58
  """A cursor page of a copy: the closed steps after ``after``, ``next`` the last one's ``step_id``, and the
57
- sub-agents of their tasks."""
59
+ sub-agents of their tasks; the header's digest, and with cursors, each sub-agent's."""
58
60
 
59
61
  header: dict[str, Any] | None
60
62
  subagents: list[dict[str, Any]]
61
63
  steps: list[dict[str, Any]]
62
64
  next: int
63
65
  has_more: bool
66
+ header_digest: str | None = None
67
+ subagent_header_digests: dict[str, str] | None = None
64
68
 
65
69
 
66
70
  class AtifCopy:
@@ -150,12 +154,15 @@ class AtifCopy:
150
154
  page = self._run.page()
151
155
  return None if page is None else self._scrub(page)
152
156
 
153
- def page(self, after: int, max_steps: int, max_bytes: int, *, task_id: str | None = None) -> AtifPage:
157
+ def page(self, after: int, max_steps: int, max_bytes: int, *, task_id: str | None = None,
158
+ subagent_cursors: Mapping[str, SubagentCursor] | None = None) -> AtifPage:
154
159
  """The closed steps after step ``after``, of the whole context or of task ``task_id``, within both budgets; the
155
160
  first is always returned, so one larger than ``max_bytes`` can't stall a reader. With them, the sub-agents of
156
161
  every task they belong to, as far as each is served: a sub-agent can gain steps while its task runs, and the
157
- page that serves a task's last step, which closes only as the task ends, carries them whole. The byte budget
158
- counts what it serves, scrubbed."""
162
+ page that serves a task's last step, which closes only as the task ends, carries them whole. With
163
+ ``subagent_cursors``, instead, each of task ``task_id``'s sub-agents with only its closed steps past its cursor
164
+ and its header only when that changed, whether or not the step that started it has closed. The byte budget
165
+ counts the root steps it serves, scrubbed."""
159
166
  with self._lock:
160
167
  self._check()
161
168
  document = self._run.page()
@@ -182,13 +189,36 @@ class AtifCopy:
182
189
  last = step["step_id"]
183
190
  header = None
184
191
  subagents: list[dict[str, Any]] = []
192
+ sub_digests = None
185
193
  if document is not None:
186
194
  header = self._scrub({key: value for key, value in document.items()
187
195
  if key not in ("steps", "subagent_trajectories")})
188
- subagents = self._scrub([sub for sub in document.get("subagent_trajectories", [])
189
- if sub_tasks.get(sub["trajectory_id"]) in tasks])
190
- return AtifPage(header=header, subagents=subagents, steps=served,
191
- next=last, has_more=len(served) < len(pending))
196
+ subs = document.get("subagent_trajectories", [])
197
+ if subagent_cursors is None:
198
+ subagents = self._scrub([sub for sub in subs if sub_tasks.get(sub["trajectory_id"]) in tasks])
199
+ else:
200
+ subagents, sub_digests = self._subagents_past(
201
+ [sub for sub in subs if sub_tasks.get(sub["trajectory_id"]) == task_id], subagent_cursors)
202
+ return AtifPage(header=header, subagents=subagents, steps=served, next=last,
203
+ has_more=len(served) < len(pending), header_digest=None if header is None else _digest(header),
204
+ subagent_header_digests=sub_digests)
205
+
206
+ def _subagents_past(self, subs: Sequence[dict[str, Any]], cursors: Mapping[str, SubagentCursor]
207
+ ) -> tuple[list[dict[str, Any]], dict[str, str]]:
208
+ """Each sub-agent with what its reader lacks, its closed steps past its cursor and its header if the reader's
209
+ digest is another, left out when it lacks neither; and each one's header digest."""
210
+ served: list[dict[str, Any]] = []
211
+ digests: dict[str, str] = {}
212
+ for sub in subs:
213
+ sub_id = sub["trajectory_id"]
214
+ cursor = cursors.get(sub_id) or SubagentCursor(after=0)
215
+ head = self._scrub({key: value for key, value in sub.items() if key != "steps"})
216
+ digests[sub_id] = digest = _digest(head)
217
+ steps = self._scrub([step for step in sub["steps"] if step["step_id"] > cursor.after])
218
+ changed = digest != cursor.header_digest
219
+ if steps or changed:
220
+ served.append({**(head if changed else {"trajectory_id": sub_id}), "steps": steps})
221
+ return served, digests
192
222
 
193
223
  def _open(self, task_id: str) -> _Task | None:
194
224
  if self._failed is not None:
@@ -220,6 +250,11 @@ class AtifCopy:
220
250
  )
221
251
 
222
252
 
253
+ def _digest(value: Any) -> str:
254
+ """What a reader names to say it holds ``value``: the sha256 of its canonical JSON."""
255
+ return "sha256:" + hashlib.sha256(json.dumps(value, sort_keys=True, separators=(",", ":")).encode()).hexdigest()
256
+
257
+
223
258
  def _real_now() -> datetime:
224
259
  return datetime.now(timezone.utc)
225
260
 
@@ -6,14 +6,14 @@ import json
6
6
  import logging
7
7
  from collections import OrderedDict
8
8
  from dataclasses import dataclass
9
- from typing import Any, Callable, Iterable, Sequence
9
+ from typing import Any, Callable, Iterable, Mapping, Sequence
10
10
 
11
11
  from ..atif import FORMAT as ATIF_FORMAT
12
12
  from ..atif import Adapter
13
13
  from ._atif_copy import AtifCopy, AtifPage, TurnStart
14
14
  from ._media_spool import MediaSpool
15
15
  from ._turn_index import TurnIndex
16
- from .extensions import TrajectoryState
16
+ from .extensions import SubagentCursor, TrajectoryState
17
17
  from .tasks.v1 import TaskError, TrajectoryLog
18
18
 
19
19
  logger = logging.getLogger(__name__)
@@ -320,16 +320,18 @@ class TaskTrajectories:
320
320
  return copy.context_read()
321
321
 
322
322
  def atif_task_page(
323
- self, task_id: str, after: int, max_steps: int, max_bytes: int
323
+ self, task_id: str, after: int, max_steps: int, max_bytes: int, *,
324
+ subagent_cursors: Mapping[str, SubagentCursor] | None = None,
324
325
  ) -> AtifCursor | None:
325
- """A cursor page of the task's closed atif/1 steps, in the task's state."""
326
+ """A cursor page of the task's closed atif/1 steps, in the task's state; with ``subagent_cursors``, its
327
+ sub-agents by what the reader lacks of each (``AtifCopy.page``)."""
326
328
  record = self._tasks.get(task_id)
327
329
  copy = self._copy(record.context_id) if record is not None else None
328
330
  if copy is None:
329
331
  return None
330
332
  self._touch(record.context_id)
331
333
  state = record.state
332
- page = copy.page(after, max_steps, max_bytes, task_id=task_id)
334
+ page = copy.page(after, max_steps, max_bytes, task_id=task_id, subagent_cursors=subagent_cursors)
333
335
  return AtifCursor(page=page, context_id=record.context_id, task_id=task_id, state=state)
334
336
 
335
337
  def atif_context_page(
@@ -276,11 +276,25 @@ class TrajectoryState(str, Enum):
276
276
  MAX_TRAJECTORY_READ_EVENTS = 1_000
277
277
 
278
278
 
279
+ class SubagentCursor(ExtensionRequest):
280
+ """How far a live atif/1 reader holds one sub-agent: its last step's ``step_id``, and its header's digest."""
281
+
282
+ after: StrictInt = Field(ge=0)
283
+ header_digest: str = ""
284
+
285
+
279
286
  class TaskEventsTrajectoryRequest(ExtensionRequest):
287
+ """A cursor read of a task's trajectory from event ``after``. An atif/1 read may also name the digest of the header
288
+ the reader holds (``header_digest``, "" for none), which the answer then leaves out while it's unchanged, and how
289
+ far it holds each sub-agent (``subagent_cursors``, {} at first), which has the answer serve each of the task's
290
+ sub-agents by its new closed steps alone, whether or not the step that started it has closed."""
291
+
280
292
  task_id: str
281
293
  after: StrictInt = Field(ge=0)
282
294
  limit: StrictInt | None = Field(default=None, ge=1, le=MAX_TRAJECTORY_READ_EVENTS)
283
295
  format: TrajectoryFormat | None = None
296
+ header_digest: str | None = None
297
+ subagent_cursors: dict[str, SubagentCursor] | None = None
284
298
 
285
299
 
286
300
  class ContextEventsTrajectoryRequest(ExtensionRequest):
@@ -309,7 +323,13 @@ class AtifEventsResponse(ExtensionResponse):
309
323
  ``subagents`` the embedded sub-agent trajectories of the
310
324
  tasks these steps belong to, as far as each is served, so the page stands alone. A sub-agent can gain steps while
311
325
  its task runs; a reader keeps each sub-agent's latest copy, and the page that serves a task's last step carries
312
- them whole. The last page's header with every page's steps and the latest sub-agents is the document."""
326
+ them whole. The last page's header with every page's steps and the latest sub-agents is the document.
327
+
328
+ A read that named ``header_digest`` gets the header's digest, and the header only when it differs from the one the
329
+ reader holds. A read that named ``subagent_cursors`` gets each of its task's sub-agents with only the closed steps
330
+ past its cursor, and its header (the trajectory without its steps) only when that changed; ``subagent_header_digests``
331
+ then names each one's header digest. The reader's latest header, with every page's steps and each sub-agent's
332
+ latest header and steps, is the document."""
313
333
 
314
334
  context_id: str
315
335
  task_id: str
@@ -322,6 +342,8 @@ class AtifEventsResponse(ExtensionResponse):
322
342
  events: list[Any]
323
343
  next: int
324
344
  has_more: bool
345
+ header_digest: str | None = None
346
+ subagent_header_digests: dict[str, str] | None = None
325
347
 
326
348
 
327
349
  def _opaque_snapshot_objects(
@@ -905,12 +905,16 @@ class _SdkServices:
905
905
  self, request: TaskEventsTrajectoryRequest | ContextEventsTrajectoryRequest
906
906
  ) -> dict[str, Any]:
907
907
  """An atif/1 cursor page: the copy's closed steps after step ``after``, of the task or of
908
- the whole context."""
908
+ the whole context. A task read that names the digest of the header it holds gets the
909
+ header's digest, and the header only when it's another; one that names sub-agent cursors
910
+ gets the task's sub-agents by what it lacks of each, with their header digests."""
909
911
  max_steps = request.limit or MAX_TRAJECTORY_READ_EVENTS
912
+ held = request.header_digest if isinstance(request, TaskEventsTrajectoryRequest) else None
910
913
  try:
911
914
  if isinstance(request, TaskEventsTrajectoryRequest):
912
915
  cursor = self.task_trajectories.atif_task_page(
913
- request.task_id, request.after, max_steps, MAX_TRAJECTORY_READ_BYTES
916
+ request.task_id, request.after, max_steps, MAX_TRAJECTORY_READ_BYTES,
917
+ subagent_cursors=request.subagent_cursors,
914
918
  )
915
919
  unknown = f"Unknown task '{request.task_id}'"
916
920
  else:
@@ -930,11 +934,13 @@ class _SdkServices:
930
934
  task_id=cursor.task_id,
931
935
  state=cursor.state,
932
936
  **_atif_versions(page.header),
933
- header=page.header,
937
+ header=None if held is not None and held == page.header_digest else page.header,
934
938
  subagents=page.subagents,
935
939
  events=page.steps,
936
940
  next=page.next,
937
941
  has_more=page.has_more,
942
+ header_digest=page.header_digest if held is not None else None,
943
+ subagent_header_digests=page.subagent_header_digests,
938
944
  ).model_dump(mode="json", exclude_none=True)
939
945
 
940
946
  async def _atif_document(