Turi Create
4.0
|
#include <model_server/lib/toolkit_function_specification.hpp>
Public Attributes | |
std::string | name |
variant_map_type | default_options |
std::map< std::string, flexible_type > | description |
std::function< toolkit_function_response_type(toolkit_function_invocation &)> | toolkit_execute_function |
std::function< variant_type(const std::vector< variant_type > &invoke)> | native_execute_function |
Each toolkit is specified by filling in toolkit_function_specification struct. The contents of the struct describe user-facing documentation and default options, as well as a callback to actual toolkit execution.
Definition at line 21 of file toolkit_function_specification.hpp.
variant_map_type turi::toolkit_function_specification::default_options |
A list of required configurable parameters and their default values.
Definition at line 31 of file toolkit_function_specification.hpp.
std::map<std::string, flexible_type> turi::toolkit_function_specification::description |
Toolkit properties. The following keys are recognized:
Definition at line 41 of file toolkit_function_specification.hpp.
std::string turi::toolkit_function_specification::name |
A short name used to identify this toolkit. For instance, LDA, or PageRank.
Definition at line 26 of file toolkit_function_specification.hpp.
std::function<variant_type(const std::vector<variant_type>& invoke)> turi::toolkit_function_specification::native_execute_function |
A pointer to a simple version of the toolkit execution function which can be executed natively without a toolkit_function_invocation. It will not have some of the error management/reporting capabilities of the invocation object, and does not have named parameters. But it is much simpler.
Definition at line 58 of file toolkit_function_specification.hpp.
std::function<toolkit_function_response_type(toolkit_function_invocation&)> turi::toolkit_function_specification::toolkit_execute_function |
A pointer to the actual execution function. All parameters to the execution are passed in the toolkit_function_invocation struct. Returns an std::pair<bool, options_map> with status results.
Definition at line 50 of file toolkit_function_specification.hpp.