> For the complete documentation index, see [llms.txt](https://docs.flowiseai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flowiseai.com/espanol/documentacion-oficial/integraciones/langchain/chat-models/chatollama.md).

# ChatOllama

## Prerequisitos

1. Descarga [Ollama](https://github.com/ollama/ollama) o ejecútalo en [Docker.](https://hub.docker.com/r/ollama/ollama)
2. Por ejemplo, puedes usar el siguiente comando para iniciar una instancia de Docker con llama3

   ```bash
   docker run -d -v ollama:/root/.ollama -p 11434:11434 --name ollama ollama/ollama
   docker exec -it ollama ollama run llama3
   ```

## Configuración

1. **Chat Models** > arrastra el nodo **ChatOllama**

<figure><img src="https://4068692976-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUiD7nOmFRK805sNuiieJ%2Fuploads%2Fgit-blob-bde86b4973bdb31361b80f54fd01f1ad7abf77c5%2Fimage%20(139).png?alt=media" alt="" width="563"><figcaption></figcaption></figure>

2. Completa el modelo que se está ejecutando en Ollama. Por ejemplo: `llama2`. También puedes usar parámetros adicionales:

<figure><img src="https://4068692976-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUiD7nOmFRK805sNuiieJ%2Fuploads%2Fgit-blob-d3bec65d2769f5e12a2497efa76d687e886abc9d%2Fimage%20(140).png?alt=media" alt=""><figcaption></figcaption></figure>

3. ¡Voilà [🎉](https://emojipedia.org/party-popper/), ahora puedes usar el **nodo ChatOllama** en Flowise

<figure><img src="https://4068692976-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUiD7nOmFRK805sNuiieJ%2Fuploads%2Fgit-blob-004a46b3c6799bfc5875e1885e7ac1d558d58192%2Fimage%20(141).png?alt=media" alt=""><figcaption></figcaption></figure>

### Adicional

Si estás ejecutando tanto Flowise como Ollama en docker, tendrás que cambiar la URL Base para ChatOllama.

Para sistemas operativos Windows y MacOS, especifica [http://host.docker.internal:8000](http://host.docker.internal:8000/). Para sistemas basados en Linux, se debe usar el gateway predeterminado de docker ya que host.docker.internal no está disponible: [http://172.17.0.1:8000](http://172.17.0.1:8000/)

<figure><img src="https://4068692976-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FUiD7nOmFRK805sNuiieJ%2Fuploads%2Fgit-blob-d814dc411850b1ea40c90ef6bec0fbe188aee449%2Fimage%20(142).png?alt=media" alt="" width="292"><figcaption></figcaption></figure>

## Recursos

* [LangchainJS ChatOllama](https://js.langchain.com/docs/integrations/chat/ollama)
* [Ollama](https://github.com/ollama/ollama)
