Skip to content

Commit fb2c9f3

Browse files
committed
Update retrieval chain tests
1 parent edc170b commit fb2c9f3

1 file changed

Lines changed: 64 additions & 71 deletions

File tree

tests/mlmodel_langchain/test_chain.py

Lines changed: 64 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -410,9 +410,9 @@
410410
"response.organization": "nr-test-org",
411411
"response.headers.llmVersion": "2020-10-01",
412412
"response.headers.ratelimitLimitRequests": 10000,
413-
"response.headers.ratelimitLimitTokens": 10000000,
413+
"response.headers.ratelimitLimitTokens": 50000000,
414414
"response.headers.ratelimitRemainingRequests": 9999,
415-
"response.headers.ratelimitRemainingTokens": 9999992,
415+
"response.headers.ratelimitRemainingTokens": 49999975,
416416
"response.headers.ratelimitResetRequests": "6ms",
417417
"response.headers.ratelimitResetTokens": "0s",
418418
"response.usage.total_tokens": 8,
@@ -434,9 +434,9 @@
434434
"response.organization": "nr-test-org",
435435
"response.headers.llmVersion": "2020-10-01",
436436
"response.headers.ratelimitLimitRequests": 10000,
437-
"response.headers.ratelimitLimitTokens": 10000000,
437+
"response.headers.ratelimitLimitTokens": 50000000,
438438
"response.headers.ratelimitRemainingRequests": 9999,
439-
"response.headers.ratelimitRemainingTokens": 9999999,
439+
"response.headers.ratelimitRemainingTokens": 49999975,
440440
"response.headers.ratelimitResetRequests": "6ms",
441441
"response.headers.ratelimitResetTokens": "0s",
442442
"response.usage.total_tokens": 1,
@@ -535,12 +535,12 @@
535535
"response.headers.ratelimitLimitRequests": 10000,
536536
"response.headers.ratelimitLimitTokens": 50000000,
537537
"response.headers.ratelimitRemainingRequests": 9999,
538-
"response.headers.ratelimitRemainingTokens": 49999927,
538+
"response.headers.ratelimitRemainingTokens": 49999975,
539539
"response.headers.ratelimitResetRequests": "6ms",
540540
"response.headers.ratelimitResetTokens": "0s",
541+
"response.usage.completion_tokens": 210,
541542
"response.usage.prompt_tokens": 73,
542-
"response.usage.completion_tokens": 228,
543-
"response.usage.total_tokens": 301,
543+
"response.usage.total_tokens": 283,
544544
"response.number_of_messages": 3,
545545
"response.organization": "nr-test-org",
546546
"span_id": None,
@@ -590,40 +590,36 @@
590590
{
591591
"completion_id": None,
592592
"content": "```html\n"
593-
"1. What is the sum of 5 + 3?\n"
594-
" A) 6\n"
595-
" B) 7\n"
596-
" C) 8\n"
597-
" D) 9\n"
598-
" Answer: B) 7\n"
593+
"1. What is the result of 5 x 3?\n"
594+
" A) 12\n"
595+
" B) 15\n"
596+
" C) 18\n"
597+
" D) 20\n"
599598
"\n"
600-
"2. What is the result of 10 - 3?\n"
601-
" A) 5\n"
602-
" B) 6\n"
603-
" C) 7\n"
604-
" D) 8\n"
605-
" Answer: C) 7\n"
606-
"\n"
607-
"3. What is the product of 4 * 6?\n"
608-
" A) 20\n"
609-
" B) 24\n"
610-
" C) 28\n"
611-
" D) 30\n"
612-
" Answer: B) 24\n"
613-
"\n"
614-
"4. What is the outcome of 15 / 3?\n"
599+
"2. What is the solution to 10 / 2?\n"
615600
" A) 3\n"
616601
" B) 4\n"
617602
" C) 5\n"
618603
" D) 6\n"
619-
" Answer: A) 3\n"
620604
"\n"
621-
"5. What is the value of 8 squared?\n"
622-
" A) 64\n"
623-
" B) 72\n"
624-
" C) 80\n"
625-
" D) 88\n"
626-
" Answer: A) 64\n"
605+
"3. If a rectangle has a length of 8 and a width of 6, what is its area?\n"
606+
" A) 12\n"
607+
" B) 24\n"
608+
" C) 36\n"
609+
" D) 48\n"
610+
"\n"
611+
"4. What is the value of 3 squared?\n"
612+
" A) 6\n"
613+
" B) 8\n"
614+
" C) 9\n"
615+
" D) 12\n"
616+
"\n"
617+
"5. If a store sells a shirt for $20 and a customer buys 3 shirts, how much "
618+
"do they owe?\n"
619+
" A) $40\n"
620+
" B) $50\n"
621+
" C) $60\n"
622+
" D) $70\n"
627623
"```\n",
628624
"id": None,
629625
"request_id": None,
@@ -679,40 +675,37 @@
679675
{
680676
"completion_id": None,
681677
"content": "```html\n"
682-
"1. What is the sum of 5 + 3?\n"
683-
" A) 6\n"
684-
" B) 7\n"
685-
" C) 8\n"
686-
" D) 9\n"
687-
" Answer: B) 7\n"
688-
"\n"
689-
"2. What is the result of 10 - 3?\n"
690-
" A) 5\n"
691-
" B) 6\n"
692-
" C) 7\n"
693-
" D) 8\n"
694-
" Answer: C) 7\n"
695-
"\n"
696-
"3. What is the product of 4 * 6?\n"
697-
" A) 20\n"
698-
" B) 24\n"
699-
" C) 28\n"
700-
" D) 30\n"
701-
" Answer: B) 24\n"
678+
"1. What is the result of 5 x 3?\n"
679+
" A) 12\n"
680+
" B) 15\n"
681+
" C) 18\n"
682+
" D) 20\n"
702683
"\n"
703-
"4. What is the outcome of 15 / 3?\n"
684+
"2. What is the solution to 10 / 2?\n"
704685
" A) 3\n"
705686
" B) 4\n"
706687
" C) 5\n"
707688
" D) 6\n"
708-
" Answer: A) 3\n"
709689
"\n"
710-
"5. What is the value of 8 squared?\n"
711-
" A) 64\n"
712-
" B) 72\n"
713-
" C) 80\n"
714-
" D) 88\n"
715-
" Answer: A) 64\n"
690+
"3. If a rectangle has a length of 8 and a width of 6, what is "
691+
"its area?\n"
692+
" A) 12\n"
693+
" B) 24\n"
694+
" C) 36\n"
695+
" D) 48\n"
696+
"\n"
697+
"4. What is the value of 3 squared?\n"
698+
" A) 6\n"
699+
" B) 8\n"
700+
" C) 9\n"
701+
" D) 12\n"
702+
"\n"
703+
"5. If a store sells a shirt for $20 and a customer buys 3 "
704+
"shirts, how much do they owe?\n"
705+
" A) $40\n"
706+
" B) $50\n"
707+
" C) $60\n"
708+
" D) $70\n"
716709
"```\n",
717710
"id": None,
718711
"ingest_source": "Python",
@@ -767,14 +760,14 @@
767760
"completion_id": None,
768761
"content": "{'input': 'math', 'context': [Document(id='1234', metadata={}, "
769762
"page_content='What is 2 + 4?')], 'answer': '```html\\n1. What "
770-
"is the sum of 5 + 3?\\n A) 6\\n B) 7\\n C) 8\\n D) "
771-
"9\\n Answer: B) 7\\n\\n2. What is the result of 10 - 3?\\n "
772-
"A) 5\\n B) 6\\n C) 7\\n D) 8\\n Answer: C) 7\\n\\n3. "
773-
"What is the product of 4 * 6?\\n A) 20\\n B) 24\\n C) "
774-
"28\\n D) 30\\n Answer: B) 24\\n\\n4. What is the outcome of "
775-
"15 / 3?\\n A) 3\\n B) 4\\n C) 5\\n D) 6\\n Answer: A) "
776-
"3\\n\\n5. What is the value of 8 squared?\\n A) 64\\n B) "
777-
"72\\n C) 80\\n D) 88\\n Answer: A) 64\\n```\\n'}",
763+
"is the result of 5 x 3?\\n A) 12\\n B) 15\\n C) 18\\n "
764+
"D) 20\\n\\n2. What is the solution to 10 / 2?\\n A) 3\\n B) "
765+
"4\\n C) 5\\n D) 6\\n\\n3. If a rectangle has a length of 8 "
766+
"and a width of 6, what is its area?\\n A) 12\\n B) 24\\n "
767+
"C) 36\\n D) 48\\n\\n4. What is the value of 3 squared?\\n "
768+
"A) 6\\n B) 8\\n C) 9\\n D) 12\\n\\n5. If a store sells a "
769+
"shirt for $20 and a customer buys 3 shirts, how much do they "
770+
"owe?\\n A) $40\\n B) $50\\n C) $60\\n D) $70\\n```\\n'}",
778771
"id": None,
779772
"ingest_source": "Python",
780773
"is_response": True,

0 commit comments

Comments
 (0)