AWS for Industries

Transforming Siemens global search with generative AI  powered by AWS

Introduction

In today’s fast-paced digital world, providing customers with a seamless search experience is crucial for businesses to drive sales and improve customer satisfaction. Siemens is a leading technology company focused on industry, infrastructure, transportation and healthcare. Realizing the importance of serving their customers with an outstanding and efficient search experience, Siemens looked to generative AI (GenAI) technology to help transform their online search experience. This blog post explores how Siemens implemented an innovative AI search solution, built on Amazon Web Services (AWS), to address the diverse needs of their users while being policy compliant. We’ll dive deep into the underlying architecture, the challenges faced, and the innovative solutions employed to overcome them.

The Siemens search use case

The Siemens search functionality on siemens.com is a central pillar of the company’s public relations and communications strategy, supporting its industrial business. A well-designed search experience not only facilitates the discovery of relevant products and information but also contributes to higher sales and a positive brand reputation. Different users have varying search needs. For instance, an engineer might search for a specific product number, while an analyst might seek company information. The introduction of AI-powered search was driven by the need to provide a more personalized and contextual experience for users. The AI search aims to understand the user’s intent for using a generative AI model and then selects and combines information from more than 15 different sources to provide tailored responses. However, Siemens faced unexpected challenges implementing this AI search solution. Reputation is paramount for the company’s success, and ensuring the accuracy and relevance of search results is critical. Siemens needed to address the complexities of interpreting content from many sources, each with its own context, while adhering to strict communication guidelines across various languages in the combined responses.

Overview of the solution on AWS

To tackle the challenges of a public-facing search, Siemens leveraged the power of AWS to build a robust and scalable search solution and augmented it with a multi-layered set of guardrails. From a technical side, the architecture revolves around a serverless, multi-agent setup using AWS Lambda and Amazon Bedrock, with Amazon API Gateway serving as the entry point for user requests. AWS Lambda lets users run code without provisioning or managing servers, creating workload-aware cluster scaling logic, maintaining event integrations, or managing runtimes, while Amazon Bedrock is a fully managed service that offers a choice of high-performing foundation models (FMs) through a single API, along with a broad set of capabilities to build generative AI applications with security, privacy, and responsible AI.

The Siemens global search frontend allows the user to write their query, and multiple backend services provide different search capabilities in the form of microservices. In this blog, we focus only on the AI Search portion of the solution. Incoming search queries are first analyzed to determine the user’s intent and context, ensuring that the appropriate answering mechanism is employed. Based on the classified request, different answering options are chosen, ranging from retrieval-based approaches to generative AI models. This diversity allows the system to provide tailored responses that meet the user’s needs. The AI search then provides summarization and reformulation of these results tailored to the user request. On both arrival and before sending a response, guardrails are used that ensure the accuracy and appropriateness of search results.

AWS Services

Throughout the search answering process, the different agents use generative AI functionality. Most of the agents use the Amazon Bedrock services for prompting Large Language Models (LLMs) and augmented retrieval generation (RAG). This removes the need to manage and operate the underlying infrastructure. For tasks where additional customization is required, such as specialized document embeddings, the agents use custom models created and hosted on Amazon SageMaker. To improve answers, agents retrieve customized and up-to-date context for model prompts from Amazon DynamoDB tables, such as disallow-listed topics and terms, custom answering mechanisms tailored to specific scenarios, answers to frequent questions and recent facts. Several factors drove the choice of AWS and the architectural decisions including scalability, performance, and security considerations. For instance, the use of serverless services like AWS Lambda and Amazon Bedrock allow for efficient scaling and cost optimization, while ensuring the necessary computational power for the AI models. To understand how these services work together for solving the complex needs of this search use case, let us take a closer look at the data flow:

  • Main API Gateway: The process begins when a user submits a search query through the Siemens Global Search Account interface. The Amazon API Gateway receives this request and forwards it to the AWS Lambda function for AI search handling.
  • AWS Lambda function for AI Search Handling: This AWS Lambda function acts as the central orchestrator for the entire search process. It receives the search query from the API Gateway and coordinates the flow of data between different agents and services.
  • Validation Agent: This agent is the main guardrail and the first to process the incoming query. It checks the query against predefined criteria, such as disallowed topics, terms or known frequently asked questions to ensure it is valid and appropriate. The agent accepts or rejects the query based on its content and structure or provides an appropriate FAQ answer right away.
  • Intention Classification and Language Agents: After validation, the classification agent analyzes the query to determine the user’s intent. It classifies the query into categories such as “Product”, “Person”, or “Contact Request” and thereby helps to direct the search to the most relevant resources. To provide more relevant information, the language agent detects the language in which the question was asked, so that the prompt can be answered in the same language.
  • Product Search and Semantic Search: Based on the intention classification, the query is then passed to an appropriate search backend, such as the product Search, a search specialized on press communications, or are forwarded to domain specific searches. These agents perform targeted searches within their respective domains to find the most relevant results in their corresponding knowledge bases. To ensure that the information provided is current, the Recent Facts Search Agent is used to search an additional knowledge base containing recent information and announcements, such as press releases or other communications.
  • Summarizer Agents: Once search results are obtained, an appropriate Summarizer Agent for the type of information searched processes and condenses the information. It extracts key points and creates a concise summary of the search results, making it easier for users to quickly grasp the essential information. Also in this stage, the agent checks the context against the set of recent facts provided by the Facts Search.
  • Guardrail Agents: As the final step in each process, the Guardrail Agents review the AI-generated answer. They check it against predefined rules, policies and commonly asked questions provided as context to the model. If these guardrails approve the response, then it is sent back to the API Gateway, which delivers it to the user’s search interface.
  • Reformulation Agent: If an answer does not pass the initial Guardrails check, this agent attempts to reformulate the answer according to the Guardrail needs. The result is then provided again to the Guardrail Agents. This reduces removing answers when only minor details were detected by the guardrails.

