Skip to main content

nlux and ChatGPT

How to connect nlux to ChatGPT

nlux provides a built-in adapter for connecting to OpenAI's API, which you can use to connect to ChatGPT.

Installation

npm install @nlux/openai-react

Usage

import {useUnsafeChatAdapter} from '@nlux/openai-react';

const Component = () => {
const adapter = useUnsafeChatAdapter({
[option name]: <option value>,
});
}