Extract structured data from web pages using the OpenAI API.
npm install @nomland/elephant
Variable | Value |
---|---|
OPENAI_MODEL | The OpenAI model name (gpt-3.5-turbo-16k or gpt-4-1106-preview recommended) |
OPENAI_API_KEY | Your OpenAI API key |
To use an Azure OpenAI endpoint, visit the Typechat documentation.
Run examples:
npm run start
or use elephant in project
import {extract} from @nomland/elephant
await extract('https://test.com/example-page')
Move examples to ./examples Extract IPFS url if existed