Inspiration
I work for a logistic company, I've seen first hand the problem of unclassified documents that makes sense only for a couple of persons in the organization. Putting the right tools in the hands of everyone closes the gap between technical and non technical prople.
What it does
The project allows to bulk load any number of PDF files into S3, they are organized by its type, classified and extracted into folders and two different databases. Using a simple english interface any non technical user can find they data they looking for and interact with it.
How we built it
- Seven lambdas build this project, they load, extract, interpret the input data.
- Lambdas communicate with AWS services and foundation models to interact with the data.
- The stack is deployed using AWS CDK, instructions provided.
- For testing, I downloaded a dataset of diferent types of documents I found in Kaggle. It was very helpful because they contain orders, invoices, shipping orders, purcharse orders. So this project is some battle-tested I could say.
Challenges we ran into
- Lack of knowledge about Bedrock
Accomplishments that we're proud of
- The stack is relatively cheap and remains so due to its design
- The web interface was so easy to build once the API were in place
What we learned
- Before this project there zero knowledge about Bedrock nor how to invoke it with lambda.
- As of now
pgvectorextension has to be manually loaded once the RDS table is created. Probably a custom resource will do the trick but time was not in my side.
What's next for Smart Document Router with RAG capabilities
- I'd probably use Step functions instead of invoking lambdas sequentially
- I'd love to get feedback and see if this problem is shared with other organizations.
Built With
- amazon-dynamodb
- bedrock
- cdk
- lambda
- postgresql
- python
- rds
- s3
- typescript