Skip to content

Commit

Permalink
fix:ollama text embedding 500 error (langgenius#8252)
Browse files Browse the repository at this point in the history
  • Loading branch information
Howe829 authored and cuiks committed Sep 26, 2024
1 parent 5ab0ba6 commit 1d3f5e3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def _invoke(
inputs.append(text)

# Prepare the payload for the request
payload = {"input": inputs, "model": model, "options": {"use_mmap": "true"}}
payload = {"input": inputs, "model": model, "options": {"use_mmap": True}}

# Make the request to the Ollama API
response = requests.post(endpoint_url, headers=headers, data=json.dumps(payload), timeout=(10, 300))
Expand Down

0 comments on commit 1d3f5e3

Please sign in to comment.