{ lib, fetchFromGitHub, python3Packages, }: python3Packages.buildPythonApplication rec { pname = "haivemind"; version = "0.1.0"; pyproject = true; src = fetchFromGitHub { owner = "dev-boz"; repo = "haivemind"; rev = "ce4a0437d41f57638b71a17e2ff3af524d5a1b6e"; hash = "sha256-x7NM2wHwi11i07jHTL9NgYJkzzlP+tOmJy027itRtWs="; }; build-system = with python3Packages; [ setuptools ]; dependencies = with python3Packages; [ textual ]; patches = [ ./fix-chat-log-race.patch ]; doCheck = false; pythonImportsCheck = [ "haivemind" "haivemind_tui" "haivemind_curses" ]; passthru = { category = "AI Coding Agents"; updateScript = [ "nix-update" "--flake" ".#haivemind" "--version=branch=main" ]; }; meta = with lib; { description = "Multi-model AI consensus, aggregation, and fusion runner for popular AI CLIs"; homepage = "https://github.com/dev-boz/haivemind"; changelog = "https://github.com/dev-boz/haivemind/commits/main"; license = licenses.mit; mainProgram = "haivemind"; platforms = platforms.all; }; }