Bayesian prompt ensembles: Model uncertainty estimation for black-box large language models

2024
Download Copy BibTeX
Copy BibTeX
An important requirement for the reliable deployment of pre-trained large language models (LLMs) is the well-calibrated quantification of the uncertainty in their outputs. While the likelihood of predicting the next token is a practical surrogate of the data uncertainty learned during training, model uncertainty is challenging to estimate, i.e., due to lack of knowledge acquired during training. Prior efforts to quantify uncertainty of neural networks require specific architectures or (re-)training strategies, which are impractical to apply to LLMs with several billion parameters, or for black-box models where the architecture and parameters are not available. In this paper, we propose Bayesian Prompts Ensembles (BayesPE), a novel approach to effectively obtain well-calibrated uncertainty for the output of pre-trained LLMs. BayesPE computes output probabilities through a weighted ensemble of different, but semantically equivalent, task instruction prompts. The relative weights of the different prompts in the ensemble are estimated through approximate Bayesian variational inference over a small labeled validation set. We demonstrate that BayesPE approximates a Bayesian input layer for the LLM, providing a lower bound on the expected model error. In our extensive experiments, we show that BayesPE achieves significantly superior uncertainty calibration compared to several baselines over a range of natural language classification tasks, both in zero- and few-shot settings.
Research areas

Latest news

