order-loop-unawaited-fresh-actor.ts 370 B

12345678
  1. // The same un-awaited loop, but the actor is created INSIDE the body: one fresh actor
  2. // per round, so the instances genuinely coexist. Cue is a stack (repeat=stack), no
  3. // self-arrow — the split is on concurrency, not cardinality.
  4. const topics = await files.glob("*.md");
  5. for (const topic of topics) {
  6. agent("noter").ask<string>(`note ${topic}`);
  7. }
  8. return topics;