voxagent 0.2.1__tar.gz → 0.2.2__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 (59) hide show
  1. {voxagent-0.2.1 → voxagent-0.2.2}/PKG-INFO +1 -1
  2. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/_version.py +1 -1
  3. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/code/agent.py +8 -5
  4. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/code/virtual_fs.py +21 -7
  5. {voxagent-0.2.1 → voxagent-0.2.2}/.gitignore +0 -0
  6. {voxagent-0.2.1 → voxagent-0.2.2}/README.md +0 -0
  7. {voxagent-0.2.1 → voxagent-0.2.2}/examples/README.md +0 -0
  8. {voxagent-0.2.1 → voxagent-0.2.2}/pyproject.toml +0 -0
  9. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/__init__.py +0 -0
  10. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/agent/__init__.py +0 -0
  11. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/agent/abort.py +0 -0
  12. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/agent/core.py +0 -0
  13. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/code/__init__.py +0 -0
  14. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/code/sandbox.py +0 -0
  15. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/code/tool_proxy.py +0 -0
  16. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/mcp/__init__.py +0 -0
  17. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/mcp/manager.py +0 -0
  18. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/mcp/tool.py +0 -0
  19. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/__init__.py +0 -0
  20. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/anthropic.py +0 -0
  21. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/augment.py +0 -0
  22. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/auth.py +0 -0
  23. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/base.py +0 -0
  24. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/chatgpt.py +0 -0
  25. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/claudecode.py +0 -0
  26. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/cli_base.py +0 -0
  27. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/codex.py +0 -0
  28. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/failover.py +0 -0
  29. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/google.py +0 -0
  30. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/groq.py +0 -0
  31. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/ollama.py +0 -0
  32. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/openai.py +0 -0
  33. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/providers/registry.py +0 -0
  34. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/py.typed +0 -0
  35. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/security/__init__.py +0 -0
  36. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/security/events.py +0 -0
  37. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/security/filter.py +0 -0
  38. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/security/registry.py +0 -0
  39. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/session/__init__.py +0 -0
  40. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/session/compaction.py +0 -0
  41. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/session/lock.py +0 -0
  42. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/session/model.py +0 -0
  43. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/session/storage.py +0 -0
  44. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/streaming/__init__.py +0 -0
  45. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/streaming/emitter.py +0 -0
  46. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/streaming/events.py +0 -0
  47. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/subagent/__init__.py +0 -0
  48. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/subagent/context.py +0 -0
  49. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/subagent/definition.py +0 -0
  50. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/__init__.py +0 -0
  51. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/context.py +0 -0
  52. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/decorator.py +0 -0
  53. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/definition.py +0 -0
  54. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/executor.py +0 -0
  55. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/policy.py +0 -0
  56. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/tools/registry.py +0 -0
  57. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/types/__init__.py +0 -0
  58. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/types/messages.py +0 -0
  59. {voxagent-0.2.1 → voxagent-0.2.2}/src/voxagent/types/run.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: voxagent
3
- Version: 0.2.1
3
+ Version: 0.2.2
4
4
  Summary: A lightweight, model-agnostic LLM provider abstraction with streaming and tool support
5
5
  Project-URL: Homepage, https://github.com/lensator/voxagent
6
6
  Project-URL: Documentation, https://github.com/lensator/voxagent#readme
@@ -1,2 +1,2 @@
1
- __version__ = "0.2.1"
1
+ __version__ = "0.2.2"
2
2
  __version_info__ = tuple(int(x) for x in __version__.split("."))
@@ -101,10 +101,15 @@ class CodeModeExecutor:
101
101
  timeout_seconds=config.timeout_seconds,
102
102
  memory_limit_mb=config.memory_limit_mb,
103
103
  )
104
- self.virtual_fs = VirtualFilesystem(tool_registry)
105
-
104
+
106
105
  # Tool proxy for routing calls
107
106
  self._tool_implementations: dict[str, Any] = {}
107
+
108
+ # Create virtual filesystem with call_tool support
109
+ self.virtual_fs = VirtualFilesystem(
110
+ registry=tool_registry,
111
+ tool_caller=self.call_tool,
112
+ )
108
113
 
109
114
  def register_tool_implementation(
110
115
  self,
@@ -127,9 +132,7 @@ class CodeModeExecutor:
127
132
  Returns:
128
133
  Captured output or error message
129
134
  """
130
- # Build globals with virtual filesystem functions only
131
- # Note: call_tool is not passed to sandbox due to pickling constraints
132
- # The LLM should use ls() and read() to explore, then describe what to call
135
+ # Build globals with virtual filesystem functions (ls, read, call_tool)
133
136
  globals_dict = self.virtual_fs.get_sandbox_globals()
134
137
 
135
138
  # Execute in sandbox
@@ -95,11 +95,15 @@ class ToolRegistry:
95
95
  return []
96
96
 
97
97
 
98
+ # Type alias for tool caller function
99
+ ToolCaller = Any # Callable[[str, str, ...], Any]
100
+
101
+
98
102
  class VirtualFilesystem:
99
103
  """Virtual filesystem for tool discovery.
100
-
104
+
101
105
  Provides ls() and read() functions that can be injected into the sandbox.
102
-
106
+
103
107
  Directory structure:
104
108
  tools/
105
109
  ├── __index__.md
@@ -111,9 +115,14 @@ class VirtualFilesystem:
111
115
  ├── __index__.md
112
116
  └── temperature.py
113
117
  """
114
-
115
- def __init__(self, registry: ToolRegistry) -> None:
118
+
119
+ def __init__(
120
+ self,
121
+ registry: ToolRegistry,
122
+ tool_caller: ToolCaller | None = None,
123
+ ) -> None:
116
124
  self._registry = registry
125
+ self._tool_caller = tool_caller
117
126
 
118
127
  def ls(self, path: str) -> list[str]:
119
128
  """List directory contents.
@@ -212,12 +221,17 @@ class VirtualFilesystem:
212
221
 
213
222
  def get_sandbox_globals(self) -> dict[str, Any]:
214
223
  """Get globals dict to inject into sandbox.
215
-
224
+
216
225
  Returns:
217
- Dict with ls and read functions bound to this filesystem
226
+ Dict with ls, read, and call_tool functions bound to this filesystem
218
227
  """
219
- return {
228
+ globals_dict: dict[str, Any] = {
220
229
  "ls": self.ls,
221
230
  "read": self.read,
222
231
  }
223
232
 
233
+ if self._tool_caller is not None:
234
+ globals_dict["call_tool"] = self._tool_caller
235
+
236
+ return globals_dict
237
+
File without changes
File without changes
File without changes
File without changes
File without changes