Skip to content
Snippets Groups Projects
Unverified Commit 5fdf7f59 authored by James Braza's avatar James Braza Committed by GitHub
Browse files

Allowing `LOCALAI_DEFAULTS` to work with `__ror__` (#9502)

parent 90994aca
Branches
Tags
No related merge requests found
......@@ -7,7 +7,7 @@ Source: https://github.com/go-skynet/LocalAI
import warnings
from types import MappingProxyType
from typing import Any, Callable, Dict, Mapping, Optional, Sequence
from typing import Any, Callable, Dict, Optional, Sequence
from llama_index.bridge.pydantic import Field
from llama_index.constants import DEFAULT_CONTEXT_WINDOW
......@@ -19,7 +19,8 @@ from llama_index.types import BaseOutputParser, PydanticProgramMode
# Use these as kwargs for OpenAILike to connect to LocalAIs
DEFAULT_LOCALAI_PORT = 8080
LOCALAI_DEFAULTS: Mapping[str, Any] = MappingProxyType(
# TODO: move to MappingProxyType[str, Any] once Python 3.9+
LOCALAI_DEFAULTS: Dict[str, Any] = MappingProxyType( # type: ignore[assignment]
{
"api_key": "localai_fake",
"api_type": "localai_fake",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment