Shared MoonBit process foundation for JSONL agent CLIs
let result = @agent_cli.run(
@agent_cli.Invocation::new(
command="agent",
arguments=["run", "--format", "json"],
input="Hello",
),
async fn(line) {
println(line.value.stringify())
true
},
)fn Invocation::new(command~ : String, arguments~ : Array[String], input~ : String, environment? : Map[String, String], inherit_environment? : Bool) -> Invocation