Skip to main content

Convert documents to Markdown (MarkItDown), package with Repomix, and serve a Streamlit UI for copyable LLM context.

Project description

Context Packager

Convert documents to Markdown (MarkItDown), package into a single LLM-ready context (Repomix), and use a sleek Streamlit UI to copy/download.

1. Quick start (uv)

macOS/Linux (full extras)

sh -c 'command -v uv >/dev/null 2>&1 || (curl -LsSf https://astral.sh/uv/install.sh | sh); PATH="$HOME/.local/bin:$PATH" uvx --python 3.12 --refresh --from "git+https://github.com/ruizmr/resume-context-builder.git@main?extra=full" resume-ui'

Windows (full extras)

powershell -NoProfile -ExecutionPolicy Bypass -Command "if (-not (Get-Command uv -EA SilentlyContinue)) { iwr https://astral.sh/uv/install.ps1 -UseBasicParsing | iex }; $env:Path = \"$env:USERPROFILE\.local\bin;$env:Path\"; uvx --python 3.12 --refresh --from 'git+https://github.com/ruizmr/resume-context-builder.git@main?extra=full' resume-ui"

Use the sidebar to upload files or point to a folder. Download/copy packaged chunks. Check "Include in knowledge base" to persist chunks and use the built-in search.

For smoother live reload and file watching, the full extras include Watchdog.

KB persistence defaults to a local SQLite file at ~/.context-packager-state/context.db. To use a shared DB, set CONTEXT_DB_URL before launching, for example on Linux/macOS:

export CONTEXT_DB_URL="sqlite:////absolute/path/to/context.db"
resume-ui

2. Install a shortcut (one-time)

Creates a persistent resume-ui command on your PATH.

macOS/Linux (full extras)

sh -c 'command -v uv >/dev/null 2>&1 || (curl -LsSf https://astral.sh/uv/install.sh | sh); PATH="$HOME/.local/bin:$PATH" uv tool install --python 3.12 --force "git+https://github.com/ruizmr/resume-context-builder.git?extra=full" && echo "Installed. Next time just run: resume-ui"'

Windows (full extras)

powershell -NoProfile -ExecutionPolicy Bypass -Command "if (-not (Get-Command uv -EA SilentlyContinue)) { iwr https://astral.sh/uv/install.ps1 -UseBasicParsing | iex }; $env:Path = \"$env:USERPROFILE\.local\bin;$env:Path\"; uv tool install --python 3.12 --force \"git+https://github.com/ruizmr/resume-context-builder.git?extra=full\"; Write-Host 'Installed. Next time just run: resume-ui'"

Next runs after install:

resume-ui

Available commands after install:

# Launch UI (Home + Manage knowledge)
resume-ui

# Convert to Markdown then upsert to KB (cron-friendly)
context-ingest "/path/to/input_dir" "/path/to/markdown_out_dir"

# Upsert existing Markdown into KB
context-upsert "/path/to/markdown_out_dir"

# Scheduler (persistent)
# Add a job that ingests every hour
context-scheduler add hourly_ingest "/path/to/input_dir" --md-out "/path/to/markdown_out_dir" --interval 60
# Or cron syntax
context-scheduler add nightly_ingest "/path/to/input_dir" --md-out "/path/to/markdown_out_dir" --cron "0 2 * * *"
# List jobs
context-scheduler list
# Remove job
context-scheduler remove hourly_ingest
# Start scheduler (blocking)
context-scheduler start

One-shot (no install):

# UI
sh -c 'command -v uv >/dev/null 2>&1 || (curl -LsSf https://astral.sh/uv/install.sh | sh); PATH="$HOME/.local/bin:$PATH" uvx --python 3.12 --refresh --from "git+https://github.com/ruizmr/resume-context-builder.git@main?extra=full" resume-ui'

