mirror of
https://github.com/hanzoai/python-sdk.git
synced 2026-10-23 20:23:00 +00:00
HIP-0300 tools serialize results to JSON text, which flattened images into useless base64-in-text. Add a ToolImage value type + one converter in BaseTool.register: any ToolImage anywhere in a result becomes a real mcp.types.ImageContent block; text-only results stay byte-for-byte JSON. Emitters wired: fs read of image files, browser screenshots (bidi+playwright). This gives hanzo-mcp vision parity with zai-mcp — an agent with native vision (Claude) sees pixels directly, no per-task vision tool needed. Also decomplect the core-package collision that caused this class of bug: hanzo-tools-core shipped a DUPLICATE hanzo_tools/core/ that nondeterministically shadowed canonical hanzo-tools (dropping ToolImage, the sophisticated register, etc. — same shadow class as the 0.3.0 error-reexport gap). Finish the 'merge core into hanzo-tools' refactor: move id_tool into hanzo-tools, make hanzo-tools-core a pure empty metapackage. Now ONE package owns hanzo_tools.core. Versions: hanzo-tools 0.3.2, -core 0.3.1 (shim), -browser 0.5.9, -fs 0.3.4, hanzo-mcp 0.15.12 (floors bumped). Verified: fs read PNG -> [text, image]; fs stat -> [text]; 29 tools intact; 9 tests pass.
34 lines
1.1 KiB
TOML
34 lines
1.1 KiB
TOML
[build-system]
|
|
requires = ["setuptools>=61.0.0", "wheel"]
|
|
build-backend = "setuptools.build_meta"
|
|
|
|
[project]
|
|
name = "hanzo-tools-core"
|
|
version = "0.3.1"
|
|
description = "DEPRECATED: Use hanzo-tools instead. Empty compatibility shim that installs hanzo-tools."
|
|
readme = "README.md"
|
|
requires-python = ">=3.12"
|
|
license = { text = "MIT" }
|
|
authors = [{ name = "Hanzo Industries Inc", email = "[email protected]" }]
|
|
classifiers = [
|
|
"Programming Language :: Python :: 3",
|
|
"License :: OSI Approved :: MIT License",
|
|
"Operating System :: OS Independent",
|
|
]
|
|
keywords = ["hanzo", "tools", "mcp", "ai"]
|
|
# Pure metapackage: ships no modules, only pulls in canonical hanzo-tools.
|
|
# It used to bundle a duplicate hanzo_tools/core/ that SHADOWED hanzo-tools
|
|
# (nondeterministic collision → missing symbols like ToolImage). Canonical
|
|
# hanzo-tools now owns hanzo_tools.core exclusively; this just redirects.
|
|
dependencies = [
|
|
"hanzo-tools>=0.3.2",
|
|
]
|
|
|
|
[project.urls]
|
|
"Homepage" = "https://github.com/hanzoai/python-sdk"
|
|
"Bug Tracker" = "https://github.com/hanzoai/python-sdk/issues"
|
|
|
|
[tool.setuptools]
|
|
# Empty shim — no importable packages or modules of its own.
|
|
py-modules = []
|