Helicone Community Page

m
mobob
Offline, last seen 2 months ago
Joined August 29, 2024
Hey folks,

I've tried to get custom properties working a couple different ways... but either i don't know where to look or they don't show up on the Helicone console. What am i missing?

Jamming em in in both spots below and don't see them anywhere on the requests.
Plain Text
import { HeliconeAsyncOpenAI as OpenAI } from '@helicone/helicone';

describe('helicone params test', () => {
  it('basic test to see if headers are going through', async () => {
    const apiKey = process.env['OPENAI_API_KEY'];

    const openai = new OpenAI({
      apiKey,
      heliconeMeta: {
        apiKey: process.env['HELICONE_API_KEY'],
      },
      defaultHeaders: {
        'Helicone-Property-Environment': 'TEST',
        'Helicone-Property-Feature': 'general',
      },
    });

    const response = await openai.completions.create(
      {
        model: 'gpt-3.5-turbo-instruct',
        prompt: 'Once upon a time',
      },
      {
        headers: {
          'Helicone-Property-Environment': 'TEST2',
          'Helicone-Property-Feature': 'general2',
        },
      },
    );

    console.log(`response: `, response);
  });
});


Let me know, i'm sure this is user error πŸ™‚
24 comments
1
J
A
c
C
S
Any chance there is a 2.1 -> 3.1 upgrade note for the Node SDK? I'm a laggard πŸ˜‡
6 comments
J
m