You can integrate with Helicone and bring data into PostHog for analysis. Additionally, we offer a dashboard template to help you quickly get insights into your LLM product.
How to install the integration
- Sign up for Helicone and add it to your app.
- Similar to how you set
Helicone-Auth
header when configuring your LLM client, add two new headersHelicone-Posthog-Key
andHelicone-Posthog-Host
with your PostHog host and API key (you can find these in your PostHog project settings):
client = OpenAI(api_key="your-api-key-here", # Replace with your OpenAI API keybase_url="https://oai.hconeai.com/v1", # Set the API endpointdefault_headers= {"Helicone-Auth": f"Bearer {HELICONE_API_KEY}","Helicone-Posthog-Key": "<ph_project_api_key>","Helicone-Posthog-Host": "https://us.i.posthog.com",})
Helicone events will now be exported into PostHog as soon as they're available.
Using the Helicone dashboard template
Once you've installed the integration, dashboard templates help you quickly set up relevant insights. You can see an example Helicone dashboard here.
To create your own dashboard from a template:
- Go the dashboard tab in PostHog.
- Click the New dashboard button in the top right.
- Select LLM metrics – Helicone from the list of templates.