- overlay.zig: frameless translucent panel (fixed bg + rounded corners, only bubbles scroll), drag handle, hover-to-full-opacity, top-right spawn - chat layout: per-message QLabel bubbles (user purple / agent green / tool steps grey mono), transcript retained across turns, End-conversation resets - agent reply streams into its own growing bubble (re-render per chunk) - basic markdown in all messages: **bold**, *italic*, `code`, HTML-escaped - tool steps truncated to 90 chars, click to expand/collapse - polite autoscroll: pins to bottom unless user scrolled up - letta.zig: streamInfer() — --output-format stream-json, per-event callback (tool calls, returns, reply chunks), full reply still returned for TTS - whisper: --language auto (no more hardcoded English) - fix: stderr_log leak crashing Quit via debug allocator 👾 Generated with [Letta Code](https://letta.com) Co-Authored-By: Letta Code <noreply@letta.com>
69 lines
1.8 KiB
Zig
69 lines
1.8 KiB
Zig
const std = @import("std");
|
|
const configureQtExeRootModule = @import("libqt6zig").configureQtExeRootModule;
|
|
|
|
pub fn build(b: *std.Build) void {
|
|
const target = b.standardTargetOptions(.{});
|
|
const optimize = b.standardOptimizeOption(.{});
|
|
|
|
const qt6zig = b.dependency("libqt6zig", .{
|
|
.target = target,
|
|
.optimize = optimize,
|
|
});
|
|
|
|
// Qt C++ binding libraries we link for the tray daemon.
|
|
const qt_libraries = [_][]const u8{
|
|
"qapplication",
|
|
"qcoreapplication",
|
|
"qguiapplication",
|
|
"qaction",
|
|
"qabstractscrollarea",
|
|
"qabstractslider",
|
|
"qboxlayout",
|
|
"qcursor",
|
|
"qevent",
|
|
"qlabel",
|
|
"qlayout",
|
|
"qobject",
|
|
"qbrush",
|
|
"qcolor",
|
|
"qpoint",
|
|
"qscreen",
|
|
"qscrollarea",
|
|
"qicon",
|
|
"qpainter",
|
|
"qpixmap",
|
|
"qmenu",
|
|
"qrect",
|
|
"qsystemtrayicon",
|
|
"qt6zigthreading",
|
|
"qtextedit",
|
|
"qwidget",
|
|
};
|
|
|
|
const exe = b.addExecutable(.{
|
|
.name = "inferon",
|
|
.root_module = b.createModule(.{
|
|
.root_source_file = b.path("src/main.zig"),
|
|
.target = target,
|
|
.optimize = optimize,
|
|
.link_libc = true,
|
|
.imports = &.{
|
|
.{ .name = "libqt6zig", .module = qt6zig.module("libqt6zig") },
|
|
},
|
|
}),
|
|
});
|
|
|
|
for (qt_libraries) |lib|
|
|
exe.root_module.linkLibrary(qt6zig.artifact(lib));
|
|
|
|
configureQtExeRootModule(b, exe, .{}) catch @panic("Qt configuration failed");
|
|
|
|
b.installArtifact(exe);
|
|
|
|
const run_step = b.step("run", "Run inferon");
|
|
const run_cmd = b.addRunArtifact(exe);
|
|
run_step.dependOn(&run_cmd.step);
|
|
run_cmd.step.dependOn(b.getInstallStep());
|
|
if (b.args) |args| run_cmd.addArgs(args);
|
|
}
|