The machine configuration is optional. Using higher spec machines will increase the cost of running the task but can also improve the performance of the task if it is CPU or memory bound.

/trigger/heavy-task.ts
export const heavyTask = task({
  id: "heavy-task",
  machine: {
    cpu: 2,
    memory: 4,
  },
  run: async ({ payload, ctx }) => {
    //...
  },
});

Possible configurations

This documentation is coming soon.