diff --git a/pyproject.toml b/pyproject.toml index 26c6aba..6a3e4b6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "simplemind-chat" -version = "0.1.6" +version = "0.1.8" description = "A chat interface for AI models using Simplemind." readme = "README.md" requires-python = ">=3.11" diff --git a/simplechat/cli.py b/simplechat/cli.py index 0c99650..0cd1788 100644 --- a/simplechat/cli.py +++ b/simplechat/cli.py @@ -1,8 +1,7 @@ import docopt import re -import sys -import subprocess from typing import Any + import spacy import nltk from spacy.cli import download @@ -109,15 +108,10 @@ class Simplechat: self.conversation.add_plugin(plugin()) def send(self, message: str) -> Any: - # First, ensure the message is added to the conversation self.conversation.add_message(role="user", text=message) + with console.status("[yellow]Thinking...[/yellow]"): + response = self.conversation.send(message) - progress = Progress( - SpinnerColumn(), TextColumn("[yellow]Thinking..."), transient=True - ) - with progress: - progress.add_task("", total=None) - response = self.conversation.send() return response @property @@ -260,14 +254,7 @@ class Simplechat: + memories ) - progress = Progress( - SpinnerColumn(), - TextColumn("[yellow]Summarizing memories..."), - transient=True, - ) - with progress: - progress.add_task("", total=None) - summary_response = self.send(summary_prompt) + summary_response = self.send(summary_prompt) console.print("\n[bold blue]Raw Memories:[/bold blue]") console.print(Markdown(memories))