NeboAI
NeboAI
စတင်ပါ

လုပ်ဆောင်မှုများ

Activity တစ်ခုသည် လုပ်ငန်းစဉ်၏ အဆင့်တစ်ဆင့် ဖြစ်သည်။ Activity အများစုကို ဝန်ထမ်းက ဆောင်ရွက်သည်- သင်က ရည်ရွယ်ချက်ကို ပြောပြီး ၎င်းက ၎င်း၏ ကျွမ်းကျင်မှုများနှင့် ချိတ်ဆက်မှုများဖြင့် အလုပ်ကို လုပ်သည်။ Type ခြောက်ခုသည် model မပါဘဲ run သောကြောင့် လမ်းကြောင်းပေးမှုနှင့် အချိန်ကိုက်မှု တိကျနေသည်။

Field များ

{
  "id": "draft-reply",
  "label": "Draft the reply",
  "intent": "Draft a reply to the customer message in _watch_payload using the reply-drafting skill.",
  "skills": ["reply-drafting"],
  "requires_tools": ["mail_message_send"],
  "on_error": { "retry": 1, "fallback": "notify_owner" }
}
Fieldမူလတန်ဖိုးအဓိပ္ပာယ်
idမဖြစ်မနေလုပ်ငန်းစဉ်အတွင်း တစ်ခုတည်းသာ ဖြစ်ရမည်။ connections နှင့် data path များတွင် သုံးသည်။
typecustomဝန်ထမ်းအဆင့် သို့မဟုတ် condition၊ loop၊ wait၊ http၊ command၊ decide အနက် တစ်ခု။
intentမရှိဝန်ထမ်း ပြီးမြောက်ရမည့်အရာ။ ဝန်ထမ်းအဆင့်တစ်ခုတွင် intent သို့မဟုတ် steps လိုအပ်သည်။
steps[]ဝါကျတစ်ကြောင်း မလုံလောက်သည့်အခါ အစဉ်လိုက် ညွှန်ကြားချက်များ။
labelမရှိပိုင်ရှင်အား ပြသမည့်အမည်။
skills[]သုံးမည့် ကျွမ်းကျင်မှုများ။ ဤနေရာတွင် ဖော်ပြထားသော စျေးကွက်ကျွမ်းကျင်မှုများကို ဝန်ထမ်းနှင့်အတူ ထည့်သွင်းသည်။
tools[]သတ်မှတ်ထားပါက အဆင့်က သုံးနိုင်သော tool များသာ ဖြစ်သည်။
requires_tools[]အဆင့် ပြီးဆုံးသည်ဟု သတ်မှတ်ရန် အောင်မြင်ရမည့် tool များ။
cmds[]ဤအဆင့်အတွက် အမည်ဖော်ထားသော Plugin command များ။
mcps[]ဤအဆင့်အတွက် အမည်ဖော်ထားသော MCP server များ။
modelမရှိဤအဆင့်အတွက် model id။
paramsမရှိType သတ်မှတ်ထားသော activity များအတွက် parameter များနှင့် ဝန်ထမ်းအဆင့်များအတွက် maxIterations။
min_iterationsမရှိအဆင့် မပြီးဆုံးမီ အနည်းဆုံး model အလှည့်။
token_budgetမရှိ{max}။ ခန့်မှန်းချက်။
on_error{retry: 1, fallback: notify_owner}ပြန်ကြိုးစားမှုများ၊ ထို့နောက် fallback။ ပြန်ကြိုးစားပြီးနောက် မည်သည့်ပျက်ကွက်မှုမဆို run ကို အဆုံးသတ်သည်။

ဝန်ထမ်းအဆင့်များ

