Alternatives to TruLens Dashboard When Logs Are Stored in Elasticsearch #2273
Replies: 1 comment
-
|
Hi @aryarishik-7, glad to hear the framework is useful for you! We don’t have a direct integration yet with elasticsearch yet, but TruLens is compatible with relational databases via sqlalchemy. I’d recommend logging to Postgres and then piping your data from Postgres to logstash/elasticsearch. You can connect to Postgres via SqlAlchemy by passing the database URL. from trulens.core.session import TruSession
from trulens.core.database.connector.default import DefaultDBConnector
connector = DefaultDBConnector(database_url = "+psycopg://trulensuser:password@localhost/trulens")
session = TruSession(connector = connector)Then you should be able to pipe over the data from Postgres to logstash following this guide: https://www.cdata.com/kb/tech/postgresql-jdbc-elasticsearch-logstash.rst Down the road if you wanted to build a direct integration so TruLens can write directly to logstash, we’d welcome that too! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
We have previously built an agentic system and used its logs to generate evaluation metrics via the TruLens GPA framework. This workflow creates a SQLite file, which can then be visualized using the built-in TruLens dashboard.
However, we’re required to store all logs in Logstash/Elasticsearch—so using SQLite isn’t an option. I can still leverage TruLens to generate feedback and evaluation metrics, but without the SQLite file, the dashboard visualization is no longer supported.
One workaround I’m considering is building a custom Kibana dashboard to visualize the metrics stored in Elasticsearch. Before I go down that path, I wanted to ask:
Would love to hear your thoughts or suggestions!
Thanks in advance.
Beta Was this translation helpful? Give feedback.
All reactions