Repository navigation
Conversation
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Tehsmash
force-pushed
the
feat/a2acli-collaborate
branch
from
November 20, 2026 13:33
00965bc to
ba6256d
Compare
New `a2acli collaborate` subcommand implementing the Basic Relay model from the A2A collaborative task spec §2.1. Works with any A2A transport. Usage: a2acli collaborate --agent CARD1 --agent CARD2 "initial message" - Pre-flight check: verify every agent declares both required extension URIs (EXTENSION_URI_SHARED_TASK + EXTENSION_URI_COLLABORATIVE_TASK) before opening any connections. - Streams initial message to all agents simultaneously. - Merges streams with select_all; for each event: prints to stdout with agent label prefix, then relays a translated copy to every other agent (echo suppression). Uses return_immediately=true for relay injection. - Caches each agent's context_id/task_id from first Task event for session ID rewriting. - Respects global --timeout. - Supports -o json (JSONL with agent field) and -o text (prefixed lines). Depends on a2a-collab crate for translate_peer_response() and require_collaborative_extensions(). Closes #572. Part of #569. Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
…sion Replace the manual relay loop in run_collaborate_command with CollaborativeSession::new(agents).start(initial_request).await. The relay logic (stream merge, session ID caching, echo suppression, translate_peer_response dispatch) now lives in a2a-collab where it belongs. CLI retains responsibility for: timeout loop, output formatting, and injecting cli.tenant into each client via with_tenant(). Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
Signed-off-by: Sam Betts <1769706+Tehsmash@users.noreply.github.com>
Tehsmash
force-pushed
the
feat/a2acli-collaborate
branch
from
November 20, 2026 16:16
ba6256d to
c325d00
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
New
a2acli collaboratesubcommand implementing the Basic Relay model from spec §2.1.Behavior
--agentreference to its AgentCardrequire_collaborative_extensionson each card — fails fast if any agent missing both required URIsSendMessageRequestfrom parts (same--text-part/--file-part/--data-partflags assend)[agent-name] <rendered-event>(or JSONL withagentfield under-o json)translate_peer_response()+send_message(return_immediately=true)--timeoutChanges
a2acli/Cargo.toml: adda2a-collabdependencya2acli/src/lib.rs:CollaborateCommandstruct,Collaborateenum variant,run_collaborate_command(),resolve_collaborate_parts(),fetch_card_for_reference()All existing 123 tests pass.
Depends on #577. Closes #572. Part of #569.