US, WA, Bellevue
WW Amazon Stores Finance Science (ASFS) works to leverage science and economics to drive improved financial results, foster data backed decisions, and embed science within Finance. ASFS is focused on developing products that empower controllership, improve business decisions and financial planning by understanding financial drivers, and innovate science capabilities for efficiency and scale. We are looking for an outstanding data scientist to lead high visibility initiatives for forecasting Amazon Stores' financials. You will develop new science-based forecasting methodologies and build scalable models to improve financial decision making and planning for senior leadership up to VP and SVP level. You will build new ML and statistical models from the ground up that aim to transform financial planning for Amazon Stores. We prize creative problem solvers with the ability to draw on an expansive methodological toolkit to transform financial decision-making with science. The ideal candidate combines data-science acumen with strong business judgment. You have versatile modeling skills and are comfortable owning and extracting insights from data. You are excited to learn from and alongside seasoned scientists, engineers, and business leaders. You are an excellent communicator and effectively translate technical findings into business action. Key job responsibilities Demonstrating thorough technical knowledge on feature engineering with large datasets, effective exploratory data analysis, and model building using industry standard ML models Working with technical and non-technical stakeholders across every step of science project life cycle Collaborating with finance, product, data engineering, and software engineering teams to create production implementations for large-scale ML models Innovating by adapting new modeling techniques and procedures Presenting research results to our internal research community
LU, Luxembourg
Have you ever wished to build high standard Operations Research and Machine Learning algorithms to optimize one of the most complex logistics network? Have you ever ordered a product on Amazon websites and wondered how it got delivered to you so fast, and what kinds of algorithms & processes are running behind the scenes to power the whole operation? If so, this role is for you. The team: Global transportation services, Research and applied science - Operations is at the heart of the Amazon customer experience. Each action we undertake is on behalf of our customers, as surpassing their expectations is our passion. We improve customer experience through continuously optimizing the complex movements of goods from vendors to customers throughout Europe. - Global transportation analytical teams are transversal centers of expertise, composed of engineers, analysts, scientists, technical program managers and developers. We are focused on Amazon most complex problems, processes and decisions. We work with fulfillment centers, transportation, software developers, finance and retail teams across the world, to improve our logistic infrastructure and algorithms. - GTS RAS is one of those Global transportation scientific team. We are obsessed by delivering state of the art OR and ML tools to support the rethinking of our advanced end-to-end supply chain. Our overall mission is simple: we want to implement the best logistics network, so Amazon can be the place where our customers can be delivered the next-day. The role: Applied scientist, speed and long term network design The person in this role will have end-to-end ownership on augmenting RAS Operation Research and Machine Learning modeling tools. They will help understand where are the constraints in our transportation network, and how we can remove them to make faster deliveries at a lower cost. Concretely, you will be responsible for designing and implementing state-of-the-art algorithmic in transportation planning and network design, to expand the scope of our Operations Research and Machine Learning tools, to reflect the constantly evolving constraints in our network. You will enable the creation of a product that drives ever-greater automation, scalability and optimization of every aspect of transportation, planning the best network and modeling the constraints that prevent us from offering more speed to our customer, to maximize the utilization of the associated resources. The impact of your work will be in the Amazon EU global network. The product you will build will span across multiple organizations that play a role in Amazon’s operations and transportation and the shopping experience we deliver to customer. Those stakeholders include fulfilment operations and transportation teams; scientists and developers, and product managers. You will understand those teams constraints, to include them in your product; you will discuss with technical teams across the organization to understand the existing tools and assess the opportunity to integrate them in your product. You will also be challenged to think several steps ahead so that the solutions you are building today will scale well with future growth and objective (e.g.: sustainability). You will engage with fellow scientists across the globe, to discuss the solutions they have implemented and share your peculiar expertise with them. This is a critical role and will require an aptitude for independent initiative and the ability to drive innovation in transportation planning and network design. Successful candidates should be able to design and implement high quality algorithm solutions, using state-of-the art Operations Research and Machine Learning techniques. You will have the opportunity to thrive in a highly collaborative, creative, analytical, and fast-paced environment oriented around building the world’s most flexible and effective transportation planning and network design management technology. Key job responsibilities - Engage with stakeholders to understand what prevents them to build a better transportation network for Amazon - Review literature to identify similar problems, or new solving techniques - Build the mathematical model representing your problem - Implement light version of the model, to gather early feed-back from your stakeholders and fellow scientists - Implement the final product, leveraging the highest development standards - Share your work in internal and external conferences - Train on the newest techniques available in your field, to ensure the team stays at the highest bar About the team GTS Research and Applied Science is a team of 15 scientists and engineers whom mission is to build the best decision support tools for strategic decisions. We model and optimize Amazon end-to-end operations. The team is composed of enthusiastic members, that love to discuss any scientific problem, foster new ideas and think out of the box. We are eager to support each others and share our unique knowledge to our colleagues.
IL, Haifa
Come build the future of entertainment with us. Are you interested in helping shape the future of movies and television? Do you want to help define the next generation of how and what Amazon customers are watching? Prime Video is a premium streaming service that offers customers a vast collection of TV shows and movies - all with the ease of finding what they love to watch in one place. We offer customers thousands of popular movies and TV shows from Originals and Exclusive content to exciting live sports events. We also offer our members the opportunity to subscribe to add-on channels which they can cancel at any time and to rent or buy new release movies and TV box sets on the Prime Video Store. Prime Video is a fast-paced, growth business - available in over 240 countries and territories worldwide. The team works in a dynamic environment where innovating on behalf of our customers is at the heart of everything we do. If this sounds exciting to you, please read on As a Prime Video technologist, you’ll have end-to-end ownership of the product, user experience, design, and technology required to deliver state-of-the-art experiences for our customers. You’ll get to work on projects that are fast-paced, challenging, and varied. You’ll also be able to experiment with new possibilities, take risks, and collaborate with remarkable people. We’ll look for you to bring your diverse perspectives, ideas, and skill-sets to make Prime Video even better for our customers. With global opportunities for talented technologists, you can decide where a career Prime Video Tech takes you! Key job responsibilities As an Applied Scientist at Prime Video, you will have end-to-end ownership of the product, related research and experimentation, applying advanced machine learning techniques in computer vision (CV), natural language processing (NLP), multimedia understanding and so on. You’ll work on diverse projects that enhance Prime Video’s recommendation systems, image/video understanding, and content personalization, driving impactful innovations for our global audience. Other responsibilities include: - Lead cutting-edge research in computer vision and natural language processing, applying it to video-centric media challenges. - Develop scalable machine learning models to enhance media asset generation, content discovery, and personalization. - Collaborate closely with engineering teams to integrate your models into production systems at scale, ensuring optimal performance and reliability. - Actively participate in publishing your research in leading conferences and journals. - Lead a team of skilled applied scientists, you will shape the research strategy, create forward-looking roadmaps, and effectively communicate progress and insights to senior leadership - Stay up-to-date with the latest advancements in AI and machine learning to drive future research initiatives. About the team At Prime Video, we strive to deliver the best-in-class entertainment experiences across devices for millions of customers. Whether it’s developing new personalization algorithms, improving video content discovery, or building robust media processing systems, our scientists and engineers tackle real-world challenges daily. You’ll be part of a fast-paced environment where experimentation, risk-taking, and innovation are encouraged.
BR, SP, Sao Paulo
The Transportation Data Scientist is responsible for leveraging data analytics and machine learning techniques to gain insights and drive decision-making for transportation-related challenges. This role involves working closely with all miles from transportation, planning areas, and engineering teams to identify, collect, and analyze relevant data to uncover patterns, trends, and predictions that can optimize transportation systems and services. Key job responsibilities Collaborate with cross-functional teams to understand transportation challenges and identify data sources that can provide valuable insights Design and implement data collection, processing, and storage pipelines to gather and manage large-scale transportation data (e.g., traffic sensor data, vehicle telematics, rideshare data, infrastructure utilization, etc.); Develop advanced analytical models and machine learning algorithms to analyze transportation data and generate predictive insights (e.g., demand forecasting, route optimization, infrastructure maintenance planning, etc.) Visualize and present data-driven insights and recommendations to stakeholders, including transportation miles (ATS, AMZL, 3P carriers and Air), operations teams, and decision-makers. Stay up-to-date with the latest trends, technologies, and best practices in transportation data science and analytics; Contribute to the development and improvement of the organization's transportation data strategy and capabilities.
US, WA, Bellevue
Alexa International Tech (AIT) team is looking for a passionate, talented, and inventive Applied Scientist to help build industry-leading technology with Large Language Models (LLMs) and multimodal systems, requiring strong deep learning and generative models knowledge. Key job responsibilities As an Applied Scientist with the AIT team, you will work with talented peers to develop novel algorithms and modeling techniques to advance the state of the art with LLMs. Your work will directly impact our international customers in the form of products and services that make use of digital assistance technology. You will leverage Amazon’s heterogeneous data sources, unique but diverse international customer nuances and large-scale computing resources to accelerate advances in voice domain in multi-modal setup. The ideal candidate possesses a solid understanding of machine learning fundamentals and a passion for pushing boundaries in this vast and quickly evolving field. They thrive in fast-paced environments to will tackle complex challenges, and excel at swiftly delivering impactful solutions while iterating based on user feedback. A day in the life · Analyze, understand, and model customer behavior and the customer experience based on large scale data. Especially showing passion towards solving for international customer-centric challenges. · Build novel online & offline evaluation metrics an methodologies for personal digital assistants and customer scenarios, on multi-modal devices. · innovate and deliver deep learning based innovation across life-cycle such as policy-based learning, international customer specific model performance tuning. · Quickly experiment and setup experimentation framework for agile model and data analysis or A/B testing · Contribute through industry first research to drive the innovation forward.
FR, Courbevoie
Amazon launched the Generative AI Innovation Center (GenAIIC) in June 2023 to help AWS customers accelerate the use of generative AI to solve business and operational problems and promote innovation in their organization. This is a team of strategists, data scientists, engineers, and solution architects working step-by-step with customers to build bespoke solutions that harness the power of generative AI.(https://press.aboutamazon.com/2023/6/aws-announces- generative-ai-innovation-center). We’re looking for Data Scientists capable of using generative AI and other techniques to design, evangelize, and implement state-of-the-art solutions for never-before-solved problems. You will work directly with customers and innovate in a fast-paced organization that contributes to game-changing projects and technologies. You will design and run experiments, research new algorithms, and find new ways of optimizing risk, profitability, and customer experience. AWS Sales, Marketing, and Global Services (SMGS) is responsible for driving revenue, adoption, and growth from the largest and fastest growing small- and mid-market accounts to enterprise-level customers including public sector. The AWS Global Support team interacts with leading companies and believes that world-class support is critical to customer success. AWS Support also partners with a global list of customers that are building mission-critical applications on top of AWS services. Key job responsibilities As a Data Scientist, you will - Collaborate with AI/ML scientists, engineers, and architects to research, design, develop, and evaluate cutting-edge generative AI algorithms to address real-world challenges - Interact with customers directly to understand the business problem, help and aid them in implementation of generative AI solutions, deliver briefing and deep dive sessions to customers and guide customer on adoption patterns and paths to production - Create and deliver best practice recommendations, tutorials, blog posts, sample code, and presentations adapted to technical, business, and executive stakeholder - Provide customer and market feedback to Product and Engineering teams to help define product direction About the team The team helps customers imagine and scope the use cases that will create the greatest value for their businesses, select and train or fine tune the right models, define paths to navigate technical or business challenges, develop proof-of-concepts, and make plans for launching solutions at scale. The Generative AI Innovation Center team provides guidance on best practices for applying generative AI responsibly and cost efficiently. Diverse Experiences AWS values diverse experiences. Even if you do not meet all of the qualifications and skills listed in the job description, we encourage candidates to apply. If your career is just starting, hasn’t followed a traditional path, or includes alternative experiences, don’t let it stop you from applying. Why AWS? Amazon Web Services (AWS) is the world’s most comprehensive and broadly adopted cloud platform. We pioneered cloud computing and never stopped innovating — that’s why customers from the most successful startups to Global 500 companies trust our robust suite of products and services to power their businesses. Inclusive Team Culture Here at AWS, it’s in our nature to learn and be curious. Our employee-led affinity groups foster a culture of inclusion that empower us to be proud of our differences. Ongoing events and learning experiences, including our Conversations on Race and Ethnicity (CORE) and AmazeCon (gender diversity) conferences, inspire us to never stop embracing our uniqueness. Mentorship & Career Growth We’re continuously raising our performance bar as we strive to become Earth’s Best Employer. That’s why you’ll find endless knowledge-sharing, mentorship and other career-advancing resources here to help you develop into a better-rounded professional. Work/Life Balance We value work-life harmony. Achieving success at work should never come at the expense of sacrifices at home, which is why we strive for flexibility as part of our working culture. When we feel supported in the workplace and at home, there’s nothing we can’t achieve in the cloud.
IN, KA, Bengaluru
Do you want to join an innovative team of scientists who use machine learning and statistical techniques to create state-of-the-art solutions for providing better value to Amazon’s customers? Do you want to build and deploy advanced ML systems that help optimize millions of transactions every day? Are you excited by the prospect of analyzing and modeling terabytes of data to solve real-world problems? Do you like to own end-to-end business problems/metrics and directly impact the profitability of the company? Do you like to innovate and simplify? If yes, then you may be a great fit to join the Machine Learning team for India Consumer Businesses. Machine Learning, Big Data and related quantitative sciences have been strategic to Amazon from the early years. Amazon has been a pioneer in areas such as recommendation engines, ecommerce fraud detection and large-scale optimization of fulfillment center operations. As Amazon has rapidly grown and diversified, the opportunity for applying machine learning has exploded. We have a very broad collection of practical problems where machine learning systems can dramatically improve the customer experience, reduce cost, and drive speed and automation. These include product bundle recommendations for millions of products, safeguarding financial transactions across by building the risk models, improving catalog quality via extracting product attribute values from structured/unstructured data for millions of products, enhancing address quality by powering customer suggestions We are developing state-of-the-art machine learning solutions to accelerate the Amazon India growth story. Amazon India is an exciting place to be at for a machine learning practitioner. We have the eagerness of a fresh startup to absorb machine learning solutions, and the scale of a mature firm to help support their development at the same time. As part of the India Machine Learning team, you will get to work alongside brilliant minds motivated to solve real-world machine learning problems that make a difference to millions of our customers. We encourage thought leadership and blue ocean thinking in ML. Key job responsibilities Use machine learning and analytical techniques to create scalable solutions for business problems Analyze and extract relevant information from large amounts of Amazon’s historical business data to help automate and optimize key processes Design, develop, evaluate and deploy, innovative and highly scalable ML models Work closely with software engineering teams to drive real-time model implementations Work closely with business partners to identify problems and propose machine learning solutions Establish scalable, efficient, automated processes for large scale data analyses, model development, model validation and model maintenance Work proactively with engineering teams and product managers to evangelize new algorithms and drive the implementation of large-scale complex ML models in production Leading projects and mentoring other scientists, engineers in the use of ML techniques About the team International Machine Learning Team is responsible for building novel ML solutions that attack India first (and other Emerging Markets across MENA and LatAm) problems and impact the bottom-line and top-line of India business. Learn more about our team from https://www.amazon.science/working-at-amazon/how-rajeev-rastogis-machine-learning-team-in-india-develops-innovations-for-customers-worldwide
US, CA, Sunnyvale
Want to help develop the next generation of intelligent assistant products? Join us! We are looking for a talented Applied Science Manager to help us. Key job responsibilities You will lead a team of scientists to improve our RAG applications. You will be responsible for: (i) developing novel retrieval and ranking models and partnering closely with engineering to improve model performance; (ii) improve content and query understanding models to deliver improved signal to retrieval and ranking models; (iii) partner closely with content acquisition and LLM client teams to ensure our dependencies are met and we’re delivering value to the end customers, enhancing information grounding for LLMs; (iv) develop a science roadmap, including publication opportunities and how we can accelerate delivery of customer impact; (v) coach and develop the team, hire, and hold the bar on scientific rigor throughout the team. A day in the life A mix of (i) technical deep dives: working with the team to develop the right models, setup good experiments, debug models, etc. (ii) coaching and development: providing feedback, setting up mechanisms to ensure the team’s success, and (iii) working with customers and dependency teams to ensure delivery.
US, WA, Bellevue
Amazon’s maps play a crucial role in our vehicle navigation, routing, and planning problems to ensure fast and safe deliveries to our customers. As part of the Last Mile Geospatial Science organization, you’ll partner closely with other scientists and engineers in a collegial environment with a clear path to business impact. We have an exciting problem area to augment the maps and routing inputs from satellite/aerial imagery and street videos by leveraging the latest computer vision and deep learning techniques. Key job responsibilities Successful candidates should have a deep knowledge (both theoretical and practical) of various machine learning algorithms for large scale computer vision problems, the ability to map models into production-worthy code, the communication skills necessary to explain complex technical approaches to a variety of stakeholders and customers, and the excitement to take iterative approaches to tackle big, long term problems. The applied scientist should be proficient with image and video analysis using machine learning, including designing architecture from scratch, modify existing loss functions, full model training, fine-tuning, and evaluating the latest deep learning models. The Applied Scientist optimizes different models for specific platforms, including edge devices with restricted resources. Multi-modal models, e.g., Large Vision Language Models (LVLM), zero-shot, few-shot, and semi-supervised learning paradigms are used extensively. A day in the life If you are not sure that every qualification on the list above describes you exactly, we'd still love to hear from you! At Amazon, we value people with unique backgrounds, experiences, and skillsets. If you’re passionate about this role and want to make an impact on a global scale, please apply! Amazon offers a full range of benefits that support you and eligible family members, including domestic partners and their children. Benefits can vary by location, the number of regularly scheduled hours you work, length of employment, and job status such as seasonal or temporary employment. The benefits that generally apply to regular, full-time employees include: 1. Medical, Dental, and Vision Coverage 2. Maternity and Parental Leave Options 3. Paid Time Off (PTO) 4. 401(k) Plan
US, WA, Seattle
We are seeking a talented and analytical Data Scientist to join our team and drive data-driven insights and solutions. In this role, you will be responsible for performing exploratory data analysis, developing and deploying predictive models, and leveraging advanced analytics techniques to uncover valuable insights and support data-driven decision-making across the organization. Key job responsibilities • Collaborate with our applied and data scientists to build robust and scalable Generative AI solutions for business problems • Effectively use Foundation Models available on Amazon Bedrock and Amazon SageMaker to meet our customer's performance needs • Work hands on to build scalable cloud environment for our customers to label data, build, train, tune and deploy their models • Interact with customer directly to understand the business problem, help and aid them in implementation of their ML ecosystem • Analyze and extract relevant information from large amounts of historical data to help automate and optimize key processes • Work closely with partner teams to drive model implementations and new algorithms About the team Amazon Web Services (AWS) provides a scalable cloud computing platform to companies globally. AWS Global Services (GS), formed in 2022, delivers customer success throughout the cloud adoption lifecycle. Our 25K+ employees and integrated offerings enable us to combine technology and human expertise to maximize and accelerate customer outcomes. GS is comprised of four primary business units: 1) Global Services Security (GSS) provides security guidance and offerings, 2) Training & Certification (T&C) offers cloud skills training and certification, 3) Professional Services (ProServe) provides consulting and hands-on-keyboard services, and 4) Support and AWS Managed Services (Support) delivers 24/7 technical support and managed services. Together, these teams continuously improve our systems and processes to enable better results for both customers and employees, with the GS Strategy & Operations (GSS) teams supporting each. GSSO enables integrated business support, product management, planning, and deal strategy for GS. GSSO understands customer experiences and inspires bold ideas to deliver the best experiences and solutions to our customers. We embrace scientific thinking, pursue continuous improvement, and develop talent to provide world-class support across GS. About AWS Diverse Experiences AWS values diverse experiences. Even if you do not meet all of the preferred qualifications and skills listed in the job description, we encourage candidates to apply. If your career is just starting, hasn’t followed a traditional path, or includes alternative experiences, don’t let it stop you from applying. Why AWS? Amazon Web Services (AWS) is the world’s most comprehensive and broadly adopted cloud platform. We pioneered cloud computing and never stopped innovating — that’s why customers from the most successful startups to Global 500 companies trust our robust suite of products and services to power their businesses. Inclusive Team Culture Here at AWS, it’s in our nature to learn and be curious. Our employee-led affinity groups foster a culture of inclusion that empower us to be proud of our differences. Ongoing events and learning experiences, including our Conversations on Race and Ethnicity (CORE) and AmazeCon (gender diversity) conferences, inspire us to never stop embracing our uniqueness. Mentorship & Career Growth We’re continuously raising our performance bar as we strive to become Earth’s Best Employer. That’s why you’ll find endless knowledge-sharing, mentorship and other career-advancing resources here to help you develop into a better-rounded professional. Work/Life Balance We value work-life harmony. Achieving success at work should never come at the expense of sacrifices at home, which is why we strive for flexibility as part of our working culture. When we feel supported in the workplace and at home, there’s nothing we can’t achieve in the cloud. Hybrid Work We value innovation and recognize this sometimes requires uninterrupted time to focus on a build. We also value in-person collaboration and time spent face-to-face. Our team affords employees options to work in the office every day or in a flexible, hybrid work model near one of our US Amazon offices.