ဝန်ထမ်းအဆင့်တစ်ခုသည် ဝန်ထမ်း၏ အလှည့်တစ်ခုအဖြစ် run သည်- ၎င်း၏ persona၊ မှတ်ဉာဏ်နှင့် ချိတ်ဆက်မှုများ သက်ရောက်ပြီး model အလှည့် 50 အထိ သို့မဟုတ် params.maxIterations အထိ သုံးနိုင်သည်။ အစောပိုင်းအဆင့်များ၏ ရလဒ်များကို [Activity 'id' result] block များအဖြစ် ပေးပို့သည်။ emit စာရင်းဖြင့် လုပ်ငန်းစဉ်ကို အဆုံးသတ်သော အဆင့်ကို ထို event များဖြင့် emit_event ကို ခေါ်ရန် ပြောသည်။ Run ကို အဆုံးသတ်ရန် exit tool ကို အမြဲ သုံးနိုင်သည်။

Data context

Type သတ်မှတ်ထားသော activity များသည် object တစ်ခုမှ အစက်ပါ path ဖြင့် တန်ဖိုးများကို ဖတ်သည်- inputs တွင် run ၏ input များ၊ nodes.<id> တွင် ပြီးဆုံးသော activity တစ်ခုစီ၏ output (JSON ဖြစ်ပါက JSON အဖြစ် parse လုပ်ထားသည်) နှင့် item တွင် loop အတွင်းရှိ လက်ရှိ item ပါသည်။ ရှေ့ဆက်မပါသော path သည် inputs ထဲတွင် အရင်ရှာပြီး ထို့နောက် nodes ထဲတွင် ရှာသည်။

condition

{ "id": "large", "type": "condition", "params": { "expression": "inputs.amount >= 500" } }

params.expression မဖြစ်မနေ လိုအပ်သည်။ ၎င်း၏ အထွက်ချိတ်ဆက်မှုများကို True နှင့် False ဟု အမည်တပ်သည်။ params.mode က ၎င်းကို ဖတ်ပုံကို ရွေးသည်-

ModeExpression
expressionမူလတန်ဖိုး။ ==၊ !=၊ >=၊ <=၊ > သို့မဟုတ် < ပါသော path op value၊ နှစ်ဖက်လုံး ဂဏန်းဖြစ်ပါက ဂဏန်းအဖြစ် နှိုင်းယှဉ်သည်။ သို့မဟုတ် path သက်သက်၊ ၎င်း၏တန်ဖိုး truthy ဖြစ်လျှင် true။
existsPath တစ်ခု။ Truthy တန်ဖိုးသို့ resolve ဖြစ်လျှင် true။
containspath contains text သို့မဟုတ် ယခင် output နှင့် တိုက်စစ်သော စာသားသက်သက်။
regexယခင် output နှင့် တိုက်စစ်သော pattern။

loop

{ "id": "each-invoice", "type": "loop", "params": { "source": "nodes.fetch.invoices", "concurrency": 4 } }

params.source သည် စာရင်းတစ်ခု၏ path ဖြစ်သည်။ Each item ဟု အမည်တပ်ထားသော ချိတ်ဆက်မှုသည် body သို့ ဦးတည်ပြီး ၎င်းသည် item တစ်ခုလျှင် တစ်ကြိမ် item သတ်မှတ်ပြီးဖြင့် run သည်။ Done ဟု အမည်တပ်ထားသော ချိတ်ဆက်မှုသည် item အားလုံးပြီးနောက် run သည်။ concurrency မသတ်မှတ်ပါက iteration များ အတူတကွ စတင်သည်။ maxIterations နှင့် batchSize ကိုလည်း လက်ခံသည်။

"connections": [
  { "from": "__trigger__", "to": "fetch" },
  { "from": "fetch", "to": "each-invoice" },
  { "from": "each-invoice", "to": "check", "label": "Each item" },
  { "from": "each-invoice", "to": "report", "label": "Done" }
]

wait၊ http နှင့် command

