Skip to main content

Precision-focused media metadata inspection tool built in Go and distributed via Python

Project description

Media Metadata Surgery

Media Metadata Surgery is a precision‑focused, offline CLI tool for inspecting and modifying metadata in media files.

The core engine is written in Go for performance, safety, and correctness. A lightweight Python wrapper is used only for distribution, making the tool easy to install via pip while keeping the actual logic native and fast.

v0.1.0 is the beginning. The project is intentionally small, strict, and correct. More formats and operations will be added incrementally.


Why Media Metadata Surgery exists

Media files silently carry far more information than most users realize:

  • GPS location and timestamps
  • Device make, model, and camera internals
  • Processing pipelines, filters, and AI hints
  • Hidden user comments and sensor data

This project exists to:

  • Expose metadata clearly
  • Operate fully offline
  • Avoid heavy external dependencies
  • Favor correctness over convenience

No cloud. No telemetry. No shelling out to system tools.


Current status

Version: 0.1.0 (initial release)

This version intentionally supports only one format and one operation:

  • JPG / JPEG
  • EXIF metadata inspection (read‑only)

This narrow scope allows the foundation to remain clean and extensible.


Installation

Install via pip (recommended)

pip install surgery

This installs the surgery command globally. The Go binary is bundled inside the Python package.


Build from source (Go)

Requirements:

  • Go 1.20+
git clone https://github.com/ankit-chaubey/media-metadata-surgery
cd media-metadata-surgery
go build -o surgery ./cli

Run directly:

./surgery view image.jpg

Usage

View EXIF metadata from a JPG image

surgery view image.jpg

Example output:

EXIF Metadata:
Make: "vivo"
Model: "vivo T1 5G"
DateTimeOriginal: "2026:02:04 18:44:10"
GPSLatitude: ["18/1","20/1","4247/900"]
GPSLongitude: ["84/1","25/1","4824/190"]
UserComment: "filter: 104; ..."

Supported formats (v0.1.0)

Media type Format Operation
Image JPG / JPEG View EXIF metadata

More formats will be added only when they can be handled correctly.


Project structure

media-metadata-surgery/
├── cli/                # Go CLI entry point
├── core/               # Core metadata logic
│   └── jpg/            # JPG / EXIF handling
├── surgery/            # Python wrapper package
│   └── bin/surgery     # Go binary (bundled)
├── setup.py            # PyPI configuration
├── pyproject.toml
└── README.md

Design principles:

  • Go does all real work
  • Python only launches the binary
  • No CGO
  • No external system tools

Security & privacy notes

  • All operations are offline
  • No network access
  • No background processes
  • Viewing metadata does not modify files

Metadata removal, when added, will be explicit and opt‑in.


Roadmap

Planned, in order of correctness priority:

  • GPS metadata removal (JPG)
  • Structured JSON output
  • Audio metadata (MP3 / FLAC)
  • Video containers (MP4 / MKV)
  • Batch processing
  • Integrity and diff reporting

The project will grow conservatively.


License

Apache License 2.0


Developed by

Ankit Chaubey
GitHub: https://github.com/ankit-chaubey
Project repository: https://github.com/ankit-chaubey/media-metadata-surgery


Philosophy

Precision over features. Correctness over speed. Transparency over magic.

Media Metadata Surgery is built as a long‑term, trustworthy utility — not a shortcut tool.

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

surgery-0.1.0.tar.gz (7.7 kB view details)

Uploaded Source

Built Distribution

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

surgery-0.1.0-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file surgery-0.1.0.tar.gz.

File metadata

  • Download URL: surgery-0.1.0.tar.gz
  • Upload date:
  • Size: 7.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for surgery-0.1.0.tar.gz
Algorithm Hash digest
SHA256 02dd6f2d1fa4b552b8c376dfbf5e0ff990eb7c8a9376dfc34ceb9277153ae75f
MD5 1bac50a5f48e9851c7d9a6aee4bf4ee0
BLAKE2b-256 e199af2154f23b7ba7e0a6b83531cbe86a5621f288b670ad8f030415e7b9de06

See more details on using hashes here.

Provenance

The following attestation bundles were made for surgery-0.1.0.tar.gz:

Publisher: publish.yml on ankit-chaubey/media-metadata-surgery

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

File details

Details for the file surgery-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: surgery-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for surgery-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3171ce5937148663acf7840618e7a09381185c93a403801163e2e5cf41d54dbc
MD5 0b90b9d20aca88a941cfd8288801dbaa
BLAKE2b-256 267bd3ad4e5ba737dba413936abb4863dfe35e0b9bf77779664647cd352b39c1

See more details on using hashes here.

Provenance

The following attestation bundles were made for surgery-0.1.0-py3-none-any.whl:

Publisher: publish.yml on ankit-chaubey/media-metadata-surgery

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