Skip to content

Instantly share code, notes, and snippets.

View jasonforte's full-sized avatar

Jason Forté jasonforte

View GitHub Profile
@jasonforte
jasonforte / README.md
Created September 11, 2025 16:06
Deploy AWS Lambda Python Webhook to Invoke Amazon Bedrock

Invoke Amazon Bedrock via AWS Lambda

This gist is part of a tutorial by MakeOps on how to invoke Amazon Bedrock from an AWS Lambda function.

@jasonforte
jasonforte / .env
Last active September 1, 2025 12:02
Simple Agent Example - Amazon Bedrock Agents
AWS_REGION_NAME = 'eu-west-1'
BEDROCK_AGENT_ALIAS_ID = ''
BEDROCK_AGENT_ID = ''
@jasonforte
jasonforte / .env
Created August 31, 2025 11:13
How to Summarize Images with Bedrock Data Automation
AWS_REGION = 'eu-west-1'
BEDROCK_DATA_AUTOMATION_PROJECT_ARN = ''
BEDROCK_DATA_AUTOMATION_INPUT_BUCKET = ''
BEDROCK_DATA_AUTOMATION_OUTPUT_BUCKET = ''
BEDROCK_DATA_AUTOMATION_PROFILE_ARN = ''
@jasonforte
jasonforte / .env
Created August 19, 2025 13:52
Example Python code for interacting with Amazon S3 Vectors (boto3 & langchain)
REGION_NAME = "us-east-1"
AWS_DEFAULT_PROFILE = "demo"
MODEL_ID = "amazon.titan-embed-text-v2:0"
S3_VECTOR_BUCKET_NAME = ""
S3_VECTOR_INDEX_NAME = ""
INPUT_DATASET_PATH = "dataset/occurrences.csv"
MAX_INPUT_DOCUMENTS = "200"
@jasonforte
jasonforte / README.md
Created August 10, 2025 12:45
Python Sample - Invoke Qwen 2.5 VL Instruct on Amazon Bedrock

Invoke Qwen2.5 VL Instruct via Amazon Bedrock

This is part of a YouTube tutorial series by MakeOps.

The file is a script that invokes Qwen2.5 VL via Amazon Bedrock to describe and image.

usage: main.py [-h] image

positional arguments:
@jasonforte
jasonforte / main.go
Created July 31, 2025 11:41
Connecting Elixir (Phoenix) to Amazon Aurora DSQL
package main
import (
"context"
"flag"
"fmt"
"log"
"github.com/aws/aws-sdk-go-v2/config"
"github.com/aws/aws-sdk-go-v2/feature/dsql/auth"
@jasonforte
jasonforte / README.md
Last active May 27, 2025 13:57
Alembic Migration Script

Migrations Script Usage

This script provides a standard way to access postgres from a remote server. It will fetch db credentials based on the following inputs:

  • DB_CREDENTIALS_NAME is the name of the Secrets Manager secret to retrieve the db credentials from. (Required)
  • DB_NAME is the database name to connect to (Optional, Default: postgres)
  • ENV should be set to prod to modify the remote database, else it returns for a local environment. (Optional)
@jasonforte
jasonforte / README.md
Created July 31, 2024 11:34
Dynamic Configuration Example for AWS AppConfig in Python

Dynamic Configuartion using AWS AppConfig

This gist provides a Python class that allows retrieval of dynamic configuration from AWS AppConfig.

Pre-Requisites

This assumes a Freeform, JSON configuration is available in AWS AppConfig as follows:

{
@jasonforte
jasonforte / README.md
Last active June 2, 2021 15:02
Amazon CloudWatch Logs - Standard Setup - Ubuntu

Amazon CloudWatch Agent - Setup Instructions

Install the Amazon CloudWatch Agent on the instances. We want to monitor the memory usage mostly but the CPU & disk metrics are nice to have available too.

Installation

Connect to the instance and run the following:

$ wget https://s3.amazonaws.com/amazoncloudwatch-agent/ubuntu/amd64/latest/amazon-cloudwatch-agent.deb
@jasonforte
jasonforte / main.tfvars
Created December 29, 2019 11:25
S3 Static Site w/ CloudFront - Terraform
hostname = ""
acm_certificate_arn = ""