GithubHelp home page GithubHelp logo

gru-report-workflow's Introduction

Introduction

The Company report generator is designed to facilitate companies in generating AI-driven reports based on their input data. This project enables users to submit their company details, goals and email through a web interface. The backend processes this information using Django and SuperAGI, an open-source project, to produce insightful reports, which are then emailed to the provided email. The workflow includes backend tasks managed by Celery, ensuring efficient and asynchronous handling of data processing.

Features

  • User Input Form: Collects company details, goals, and contact information.
  • Django Backend: Stores user input in a database and triggers Celery tasks.
  • Celery Tasks: Asynchronously handles SuperAGI agent runs, monitors completion, and processes generated reports.
  • SuperAGI Integration: Utilizes a custom integration library for seamless communication with SuperAGI.
  • Amazon S3 Integration: Stores resource files (e.g., reports) on Amazon S3 for easy access.
  • PDF Conversion and Emailing: Converts reports to PDF and sends them to the provided email addresses.
  • Organized Codebase: Follows best practices, including code organization and adherence to the three rules of simple design.

Get it up and running

  1. Setup for Superagi
    • Clone my fork for superagi and checkout "custom_gru" branch.
    git clone https://github.com/aleric-cusher/SuperAGI.git
    cd SuperAGI
    git checkout custom_gru
    • Get openai api keys and add them to the config.yaml
    • Setup AmazonS3 for SuperAGI and add its details to the config.yaml file in SuperAGI.
    • Setup google search toolkit for SuperAGI. Follow the guide here.
  • After the setup the following fields in SuperAGI's config.yaml should be set
    • OPENAI_API_KEY: your-openai-api-key
    • STORAGE_TYPE: "S3"
    • BUCKET_NAME: "your-s3-bucket-name"
    • INSTAGRAM_TOOL_BUCKET_NAME: "your-s3-bucket-name"
    • AWS_ACCESS_KEY_ID: "your-aws-access-key-id"
    • AWS_SECRET_ACCESS_KEY: "your-aws-secret-access-key"
    • GOOGLE_API_KEY: your-google-api-key
    • SEARCH_ENGINE_ID: your-search-engine-id
  1. Create custom docker networks
    docker network create gru_network
    docker network create super_network
  2. Run SuperAGI
    • Navigate to the SuperAGI clone, base directory.
    • Run command:
    docker compose -f ./docker-compose-gru.yaml up -d --build
    • This takes 5 to 15 minutes to startup completely
  • Get SuperAGI api key
    • Navigate to http://localhost:3000 in your browser
    • Go to Settings -> Api Keys -> Create Key
    • Enter a name for your api key then click create key.
    • Copy the displayed key, this is your SuperAGI api key.
  1. Setup for report generator
    • Clone the current repo
    git clone https://github.com/aleric-cusher/gru-report-workflow.git
    • Create a ".env" by renaming or copying the ".env.example" file in the base directory of the clone.
    • Fill out email server settings in .env, for quick testing checkout mailtrap.io
    • Add your SuperAGI api key in the .env file.
    • Add AmazonS3 settings in the .env file.
  2. Run report generator
    • Navigate to the clone of the current repository, base directory.
    • Run the following commands commands:
    docker compose -f ./gru/docker-compose.yaml up -d --build
    docker compose -f ./frontend/docker-compose.yaml up -d --build
  3. After everything is up and running you can navigate to http://localhost:1573, to interact with the demo frontend.

Generate a report for a company

After everything is up and running successfully, navigate to http://localhost:1573. This will show a demo page.

On the top right click Get Quote button. This will open up a modal, enter in your company details, and your details and click submit. After about 20-30 minutes a report will be emailed to the email address you enter.

View logs for docker compose.

You can view the logs for SuperAGI by:

  • Navigating to the SuperAGI clone and running the command:
docker compose -f ./docker-compose-gru.yaml logs -f backend celery

And for the gru logs:

  • Navigating to the base directory of the current repo and running:
docker compose -f ./gru/docker-compose.yaml logs -f

gru-report-workflow's People

Contributors

aleric-cusher avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.