Skip to content

feat: add GNAP coordinator components for git-native multi-agent coordination#10861

Open
SyedShahmeerAli12 wants to merge 2 commits intodeepset-ai:mainfrom
SyedShahmeerAli12:feat/gnap-coordinator-components
Open

feat: add GNAP coordinator components for git-native multi-agent coordination#10861
SyedShahmeerAli12 wants to merge 2 commits intodeepset-ai:mainfrom
SyedShahmeerAli12:feat/gnap-coordinator-components

Conversation

@SyedShahmeerAli12
Copy link

Summary

Closes #10829

Adds two new Haystack components implementing the GNAP (Git-Native Agent Protocol)
coordination pattern proposed in #10829:

  • GNAPTaskCreator — writes a task as a markdown file into board/todo/ and
    optionally records the transition as a git commit
  • GNAPResultReader — polls board/done/<task_id>.md until a result is written
    by another agent, then returns its content

Both components live in a new haystack/components/coordinators/ module and follow
all existing Haystack conventions: @component decorator, to_dict/from_dict
serialization, and lazy imports via LazyImporter.

Usage example

from haystack.components.coordinators import GNAPTaskCreator, GNAPResultReader

creator = GNAPTaskCreator(board_path="/path/to/board")
reader  = GNAPResultReader(board_path="/path/to/board", timeout=300)

# Pipeline A creates a task
task_id = creator.run(query="Summarize this document", task_spec={"priority":
"high"})["task_id"]

# A parallel agent writes board/done/<task_id>.md ...

# Pipeline B reads the result
output = reader.run(task_id=task_id)["result"]

Test plan

- 8 unit tests for GNAPTaskCreator (file creation, content, git mock, serialization, unique   
IDs)
- 5 unit tests for GNAPResultReader (immediate read, timeout, threaded wait, serialization)   
- All 13 tests pass

…nation

Implements GNAPTaskCreator and GNAPResultReader components as proposed in
issue deepset-ai#10829. These components enable git-native coordination between
parallel Haystack pipelines using a board/todo → board/done task board.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@SyedShahmeerAli12 SyedShahmeerAli12 requested a review from a team as a code owner March 18, 2026 10:06
@SyedShahmeerAli12 SyedShahmeerAli12 requested review from anakin87 and removed request for a team March 18, 2026 10:06
@vercel
Copy link

vercel bot commented Mar 18, 2026

@SyedShahmeerAli12 is attempting to deploy a commit to the deepset Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions bot added topic:tests type:documentation Improvements on the docs labels Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic:tests type:documentation Improvements on the docs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GNAP: git-native coordination for Haystack's multi-agent pipeline workflows

1 participant