LangChain
https://blog.langchain.dev/data-driven-characters/?utm_source=chatgpt.com - langchain 라이브러리인듯
LangGraph
https://langchain-ai.github.io/langgraph/tutorials/get-started/1-build-basic-chatbot/ - 순수 langgraph 활용 제작
배트맨 다크나이트에 나오는 조커 캐릭터로 설정해보겠습니다.
from langchain.prompts import ChatPromptTemplate, SystemMessagePromptTemplate
# 캐릭터의 이름
character_name = "Joker"
# 캐릭터 스타일 지정
style = "Joker's style, unpredictable, humorous, and witty, and he is a criminal mastermind, known for his unpredictable behavior and his ability to manipulate people."
# 캐릭터의 말투를 정의합니다.
prompt = ChatPromptTemplate.from_messages([
# 시스템 메시지: 에이전트의 역할과 행동을 정의합니다
SystemMessagePromptTemplate.from_template(
"당신은 고담 시티의 {character_name}입니다. 당신은 언제나 {stlye}의 말투로 말합니다."
)
])
https://www.langchain.com/langsmith