forked from phoenix/litellm-mirror
Add literalai in the sidebar observability category (#6163)
* fix: add literalai in the sidebar * fix: typo
This commit is contained in:
parent
d28c6b390c
commit
8b00d2a25f
2 changed files with 5 additions and 1 deletions
|
@ -22,6 +22,7 @@ import os
|
||||||
|
|
||||||
os.environ["LITERAL_API_KEY"] = ""
|
os.environ["LITERAL_API_KEY"] = ""
|
||||||
os.environ['OPENAI_API_KEY']= ""
|
os.environ['OPENAI_API_KEY']= ""
|
||||||
|
os.environ['LITERAL_BATCH_SIZE'] = "1" # You won't see logs appear until the batch is full and sent
|
||||||
|
|
||||||
litellm.success_callback = ["literalai"] # Log Input/Output to LiteralAI
|
litellm.success_callback = ["literalai"] # Log Input/Output to LiteralAI
|
||||||
litellm.failure_callback = ["literalai"] # Log Errors to LiteralAI
|
litellm.failure_callback = ["literalai"] # Log Errors to LiteralAI
|
||||||
|
@ -46,6 +47,7 @@ import os
|
||||||
|
|
||||||
os.environ["LITERAL_API_KEY"] = ""
|
os.environ["LITERAL_API_KEY"] = ""
|
||||||
os.environ['OPENAI_API_KEY']= ""
|
os.environ['OPENAI_API_KEY']= ""
|
||||||
|
os.environ['LITERAL_BATCH_SIZE'] = "1" # You won't see logs appear until the batch is full and sent
|
||||||
|
|
||||||
litellm.input_callback = ["literalai"] # Support other Literal AI decorators and prompt templates
|
litellm.input_callback = ["literalai"] # Support other Literal AI decorators and prompt templates
|
||||||
litellm.success_callback = ["literalai"] # Log Input/Output to LiteralAI
|
litellm.success_callback = ["literalai"] # Log Input/Output to LiteralAI
|
||||||
|
@ -60,7 +62,8 @@ def my_agent(question: str):
|
||||||
model="gpt-3.5-turbo",
|
model="gpt-3.5-turbo",
|
||||||
messages=[
|
messages=[
|
||||||
{"role": "user", "content": question}
|
{"role": "user", "content": question}
|
||||||
]
|
],
|
||||||
|
metadata={"literalai_parent_id": literalai_client.get_current_step().id}
|
||||||
)
|
)
|
||||||
return response
|
return response
|
||||||
|
|
||||||
|
|
|
@ -273,6 +273,7 @@ const sidebars = {
|
||||||
"observability/langfuse_integration",
|
"observability/langfuse_integration",
|
||||||
"observability/gcs_bucket_integration",
|
"observability/gcs_bucket_integration",
|
||||||
"observability/langsmith_integration",
|
"observability/langsmith_integration",
|
||||||
|
"observability/literalai_integration",
|
||||||
"observability/opentelemetry_integration",
|
"observability/opentelemetry_integration",
|
||||||
"observability/logfire_integration",
|
"observability/logfire_integration",
|
||||||
"observability/arize_integration",
|
"observability/arize_integration",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue