MCPcopy Create free account
hub / github.com/antirez/llama.cpp-deepseek-v4-flash / load_input_file

Method load_input_file

tools/cli/cli.cpp:186–200  ·  view source on GitHub ↗

TODO: support remote files in the future (http, https, etc)

Source from the content-addressed store, hash-verified

184
185 // TODO: support remote files in the future (http, https, etc)
186 std::string load_input_file(const std::string & fname, bool is_media) {
187 std::ifstream file(fname, std::ios::binary);
188 if (!file) {
189 return "";
190 }
191 if (is_media) {
192 raw_buffer buf;
193 buf.assign((std::istreambuf_iterator<char>(file)), std::istreambuf_iterator<char>());
194 input_files.push_back(std::move(buf));
195 return get_media_marker();
196 } else {
197 std::string content((std::istreambuf_iterator<char>(file)), std::istreambuf_iterator<char>());
198 return content;
199 }
200 }
201
202 common_chat_params format_chat() {
203 auto meta = ctx_server.get_meta();

Callers 1

mainFunction · 0.80

Calls 3

get_media_markerFunction · 0.85
assignMethod · 0.80
push_backMethod · 0.45

Tested by

no test coverage detected