mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2026-09-18 16:55:05 +02:00
working
This commit is contained in:
+1
-25
@@ -1,9 +1,3 @@
|
||||
// controller for llama-cli (the "controller" in MVC)
|
||||
//
|
||||
// owns the chat state, drives the view and talks to llama-server through
|
||||
// cli_client; when no --server-base is given it also manages a local
|
||||
// llama-server child process via cli_server
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "common.h"
|
||||
@@ -20,25 +14,6 @@ struct cli_timings {
|
||||
double predicted_per_second = 0.0;
|
||||
};
|
||||
|
||||
struct cli_command_info {
|
||||
std::string usage; // e.g. "/read <file>"
|
||||
std::string description; // e.g. "add a text file"
|
||||
};
|
||||
|
||||
// properties of the connected server, shown on startup
|
||||
struct cli_server_info {
|
||||
std::string build_info;
|
||||
std::string model_name;
|
||||
std::string server_base;
|
||||
bool is_local_server = false; // server is spawned and managed by llama-cli
|
||||
bool has_system_prompt = false;
|
||||
bool has_vision = false;
|
||||
bool has_audio = false;
|
||||
bool has_video = false;
|
||||
|
||||
std::vector<cli_command_info> commands;
|
||||
};
|
||||
|
||||
// set by the SIGINT handler; cleared once the interrupt has been handled
|
||||
extern std::atomic<bool> g_cli_interrupted;
|
||||
|
||||
@@ -52,6 +27,7 @@ struct cli_context {
|
||||
json pending_media = json::array(); // staged multimodal content parts
|
||||
|
||||
// properties of the connected server
|
||||
// will be populated by fetch_server_props()
|
||||
std::string model_name;
|
||||
std::string build_info;
|
||||
bool has_vision = false;
|
||||
|
||||
Reference in New Issue
Block a user