summaryrefslogtreecommitdiff
path: root/examples/main/main.cpp
diff options
context:
space:
mode:
authorMichael Klimenko <mklimenko29@gmail.com>2024-02-03 12:23:37 +0100
committerGitHub <noreply@github.com>2024-02-03 13:23:37 +0200
commit52bb63c7082c859c3f1dfc527227e6a95b299c7c (patch)
tree16eefdb31b66fd3797383fb877c0f910e3000c7f /examples/main/main.cpp
parent1ec3332ade60aeb1494ace2211cf1a966db6d770 (diff)
refactor : switch to emplace_back to avoid extra object (#5291)
Diffstat (limited to 'examples/main/main.cpp')
-rw-r--r--examples/main/main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/main/main.cpp b/examples/main/main.cpp
index 1c6138d2..0ed4d79f 100644
--- a/examples/main/main.cpp
+++ b/examples/main/main.cpp
@@ -352,12 +352,12 @@ int main(int argc, char ** argv) {
// in instruct mode, we inject a prefix and a suffix to each input by the user
if (params.instruct) {
params.interactive_first = true;
- params.antiprompt.push_back("### Instruction:\n\n");
+ params.antiprompt.emplace_back("### Instruction:\n\n");
}
// similar for chatml mode
else if (params.chatml) {
params.interactive_first = true;
- params.antiprompt.push_back("<|im_start|>user\n");
+ params.antiprompt.emplace_back("<|im_start|>user\n");
}
// enable interactive mode if interactive start is specified