Skip to content

[FEATURE] Implement A2A Artifacts #31

@edenreich

Description

@edenreich

Summary

The A2A server need to have a server so A2A clients can download the artifacts.

An artifacts according to the A2A specification is in the context of a Task. One task can have a list / array of artifacts.

Each artifact have parts which is an array Parts, which could be either a TextPart, DataPart or a FilePart.

Here is the full specification: https://raw.githubusercontent.com/inference-gateway/schemas/refs/heads/main/a2a/a2a-schema.yaml

Let's implement it as a part of the tasks/get when the A2A client is polling the A2A server and allow the client to toggle off or on artifacts - defaulting to toggle off to reduce payload.

Clients will send includeArtifacts: true if they want to see the artifacts from the artifacts server.

In case the Artifacts containing a FilePart with fileUri those Uris should point to the artifacts server so the client can simply download those artifacts on demand. Static Server must listening by default on port 8081 - clients can only download an artifact if they specify the fully qualified URI which is /tmp/artifacts/playwright/<task_id>/<artifacts_id>

Acceptance Criteria

  • There is a new static server allowing clients to download artifacts from /tmp/artifacts/playwright/<task_id>/<artifacts_id>
  • The implementation follows the A2A official specification mentioned above
  • There is an additional attribute in the JSON-RPC payload called includeArtifacts - defaulting to nil pointer, when it's nil or false there would no be artifacts included in the response payload.
  • Artifacts could be TextPart, FilePart or DataPart according to the schema
  • The ADK types are being used - no raw data structure, only structured Go types for type safety when possible
  • It's tested
  • It's documented

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions