Amazon Q Enterprise is a generative AI-powered assistant designed to boost enterprise operations. It’s a totally managed service that helps present correct solutions to customers’ questions whereas adhering to the safety and entry restrictions of the content material. You’ll be able to tailor Amazon Q Enterprise to your particular enterprise wants by connecting to your organization’s data and enterprise techniques utilizing built-in connectors to quite a lot of enterprise information sources. It allows customers in numerous roles, comparable to advertising and marketing managers, venture managers, and gross sales representatives, to have tailor-made conversations, clear up enterprise issues, generate content material, take motion, and extra, by an online interface. This service goals to assist make staff work smarter, transfer quicker, and drive important impression by offering speedy and related data to assist them with their duties.
One such enterprise information repository you need to use to retailer and handle content material is Google Drive. Google Drive is a cloud-based storage service that gives a centralized location for storing digital property, together with paperwork, information articles, and spreadsheets. This service helps your groups collaborate successfully by enabling the sharing and group of necessary recordsdata throughout the enterprise. To make use of Google Drive inside Amazon Q Enterprise, you may configure the Amazon Q Enterprise Google Drive connector. This connector permits Amazon Q Enterprise to securely index recordsdata saved in Google Drive utilizing entry management lists (ACLs). These ACLs guarantee that customers solely entry the paperwork they’re permitted to view, permitting them to ask questions and retrieve data related to their work immediately by Amazon Q Enterprise.
This publish covers the steps to configure the Amazon Q Enterprise Google Drive connector, together with authentication setup and verifying the safe indexing of your Google Drive content material.
Index Google Drive paperwork utilizing the Amazon Q Google Drive connector
The Amazon Q Google Drive connector can index Google Drive paperwork hosted in a Google Workspace account. The connector can’t index paperwork saved on Google Drive in a private Google Gmail account. Amazon Q Enterprise can authenticate along with your Google Workspace utilizing a service account or OAuth 2.0 authentication. A service account allows indexing recordsdata for person accounts throughout an enterprise in a Google Workspace. Utilizing OAuth 2.0 authentication permits for crawling and indexing recordsdata in a single Google Workspace account. This publish reveals you the way to configure Amazon Q Enterprise to authenticate utilizing a Google service account.
Google prescribes that with a purpose to index a number of customers’ paperwork, the crawler should assist the aptitude to authenticate with a service account with domain-wide delegation. This enables the connector to index the paperwork of all customers in your drive and shared drives. Amazon Q Enterprise connectors solely crawl the paperwork that the Amazon Q Enterprise utility administrator specifies must be crawled. Directors can specify the paths to crawl, particular file identify patterns, or varieties. Amazon Q Enterprise doesn’t use buyer information to coach any fashions. All buyer information is listed solely within the buyer account. Additionally, Amazon Q Enterprise Connectors will solely index content material specified by the administrator. It gained’t index any content material by itself with out explicitly being configured to take action by the administrator of Amazon Q Enterprise.
You’ll be able to configure the Amazon Q Google Drive connector to crawl and index file varieties supported by Amazon Q Enterprise. Google Write paperwork are exported as Microsoft Phrase and Google Sheet paperwork are exported as Microsoft Excel through the crawling part.
Metadata
Each doc has structural attributes—or metadata—connected to it. Doc attributes can embody data comparable to doc title, doc creator, time created, time up to date, and doc sort.
While you join Amazon Q Enterprise to a knowledge supply, it mechanically maps particular information supply doc attributes to fields inside an Amazon Q Enterprise index. If a doc attribute in your information supply doesn’t have an attribute mapping already out there, or if you wish to map extra doc attributes to index fields, you need to use the customized discipline mappings to specify how an information supply attribute maps to an Amazon Q Enterprise index discipline. You’ll be able to create discipline mappings by enhancing your information supply after your utility and retriever are created.
There are 4 default metadata attributes listed for every Google Drive doc: authors, supply URL, creation date, and final replace date. It’s also possible to choose extra reserved information discipline mappings.
Amazon Q Enterprise crawls Google Drive ACLs outlined in a Google Workspace for doc safety. Google Workspace customers and teams are mapped to the _user_id
and _group_ids
fields related to the Amazon Q Enterprise utility in AWS IAM Id Heart. These person and group associations are continued within the person retailer related to the Amazon Q Enterprise index created for crawled Google Drive paperwork.
Overview of ACLs in Amazon Q Enterprise
Within the context of information administration and generative AI chatbot functions, an ACL performs an important function in managing who can entry data and what actions they’ll carry out inside the system. Additionally they facilitate information sharing inside particular teams or groups whereas limiting entry to others.
On this answer, we deploy an Amazon Q net expertise to reveal that two enterprise customers can solely ask questions on paperwork they’ve entry to in accordance with the ACL. With the Amazon Q Enterprise Google Drive connector, the Google Workspace ACL shall be ingested with paperwork. This permits Amazon Q Enterprise to regulate the scope of paperwork that every person can entry within the Amazon Q net expertise.
Authentication varieties
An Amazon Q Enterprise utility requires you to make use of IAM Id Heart to handle person entry. Though it’s beneficial to have an IAM Id Heart occasion configured (with customers federated and teams added) earlier than you begin, it’s also possible to select to create and configure an IAM Id Heart occasion to your Amazon Q Enterprise utility utilizing the Amazon Q console.
It’s also possible to add customers to your IAM Id Heart occasion from the Amazon Q Enterprise console, in the event you aren’t federating id. While you add a brand new person, guarantee that the person is enabled in your IAM Id Heart occasion and that they’ve verified their electronic mail ID. They should full these steps earlier than they’ll log in to your Amazon Q Enterprise net expertise.
Your id supply in IAM Id Heart defines the place your customers and teams are managed. After you configure your id supply, you may search for customers or teams to grant them single sign-on entry to AWS accounts, functions, or each.
You’ll be able to have just one id supply per group in AWS Organizations. You’ll be able to select one of many following as your id supply:
Overview of answer
With Amazon Q Enterprise, you may configure a number of information sources to supply a central place to look throughout your doc repository. For our answer, we reveal the way to index Google Drive information utilizing the Amazon Q Enterprise Google Drive connector. We full the next steps:
- Configure Google Workspace stipulations.
- Configure an Amazon Q Enterprise utility.
- Join Google Drive to Amazon Q Enterprise.
- Create customers and index the info within the Google Drive.
- Run a pattern question to check the answer.
Configure Google Workspace stipulations
For this answer, Amazon Q will hook up with a Google Workspace and crawl Google Drive paperwork owned by enterprise customers in several teams utilizing a service account. Full the next steps to configure your Google Workspace:
- Log in to the Google API console as an admin person.
- Select the dropdown menu subsequent to the search field, then select New Venture.
- Enter the venture identify, select the Google group, and select Create.
The Google Drive and Admin SDK APIs must be enabled for Amazon Q to crawl Google Drive recordsdata.
- Seek for every API on the Google Cloud console and select Allow.
- Seek for Service Accounts to entry the IAM & Admin navigation pane and select Create Service Account.
- Enter the service account identify, service account ID, and outline, and select Executed.
- Select the e-mail of the service account created within the earlier step.
- On the Keys tab, select Add Key, then select Create New Key.
- For Key sort, choose JSON, and select Create to obtain and domestically save a brand new personal key.
Now we allow domain-wide delegation for the 5 required API scopes on the Area-wide Delegation web page.
- Select Add new.
- Add the next comma delimited API scopes for consumer ID generated for the personal key created within the earlier step:
https://www.googleapis.com/auth/drive.readonly,
https://www.googleapis.com/auth/drive.metadata.readonly,
https://www.googleapis.com/auth/admin.listing.group.readonly,
https://www.googleapis.com/auth/admin.listing.person.readonly,
https://www.googleapis.com/auth/cloud-platform
- Select Authorize.
Now we create customers and add them to teams.
- Navigate to the Google Workspace Admin console and select Customers within the navigation pane.
- Select Add new person to create two new enterprise customers.
- Select Teams within the navigation pane.
- Select Create group to create two Google teams and add one enterprise person to every group.
- Add recordsdata that Amazon Q helps into every enterprise person’s Google Drive.
On this answer, we add the Amazon 2020 annual report to the primary enterprise person’s Google Drive and add the Amazon 2021 annual report and Amazon 2022 annual report to the second enterprise person’s Google Drive.
The enterprise person that uploaded the Amazon 2021 annual report may share it with the opposite enterprise person’s Google group.
- Select the choices menu (three vertical dots) for the Google Drive file and select Share.
- Enter the identify of the opposite Google group and select Ship.
Create an Amazon Q Enterprise utility with a Google Drive connector
An Amazon Q Enterprise utility must be created with a Google Drive connector to crawl and index Google Drive recordsdata. To create an Amazon Q utility, full the next steps:
- On the Amazon Q console, select Functions within the navigation pane.
- Select Create utility.
- For Software identify, enter a reputation.
- Depart utility configuration settings as defaults.
- Select Create.
- After the appliance is created, select Information Sources.
- Then select Choose retriever and Affirm to make use of a Native retriever and Enterprise provisioning.
- After confirming retriever settings, select Add information supply, after which select the plus signal subsequent to Google Drive.
- Beneath Title and outline, enter an information supply identify and elective description.
- Beneath Authentication, choose Google service account and select Create a brand new secret from the AWS Secrets and techniques Supervisor secret drop all the way down to create an AWS Secrets and techniques Supervisor secret.
- Enter a secret identify, admin account electronic mail, consumer electronic mail, and the JSON key you downloaded earlier, then select Save.
- Beneath IAM function, select Create a brand new service function.
- Beneath Extra Configuration, select Person electronic mail, and add the 2 lately created Google Workspace enterprise person electronic mail addresses.
- Beneath Sync run schedule, for Frequency, select Run on demand.
- Select Add information supply.
Create and handle customers
To create an Amazon Q net expertise accessible by Google Workspace customers, it’s essential create corresponding customers in IAM Id Heart. Amazon Q functions are solely accessible by IAM Id Heart customers with person identities that personal listed paperwork. To create the IAM Id Heart customers, full the next steps:
- On the IAM Id Heart console, select Customers within the navigation pane.
- Select Add person.
- Create IAM Id Heart customers that mirror your Google Workspace customers by getting into the required person data.
- Settle for the IAM Id Heart invitation despatched by electronic mail to every new enterprise person and set every enterprise person’s IAM Id Heart password.
- On the Amazon Q Enterprise console, navigate to the appliance with the Google Drive information supply.
- Select Handle person entry.
- Select Add teams and customers, choose Assign present customers and teams, and select Subsequent.
- Assign customers to the Amazon Q utility, select Assign, and select Affirm if every enterprise person is subscribed to Q Enterprise Professional.
After you add IAM Id Heart customers to your Amazon Q utility, its net expertise URL will seem within the Q Enterprise functions checklist. You should use the URL to hook up with the Amazon Q net expertise with both of your Google enterprise customers. By default, every person can solely ask questions on paperwork of their Google Drive.
Run pattern queries in Amazon Q
To check the Amazon Q utility with the Amazon annual experiences you uploaded to Google Drive, full the next steps:
- On the Amazon Q Enterprise console, navigate to the info supply you created.
- Run an on-demand sync of the info supply by selecting Sync now.
- Navigate to the net expertise URL in a brand new personal browser window and log in as the primary enterprise person.
- Ask Amazon Q a query, comparable to what number of staff work at Amazon.
The supply paperwork must be the Amazon 2020 and 2021 annual experiences, assuming the primary enterprise person uploaded the Amazon 2020 annual report and the second enterprise person shared the Amazon 2021 annual report with the primary enterprise person.
- Navigate to the net expertise URL in a brand new personal browser window and log in because the second enterprise person.
- Ask Amazon Q the identical query (what number of staff work at Amazon).
The supply paperwork must be the Amazon 2021 and 2022 annual experiences.
Troubleshooting
On this part, we share some frequent points and troubleshooting suggestions.
IAM Id Heart login error
You may obtain an error on the IAM Id Heart login web page that claims “We couldn’t confirm your sign-in credentials.”
To troubleshoot, full the next steps:
- Affirm that the enterprise customers that mirror the Google Workspace customers have been created in IAM Id Heart.
- If the customers exist, navigate to the person in IAM Id Heart and select Reset password, then choose Generate a one-time password and share the password with the person.
A password shall be offered for login and the person shall be requested to vary their password after a profitable login.
Google Drive information supply crawling or indexing failure
If the Google Drive information supply crawling or indexing fails, full the next steps:
- Affirm the enterprise customers provisioned within the Google Workspace are members of the Google teams.
- Examine the Amazon CloudWatch logs for the final time the Google Drive information supply was crawled for customers with Google Drive recordsdata within the Google Workspace.
- If the crawler didn’t efficiently log the indexing of an anticipated person’s recordsdata, verify the IAM Id Heart customers, then examine the attributes within the Secrets and techniques Supervisor secret to the corresponding Google Workspace attributes, together with consumer ID, service account electronic mail, and repair account personal key.
- Use the Amazon Q Enterprise document-level sync experiences to substantiate the supposed Google Drive paperwork have been listed by Amazon Q.
Google Drive information supply crawling and indexing job doesn’t crawl and index paperwork
If the Google Drive information supply crawling and indexing job doesn’t crawl and index any paperwork, full the next steps:
- Affirm the enterprise customers provisioned within the Google Workspace are members of the Google teams.
- Affirm there are IAM Id Heart customers that mirror the Google Workspace customers.
- Affirm each IAM Id Heart customers subscribe to Q Enterprise Professional.
- Affirm the Google Workspace admin person has enabled the Google Drive API.
Amazon Q net expertise doesn’t return anticipated solutions from the anticipated supply
If the Amazon Q net expertise doesn’t return anticipated solutions from the anticipated supply, full the next steps:
- Add the anticipated supply doc into an Amazon Q Enterprise chat session by selecting the paperclip icon within the Amazon Q chat interface after which selecting the file.
After you add the doc into the session, if the anticipated solutions are generated from the anticipated doc, the doc wasn’t efficiently listed from the Google Drive information supply.
- If Amazon Q doesn’t return the anticipated reply for the uploaded doc, modify the immediate used to ask the query.
Clear up
To stop incurring extra prices, it’s important to wash up and take away any sources created through the implementation of this answer. Particularly, you need to delete the Amazon Q utility, which can consequently take away the related index and information connectors. Nonetheless, any Secrets and techniques Supervisor secrets and techniques created through the Amazon Q utility setup course of must be eliminated individually. Failing to wash up these sources might lead to ongoing prices, so it’s essential to take the mandatory steps to utterly take away all parts associated to this answer.
Full the next steps to delete the Amazon Q utility, secret, and IAM Id Heart customers in your AWS account:
- On the Amazon Q Enterprise console, select Functions within the navigation pane.
- Choose the appliance that you simply created and on the Actions menu, select Delete and ensure the deletion.
- On the Secrets and techniques Supervisor console, select Secrets and techniques within the navigation pane.
- Choose the key that was created for the Google Drive connector and on the Actions menu, select Delete.
- Specify the ready interval as 7 days and select Schedule deletion.
- On the IAM Id Heart console, select Customers within the navigation pane.
- Choose the 2 customers that you simply created and select Delete customers to take away these customers.
Moreover, you need to take away the enterprise customers added to your Google Workspace through the implementation of this answer as a result of Google Workspaces prices are billed on a per-user foundation.
Conclusion
On this publish, you created an Amazon Q utility that listed Google Drive paperwork utilizing the Google Drive connector. You have been in a position to hook up with the Amazon Q conversational interface as every of your enterprise customers and ask questions in regards to the paperwork every person might entry in accordance with the ACL.
You’ll be able to proceed to experiment by including extra PDF paperwork to your enterprise customers’ Google Drives and re-syncing your Amazon Q Google Drive information supply.
Amazon Q Enterprise affords different connectors, comparable to for Confluence Cloud. To study extra in regards to the Amazon Q Enterprise Confluence Cloud connector, check with Connecting Confluence (Cloud) to Amazon Q Enterprise.
Concerning the Authors
Glen Eire is a Senior Enterprise Account Engineer at AWS within the Worldwide Public Sector. Glen’s areas of focus embody empowering prospects inquisitive about constructing generative AI options utilizing Amazon Q.
Julia Hu is a Specialist Options Architect who helps AWS prospects and companions construct generative AI options utilizing Amazon Q Enterprise on AWS. Julia has over 4 years of expertise creating options for purchasers adopting AWS companies on the forefront of cloud expertise.