Something went wrong. Try again.
Personal fork of prime agent. Mirror of: https://mnemosyne.sigilzero.dev/sigilzero/prime-agent
Something went wrong. Try again.
1234567891011121314151617181920212223242526272829-- A second plugin has its own VM and independent upvalues.local count = 100return { exports = { {name = "count", run = function(input, ctx) count = count + 1 return count end}, {name = "wait", run = function(input, ctx) return ctx.call("wait", input) end}, {name = "busy", run = function(input, ctx) ctx.emit("ready") while true do count = count + 1 end end, mode = "streaming"}, {name = "environment", run = function(input, ctx) return {io = io ~= nil, os = os ~= nil, load = load ~= nil, print = print ~= nil, dofile = dofile ~= nil, debug = debug ~= nil} end}, {name = "retain", run = function(input, ctx) retained = ctx return "saved" end}, {name = "reuse", run = function(input, ctx) return retained.call("wait", input) end} }}