Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/oss/langchain/messages.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1024,7 +1024,7 @@ for your chosen model for specifics.
const message = new HumanMessage({
content: [
{ type: "text", text: "Describe the content of this document." },
{ type: "file", source_type: "url", url: "https://example.com/path/to/document.pdf" },
{ type: "file", source_type: "url", url: "https://example.com/path/to/document.pdf", mime_type: "application/pdf" },
],
});

Expand All @@ -1036,6 +1036,7 @@ for your chosen model for specifics.
type: "file",
source_type: "base64",
data: "AAAAIGZ0eXBtcDQyAAAAAGlzb21tcDQyAAACAGlzb2...",
mime_type: "application/pdf",
},
],
});
Expand Down