mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-02 03:55:55 +00:00
27 lines
603 B
Python
27 lines
603 B
Python
from ..aamgr import AbstractCommandNode, Context
|
|
|
|
|
|
@AbstractCommandNode.register(
|
|
parent=None,
|
|
name="continue",
|
|
description="继续未完成的响应",
|
|
usage="!continue",
|
|
aliases=[],
|
|
privilege=1
|
|
)
|
|
class ContinueCommand(AbstractCommandNode):
|
|
@classmethod
|
|
def process(cls, ctx: Context) -> tuple[bool, list]:
|
|
import pkg.openai.session
|
|
import config
|
|
session_name = ctx.session_name
|
|
|
|
reply = []
|
|
|
|
session = pkg.openai.session.get_session(session_name)
|
|
|
|
text = session.append()
|
|
|
|
reply = [text]
|
|
|
|
return True, reply |