Skip to content

Commit 64bdd6c

Browse files
committed
update example and remove test code
1 parent f227b28 commit 64bdd6c

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

packages/sdk/server-ai/examples/langchain-chat/README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ This example demonstrates how to use the LaunchDarkly AI SDK with LangChain for
55
## Prerequisites
66

77
1. A LaunchDarkly account and SDK key
8-
2. An OpenAI API key (for the LangChain integration)
9-
3. Node.js 16 or later
8+
1. An OpenAI API key (for the LangChain integration)
9+
1. Node.js 16 or later
1010

1111
## Setup
1212

@@ -15,7 +15,7 @@ This example demonstrates how to use the LaunchDarkly AI SDK with LangChain for
1515
yarn install
1616
```
1717

18-
2. Set up environment variables:
18+
1. Set up environment variables:
1919
```bash
2020
cp .env.example .env
2121
```
@@ -27,7 +27,7 @@ This example demonstrates how to use the LaunchDarkly AI SDK with LangChain for
2727
LAUNCHDARKLY_AI_CONFIG_KEY=sample-ai-chat-config
2828
```
2929

30-
3. Create an AI Config in LaunchDarkly with the key `sample-ai-config`:
30+
1. Create an AI Config in LaunchDarkly with the key `sample-ai-config`:
3131
```json
3232
{
3333
"_ldMeta": {
@@ -62,10 +62,10 @@ yarn start
6262

6363
This will:
6464
1. Initialize the LaunchDarkly client
65-
2. Create a chat configuration using the AI Config
66-
3. Send a message to the AI and display the response
67-
4. Continue the conversation with a follow-up question
68-
5. Automatically track interaction metrics (duration, tokens, success/error)
65+
1. Create a chat configuration using the AI Config
66+
1. Send a message to the AI and display the response
67+
1. Continue the conversation with a follow-up question
68+
1. Automatically track interaction metrics (duration, tokens, success/error)
6969

7070
## Features Demonstrated
7171

packages/sdk/server-ai/examples/langchain-chat/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ if (!sdkKey) {
1313
}
1414

1515
// Initialize LaunchDarkly client
16-
const ldClient = init(sdkKey, { eventsUri: 'https://fd9486c18583.ngrok-free.app' });
16+
const ldClient = init(sdkKey);
1717

1818
// Set up the context properties. This context should appear on your LaunchDarkly contexts dashboard
1919
// soon after you run the demo.

0 commit comments

Comments
 (0)