← 返回首页
GitHub - rhlsthrm/bittman: Bittman algorithm implemented with serverless · GitHub
Skip to content

Navigation Menu

Toggle navigation
Sign in
Appearance settings
Search or jump to...

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Resetting focus

rhlsthrm/bittman

 master
Go to file
Code

Repository files navigation

More items

bittman

Background

This project calculates Bittman trading algorithm trading points on Wednesday evenings, and then uses them to calculate the actual triggers based on the morning open price on Thursday.

Background: http://alta5.com/blog/bittman/

This project implements the algorithm using the Serverless framework and sends emails through Mailgun. On Wednesday after market close, the calculateVolatility Lambda function runs and stores the data into DynamoDB. On Thursday at market open, the calculateTriggers Lambda function runs and sends emails with the trigger points calculated from the market open price.

Prerequisites

$ npm install serverless -g

Configuration

The project requires an active Mailgun account to send emails. Insert your mailgun API key and domain into the configuration file common/config.js. Also you will insert email addresses here.

const config = {}; config.mailgun = { apiKey: 'key-xxxxxxxxxx', domain: 'sandboxxxxxxxxxx.mailgun.org' }; config.emails = [ 'Rahul <rahul@sethuram.com>' ]; module.exports = config;

Deployment

First, install the npm dependencies:

$ npm install

Deploy the functions to AWS:

$ sls deploy

The functions have GET endpoints tied to them just so they can be tested, but the functions are meant to be run on the schedule provided.

Debugging

To debug serverless functions, you can use the following command:

$ sls logs -f <FUNCTION_NAME> -t

This will give a tailing log output of the function and provides stack traces of errors.

About

Bittman algorithm implemented with serverless

Topics

Resources

Stars

14 stars

Watchers

2 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Footer

© 2026 GitHub, Inc.