mirror of
https://github.com/katanemo/plano.git
synced 2026-07-05 15:52:12 +02:00
Merge branch 'main' into adil/agent_format
This commit is contained in:
commit
2cebc0c85f
33 changed files with 1369 additions and 421 deletions
|
|
@ -135,8 +135,9 @@ pub async fn chat(
|
|||
});
|
||||
|
||||
const MAX_MESSAGE_LENGTH: usize = 50;
|
||||
let latest_message_for_log = if latest_message_for_log.len() > MAX_MESSAGE_LENGTH {
|
||||
format!("{}...", &latest_message_for_log[..MAX_MESSAGE_LENGTH])
|
||||
let latest_message_for_log = if latest_message_for_log.chars().count() > MAX_MESSAGE_LENGTH {
|
||||
let truncated: String = latest_message_for_log.chars().take(MAX_MESSAGE_LENGTH).collect();
|
||||
format!("{}...", truncated)
|
||||
} else {
|
||||
latest_message_for_log
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue