Skip to content
Snippets Groups Projects

Create initial Tanuki bot api endpoint

Merged Terri Chu requested to merge tchu-bot-create-new-api into master
1 file
+ 4
4
Compare changes
  • Side-by-side
  • Inline
@@ -149,12 +149,12 @@
it 'calls the completions API once for each document and once for summarizing' do
expect(openai_client).to receive(:completions)
.with(hash_including(prompt: /see if any of the text is relevant to answer the question/))
.and_return(completion_response).twice
.with(hash_including(prompt: /see if any of the text is relevant to answer the question/))
.and_return(completion_response).twice
expect(openai_client).to receive(:completions)
.with(hash_including(prompt: /create a final answer with references/))
.and_return(completion_response).once
.with(hash_including(prompt: /create a final answer with references/))
.and_return(completion_response).once
execute
end
Loading