{ "id": "pause", "type": "wait", "params": { "duration": "5m" } }
{ "id": "status", "type": "http", "params": { "url": "https://status.example.com/api", "method": "GET" } }
{ "id": "export", "type": "command", "params": { "command": "date -u" } }
Typeမဖြစ်မနေအပြုအမူ
waitparams.durations၊ m သို့မဟုတ် h ဖြင့် ကာလတစ်ခု ခေတ္တရပ်သည်။ Wait-until မရှိပါ။ Event တစ်ခုတွင် ပြန်ဆက်ရန် ၎င်းပေါ်တွင် ဒုတိယ လုပ်ငန်းစဉ်တစ်ခုကို trigger လုပ်ပါ။
httpparams.urlတောင်းဆိုချက်ကို ပြုလုပ်သည်။ method၊ headers နှင့် body တို့ မဖြစ်မနေ မဟုတ်ပါ။
commandparams.commandShell command တစ်ခုကို run သည်။ ၎င်း၏ stdout သည် activity ၏ output ဖြစ်သည်။

decide

Decide activity တစ်ခုသည် ယခုအထိ အလုပ်နှင့်ပတ်သက်၍ type သတ်မှတ်ထားသော မေးခွန်းများ မေးပြီး condition တစ်ခုက လမ်းကြောင်းပေးနိုင်သည့် ဖွဲ့စည်းထားသော အဖြေများကို မှတ်တမ်းတင်သည်။

{
  "id": "triage",
  "type": "decide",
  "params": {
    "questions": {
      "urgency": { "type": "score", "instructions": "How urgent is this request?", "criteria": ["low", "normal", "high"] },
      "refund": { "type": "noul", "instructions": "The customer is asking for money back." }
    },
    "default": { "urgency": "normal", "refund": false }
  }
}
မေးခွန်း အမျိုးအစားcriteriaအဖြေ
choiceရွေးချယ်စရာမှ ဖော်ပြချက်သို့ object၊ ရွေးချယ်စရာ 2 မှ 255။choice၊ confidence နှင့် probabilities။
scoreအစဉ်လိုက် အဆင့် 2 မှ 10 စာရင်း။0 (ပထမအဆင့်) မှ အထက်သို့ score နှင့် confidence။
noulမရှိ။noul၊ ဖော်ပြချက် မှန်ကန်နိုင်ခြေ။

nodes.triage.urgency.score >= 1.5 ကဲ့သို့ condition တစ်ခုဖြင့် အဖြေပေါ်တွင် လမ်းကြောင်းပေးပါ။ ဆုံးဖြတ်ချက် မချနိုင်သည့်အခါ params.default က မေးခွန်းတစ်ခုစီအတွက် ဘေးကင်းသော အဖြေကို ပေးသည်။ မူလတန်ဖိုးဖြင့် ဖြေထားသော အဖြေ၏ confidence မှာ 0 ဖြစ်သည်။ မူလတန်ဖိုး မပါသော မေးခွန်းသည် အဖြေ မရသောကြောင့် ၎င်းအပေါ်ရှိ condition များသည် ၎င်းတို့၏ False edge ကို ယူသည်။

Error များ

on_error.retry သည် ပျက်ကွက်သော activity ကို ပြန်ကြိုးစားမည့် အကြိမ်ရေကို သတ်မှတ်သည်။ မူလတန်ဖိုးမှာ 1 ဖြစ်သည်။ နောက်ဆုံးပြန်ကြိုးစားမှုပြီးနောက် run သည် အဆုံးသတ်ပြီး မူလ fallback ဖြစ်သော notify_owner ဖြင့် ပိုင်ရှင်ကို အသိပေးသည်။ Run စတင်သောအခါ Nebo သည် type သတ်မှတ်ထားသော activity တစ်ခုစီ၏ မဖြစ်မနေလိုအပ်သော parameter များကို စစ်ဆေးပြီး မသိသော activity သို့ ညွှန်ပြသော အကိုင်းအခက်ကို ငြင်းပယ်သည်။