Metadata-Version: 2.4
Name: hamel
Version: 0.0.30
Summary: General Utilities
Author-email: Hamel Husain <hamel.husain@gmail.com>
License: Apache-2.0
Project-URL: Repository, https://github.com/hamelsmu/hamel
Project-URL: Documentation, https://hamelsmu.github.io/hamel
Keywords: nbdev,jupyter,notebook,python
Classifier: Natural Language :: English
Classifier: Intended Audience :: Developers
Classifier: Development Status :: 3 - Alpha
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Requires-Python: >=3.10.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: typer
Requires-Dist: youtube_transcript_api
Requires-Dist: httpx
Requires-Dist: fastcore
Requires-Dist: google-genai
Requires-Dist: openai-whisper
Requires-Dist: fastprogress
Requires-Dist: python-dotenv
Requires-Dist: rich
Requires-Dist: ipython
Requires-Dist: typing_extensions
Requires-Dist: twitter-api-client
Dynamic: license-file

# hamel


<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->

A collection of personal utilities for various tasks, including: -
Working with Google’s Gemini API for text generation and media
analysis - Processing YouTube videos and **local MP4 files** for
transcripts and chapter generation - Creating annotated blog posts from
technical talks

## Usage

### Installation

Install latest from the GitHub
[repository](https://github.com/hamelsmu/hamel):

``` sh
$ pip install git+https://github.com/hamelsmu/hamel.git
```

or from [pypi](https://pypi.org/project/hamel/)

``` sh
$ pip install hamel
```

**Note**: For MP4 video transcription, you’ll also need: - FFmpeg:
`brew install ffmpeg` (macOS) or `apt-get install ffmpeg` (Ubuntu) - The
installation will include openai-whisper automatically

### Documentation

Documentation can be found hosted on this GitHub
[repository](https://github.com/hamelsmu/hamel)’s
[pages](https://hamelsmu.github.io/hamel/).

## Available Utilities

### Gemini API (`hamel.gem`)

Simple interface for Google’s Gemini API supporting: - Text generation -
PDF and image analysis  
- YouTube video analysis - **Local MP4 video analysis**

See the [gem module documentation](gem.html) for details.

### YouTube & Video Utilities (`hamel.yt`)

Tools for working with video content: - Fetch transcripts from YouTube
videos - **Transcribe local MP4 files using OpenAI Whisper** - Generate
chapter timestamps for YouTube videos or **local MP4 files**

See the [yt module documentation](yt.html) for details.

### Zoom Utilities (`hamel.zoom`)

Tools for downloading Zoom meeting transcripts: - Download transcripts
by meeting ID - Search recordings by topic - Parallel downloads for
multiple meetings

**Setup**: Requires Zoom Server-to-Server OAuth app with
`recording:read:admin` scope activated in [Zoom
marketplace](https://marketplace.zoom.us/). Click **Develop** in the
top-right corner, then **Build App**, select **Server-to-Server OAuth**,
and fill in the app information.

Create `.env` with:

``` bash
ZOOM_CLIENT_ID=your_client_id
ZOOM_CLIENT_SECRET=your_client_secret
ZOOM_ACCOUNT_ID=your_account_id
```

See the [zoom module documentation](zoom.html) for details.

### Writing Utilities (`hamel.writing`)

Tools for content creation: - Convert PDFs to images - Generate
annotated blog posts from talks (supports **YouTube or MP4 videos**) -
Gather context from web pages

See the [writing module documentation](writing.html) for details.

### Twitter/X Utilities (`hamel.twitter_cli`)

Tools for fetching Twitter/X data:
- Fetch liked tweets
- Fetch bookmarked tweets
- Take screenshots of tweets

**Setup**: Requires browser cookies for authentication. Run `twitter refresh` to log in via browser and automatically extract cookies, or `twitter setup` for manual entry.

```bash
# Fetch bookmarks
twitter bookmarks -o bookmarks.json

# Fetch likes (requires username)
twitter likes -u myusername -n 50 -o likes.json

# Screenshot a tweet
twitter screenshot https://x.com/user/status/1234567890 -o tweet.png
```

Environment variables:
- `TWITTER_USERNAME` - Your Twitter username (for likes command)
- `TWITTER_COOKIES_FILE` - Custom path to cookies file (default: `~/.twitter_cookies.json`)
