Agent with Ollama can't find OllamaLanguageModelInstruction api.
Describe the bug
after install this two package 1.LangChain.Core 2.LangChain.Providers.Ollama
copy the example code for ollama, but it's show OllamaLanguageModelInstruction and OllamaLanguageModelOptions not found.
Steps to reproduce the bug
1.install LangChain.Core 2.LangChain.Providers.Ollama 3.copy agent example for ollama
Expected behavior
it's can run
Screenshots
No response
NuGet package version
LangChain v0.15.0 LangChain.Core v0.15.0 LangChain.Providers.Ollama v0.15.0
Additional context
No response
Try use this
var provider = new OllamaProvider(
"http://localhost:11434",
options: new RequestOptions
{
Temperature = 0,
Stop = new[] { "Observation", "[END]" }, // add injection word `Observation` and `[END]` to stop the model(just as additional safety feature)
});
var model = new OllamaChatModel(provider, id: "llama3").UseConsoleForDebug();
look like the wiki page is outdate and need to be update
Yes, it's best to use these tests as an example, we are in the process of migrating documentation from wiki to mkdocs https://github.com/tryAGI/LangChain/blob/main/src/Meta/test/WikiTests.AgentWithOllama.cs
https://tryagi.github.io/LangChain/wiki/AgentWithOllama/