tree: 0fe685cdb68addfc62bd274095432a004478a469 [path history] [tgz]
  1. .dlt/
  2. slack/
  3. .gitignore
  4. dag_transform.png
  5. dlt_plugin.ipynb
  6. notebook.ipynb
  7. README.md
  8. requirements.txt
  9. run.py
  10. transform.py
examples/dlt/README.md

dlt

This example shows dlt + Apache Hamilton can help you cover the full ELT cycle using portable Python code. It is a companion to this documentation page.

Content

It includes a pipeline to ingest messages from Slack channels and generate threads summaries.

  • slack/ is the code imported from dlt for the Slack Source
  • .dlt/ contains the source's version, config, and secrets for the dlt Pipeline
  • transform.py contains the Apache Hamilton code to transform data and build the threads table
  • run.py contains the code to execution the dlt Pipeline and the Apache Hamilton dataflow.
  • notebook.ipynb contains the equivalent of both transform.py and run.py allowing you to explore the code interactively.

Set up

  1. Create a virtual environment and activate it

    python -m venv venv && . venv/bin/active
    
  2. Install requirements

    pip install -r requirements.txt
    
  3. Follow this dlt guide to ingest Slack data. Make sure to invite your Slack app to your channel!

  4. Execute the code. Use --help to learn about accepted arguments.

    python run.py --help
    python run.py general dlt
    

References