Adapter
ask receives { sessionId, question, pageContext } and returns { sessionId, answerId, outcome, answer?, citations?, fallback? }. outcome is answered or unanswered.
- An answered result needs answer text. Citations are ids you retrieved. Optional URL and excerpt.
- An unanswered result needs
fallbackand must not include answer text or citations. - Optional
feedbacktakes{ sessionId, answerId, helpful }. It stays on the adapter. There is no public feedback route on the Answers service.
createLocalAdapter is the sample. createByoAdapter(impl) returns your implementation. Hosted ask uses the same result shape.