Thuta Learning
ရှာဖွေရန်
IntermediateAIadvanced

Sequential Chains

စိတ်လျှော့ပါ။ ဒီခန်းကို စာအုပ်လိုမဟုတ်ဘဲ စကားပြောသလိုပဲ၊ နားလည်လွယ်အောင် ရှင်းပါမယ်။

Sequential Chains များသည် chain တစ်ခု၏ output ကို နောက် chain တစ်ခု၏ input အဖြစ် အဆင့်ဆင့် ချိတ်ဆက်ပေးသည်။

python
from langchain.chains import SimpleSequentialChain
# Assume first_chain and second_chain are LLMChains

# This chain will run first_chain, take its output,
# and use it as the input for second_chain.
overall_chain = SimpleSequentialChain(chains=[first_chain, second_chain], verbose=True)

# Run the chain with the initial input
final_response = overall_chain.invoke("some input")
You should see
(Chains များကို အဆင့်ဆင့်ချိတ်ဆက်ပြီး ပိုမိုရှုပ်ထွေးသော tasks များကို လုပ်ဆောင်နိုင်သည်)
Sequential Chains | Thuta Learning