llm orchestration⏱10 minutes

Get Started with Refiner Js

Quick Summary

“Convert and store text as vector embeddings using OpenAI and Pinecone.”

Best for: Developers needing AI-powered search
Time to first integration: 10 minutes

📋Prerequisites

  • ✓Node.js 18+ installed
  • ✓A Refiner Js account — sign up here
  • ✓An existing project (Next.js, React, or Node.js recommended)

Setup Steps

3 steps
1

Install Refiner Js

Add Refiner Js to your project using npm.

bash
npm install refiner-js
2

Configure OpenAI and Pinecone

Set up API keys for OpenAI and Pinecone in your environment.

bash
export OPENAI_API_KEY='your-key' && export PINECONE_API_KEY='your-key'
3

Initialize Refiner Js

Import and initialize Refiner Js in your TypeScript project.

typescript
import { Refiner } from 'refiner-js'; const refiner = new Refiner();

Common Gotchas

Watch out for these issues in your first week.

API key misconfiguration

Fix: Ensure API keys for OpenAI and Pinecone are correctly set in the environment variables.

TypeScript type errors

Fix: Ensure TypeScript is properly configured in your project to avoid type errors.

Links