Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update llm_loader.py #1393

Merged
merged 1 commit into from
Jan 18, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions superagi/helper/llm_loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
if self._model is None:
try:
self._model = Llama(
model_path="/app/local_model_path", n_ctx=self.context_length, n_gpu_layers=get_config('GPU_LAYERS', '-1'))
model_path="/app/local_model_path", n_ctx=self.context_length, n_gpu_layers=int(get_config('GPU_LAYERS', '-1')))
except Exception as e:
logger.error(e)
return self._model
Expand All @@ -35,4 +35,4 @@
"superagi/llms/grammar/json.gbnf")
except Exception as e:
logger.error(e)
return self._grammar
return self._grammar

Check warning on line 38 in superagi/helper/llm_loader.py

View check run for this annotation

Codecov / codecov/patch

superagi/helper/llm_loader.py#L38

Added line #L38 was not covered by tests
Loading