import { extractStructuredDataFromContent } from "@intuned/sdk/ai-extractors";
const content = [
{ type: "text", data: "Sample text data" },
{
type: "image-url",
image_type: "jpeg",
data: "https://example.com/image.jpg"
}
];
const options = {
label: "extract_contact_info",
dataSchema: {
type: "object",
properties: {
name: { type: "string", description: "contact name" },
phone: { type: "string", description: "contact info" }
}
},
model: "gpt4-turbo"
};
const data = await extractStructuredDataFromContent(content, options);
console.log(data);