NeoGraph 0.16.0
A C++20 Graph Agent Engine Library — LangGraph for C++
Loading...
Searching...
No Matches
neograph::a2a::GraphAgentAdapter Class Reference

Adapt a NeoGraph run to the A2A request/response shape. More...

#include <server.h>

Inheritance diagram for neograph::a2a::GraphAgentAdapter:
[legend]

Public Member Functions

virtual neograph::json build_initial_state (const std::string &user_text) const
 Hook to populate the initial graph state.
 
virtual std::optional< Artifact > build_output_artifact (const neograph::json &output, const std::string &task_id) const
 Optionally promote a graph output into a typed A2A artifact.
 
virtual neograph::json build_resume_value (const Message &message) const
 The value a follow-up message to an INPUT_REQUIRED task resumes the interrupted run with (spec 3.4.3).
 
virtual std::string input_channel () const
 Channel name to write the inbound user text into (default "prompt").
 
virtual std::string output_channel () const
 Channel name to read the agent's text response from (default "response").
 

Detailed Description

Adapt a NeoGraph run to the A2A request/response shape.

Default: drop the inbound text into prompt, run the graph, return the value of response as the agent's text. Subclass / override for domain-specific input/output mapping.

Definition at line 88 of file server.h.

Member Function Documentation

◆ build_initial_state()

virtual neograph::json neograph::a2a::GraphAgentAdapter::build_initial_state ( const std::string &  user_text) const
virtual

Hook to populate the initial graph state.

Default writes the inbound user text to input_channel(). Override to add system prompts, conversation history, etc.

◆ build_resume_value()

virtual neograph::json neograph::a2a::GraphAgentAdapter::build_resume_value ( const Message &  message) const
virtual

The value a follow-up message to an INPUT_REQUIRED task resumes the interrupted run with (spec 3.4.3).

Default: the message's text parts joined with spaces; without text, the first data part's value; otherwise null.


The documentation for this class was generated from the following file: