|
ForestHub SDK 0.1.0
C++14 LLM SDK for PC and embedded platforms
|
Provider implementation that communicates with the ForestHub backend via HTTP. More...
#include <foresthub.hpp>
Public Member Functions | |
| ForestHubProvider (const config::ProviderConfig &cfg, std::shared_ptr< foresthub::core::HttpClient > http_client) | |
| Construct a ForestHub provider from configuration. | |
| core::ProviderID | ProviderId () const override |
| Returns "forest-hub" as the provider identifier. | |
| std::string | Health () const override |
| Check that the remote provider is reachable and responding. | |
| std::shared_ptr< core::ChatResponse > | Chat (const core::ChatRequest &req) override |
| Send a chat completion request to the backend. | |
| bool | SupportsModel (const core::ModelID &model) const override |
| Check if this provider lists the model as supported. | |
Provider implementation that communicates with the ForestHub backend via HTTP.
| foresthub::provider::remote::ForestHubProvider::ForestHubProvider | ( | const config::ProviderConfig & | cfg, |
| std::shared_ptr< foresthub::core::HttpClient > | http_client ) |
Construct a ForestHub provider from configuration.
| cfg | Provider configuration (api_key, base_url, supported_models). |
| http_client | HTTP implementation for API calls. |
|
overridevirtual |
Send a chat completion request to the backend.
| req | Chat request with model, input, and options. |
Implements foresthub::core::LLMClient.
|
overridevirtual |
Check that the remote provider is reachable and responding.
Implements foresthub::core::Provider.
|
overridevirtual |
Check if this provider lists the model as supported.
| model | Model identifier to check. |
Implements foresthub::core::Provider.