Automation foundation model for tiny devices: 2-bit, 8-29 MB, tool calls, ASR, structured extraction and embeddings on phones, wearables, smart homes, robots, cars and microcontrollers.
fix: emit tool description before parameters in build_schema (#79)
rshemetf7b64256ff95
diff --git a/needle/agent/tools.py b/needle/agent/tools.pyindex 2d430e8..03e64da 100644--- a/needle/agent/tools.py+++ b/needle/agent/tools.py@@ -135,9 +135,10 @@ def build_schema(fn: Callable) -> dict:parameters = {"type": "object", "properties": properties}if required:parameters["required"] = required- out = {"name": fn.__name__, "parameters": parameters}+ out = {"name": fn.__name__}if description:out["description"] = description+ out["parameters"] = parametersreturn out