feat: add QR login and browser-backed web tools
This commit is contained in:
@@ -416,6 +416,7 @@ async def echo(ctx: "CommandContext") -> None:
|
||||
category="shared",
|
||||
).shared()
|
||||
async def ai(ctx: "CommandContext") -> None:
|
||||
failed = False
|
||||
try:
|
||||
invocation = parse_agent_invocation(ctx.args, ctx.manager.config.ai)
|
||||
turn = await run_agent_turn(
|
||||
@@ -431,6 +432,9 @@ async def ai(ctx: "CommandContext") -> None:
|
||||
ctx.account.ai_sessions.register_response(turn.handle, sent)
|
||||
except Exception:
|
||||
log.exception("AI command failed for message %s", getattr(ctx.message, "id", None))
|
||||
failed = True
|
||||
|
||||
if failed:
|
||||
await _dislike(ctx.message)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user