facade-siting-spread-receiver.ts 439 B

12345678
  1. // Boundary probe: `{ ...planner }` — at runtime spreads the agent's own enumerable props
  2. // (the real ask fn ref survives), so `d.ask(seed)` calls the real facade ask. The spread
  3. // type's `ask` property symbol may be synthesized (no facade decl) => potential escape.
  4. const planner = agent("planner");
  5. const seed = await agent("seed").ask<string>("seed");
  6. const d = { ...planner };
  7. const out = await d.ask(`route ${seed}`);
  8. return out;