diff options
| author | T <t@tjp.lol> | 2026-05-26 20:14:37 -0600 |
|---|---|---|
| committer | T <t@tjp.lol> | 2026-05-27 06:26:36 -0600 |
| commit | 1f0915edbe0213e8bc134922f10933468d35a172 (patch) | |
| tree | 11834769555c7037f3393ef8d98bf5841846144a /libpanto/src/anthropic_messages_json.zig | |
| parent | b788eb05c6d194b91fdc141b6655e61ccaa76ddb (diff) | |
finish lua runtime makeover
- new multi-tool registration via ToolSource
- thread per source-or-standalone-tool
- switched to zig 0.16 Io threading interface
- cli: include `luv` package and run concurrent lua tools via libuv
- one single long-lived lua_State for the whole cli program
Diffstat (limited to 'libpanto/src/anthropic_messages_json.zig')
| -rw-r--r-- | libpanto/src/anthropic_messages_json.zig | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/libpanto/src/anthropic_messages_json.zig b/libpanto/src/anthropic_messages_json.zig index 355b3ce..708ede5 100644 --- a/libpanto/src/anthropic_messages_json.zig +++ b/libpanto/src/anthropic_messages_json.zig @@ -68,11 +68,11 @@ pub fn serializeRequest( while (it.next()) |t| { try s.beginObject(); try s.objectField("name"); - try s.write(t.name); + try s.write(t.decl.name); try s.objectField("description"); - try s.write(t.description); + try s.write(t.decl.description); try s.objectField("input_schema"); - try writeRawJson(&s, t.schema_json); + try writeRawJson(&s, t.decl.schema_json); try s.endObject(); } try s.endArray(); @@ -734,9 +734,11 @@ fn makeStaticTool( schema: []const u8, ) tool_mod.Tool { return .{ - .name = name, - .description = description, - .schema_json = schema, + .decl = .{ + .name = name, + .description = description, + .schema_json = schema, + }, .ctx = &static_tool_ctx_sentinel, .vtable = &StaticToolVT.v, }; |
