diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/main.zig | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/src/main.zig b/src/main.zig index 7f7c16a..89c0bc4 100644 --- a/src/main.zig +++ b/src/main.zig @@ -32,6 +32,41 @@ pub fn main() !void { .messages = &[_]struct { role: []const u8, content: []const u8 }{ .{ .role = "user", .content = prompt_str }, }, + .tools = &[_]struct { + type: []const u8, + function: struct { + name: []const u8, + description: []const u8, + parameters: struct { + type: []const u8, + properties: struct { + file_path: struct { + type: []const u8, + description: []const u8, + }, + }, + required: []const []const u8, + }, + }, + }{ + .{ + .type = "function", + .function = .{ + .name = "Read", + .description = "Read and return the contents of a file", + .parameters = .{ + .type = "object", + .properties = .{ + .file_path = .{ + .type = "string", + .description = "The path to the file to read", + }, + }, + .required = &[_][]const u8{"file_path"}, + }, + }, + }, + }, }); const body = body_out.written(); |