hello
i saw sample code for python sdk for generative-ai using gemini-1.5-pro model (below snippet)
i tried doing the same using node sdk, but it keeps throwing a 500 error.
isn't this functionality available in the node sdk yet?
pdf_file_uri = "gs://cloud-samples-data/generative-ai/pdf/2403.05530.pdf"
prompt = """
Your are a very professional document summarization specialist.
Please summarize the given document.
"""
pdf_file = Part.from_uri(pdf_file_uri, mime_type="application/pdf")
contents = [pdf_file, prompt]
response = model.generate_content(contents)
print(response.text)
User | Count |
---|---|
2 | |
2 | |
1 | |
1 | |
1 |