# Ingest (convert + upsert)
sh -c 'command -v uv >/dev/null 2>&1 || (curl -LsSf https://astral.sh/uv/install.sh | sh); PATH="$HOME/.local/bin:$PATH" uvx --python 3.12 --refresh --from "git+https://github.com/ruizmr/resume-context-builder.git@main?extra=full" context-ingest "/path/to/input_dir" "/path/to/markdown_out_dir"'

Database configuration:

# SQLite (default)
# ~/.context-packager-state/context.db

# Postgres
export CONTEXT_DB_URL='postgresql+psycopg://user:pass@host:5432/dbname'
resume-ui

3. Troubleshooting PATH

  • macOS/Linux: ensure ~/.local/bin is on PATH (e.g., add export PATH="$HOME/.local/bin:$PATH" to your shell rc).
  • Windows: ensure %USERPROFILE%\.local\bin is on PATH, then open a new terminal.

If resume-ui is not found right after install

  • Quick fix (macOS/Linux):
source "$HOME/.local/bin/env" || { echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc && source ~/.zshrc; }
  • Run via absolute path once:
"$HOME/.local/bin/resume-ui"
  • Windows PowerShell:
& "$env:USERPROFILE\.local\bin\resume-ui.exe"

4. Reset/nuke cached install (uv)

If you’re not seeing the latest UI changes:

# Remove cached venvs and archives
uv cache prune

# Remove previously installed tool shim (optional)
uv tool uninstall resume-ui || true

# Reinstall and pin to main
sh -c 'command -v uv >/dev/null 2>&1 || (curl -LsSf https://astral.sh/uv/install.sh | sh); PATH="$HOME/.local/bin:$PATH" uvx --python 3.12 --refresh --from "git+https://github.com/ruizmr/resume-context-builder.git@main?extra=full" resume-ui'

5. Scheduler visibility and continuous sync

  • Jobs added via UI or context-scheduler add are mirrored in a lightweight jobs table for display.
  • Every execution (scheduled or one-off) creates a job_runs record with:
    • status: queued, running, success, failed, cancelled
    • progress: 0-100, processed/total files, chunks upserted
    • recent log tail and last message
  • In the UI Manage knowledge tab:
    • Add job with Daily/Weekly/Monthly/Interval/Cron.
    • Run now for ad-hoc runs.
    • View recent runs with progress and cancel running jobs.

Environment notes:

  • Set CONTEXT_DB_URL to persist job/run history in a shared DB.
  • APScheduler jobs are still stored in apscheduler_jobs table via SQLAlchemyJobStore for durability.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

context_packager-0.2.26.tar.gz (2.5 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

context_packager-0.2.26-py3-none-any.whl (2.5 MB view details)

Uploaded Python 3

File details

Details for the file context_packager-0.2.26.tar.gz.

File metadata

  • Download URL: context_packager-0.2.26.tar.gz
  • Upload date:
  • Size: 2.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for context_packager-0.2.26.tar.gz
Algorithm Hash digest
SHA256 0b015e409461bf46208cb5048cbb46a3b1a16a242de1140860ea1e37e689db64
MD5 b6716c6a2a0d2e9a23e29f10442bb11c
BLAKE2b-256 44a7c86d84ec31cae48db8615a9dc24ddfb9827808b04b590402f5ee4735a64d

See more details on using hashes here.

Provenance

The following attestation bundles were made for context_packager-0.2.26.tar.gz:

Publisher: publish.yml on ruizmr/resume-context-builder

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file context_packager-0.2.26-py3-none-any.whl.

File metadata

File hashes

Hashes for context_packager-0.2.26-py3-none-any.whl
Algorithm Hash digest
SHA256 b0171afc1d4a6d9534e0eb4f2250c0ee4f3778056b02e2cf65d57a42bc00947e
MD5 b735053f61c9b8aea6c21cb717ee640c
BLAKE2b-256 90fa1d71d57e7ac4b6019525103ac303bd378baaa7e5ab62366f4e0e55fbce58

See more details on using hashes here.

Provenance

The following attestation bundles were made for context_packager-0.2.26-py3-none-any.whl:

Publisher: publish.yml on ruizmr/resume-context-builder

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page