Vowpal Wabbit
parse_args.h
Go to the documentation of this file.
1 /*
2 Copyright (c) by respective owners including Yahoo!, Microsoft, and
3 individual contributors. All rights reserved. Released under a BSD
4 license as described in the file LICENSE.
5  */
6 #pragma once
7 #include "global_data.h"
8 #include "options.h"
9 
10 // Used in parse_source
12 {
13  bool daemon;
14  bool foreground;
15  size_t port;
16  std::string pid_file;
17  std::string port_file;
18 
19  bool cache;
20  std::vector<std::string> cache_files;
21  bool json;
22  bool dsjson;
23  bool kill_cache;
24  bool compressed;
25 };
26 
27 // trace listener + context need to be passed at initialization to capture all messages.
28 vw& parse_args(VW::config::options_i& options, trace_message_t trace_listener = nullptr, void* trace_context = nullptr);
29 void parse_modules(VW::config::options_i& options, vw& all);
30 void parse_sources(VW::config::options_i& options, vw& all, io_buf& model, bool skipModelLoad = false);
31 
33 
34 std::string spoof_hex_encoded_namespaces(const std::string& arg);
void parse_sources(VW::config::options_i &options, vw &all, io_buf &model, bool skipModelLoad=false)
Definition: parse_args.cc:1551
vw & parse_args(VW::config::options_i &options, trace_message_t trace_listener=nullptr, void *trace_context=nullptr)
Definition: parse_args.cc:1308
std::string port_file
Definition: parse_args.h:17
std::vector< std::string > cache_files
Definition: parse_args.h:20
size_t port
Definition: parse_args.h:15
bool compressed
Definition: parse_args.h:24
LEARNER::base_learner * setup_base(VW::config::options_i &options, vw &all)
Definition: parse_args.cc:1222
bool kill_cache
Definition: parse_args.h:23
bool foreground
Definition: parse_args.h:14
Definition: io_buf.h:54
void parse_modules(VW::config::options_i &options, vw &all)
void(* trace_message_t)(void *context, const std::string &)
std::string spoof_hex_encoded_namespaces(const std::string &arg)
Definition: parse_args.cc:568
std::string pid_file
Definition: parse_args.h:16