mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 18:54:30 +00:00
Update aporia_ai.py
This commit is contained in:
parent
b3de3216a8
commit
da04d3ce94
1 changed files with 4 additions and 4 deletions
|
@ -46,8 +46,8 @@ class AporiaGuardrail(CustomGuardrail):
|
||||||
self.async_handler = get_async_httpx_client(
|
self.async_handler = get_async_httpx_client(
|
||||||
llm_provider=httpxSpecialProvider.GuardrailCallback
|
llm_provider=httpxSpecialProvider.GuardrailCallback
|
||||||
)
|
)
|
||||||
self.aporia_api_key = api_key or os.environ["APORIO_API_KEY"]
|
self.aporia_api_key = api_key or os.environ["APORIA_API_KEY"]
|
||||||
self.aporia_api_base = api_base or os.environ["APORIO_API_BASE"]
|
self.aporia_api_base = api_base or os.environ["APORIA_API_BASE"]
|
||||||
super().__init__(**kwargs)
|
super().__init__(**kwargs)
|
||||||
|
|
||||||
#### CALL HOOKS - proxy only ####
|
#### CALL HOOKS - proxy only ####
|
||||||
|
@ -105,10 +105,10 @@ class AporiaGuardrail(CustomGuardrail):
|
||||||
_json_data = json.dumps(data)
|
_json_data = json.dumps(data)
|
||||||
|
|
||||||
"""
|
"""
|
||||||
export APORIO_API_KEY=<your key>
|
export APORIA_API_KEY=<your key>
|
||||||
curl https://gr-prd-trial.aporia.com/some-id \
|
curl https://gr-prd-trial.aporia.com/some-id \
|
||||||
-X POST \
|
-X POST \
|
||||||
-H "X-APORIA-API-KEY: $APORIO_API_KEY" \
|
-H "X-APORIA-API-KEY: $APORIA_API_KEY" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
-d '{
|
-d '{
|
||||||
"messages": [
|
"messages": [
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue