Skip to content

Commit

Permalink
Rename categorize conversation route to its plural batch form
Browse files Browse the repository at this point in the history
  • Loading branch information
valeriansaliou committed Oct 23, 2023
1 parent 5a758ac commit 51b2f38
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 14 deletions.
30 changes: 18 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -247,24 +247,28 @@ $client->task->summarizeConversation([
}
```

#### ➡️ Categorize Conversation
#### ➡️ Categorize Conversations

* **Method:** `$client->task->categorizeConversation(data)`
* **Reference:** [Categorize Conversation](https://docs.mirage-ai.com/references/api/v1/#categorize-conversation)
* **Method:** `$client->task->categorizeConversations(data)`
* **Reference:** [Categorize Conversations](https://docs.mirage-ai.com/references/api/v1/#categorize-conversations)

* **Request:**

```php
$client->task->categorizeConversation([
"transcript" => [
$client->task->categorizeConversations([
"conversations" => [
[
"from" => "customer",
"text" => "Hello! I have a question about the Crisp chatbot, I am trying to setup a week-end auto-responder, how can I do that?"
],
"transcript" => [
[
"from" => "customer",
"text" => "Hello! I have a question about the Crisp chatbot, I am trying to setup a week-end auto-responder, how can I do that?"
],

[
"from" => "agent",
"text" => "Hi. Baptiste here. I can provide you an example bot scenario that does just that if you'd like?"
[
"from" => "agent",
"text" => "Hi. Baptiste here. I can provide you an example bot scenario that does just that if you'd like?"
]
]
]
]
]);
Expand All @@ -277,7 +281,9 @@ $client->task->categorizeConversation([
"reason": "processed",

"data": {
"category": "Chatbot Configuration Issue"
"categories": [
"Chatbot Configuration Issue"
]
}
}
```
Expand Down
4 changes: 2 additions & 2 deletions resources/Task.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ public function summarizeConversation($data) {
return $this->parent->_post("/task/summarize/conversation", $data);
}

public function categorizeConversation($data) {
return $this->parent->_post("/task/categorize/conversation", $data);
public function categorizeConversations($data) {
return $this->parent->_post("/task/categorize/conversations", $data);
}

public function rankQuestion($data) {
Expand Down

0 comments on commit 51b2f38

Please sign in to comment.