traceloop / openllmetry

Open-source observability for your LLM application, based on OpenTelemetry
https://www.traceloop.com/openllmetry
Apache License 2.0
1.83k stars 150 forks source link

🚀 Feature: Tracing support for Amazon Bedrock knowledge bases #1659

Open tonykchen opened 1 month ago

tonykchen commented 1 month ago

Which component is this feature for?

Bedrock Instrumentation

🔖 Feature description

Add tracing support for Amazon Bedrock knowledge bases.

🎤 Why is this feature needed ?

Developers may configure their RAG application to use the RetrieveAndGenerate API to query their Bedrock knowledge base and generate responses from the information it retrieves. They may also call the Retrieve API to query their knowledge base with information retrieved directly from the knowledge base.

✌️ How do you aim to achieve this?

  1. Add instrumentation logic for the bedrock-agent-runtime service and patch the retreive and retrieve_and_generate methods.
  2. Create spans for the requests.

🔄️ Additional Information

No response

👀 Have you spent some time to check if this feature request has been raised before?

Are you willing to submit PR?

Yes I am willing to submit a PR!

tonykchen commented 1 month ago

I'll likely work on this one before https://github.com/traceloop/openllmetry/issues/1647

nirga commented 1 month ago

Thanks @tonykchen! Let me know if I can help :)