Error Occurs When Using Service Method Inside Another Service

I have to admit that I'm a bit puzzled about this error. It happens just by using this service inside another service:
const aiResponse = yield* aiTools.processQuestion(chatId, message.body);

Requesting the service doesn't make this happen, it's just when using that method.
However, I was able to use it no problem in a scratch file, providing the required AI model at the end:
const runable = Effect
  .gen(function*() {
    const claude = yield* AnthropicCompletions.model('claude-3-5-haiku-latest');
    yield* claude.provide(program);
  })
Screenshot_2025-05-10_at_12.08.49.png
Was this page helpful?