meltify 0.2.2__tar.gz → 0.2.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {meltify-0.2.2 → meltify-0.2.3}/PKG-INFO +13 -1
- {meltify-0.2.2 → meltify-0.2.3}/README.md +12 -0
- {meltify-0.2.2 → meltify-0.2.3}/pyproject.toml +1 -1
- {meltify-0.2.2 → meltify-0.2.3}/pyproject.toml.orig +1 -1
- meltify-0.2.3/src/meltify/__init__.py +69 -0
- meltify-0.2.3/src/meltify/py.typed +0 -0
- meltify-0.2.2/src/meltify/__init__.py +0 -6
- {meltify-0.2.2 → meltify-0.2.3}/LICENSE +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/__main__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/cli.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/__init__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/brief.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/check.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/doctor.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/hidden.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/media.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/ocr.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/read.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/commands/submit.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/config.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/__init__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/archive.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/blips.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/doc.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/embeds.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/epub.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/fallback.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/hwp.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/iwa.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/iwork.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/kakao.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/limits.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/mail.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/mbox.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/metafile.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/msg.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/notebook.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/odf.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/office.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/ooxml.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/ooxml_charts.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/parquet.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/pdf.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/ppt.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/quicklook.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/raster.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/render.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/rtf.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/run.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/sheet.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/slack.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/sqlite.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/subtitle.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/svg.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/tables.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/text.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/unlock.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/web.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/webarchive.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/wordperfect.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/converters/xmlsafe.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/data/__init__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/data/brief_en.md +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/data/brief_ko.md +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/data/defaults.toml +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/engines/__init__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/engines/asr.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/engines/consensus.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/engines/ocr.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/evidence.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/fetch.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/ffmpeg.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/files.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/forensics/__init__.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/forensics/pdf.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/imaging.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/lang.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/llm.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/needs.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/output.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/passwords.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/recognize.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/safe.py +0 -0
- {meltify-0.2.2 → meltify-0.2.3}/src/meltify/tools.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: meltify
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.3
|
|
4
4
|
Summary: Melt files of any format into prompt-ready text where every line cites its source
|
|
5
5
|
Keywords: llm,prompt,ocr,pdf,transcription,claude-code,agent-skills
|
|
6
6
|
Author: jeon-jihyeon
|
|
@@ -80,6 +80,18 @@ Command line only:
|
|
|
80
80
|
uvx meltify read ./inputs
|
|
81
81
|
```
|
|
82
82
|
|
|
83
|
+
From Python, after `pip install meltify`:
|
|
84
|
+
|
|
85
|
+
```python
|
|
86
|
+
import meltify
|
|
87
|
+
|
|
88
|
+
env = meltify.read("./inputs", out="melted", shallow=True)
|
|
89
|
+
for row in env.results:
|
|
90
|
+
print(row["cite"], row["out"], row["needs"])
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
`meltify.read` takes the same flags as the command as keywords and returns the same result envelope that `--json` prints. A string option gets the flag's own type, so `password_file="pw.txt"` arrives as a path and `budget="60"` as a number. For encrypted files, pass `password=`: it outranks `--password-file` and never touches argv. Only the names exported from `meltify` are public. Every other module is internal and can change in any release.
|
|
94
|
+
|
|
83
95
|
The skills call the `meltify` command. If it isn't installed, the plugin launcher runs it through `uvx`, so [uv](https://docs.astral.sh/uv/) is the only thing you need.
|
|
84
96
|
|
|
85
97
|
## What it does
|
|
@@ -30,6 +30,18 @@ Command line only:
|
|
|
30
30
|
uvx meltify read ./inputs
|
|
31
31
|
```
|
|
32
32
|
|
|
33
|
+
From Python, after `pip install meltify`:
|
|
34
|
+
|
|
35
|
+
```python
|
|
36
|
+
import meltify
|
|
37
|
+
|
|
38
|
+
env = meltify.read("./inputs", out="melted", shallow=True)
|
|
39
|
+
for row in env.results:
|
|
40
|
+
print(row["cite"], row["out"], row["needs"])
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
`meltify.read` takes the same flags as the command as keywords and returns the same result envelope that `--json` prints. A string option gets the flag's own type, so `password_file="pw.txt"` arrives as a path and `budget="60"` as a number. For encrypted files, pass `password=`: it outranks `--password-file` and never touches argv. Only the names exported from `meltify` are public. Every other module is internal and can change in any release.
|
|
44
|
+
|
|
33
45
|
The skills call the `meltify` command. If it isn't installed, the plugin launcher runs it through `uvx`, so [uv](https://docs.astral.sh/uv/) is the only thing you need.
|
|
34
46
|
|
|
35
47
|
## What it does
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"""Melt files of any format into prompt-ready text where every line cites its source
|
|
2
|
+
|
|
3
|
+
Only the names in `__all__` are public. Every other module is internal and can change
|
|
4
|
+
in any release
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from __future__ import annotations
|
|
8
|
+
|
|
9
|
+
from importlib.metadata import PackageNotFoundError, version
|
|
10
|
+
from pathlib import Path
|
|
11
|
+
from typing import TYPE_CHECKING, Any
|
|
12
|
+
|
|
13
|
+
from meltify.safe import MissingTool
|
|
14
|
+
|
|
15
|
+
if TYPE_CHECKING:
|
|
16
|
+
from meltify.evidence import Envelope
|
|
17
|
+
|
|
18
|
+
try:
|
|
19
|
+
__version__ = version("meltify")
|
|
20
|
+
except PackageNotFoundError:
|
|
21
|
+
__version__ = "0.0.0"
|
|
22
|
+
|
|
23
|
+
__all__ = ["Envelope", "MissingTool", "__version__", "read"]
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
def read(
|
|
27
|
+
*paths: str | Path,
|
|
28
|
+
out: str | Path | None = None,
|
|
29
|
+
config_file: str | Path | None = None,
|
|
30
|
+
password: str | None = None,
|
|
31
|
+
**options: Any,
|
|
32
|
+
) -> Envelope:
|
|
33
|
+
"""Melt files, folders and URLs the way `meltify read` does
|
|
34
|
+
|
|
35
|
+
`options` takes the command's flags as keywords, like `shallow=True` or `budget=60`.
|
|
36
|
+
Each result row cites its source and points at the markdown it wrote under `out`.
|
|
37
|
+
Raises MissingTool when a needed engine or extra isn't installed
|
|
38
|
+
"""
|
|
39
|
+
import argparse
|
|
40
|
+
|
|
41
|
+
from meltify import config
|
|
42
|
+
from meltify.commands import read as command
|
|
43
|
+
|
|
44
|
+
if not paths:
|
|
45
|
+
raise TypeError("read() needs at least one path")
|
|
46
|
+
parser = argparse.ArgumentParser()
|
|
47
|
+
actions = command.add_arguments(parser)
|
|
48
|
+
args = parser.parse_args(["-"])
|
|
49
|
+
args.paths = [str(p) for p in paths]
|
|
50
|
+
for name, value in options.items():
|
|
51
|
+
# password stays a keyword of its own, so it never looks like a command line flag
|
|
52
|
+
if name in ("paths", "password") or name not in actions:
|
|
53
|
+
raise TypeError(f"read() got an unexpected keyword argument {name!r}")
|
|
54
|
+
convert = actions[name].type
|
|
55
|
+
# A string gets the flag's own type, as argparse would give it, so
|
|
56
|
+
# password_file="pw.txt" arrives as the Path the command reads
|
|
57
|
+
setattr(args, name, convert(value) if isinstance(value, str) and convert else value)
|
|
58
|
+
overrides = {"out_dir": str(out)} if out is not None else None
|
|
59
|
+
settings = config.load(overrides, project=Path(config_file) if config_file else None)
|
|
60
|
+
return command.run(args, settings, password)
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
def __getattr__(name: str) -> Any:
|
|
64
|
+
# Envelope loads lazily, so `meltify --help` doesn't pay for the import
|
|
65
|
+
if name == "Envelope":
|
|
66
|
+
from meltify.evidence import Envelope
|
|
67
|
+
|
|
68
|
+
return Envelope
|
|
69
|
+
raise AttributeError(f"module 'meltify' has no attribute {name!r}")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|