golem-trigger-agent-moonbit

Triggers fire-and-forget invocations of MoonBit Golem agents via the golem CLI.

1.5k|212|Updated Nov 24, 2023
One-click install
npx skills add https://github.com/golemcloud/golem --skill golem-trigger-agent-moonbit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: golem-trigger-agent-moonbit
Source: https://github.com/golemcloud/golem/tree/main/golem-skills/skills/moonbit/golem-trigger-agent-moonbit
Command: npx skills add https://github.com/golemcloud/golem --skill golem-trigger-agent-moonbit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

When calling a Golem agent, the default invocation blocks until the result returns. This Skill shows how to enqueue a MoonBit agent method call asynchronously so the caller returns immediately without waiting for the result.

Core Features & Use Cases

  • Fire-and-Forget Invocation: Uses golem agent invoke --trigger to enqueue a method call and return only the idempotency key.
  • Idempotency and Scheduling: Supports explicit idempotency keys and --schedule-at for deferred execution at a specific ISO 8601 time.
  • MoonBit Naming Conventions: Documents that method names use snake_case and agent type names use PascalCase, with Rust-style value syntax for arguments.
  • Use Case: Trigger a long-running background job such as start_background_job on a MoonBit agent without blocking the caller, or schedule a daily report to run at a future time.

Quick Start

Ask the AI to trigger a fire-and-forget invocation of a MoonBit Golem agent method, for example triggering 'MyAgent()' start_background_job with a job ID argument.

Frequently Asked Questions about golem-trigger-agent-moonbit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I trigger a Golem agent without waiting for the result?

Run golem agent invoke with the --trigger (or -t) flag, followed by the agent ID and function name. The invocation is enqueued and executed asynchronously, returning only the idempotency key instead of the result.

What is the difference between golem agent invoke and invoke --trigger?

Regular invoke waits for the result, returns the value, and streams agent output. The --trigger variant returns immediately with only the idempotency key, does not stream output, and is meant for fire-and-forget background work.

Can I schedule a Golem agent invocation for a future time?

Yes, combine --trigger with --schedule-at followed by an ISO 8601 datetime such as 2026-03-15T10:30:00Z. The invocation is enqueued and executed by the Golem runtime at the specified time.

How do idempotency keys work with triggered invocations?

Triggered invocations accept an idempotency key via -i or --idempotency-key, with "-" generating one automatically. If the same key is reused, the invocation will not be executed again, preventing duplicate background jobs.

What naming conventions do MoonBit Golem agents use in CLI commands?

Method names use snake_case exactly as written in the MoonBit source, while agent type names use PascalCase matching the struct name. Arguments are passed in Rust syntax, such as records, enums, options, and tuples.