Skip to content
Snippets Groups Projects
Commit 3942f089 authored by nabil.abdennad's avatar nabil.abdennad
Browse files

minor updates in README

parent 556e8058
Branches
No related tags found
No related merge requests found
.DS_Store 0 → 100644
File added
[aws]
aws_access_key_id =
aws_secret_access_key =
region =
aws_access_key_id = AKIAVEKYIBTQFZV3M3OP
aws_secret_access_key = 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
region = us-east-1
[opensearch]
endpoint =
index_name =
endpoint = v9b2tkt2ccr61qs9tw7e.us-east-1.aoss.amazonaws.com
index_name = cloud
......@@ -25,16 +25,15 @@ Create a vector database for storing embeddings by running:
`python3 create-vector-db.py --collection_name [Name_of_colletion] --iam_user [YourIAM_user]`
Where placeholders:
- **[Name_of_colletion]**: Name of the collection that you want to create to store embeddings.
Where:
- **[Name_of_colletion]**: Name of the collection that you want to create.
- **[YourIAM_user]** : the IAM user is `CloudSys-group-XX`, with "XX" representing your group number.
This script performs the following actions:
* Sets up encryption, network, and data access policies for the collection.
* Creates a vector store with the name collection entered as argument.
* After the vector store is set up, the script retrieves and displays the store's endpoint for immediate use.
* After the vector store is set up, the script retrieves and displays the store's endpoint.
### Step 3: Vectorizing the PDF Files
......@@ -49,10 +48,10 @@ Then, run:
`python3 vectorise-store.py --bucket_name [YourBucketName] --endpoint [YourVectorDBEndpoint] --index_name [Index_name] --local_path [local_path]`
Where placeholders:
Where:
- **[YourBucketName]**: The name of the S3 bucket containing the PDF files.
- **[YourVectorDBEndpoint]**: Endpoint for the vector database.
- **[YourVectorDBEndpoint]**: Endpoint of the vector database.
- **[Index_name]**: The index_name where to store the embeddings in the collection.
- **[local_path]**: local_path
......@@ -70,22 +69,22 @@ The vectorise-store.py script will:
### Step 1: Preparation
Before deploying the chatbot on an EC2 instance, complete the following preliminary steps:
1. Create a Key Pair: This key pair will be used for SSH access to your EC2 instance whe you need it.
1. Create a Key Pair: This key pair will be used for SSH access to your EC2 instance.
2. Create a Security Group: Define rules to allow the instance to be accessible externally. The security group should include the following rules:
- For inbound rules: you need to allow SSH traffic, HTTP/HTTPs trafic and open port 8501 used by the application.
- For inbound rules: you need to allow SSH traffic, HTTP/HTTPs traffic and open port 8501 used by the application.
- Outbound Rules: Allow all traffic.
3. Prepare config.ini: Ensure your config.ini file includes your AWS credentials (aws_access_key_id, aws_secret_access_key, region), with the region set to 'us-east-1'. Also, include the endpoint and index_name for the OpenSearch service established earlier.
### Step 2: Launching the Instance
Utilize the provided create_instance.py script to deploy your EC2 instance with the essential startup configurations. Before executing this, adjust Security Group and Key Pair already created in the first step.
Use the provided create_instance.py script to deploy your EC2 instance with the essential startup configurations. Before executing this, adjust Security Group and Key Pair already created in the first step.
In the `ec2.create_instance` we have the following parameters:
- ImageId: `ami-05747e7a13dac9d14`, this is a custom Amazon Machine Image (AMI) that contains all the configurations and dependencies required for the chatbot application.
- UserData: is used to run script after the instance starts. The script will put the credentials in the instance so that the instance can aceess other services in AWS, and the endpoint for the Vector DB, index name. Then the script will run the application.
- UserData: is used to run script after the instance starts. The script will put the credentials in the instance so that the instance can aceess other services in AWS, the endpoint of the Vector DB, and the index name. Then the script will run the application.
This is the script:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment