- Newest
- Most votes
- Most comments
The difference in behavior you're experiencing between the Bedrock Playground and the Bedrock API regarding embedded URLs in PDFs is related to a recent feature enhancement in Amazon Bedrock Data Automation (BDA).
According to recent updates, Amazon Bedrock Data Automation now supports extraction of embedded hyperlinks when processing documents in Standard Output. This feature specifically enables BDA to detect and return embedded hyperlinks found in PDFs as part of the standard output, enhancing information extraction capabilities and preserving valuable link references.
When you use the Bedrock Playground, it likely leverages this enhanced document processing capability automatically. However, when using the direct API approach with InvokeModelCommand, you're bypassing some of these document preprocessing features.
For your NodeJS implementation, you're using the basic model invocation which doesn't automatically apply the same document processing enhancements. The model can see and describe the visible content (images, text) but doesn't have access to the embedded URL metadata.
To resolve this issue, you might want to:
- Consider using Amazon Bedrock Data Automation services directly if you specifically need to extract embedded hyperlinks from PDFs
- Ensure you're using the latest version of the AWS SDK for JavaScript
- Check if there are specific parameters or preprocessing steps you can add to your API call to enable enhanced document processing
The model can only work with what's visually present in the document when using the basic API approach, while the Playground might be applying additional document processing capabilities behind the scenes.
Sources
Amazon Bedrock Data Automation now supports modality controls, hyperlinks and larger documents - AWS
answered a year ago
