mirror of
https://github.com/hwchase17/langchain.git
synced 2025-08-10 05:20:39 +00:00
docs: update OctoAI LLM doc (#21528)
This PR updates OctoAI doc to remove warnings when running the example code.
This commit is contained in:
parent
70a79f45d7
commit
85cbc55f86
@ -67,7 +67,7 @@
|
|||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"llm = OctoAIEndpoint(\n",
|
"llm = OctoAIEndpoint(\n",
|
||||||
" model=\"llama-2-13b-chat-fp16\",\n",
|
" model_name=\"llama-2-13b-chat-fp16\",\n",
|
||||||
" max_tokens=200,\n",
|
" max_tokens=200,\n",
|
||||||
" presence_penalty=0,\n",
|
" presence_penalty=0,\n",
|
||||||
" temperature=0.1,\n",
|
" temperature=0.1,\n",
|
||||||
@ -83,9 +83,9 @@
|
|||||||
"source": [
|
"source": [
|
||||||
"question = \"Who was Leonardo da Vinci?\"\n",
|
"question = \"Who was Leonardo da Vinci?\"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"llm_chain = LLMChain(prompt=prompt, llm=llm)\n",
|
"chain = prompt | llm\n",
|
||||||
"\n",
|
"\n",
|
||||||
"print(llm_chain.run(question))"
|
"print(chain.invoke(question))"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user