Skip to content

Commit 36297a1

Browse files
committed
feat: use /model to print current model
1 parent 6e2ec57 commit 36297a1

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

nanocoder/cli.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,12 +143,14 @@ def _repl(agent: Agent, config: Config):
143143
c = agent.llm.total_completion_tokens
144144
console.print(f"Tokens used this session: [cyan]{p}[/cyan] prompt + [cyan]{c}[/cyan] completion = [bold]{p+c}[/bold] total")
145145
continue
146-
if user_input.startswith("/model "):
146+
if user_input.startswith("/model"):
147147
new_model = user_input[7:].strip()
148148
if new_model:
149149
agent.llm.model = new_model
150150
config.model = new_model
151151
console.print(f"Switched to [cyan]{new_model}[/cyan]")
152+
else:
153+
console.print(f"[yellow]Current model: [cyan]{config.model}[cyan][/yellow]")
152154
continue
153155
if user_input == "/compact":
154156
from .context import estimate_tokens

0 commit comments

Comments
 (0)