diff --git a/content/LangChain for LLM Application Development/6.评估.ipynb b/content/LangChain for LLM Application Development/6.评估.ipynb index 1125634..4601453 100644 --- a/content/LangChain for LLM Application Development/6.评估.ipynb +++ b/content/LangChain for LLM Application Development/6.评估.ipynb @@ -5,9 +5,7 @@ "id": "52824b89-532a-4e54-87e9-1410813cd39e", "metadata": {}, "source": [ - "# 6. 评估\n", - "\n", - "
| \n", + " | 0 | \n", + "1 | \n", + "
|---|---|---|
| 0 | \n", + "product_name | \n", + "description | \n", + "
| 1 | \n", + "全自动咖啡机 | \n", + "规格:\\n大型 - 尺寸:13.8'' x 17.3''。\\n中型 - 尺寸:11.5'' ... | \n", + "
| 2 | \n", + "电动牙刷 | \n", + "规格:\\n一般大小 - 高度:9.5'',宽度:1''。\\n\\n为什么我们热爱它:\\n我们的... | \n", + "
| 3 | \n", + "橙味维生素C泡腾片 | \n", + "规格:\\n每盒含有20片。\\n\\n为什么我们热爱它:\\n我们的橙味维生素C泡腾片是快速补充维... | \n", + "
| 4 | \n", + "无线蓝牙耳机 | \n", + "规格:\\n单个耳机尺寸:1.5'' x 1.3''。\\n\\n为什么我们热爱它:\\n这款无线蓝... | \n", + "
| 5 | \n", + "瑜伽垫 | \n", + "规格:\\n尺寸:24'' x 68''。\\n\\n为什么我们热爱它:\\n我们的瑜伽垫拥有出色的... | \n", + "
| 6 | \n", + "防水运动手表 | \n", + "规格:\\n表盘直径:40mm。\\n\\n为什么我们热爱它:\\n这款防水运动手表配备了心率监测和... | \n", + "
| 7 | \n", + "书籍:《机器学习基础》 | \n", + "规格:\\n页数:580页。\\n\\n为什么我们热爱它:\\n《机器学习基础》以易懂的语言讲解了机... | \n", + "
| 8 | \n", + "空气净化器 | \n", + "规格:\\n尺寸:15'' x 15'' x 20''。\\n\\n为什么我们热爱它:\\n我们的空... | \n", + "
| 9 | \n", + "陶瓷保温杯 | \n", + "规格:\\n容量:350ml。\\n\\n为什么我们热爱它:\\n我们的陶瓷保温杯设计优雅,保温效果... | \n", + "
| 10 | \n", + "宠物自动喂食器 | \n", + "规格:\\n尺寸:14'' x 9'' x 15''。\\n\\n为什么我们热爱它:\\n我们的宠物... | \n", + "
| 11 | \n", + "高清电视机 | \n", + "规格:\\n尺寸:50''。\\n\\n为什么我们热爱它:\\n我们的高清电视机拥有出色的画质和强大... | \n", + "
| 12 | \n", + "旅行背包 | \n", + "规格:\\n尺寸:18'' x 12'' x 6''。\\n\\n为什么我们热爱它:\\n我们的旅行... | \n", + "
| 13 | \n", + "太阳能庭院灯 | \n", + "规格:\\n高度:18''。\\n\\n为什么我们热爱它:\\n我们的太阳能庭院灯无需电源,只需将其... | \n", + "
| 14 | \n", + "厨房刀具套装 | \n", + "规格:\\n一套包括8把刀。\\n\\n为什么我们热爱它:\\n我们的厨房刀具套装由专业级不锈钢制成... | \n", + "
| 15 | \n", + "迷你无线蓝牙音箱 | \n", + "规格:\\n直径:3'',高度:2''。\\n\\n为什么我们热爱它:\\n我们的迷你无线蓝牙音箱体... | \n", + "
| 16 | \n", + "抗菌洗手液 | \n", + "规格:\\n容量:500ml。\\n\\n为什么我们热爱它:\\n我们的抗菌洗手液含有天然植物精华,... | \n", + "
| 17 | \n", + "纯棉T恤 | \n", + "规格:\\n尺码:S, M, L, XL, XXL。\\n\\n为什么我们热爱它:\\n我们的纯棉T... | \n", + "
| 18 | \n", + "自动咖啡机 | \n", + "规格:\\n尺寸:12'' x 8'' x 14''。\\n\\n为什么我们热爱它:\\n我们的自动... | \n", + "
| 19 | \n", + "摄像头保护套 | \n", + "规格:\\n适用于各种品牌和型号的摄像头。\\n\\n为什么我们热爱它:\\n我们的摄像头保护套可以... | \n", + "
| 20 | \n", + "玻璃保护膜 | \n", + "规格:\\n适用于各种尺寸的手机屏幕。\\n\\n为什么我们热爱它:\\n我们的玻璃保护膜可以有效防... | \n", + "
| 21 | \n", + "儿童益智玩具 | \n", + "规格:\\n适合3岁以上的儿童。\\n\\n为什么我们热爱它:\\n我们的儿童益智玩具设计独特,色彩... | \n", + "
| 22 | \n", + "迷你书架 | \n", + "规格:\\n尺寸:20'' x 8'' x 24''。\\n\\n为什么我们热爱它:\\n我们的迷你... | \n", + "
| 23 | \n", + "防滑瑜伽垫 | \n", + "规格:\\n尺寸:72'' x 24''。\\n\\n为什么我们热爱它:\\n我们的防滑瑜伽垫采用高... | \n", + "
| 24 | \n", + "LED台灯 | \n", + "规格:\\n尺寸:6'' x 6'' x 18''。\\n\\n为什么我们热爱它:\\n我们的LED... | \n", + "
| 25 | \n", + "水晶酒杯 | \n", + "规格:\\n容量:250ml。\\n\\n为什么我们热爱它:\\n我们的水晶酒杯采用高品质水晶玻璃制... | \n", + "
思考:我可以使用`sorted()`函数按姓氏和名字的顺序对客户列表进行排序。我需要为`sorted()`提供一个键函数,该函数返回一个元组,元组中按顺序包含姓氏和名字。
\n", - "\n", - "2. 模型基于思考采取行动(Action), 因为使用的工具不同,Action的输出也和之前有所不同,这里输出的为python代码\n", - "行动: 使用Python编程,输入以下代码
\n", - " \n", - " \n", - " ```python\n", - " customers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\n", - " sorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\n", - " for customer in sorted_customers:\n", - " print(customer)\n", - " ```\n", - "观测:
\n", - " \n", - " ```\n", - " ['Jen', 'Ayai']\n", - " ['Lang', 'Chain']\n", - " ['Harrison', 'Chase']\n", - " ['Elle', 'Elem']\n", - " ['Trance', 'Former']\n", - " ['Geoff', 'Fusion']\n", - " ['Dolly', 'Too']\n", - " ```\n", - "思考: 现在客户按照姓氏和名字的顺序进行了排序。
\n", - "\n", - "5. 给出最终答案(Final Answer)\n", - "最终答案: [['Jen', 'Ayai'], ['Lang', 'Chain'], ['Harrison', 'Chase'], ['Elle', 'Elem'], ['Trance', 'Former'], ['Geoff', 'Fusion'], ['Dolly', 'Too']]
\n", - "6. 返回最终答案。" + "agent.run(f\"\"\"在这些客户名字转换为拼音\\\n", + "并打印输出列表: {customer_list}\\\n", + "思考过程请使用中文。\"\"\") " ] }, { + "attachments": {}, "cell_type": "markdown", "id": "16f530a5-8c50-4648-951f-4e65d15ca93f", "metadata": { @@ -506,6 +744,7 @@ ] }, { + "attachments": {}, "cell_type": "markdown", "id": "951048dc-0414-410d-a0e9-6ef32bbdda89", "metadata": { @@ -536,7 +775,7 @@ }, { "cell_type": "code", - "execution_count": 36, + "execution_count": 25, "id": "92b8961b-b990-4540-a7f9-e4701dfaa616", "metadata": {}, "outputs": [ @@ -546,11 +785,11 @@ "text": [ "\u001b[32;1m\u001b[1;3m[chain/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor] Entering Chain run with input:\n", "\u001b[0m{\n", - " \"input\": \"Sort these customers by last name and then first name and print the output: [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\"\n", + " \"input\": \"在这些客户名字转换为拼音并打印输出列表: ['小明', '小黄', '小红', '小蓝', '小橘', '小绿']思考过程请使用中文。\"\n", "}\n", "\u001b[32;1m\u001b[1;3m[chain/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain] Entering Chain run with input:\n", "\u001b[0m{\n", - " \"input\": \"Sort these customers by last name and then first name and print the output: [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\",\n", + " \"input\": \"在这些客户名字转换为拼音并打印输出列表: ['小明', '小黄', '小红', '小蓝', '小橘', '小绿']思考过程请使用中文。\",\n", " \"agent_scratchpad\": \"\",\n", " \"stop\": [\n", " \"\\nObservation:\",\n", @@ -560,18 +799,18 @@ "\u001b[32;1m\u001b[1;3m[llm/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain > 3:llm:ChatOpenAI] Entering LLM run with input:\n", "\u001b[0m{\n", " \"prompts\": [\n", - " \"Human: You are an agent designed to write and execute python code to answer questions.\\nYou have access to a python REPL, which you can use to execute python code.\\nIf you get an error, debug your code and try again.\\nOnly use the output of your code to answer the question. \\nYou might know the answer without running any code, but you should still run the code to get the answer.\\nIf it does not seem like you can write code to answer the question, just return \\\"I don't know\\\" as the answer.\\n\\n\\nPython REPL: A Python shell. Use this to execute python commands. Input should be a valid python command. If you want to see the output of a value, you should print it out with `print(...)`.\\n\\nUse the following format:\\n\\nQuestion: the input question you must answer\\nThought: you should always think about what to do\\nAction: the action to take, should be one of [Python REPL]\\nAction Input: the input to the action\\nObservation: the result of the action\\n... (this Thought/Action/Action Input/Observation can repeat N times)\\nThought: I now know the final answer\\nFinal Answer: the final answer to the original input question\\n\\nBegin!\\n\\nQuestion: Sort these customers by last name and then first name and print the output: [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nThought:\"\n", + " \"Human: You are an agent designed to write and execute python code to answer questions.\\nYou have access to a python REPL, which you can use to execute python code.\\nIf you get an error, debug your code and try again.\\nOnly use the output of your code to answer the question. \\nYou might know the answer without running any code, but you should still run the code to get the answer.\\nIf it does not seem like you can write code to answer the question, just return \\\"I don't know\\\" as the answer.\\n\\n\\nPython_REPL: A Python shell. Use this to execute python commands. Input should be a valid python command. If you want to see the output of a value, you should print it out with `print(...)`.\\n\\nUse the following format:\\n\\nQuestion: the input question you must answer\\nThought: you should always think about what to do\\nAction: the action to take, should be one of [Python_REPL]\\nAction Input: the input to the action\\nObservation: the result of the action\\n... (this Thought/Action/Action Input/Observation can repeat N times)\\nThought: I now know the final answer\\nFinal Answer: the final answer to the original input question\\n\\nBegin!\\n\\nQuestion: 在这些客户名字转换为拼音并打印输出列表: ['小明', '小黄', '小红', '小蓝', '小橘', '小绿']思考过程请使用中文。\\nThought:\"\n", " ]\n", "}\n", - "\u001b[36;1m\u001b[1;3m[llm/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain > 3:llm:ChatOpenAI] [12.25s] Exiting LLM run with output:\n", + "\u001b[36;1m\u001b[1;3m[llm/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain > 3:llm:ChatOpenAI] [2.91s] Exiting LLM run with output:\n", "\u001b[0m{\n", " \"generations\": [\n", " [\n", " {\n", - " \"text\": \"I can use the sorted() function to sort the list of customers by last name and then first name. I will need to provide a key function to sorted() that returns a tuple of the last name and first name in that order.\\nAction: Python REPL\\nAction Input:\\n```\\ncustomers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nsorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\\nprint(sorted_customers)\\n```\",\n", + " \"text\": \"我需要使用拼音转换库来将这些客户名字转换为拼音。我可以使用Python的pinyin库来完成这个任务。\\nAction: Python_REPL\\nAction Input: import pinyin\",\n", " \"generation_info\": null,\n", " \"message\": {\n", - " \"content\": \"I can use the sorted() function to sort the list of customers by last name and then first name. I will need to provide a key function to sorted() that returns a tuple of the last name and first name in that order.\\nAction: Python REPL\\nAction Input:\\n```\\ncustomers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nsorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\\nprint(sorted_customers)\\n```\",\n", + " \"content\": \"我需要使用拼音转换库来将这些客户名字转换为拼音。我可以使用Python的pinyin库来完成这个任务。\\nAction: Python_REPL\\nAction Input: import pinyin\",\n", " \"additional_kwargs\": {},\n", " \"example\": false\n", " }\n", @@ -580,29 +819,26 @@ " ],\n", " \"llm_output\": {\n", " \"token_usage\": {\n", - " \"prompt_tokens\": 327,\n", - " \"completion_tokens\": 138,\n", - " \"total_tokens\": 465\n", + " \"prompt_tokens\": 322,\n", + " \"completion_tokens\": 50,\n", + " \"total_tokens\": 372\n", " },\n", " \"model_name\": \"gpt-3.5-turbo\"\n", - " }\n", + " },\n", + " \"run\": null\n", "}\n", - "\u001b[36;1m\u001b[1;3m[chain/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain] [12.25s] Exiting Chain run with output:\n", + "\u001b[36;1m\u001b[1;3m[chain/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 2:chain:LLMChain] [2.91s] Exiting Chain run with output:\n", "\u001b[0m{\n", - " \"text\": \"I can use the sorted() function to sort the list of customers by last name and then first name. I will need to provide a key function to sorted() that returns a tuple of the last name and first name in that order.\\nAction: Python REPL\\nAction Input:\\n```\\ncustomers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nsorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\\nprint(sorted_customers)\\n```\"\n", + " \"text\": \"我需要使用拼音转换库来将这些客户名字转换为拼音。我可以使用Python的pinyin库来完成这个任务。\\nAction: Python_REPL\\nAction Input: import pinyin\"\n", "}\n", - "\u001b[32;1m\u001b[1;3m[tool/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 4:tool:Python REPL] Entering Tool run with input:\n", - "\u001b[0m\"```\n", - "customers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\n", - "sorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\n", - "print(sorted_customers)\n", - "```\"\n", - "\u001b[36;1m\u001b[1;3m[tool/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 4:tool:Python REPL] [2.2239999999999998ms] Exiting Tool run with output:\n", - "\u001b[0m\"[['Jen', 'Ayai'], ['Lang', 'Chain'], ['Harrison', 'Chase'], ['Elle', 'Elem'], ['Trance', 'Former'], ['Geoff', 'Fusion'], ['Dolly', 'Too']]\"\n", + "\u001b[32;1m\u001b[1;3m[tool/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 4:tool:Python_REPL] Entering Tool run with input:\n", + "\u001b[0m\"import pinyin\"\n", + "\u001b[36;1m\u001b[1;3m[tool/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 4:tool:Python_REPL] [0.0ms] Exiting Tool run with output:\n", + "\u001b[0m\"\"\n", "\u001b[32;1m\u001b[1;3m[chain/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 5:chain:LLMChain] Entering Chain run with input:\n", "\u001b[0m{\n", - " \"input\": \"Sort these customers by last name and then first name and print the output: [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\",\n", - " \"agent_scratchpad\": \"I can use the sorted() function to sort the list of customers by last name and then first name. I will need to provide a key function to sorted() that returns a tuple of the last name and first name in that order.\\nAction: Python REPL\\nAction Input:\\n```\\ncustomers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nsorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\\nprint(sorted_customers)\\n```\\nObservation: [['Jen', 'Ayai'], ['Lang', 'Chain'], ['Harrison', 'Chase'], ['Elle', 'Elem'], ['Trance', 'Former'], ['Geoff', 'Fusion'], ['Dolly', 'Too']]\\n\\nThought:\",\n", + " \"input\": \"在这些客户名字转换为拼音并打印输出列表: ['小明', '小黄', '小红', '小蓝', '小橘', '小绿']思考过程请使用中文。\",\n", + " \"agent_scratchpad\": \"我需要使用拼音转换库来将这些客户名字转换为拼音。我可以使用Python的pinyin库来完成这个任务。\\nAction: Python_REPL\\nAction Input: import pinyin\\nObservation: \\nThought:\",\n", " \"stop\": [\n", " \"\\nObservation:\",\n", " \"\\n\\tObservation:\"\n", @@ -611,18 +847,33 @@ "\u001b[32;1m\u001b[1;3m[llm/start]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 5:chain:LLMChain > 6:llm:ChatOpenAI] Entering LLM run with input:\n", "\u001b[0m{\n", " \"prompts\": [\n", - " \"Human: You are an agent designed to write and execute python code to answer questions.\\nYou have access to a python REPL, which you can use to execute python code.\\nIf you get an error, debug your code and try again.\\nOnly use the output of your code to answer the question. \\nYou might know the answer without running any code, but you should still run the code to get the answer.\\nIf it does not seem like you can write code to answer the question, just return \\\"I don't know\\\" as the answer.\\n\\n\\nPython REPL: A Python shell. Use this to execute python commands. Input should be a valid python command. If you want to see the output of a value, you should print it out with `print(...)`.\\n\\nUse the following format:\\n\\nQuestion: the input question you must answer\\nThought: you should always think about what to do\\nAction: the action to take, should be one of [Python REPL]\\nAction Input: the input to the action\\nObservation: the result of the action\\n... (this Thought/Action/Action Input/Observation can repeat N times)\\nThought: I now know the final answer\\nFinal Answer: the final answer to the original input question\\n\\nBegin!\\n\\nQuestion: Sort these customers by last name and then first name and print the output: [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nThought:I can use the sorted() function to sort the list of customers by last name and then first name. I will need to provide a key function to sorted() that returns a tuple of the last name and first name in that order.\\nAction: Python REPL\\nAction Input:\\n```\\ncustomers = [['Harrison', 'Chase'], ['Lang', 'Chain'], ['Dolly', 'Too'], ['Elle', 'Elem'], ['Geoff', 'Fusion'], ['Trance', 'Former'], ['Jen', 'Ayai']]\\nsorted_customers = sorted(customers, key=lambda x: (x[1], x[0]))\\nprint(sorted_customers)\\n```\\nObservation: [['Jen', 'Ayai'], ['Lang', 'Chain'], ['Harrison', 'Chase'], ['Elle', 'Elem'], ['Trance', 'Former'], ['Geoff', 'Fusion'], ['Dolly', 'Too']]\\n\\nThought:\"\n", + " \"Human: You are an agent designed to write and execute python code to answer questions.\\nYou have access to a python REPL, which you can use to execute python code.\\nIf you get an error, debug your code and try again.\\nOnly use the output of your code to answer the question. \\nYou might know the answer without running any code, but you should still run the code to get the answer.\\nIf it does not seem like you can write code to answer the question, just return \\\"I don't know\\\" as the answer.\\n\\n\\nPython_REPL: A Python shell. Use this to execute python commands. Input should be a valid python command. If you want to see the output of a value, you should print it out with `print(...)`.\\n\\nUse the following format:\\n\\nQuestion: the input question you must answer\\nThought: you should always think about what to do\\nAction: the action to take, should be one of [Python_REPL]\\nAction Input: the input to the action\\nObservation: the result of the action\\n... (this Thought/Action/Action Input/Observation can repeat N times)\\nThought: I now know the final answer\\nFinal Answer: the final answer to the original input question\\n\\nBegin!\\n\\nQuestion: 在这些客户名字转换为拼音并打印输出列表: ['小明', '小黄', '小红', '小蓝', '小橘', '小绿']思考过程请使用中文。\\nThought:我需要使用拼音转换库来将这些客户名字转换为拼音。我可以使用Python的pinyin库来完成这个任务。\\nAction: Python_REPL\\nAction Input: import pinyin\\nObservation: \\nThought:\"\n", " ]\n", - "}\n", - "\u001b[36;1m\u001b[1;3m[llm/end]\u001b[0m \u001b[1m[1:chain:AgentExecutor > 5:chain:LLMChain > 6:llm:ChatOpenAI] [6.94s] Exiting LLM run with output:\n", + "}\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "Retrying langchain.chat_models.openai.ChatOpenAI.completion_with_retry.观测: 2023-06-03
\n", + "观测: 2023-07-04
\n", " \n", " \n", " \n", @@ -839,7 +1166,7 @@ "思考: 我已成功使用 time 工具检索到了今天的日期
\n", "\n", "5. 给出最终答案(Final Answer)\n", - "最终答案: 今天的日期是2023-06-03.
\n", + "最终答案: 今天的日期是2023-07-04.
\n", "6. 返回最终答案。" ] } @@ -860,7 +1187,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.9.12" + "version": "3.9.16" }, "toc": { "base_numbering": 1, diff --git a/content/LangChain for LLM Application Development/product_data.csv b/content/LangChain for LLM Application Development/product_data.csv new file mode 100644 index 0000000..a3f8362 --- /dev/null +++ b/content/LangChain for LLM Application Development/product_data.csv @@ -0,0 +1,434 @@ +product_name,description +全自动咖啡机,"规格: +大型 - 尺寸:13.8'' x 17.3''。 +中型 - 尺寸:11.5'' x 15.2''。 + +为什么我们热爱它: +这款全自动咖啡机是爱好者的理想选择。 一键操作,即可研磨豆子并沏制出您喜爱的咖啡。它的耐用性和一致性使它成为家庭和办公室的理想选择。 + +材质与护理: +清洁时只需轻擦。 + +构造: +由高品质不锈钢制成。 + +其他特性: +内置研磨器和滤网。 +预设多种咖啡模式。 +在中国制造。 + +有问题? 请随时联系我们的客户服务团队,他们会解答您的所有问题。" +电动牙刷,"规格: +一般大小 - 高度:9.5'',宽度:1''。 + +为什么我们热爱它: +我们的电动牙刷采用先进的刷头设计和强大的电机,为您提供超凡的清洁力和舒适的刷牙体验。 + +材质与护理: +不可水洗,只需用湿布清洁。 + +构造: +由食品级塑料和尼龙刷毛制成。 + +其他特性: +具有多种清洁模式和定时功能。 +USB充电。 +在日本制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +橙味维生素C泡腾片,"规格: +每盒含有20片。 + +为什么我们热爱它: +我们的橙味维生素C泡腾片是快速补充维生素C的理想方式。每片含有500mg的维生素C,可以帮助提升免疫力,保护您的健康。 + +材质与护理: +请存放在阴凉干燥的地方,避免阳光直射。 + +构造: +主要成分为维生素C和柠檬酸钠。 + +其他特性: +含有天然橙味。 +易于携带。 +在美国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +无线蓝牙耳机,"规格: +单个耳机尺寸:1.5'' x 1.3''。 + +为什么我们热爱它: +这款无线蓝牙耳机配备了降噪技术和长达8小时的电池续航力,让您无论在哪里都可以享受无障碍的音乐体验。 + +材质与护理: +只需用湿布清洁。 + +构造: +由耐用的塑料和金属构成,配备有软质耳塞。 + +其他特性: +快速充电功能。 +内置麦克风,支持接听电话。 +在韩国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +瑜伽垫,"规格: +尺寸:24'' x 68''。 + +为什么我们热爱它: +我们的瑜伽垫拥有出色的抓地力和舒适度,无论是做瑜伽还是健身,都是理想的选择。 + +材质与护理: +可用清水清洁,自然晾干。 + +构造: +由环保PVC材料制成。 + +其他特性: +附带便携包和绑带。 +在印度制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +防水运动手表,"规格: +表盘直径:40mm。 + +为什么我们热爱它: +这款防水运动手表配备了心率监测和计步功能,不仅适合日常佩戴,也是户外运动的理想伙伴。 + +材质与护理: +只需用湿布清洁。 + +构造: +由不锈钢和硅胶制成。 + +其他特性: +内置可充电电池。 +支持蓝牙连接手机。 +在瑞士制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +书籍:《机器学习基础》,"规格: +页数:580页。 + +为什么我们热爱它: +《机器学习基础》以易懂的语言讲解了机器学习的基本概念和方法,适合初学者阅读。 + +材质与护理: +纸质封面,存放在阴凉干燥处。 + +构造: +由环保纸张和油墨印刷。 + +其他特性: +附带实例和习题。 +在美国印刷。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +空气净化器,"规格: +尺寸:15'' x 15'' x 20''。 + +为什么我们热爱它: +我们的空气净化器采用了先进的HEPA过滤技术,能有效去除空气中的微粒和异味,为您提供清新的室内环境。 + +材质与护理: +清洁时使用干布擦拭。 + +构造: +由塑料和电子元件制成。 + +其他特性: +三档风速,附带定时功能。 +在德国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +陶瓷保温杯,"规格: +容量:350ml。 + +为什么我们热爱它: +我们的陶瓷保温杯设计优雅,保温效果好,是办公室和户外活动的理想伴侣。 + +材质与护理: +可以手洗或洗碗机清洗。 + +构造: +由高品质陶瓷和不锈钢制成。 + +其他特性: +有多种颜色可选。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +宠物自动喂食器,"规格: +尺寸:14'' x 9'' x 15''。 + +为什么我们热爱它: +我们的宠物自动喂食器可以定时定量投放食物,让您无论在家或外出都能确保宠物的饮食。 + +材质与护理: +可用湿布清洁。 + +构造: +由塑料和电子元件制成。 + +其他特性: +配备LCD屏幕,操作简单。 +可以设置多次投食。 +在美国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +高清电视机,"规格: +尺寸:50''。 + +为什么我们热爱它: +我们的高清电视机拥有出色的画质和强大的音效,带来沉浸式的观看体验。 + +材质与护理: +使用干布清洁。 + +构造: +由塑料、金属和电子元件制成。 + +其他特性: +支持网络连接,可以在线观看视频。 +配备遥控器。 +在韩国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +旅行背包,"规格: +尺寸:18'' x 12'' x 6''。 + +为什么我们热爱它: +我们的旅行背包拥有多个实用的内外袋,轻松装下您的必需品,是短途旅行的理想选择。 + +材质与护理: +可以手洗,自然晾干。 + +构造: +由防水尼龙制成。 + +其他特性: +附带可调节背带和安全锁。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +太阳能庭院灯,"规格: +高度:18''。 + +为什么我们热爱它: +我们的太阳能庭院灯无需电源,只需将其放在阳光下即可充电。到了晚上,它会自动点亮,为您的庭院增添温馨的氛围。 + +材质与护理: +可以用湿布清洁。 + +构造: +由塑料和太阳能板制成。 + +其他特性: +自动感应,日落后自动点亮。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +厨房刀具套装,"规格: +一套包括8把刀。 + +为什么我们热爱它: +我们的厨房刀具套装由专业级不锈钢制成,刀身坚固,刀刃锋利,切割效果出色,是厨房必备工具。 + +材质与护理: +建议手洗并立即擦干,以保持最佳状况。 + +构造: +由高品质不锈钢制成。 + +其他特性: +包括多种类型的刀,适合不同的用途。 +在德国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +迷你无线蓝牙音箱,"规格: +直径:3'',高度:2''。 + +为什么我们热爱它: +我们的迷你无线蓝牙音箱体积小巧,音质出色,可以轻松带给您音乐的享受。 + +材质与护理: +使用湿布擦拭清洁。 + +构造: +由塑料和金属构成。 + +其他特性: +内置可充电电池,充满后可播放5小时。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +抗菌洗手液,"规格: +容量:500ml。 + +为什么我们热爱它: +我们的抗菌洗手液含有天然植物精华,能有效杀灭细菌,同时滋润双手。 + +材质与护理: +直接涂抹在手上,然后用水冲洗。 + +构造: +由天然植物精华和抗菌成分制成。 + +其他特性: +具有清新的柠檬香味。 +在法国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +纯棉T恤,"规格: +尺码:S, M, L, XL, XXL。 + +为什么我们热爱它: +我们的纯棉T恤采用高品质棉质,柔软舒适,透气性好,是日常穿着的理想选择。 + +材质与护理: +可以机洗,建议反面洗涤,以保持颜色鲜艳。 + +构造: +由100%纯棉制成。 + +其他特性: +有多种颜色可选。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +自动咖啡机,"规格: +尺寸:12'' x 8'' x 14''。 + +为什么我们热爱它: +我们的自动咖啡机可以轻松制作美味的咖啡,只需按一下钮,就能享受到新鲜的咖啡。 + +材质与护理: +可以用湿布清洁外部,内部配件可以拆卸清洗。 + +构造: +由不锈钢和塑料制成。 + +其他特性: +可调节咖啡浓度。 +在意大利制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +摄像头保护套,"规格: +适用于各种品牌和型号的摄像头。 + +为什么我们热爱它: +我们的摄像头保护套可以有效保护您的摄像头不受灰尘和刮擦的影响。 + +材质与护理: +使用湿布擦拭。 + +构造: +由耐磨的合成纤维制成。 + +其他特性: +设计简洁,易于安装。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +玻璃保护膜,"规格: +适用于各种尺寸的手机屏幕。 + +为什么我们热爱它: +我们的玻璃保护膜可以有效防止手机屏幕刮伤和破裂,而且不影响触控的灵敏度。 + +材质与护理: +使用干布擦拭。 + +构造: +由高强度的玻璃材料制成。 + +其他特性: +安装简单,适合自行安装。 +在日本制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +儿童益智玩具,"规格: +适合3岁以上的儿童。 + +为什么我们热爱它: +我们的儿童益智玩具设计独特,色彩鲜艳,能够引发孩子的兴趣,同时训练他们的手眼协调能力和逻辑思维。 + +材质与护理: +使用湿布擦拭。 + +构造: +由环保无毒的塑料制成。 + +其他特性: +具有教育和娱乐的双重功能。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +迷你书架,"规格: +尺寸:20'' x 8'' x 24''。 + +为什么我们热爱它: +我们的迷你书架占地面积小,设计简约,能够有效存放和展示您的书籍。 + +材质与护理: +使用干布擦拭。 + +构造: +由实木制成。 + +其他特性: +拥有3层收纳空间。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +防滑瑜伽垫,"规格: +尺寸:72'' x 24''。 + +为什么我们热爱它: +我们的防滑瑜伽垫采用高品质环保材料,触感舒适,防滑效果好,是瑜伽爱好者的理想选择。 + +材质与护理: +可以用湿布清洁。 + +构造: +由环保PVC材料制成。 + +其他特性: +有多种颜色可选。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +LED台灯,"规格: +尺寸:6'' x 6'' x 18''。 + +为什么我们热爱它: +我们的LED台灯亮度可调,采用节能LED灯珠,不仅可以提供明亮的光照,还可以节省能源。 + +材质与护理: +使用湿布擦拭。 + +构造: +由金属和塑料制成。 + +其他特性: +具有触控开关和调光功能。 +在中国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。" +水晶酒杯,"规格: +容量:250ml。 + +为什么我们热爱它: +我们的水晶酒杯采用高品质水晶玻璃制成,造型优雅,是享受美酒的理想选择。 + +材质与护理: +建议手洗。 + +构造: +由水晶玻璃制成。 + +其他特性: +适合各种场合使用。 +在法国制造。 + +有问题?请随时联系我们的客户服务团队,他们会解答您的所有问题。"