Key Learnings

Siemens AI search solution has evolved over time, adapting to the needs of stakeholders and requirements of the business. Building on a strong foundation in traditional search, the focus of the information retrieval quickly moved to adding RAG to that search to provide the customer with more relevant search. Four factors were key for the successful creation of this high-performing search experience.

1. Models and services

The first success factor is the choice of managed LLMs and generative AI functionalities that Amazon Bedrock offers, which allows developers to easily experiment with and evaluate top FMs for the use case to optimize according to the user needs. For each task in the solution, multiple models were evaluated against each other. Priorities for this evaluation were to obtain reliable answers in multiple languages, sub-second latency, especially for guardrail queries, and cost-efficiency. At the time of writing, Anthropic Claude Sonnet and Haiku models are used as a default. In addition, evaluation of other models and features of Amazon Bedrock, such as Amazon Bedrock Guardrails and Amazon Bedrock Knowledge Bases, are continuously evaluated to further optimize the experience.

2. Systematic information gathering for guardrails

The second success factor is thorough stakeholder management to achieve comprehensive guardrails. In particular, the legal and compliance, investor relations, business and communications departments are key stakeholders, each with their own priorities and concerns. To respond to these priorities, the team continuously gathers input from these stakeholders to create three repositories: 1) disallow-listed topics, 2) keywords, and 3) custom answers to specific questions. These are used as context for the guardrail models and are the foundation of filtering AI Search results. Siemens implemented these guardrails in a staged approach with inputs used at different layers of filtering and validation. This allows the flexibly to efficiently consider the diversity of stakeholder needs.

3. Effective implementation of guardrails

The third factor was to thoroughly plan and design the guardrailing setup. More precisely, the Guardrails are implemented in a staged approach, with different layers of filtering and validation. The earlier a request can be found to be disallowed or a standard answer, the faster, the user can be served with an answer. Therefore, most effort was spent to optimize the guardrails that check the user request. In addition to providing fast answers if a request did not pass the validation, this is very cost-efficient because model inputs are generally small and no further processing needs to be performed.

4. Validation of guardrails with automated tests

The final success factor is to continuously validate the effectiveness of the guardrail mechanisms with automated tests. The solution includes a testing framework that automatically runs thousands of search queries to test if guardrails hold and edge cases are detected correctly. To achieve such deep coverage, initial test queries, contexts and topics are collected from users. The developers then use Amazon Bedrock to identify related topics and to generate many additional test cases. Using this extensive testing approach ensures that the search results adhere to the defined guidelines and enables continuous monitoring and improvement of the solution.

Conclusion

Siemens AI search solution on AWS demonstrates the power of generative AI in delivering intelligent information access while addressing the stringent compliance requirements of a public-facing use case. By leveraging AWS services such as AWS Lambda, Amazon Bedrock, and Amazon API Gateway, Siemens built a scalable and robust solution that provides a tailored, optimized search experiences for its users. To experience the search firsthand, visit the Siemens search website and explore how it guides users to the information they seek.

If you’re a business looking to innovate with generative AI while ensuring compliance and security, Siemens approach can serve as a valuable template. Using the learnings outlined in this post will help you accelerate your own journey. Start innovating with generative AI for your use case on AWS today. Reach out to your AWS account representative or contact the AWS sales team to learn more about how you can implement a similar solution and unlock the potential of AI-powered search for your organization.

Dr. Helge Aufderheide

Dr. Helge Aufderheide

Helge Aufderheide is passionate about using new technologies to innovate in traditional industries from manufacturing to railways. Coming from a physics background and moving into consulting, he has a strong focus on understanding real-world problems from business to engineering and then using automation, data analytics, (generative) AI or other smart technology architectures to solve them.

Christoph Lumme

Christoph Lumme

Christoph Lumme is an Enterprise Technology Architect with 20 years of web and e-commerce experience at Siemens. He specializes in secure, high-performance cloud solutions and delivering innovative, future-proof architectures.

Fabian Fischer

Fabian Fischer

Fabian Fischer is an Enterprise Information Technology Architect based in Erlangen, Germany, with over two decades of experience at Siemens. He is highly skilled in AWS cloud solutions, covering areas such as cloud security, infrastructure automation, and CI/CD practices. Fabian is also at the forefront of exploring emerging technologies, including Generative AI and Large Language Models (LLM). Passionate about both architecture and hands-on coding, he blends strategic vision with technical expertise to drive cloud adoption and innovation across the organization.

Dr. Markus Schweier

Dr. Markus Schweier

Dr. Markus Schweier is a Generative AI & ML Specialist at Amazon Web Services (AWS). He primarily focuses on large enterprises in the Automotive and Manufacturing industries, helping them develop innovative products, services, and solutions. With over 9 years of experience in digital transformation consulting and building scalable AI solutions, Markus advises customers on their AI adoption journey. His background is in Production Engineering, and he holds a Ph.D. in Engineering from the Technical University of Munich.