File size: 1,557 Bytes
c582d6f
 
b57200a
a5e186e
 
 
 
 
 
b57200a
c582d6f
 
14b9d91
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
a5e186e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
---
license: apache-2.0
base_model: mzbac/llama-3-8B-Instruct-function-calling-v0.2
datasets:
- mzbac/function-calling-llama-3-format-v1.1
tags:
- llama3
- function calling
- 8b
pipeline_tag: text-generation
---

Quantization of [mzbac/llama-3-8B-Instruct-function-calling-v0.2](https://huggingface.co/mzbac/llama-3-8B-Instruct-function-calling-v0.2) info GGUF

# Llama 3 function calling

Tested within LM Studio.


## Request
```bash
curl --location 'http://localhost:5000/v1/chat/completions' \
--header 'Content-Type: application/json' \
--data '{
    "model": "AABAAB/llama-3-8B-Instruct-function-calling-v0.2/llama-3-8B-Instruct-function-calling-v0.2_Q8_0.gguf",
    "messages": [
        {
            "role": "system",
            "content": "You are a helpful assistant with access to the following functions. Use them if required - {\"name\": \"search_web\",\"description\": \"Perform a web search for a given search terms.\",\"parameter\": {\"type\": \"object\", \"properties\": {\"search_terms\": {\"type\": \"array\",\"items\": {\"type\": \"string\"},\"description\": \"The search queries for which the search is performed.\",\"required\": True,}}},}"
        },
        {
            "role": "user",
            "content": "What is the weather in Sydney?"
        }
    ],
    "stream": false
}'
```

## Response

```
<functioncall> {\"name\": \"search_web\", \"arguments\": {\"search_terms\": [\"weather in Sydney\"]}}
```

![image/png](https://cdn-uploads.huggingface.co/production/uploads/663695e864f6d7cc4446c53b/P5_a-YtkEvJOz1cHCjNa_.png)