"MariTalk is an assistant developed by the Brazilian company [Maritaca AI](www.maritaca.ai).\n",
"MariTalk is an assistant developed by the Brazilian company [Maritaca AI](https://www.maritaca.ai).\n",
"MariTalk is based on language models that have been specially trained to understand Portuguese well.\n",
"MariTalk is based on language models that have been specially trained to understand Portuguese well.\n",
"\n",
"\n",
"This notebook demonstrates how to use MariTalk with llama-index through a simple example."
"This notebook demonstrates how to use MariTalk with llama-index through a simple example."
...
@@ -30,8 +30,8 @@
...
@@ -30,8 +30,8 @@
"metadata": {},
"metadata": {},
"outputs": [],
"outputs": [],
"source": [
"source": [
"%pip install llama-index-llms-maritalk\n",
"!pip install llama-index\n",
"!pip install llama-index"
"!pip install llama-index-llms-maritalk"
]
]
},
},
{
{
...
@@ -80,10 +80,8 @@
...
@@ -80,10 +80,8 @@
]
]
},
},
{
{
"cell_type": "code",
"cell_type": "markdown",
"execution_count": null,
"metadata": {},
"metadata": {},
"outputs": [],
"source": [
"source": [
"### Few-shot examples\n",
"### Few-shot examples\n",
"\n",
"\n",
...
...
%% Cell type:markdown id: tags:
%% Cell type:markdown id: tags:
<ahref="https://colab.research.google.com/github/run-llama/llama_index/blob/main/docs/examples/llm/maritalk.ipynb"target="_parent"><imgsrc="https://colab.research.google.com/assets/colab-badge.svg"alt="Open In Colab"/></a>
<ahref="https://colab.research.google.com/github/run-llama/llama_index/blob/main/docs/examples/llm/maritalk.ipynb"target="_parent"><imgsrc="https://colab.research.google.com/assets/colab-badge.svg"alt="Open In Colab"/></a>
# Maritalk
# Maritalk
## Introduction
## Introduction
MariTalk is an assistant developed by the Brazilian company [Maritaca AI](www.maritaca.ai).
MariTalk is an assistant developed by the Brazilian company [Maritaca AI](https://www.maritaca.ai).
MariTalk is based on language models that have been specially trained to understand Portuguese well.
MariTalk is based on language models that have been specially trained to understand Portuguese well.
This notebook demonstrates how to use MariTalk with llama-index through a simple example.
This notebook demonstrates how to use MariTalk with llama-index through a simple example.
%% Cell type:markdown id: tags:
%% Cell type:markdown id: tags:
## Installation
## Installation
If you're opening this Notebook on colab, you will probably need to install LlamaIndex.
If you're opening this Notebook on colab, you will probably need to install LlamaIndex.
%% Cell type:code id: tags:
%% Cell type:code id: tags:
```
```
%pip install llama-index-llms-maritalk
!pip install llama-index
!pip install llama-index
!pip install llama-index-llms-maritalk
```
```
%% Cell type:markdown id: tags:
%% Cell type:markdown id: tags:
## API Key
## API Key
You will need an API key that can be obtained from chat.maritaca.ai ("Chaves da API" section).
You will need an API key that can be obtained from chat.maritaca.ai ("Chaves da API" section).
%% Cell type:markdown id: tags:
%% Cell type:markdown id: tags:
## Usage
## Usage
### Chat
### Chat
%% Cell type:code id: tags:
%% Cell type:code id: tags:
```
```
from llama_index.core.llms import ChatMessage
from llama_index.core.llms import ChatMessage
from llama_index.llms.maritalk import Maritalk
from llama_index.llms.maritalk import Maritalk
# To customize your API key, do this
# To customize your API key, do this
# otherwise it will lookup MARITALK_API_KEY from your env variable
# otherwise it will lookup MARITALK_API_KEY from your env variable