Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 20 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,31 @@ This repo contains three things:

## Installation

CommonForms can be installed with either `uv` or `pip`, feel free to choose your package manager flavor:
CommonForms is a CLI tool with a sizable dependency footprint (`transformers`,
`torch`, `rfdetr`, `ultralytics`, and friends), so the cleanest install is an
**isolated** one that creates a dedicated environment and exposes just the
`commonforms` command:

```sh
uv tool install commonforms
# or
pipx install commonforms
```

If you'd rather use it as a **library** inside an existing project, install it with
`uv` or `pip`, feel free to choose your package manager flavor:

```sh
uv pip install commonforms
# or
pip install commonforms
```

> ⚠️ A plain `pip install` (or `uv pip install`) installs into your **active**
> environment. Because the dependency set is large and pins recent versions, this can
> upgrade packages like `numpy`, `pillow`, and `transformers` in place — so install
> into a dedicated virtualenv/conda env, not a shared `base`.

Once it's installed, you should be able to run the CLI command on ~any PDF.

## CommonForms CLI
Expand Down
3 changes: 1 addition & 2 deletions commonforms/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def main():
parser.add_argument(
"--fast",
action="store_true",
help="If running on a CPU, you can use --fast to get a 50% speedup with a small accuracy penalty",
help="If running on a CPU, you can use --fast to get a 50%% speedup with a small accuracy penalty",
)
parser.add_argument(
"--multiline",
Expand All @@ -58,7 +58,6 @@ def main():

args = parser.parse_args()

print(f"**{args.confidence=}")
prepare_form(
args.input,
args.output,
Expand Down