瀏覽代碼

server : return error on too large embedding input (#7389)

Georgi Gerganov 1 年之前
父節點
當前提交
e932094d58
共有 1 個文件被更改,包括 1 次插入2 次删除
  1. 1 2
      examples/server/server.cpp

+ 1 - 2
examples/server/server.cpp

@@ -1981,8 +1981,7 @@ struct server_context {
                                 slot.state = SLOT_STATE_PROCESSING;
                                 slot.command = SLOT_COMMAND_NONE;
                                 slot.release();
-                                slot.print_timings();
-                                send_final_response(slot);
+                                send_error(slot, "input is too large to process. increase the physical batch size", ERROR_TYPE_SERVER);
                                 continue;
                             }
                         } else {