feat: add OpenAI-compatible AI provider plugin with SSE streaming support
- Implemented the OpenAI-compatible AI provider plugin, including configuration, chat, and chat_stream functionalities. - Added support for SSE streaming and tool calls. - Integrated Boost.JSON for JSON handling. - Created CMake configuration for the plugin. - Added error handling and logging throughout the plugin.
This commit is contained in:
@@ -18,11 +18,11 @@ add_test(NAME dstalk-smoke-test COMMAND dstalk-smoke-test)
|
||||
|
||||
add_executable(dstalk-host-api-test
|
||||
host_api_test.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk-core/src/service_registry.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk_core/src/service_registry.cpp
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-host-api-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/src
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/src
|
||||
)
|
||||
|
||||
target_compile_features(dstalk-host-api-test
|
||||
@@ -41,11 +41,11 @@ add_test(NAME dstalk-host-api-test COMMAND dstalk-host-api-test)
|
||||
|
||||
add_executable(dstalk-event-bus-test
|
||||
event_bus_test.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk-core/src/event_bus.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk_core/src/event_bus.cpp
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-event-bus-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/src
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/src
|
||||
)
|
||||
|
||||
target_compile_features(dstalk-event-bus-test
|
||||
@@ -60,11 +60,11 @@ add_test(NAME dstalk-event-bus-test COMMAND dstalk-event-bus-test)
|
||||
|
||||
add_executable(dstalk-service-registry-test
|
||||
service_registry_test.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk-core/src/service_registry.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk_core/src/service_registry.cpp
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-service-registry-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/src
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/src
|
||||
)
|
||||
|
||||
target_compile_features(dstalk-service-registry-test
|
||||
@@ -95,12 +95,12 @@ add_test(NAME dstalk-context-plugin-test COMMAND dstalk-context-plugin-test)
|
||||
|
||||
add_executable(dstalk-plugin-loader-test
|
||||
plugin_loader_test.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk-core/src/plugin_loader.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk-core/src/boost_json.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk_core/src/plugin_loader.cpp
|
||||
${CMAKE_SOURCE_DIR}/dstalk_core/src/boost_json.cpp
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-plugin-loader-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/src
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/src
|
||||
)
|
||||
|
||||
target_compile_features(dstalk-plugin-loader-test
|
||||
@@ -134,7 +134,7 @@ add_executable(dstalk-anthropic-plugin-test
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-anthropic-plugin-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/include
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/include
|
||||
)
|
||||
|
||||
target_compile_definitions(dstalk-anthropic-plugin-test
|
||||
@@ -161,7 +161,7 @@ add_executable(dstalk-openai-plugin-test
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-openai-plugin-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/include
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/include
|
||||
)
|
||||
|
||||
target_compile_definitions(dstalk-openai-plugin-test
|
||||
@@ -190,7 +190,7 @@ add_executable(dstalk-network-plugin-test
|
||||
)
|
||||
|
||||
target_include_directories(dstalk-network-plugin-test
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk-core/include
|
||||
PRIVATE ${CMAKE_SOURCE_DIR}/dstalk_core/include
|
||||
)
|
||||
|
||||
target_compile_definitions(dstalk-network-plugin-test
|
||||
|
||||
Reference in New Issue
Block a user