NeoGraph 0.16.0
A C++20 Graph Agent Engine Library — LangGraph for C++
Loading...
Searching...
No Matches
native_abi.h
Go to the documentation of this file.
1
17#pragma once
18
19#include <stddef.h>
20#include <stdint.h>
21
22#ifdef __cplusplus
23extern "C" {
24#endif
25
26#define NEOGRAPH_PROGRAM_NATIVE_ABI_V1 UINT32_C(1)
27
28#define NEOGRAPH_PROGRAM_NATIVE_INVOKE_ACCEPTED INT32_C(0)
29#define NEOGRAPH_PROGRAM_NATIVE_INVOKE_REJECTED INT32_C(1)
30
31#define NEOGRAPH_PROGRAM_NATIVE_COMPLETION_SUCCESS UINT32_C(1)
32#define NEOGRAPH_PROGRAM_NATIVE_COMPLETION_FAILURE UINT32_C(2)
33#define NEOGRAPH_PROGRAM_NATIVE_COMPLETION_CANCELLED UINT32_C(3)
34
37 const uint8_t* data;
38 size_t size;
40
48typedef void (*neograph_program_native_release_v1)(void* userdata,
49 const uint8_t* data,
50 size_t size);
51
59 const uint8_t* data;
60 size_t size;
61 void* release_userdata;
64
72 uint32_t abi_version;
73 uint32_t struct_size;
74 void* userdata;
75 int32_t (*is_cancel_requested)(void* userdata);
77
80 uint32_t abi_version;
81 uint32_t struct_size;
82 uint64_t invocation_id;
86
93 uint32_t abi_version;
94 uint32_t struct_size;
95 uint32_t status;
98
99typedef void (*neograph_program_native_completion_v1)(
100 void* completion_userdata,
102
112 void* userdata,
114 neograph_program_native_completion_v1 completion,
115 void* completion_userdata);
116
122typedef void (*neograph_program_native_cancel_v1)(void* userdata, uint64_t invocation_id);
123
131typedef void (*neograph_program_native_destroy_v1)(void* userdata);
132
135 uint32_t abi_version;
136 uint32_t struct_size;
137 void* userdata;
142
143#ifdef __cplusplus
144} // extern "C"
145#endif
void(* neograph_program_native_destroy_v1)(void *userdata)
Releases plugin-owned userdata exactly once after the binding and every accepted invocation have quie...
Definition native_abi.h:131
void(* neograph_program_native_release_v1)(void *userdata, const uint8_t *data, size_t size)
Releases one output allocation.
Definition native_abi.h:48
void(* neograph_program_native_cancel_v1)(void *userdata, uint64_t invocation_id)
Requests cancellation of one accepted invocation; it never frees userdata.
Definition native_abi.h:122
int32_t(* neograph_program_native_invoke_v1)(void *userdata, const neograph_program_native_invoke_request_v1 *request, neograph_program_native_completion_v1 completion, void *completion_userdata)
Starts one invocation.
Definition native_abi.h:111
Versioned plugin binding supplied to the C++ Program registration surface.
Definition native_abi.h:134
Borrowed, non-owning bytes.
Definition native_abi.h:36
A borrowed cancellation view.
Definition native_abi.h:71
Immutable invocation input.
Definition native_abi.h:79
Plugin-owned bytes returned through a completion callback.
Definition native_abi.h:58
One terminal completion.
Definition native_abi.h:92