agent-redact 0.2.0__tar.gz → 0.3.0__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.
- {agent_redact-0.2.0 → agent_redact-0.3.0}/PKG-INFO +3 -3
- {agent_redact-0.2.0 → agent_redact-0.3.0}/README.md +2 -2
- {agent_redact-0.2.0 → agent_redact-0.3.0}/pyproject.toml +1 -1
- {agent_redact-0.2.0 → agent_redact-0.3.0}/src/agent_redact/__init__.py +4 -4
- {agent_redact-0.2.0 → agent_redact-0.3.0}/.gitignore +0 -0
- {agent_redact-0.2.0 → agent_redact-0.3.0}/src/agent_redact/py.typed +0 -0
- {agent_redact-0.2.0 → agent_redact-0.3.0}/tests/test_agent_redact.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: agent-redact
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: Secret & PII redaction for Python AI agents (wrapper around the agent-redact CLI)
|
|
5
5
|
Project-URL: Homepage, https://github.com/TonyDuongg/agent-redact
|
|
6
6
|
Project-URL: Issues, https://github.com/TonyDuongg/agent-redact/issues
|
|
@@ -22,11 +22,11 @@ Python bindings for [agent-redact](https://github.com/TonyDuongg/agent-redact).
|
|
|
22
22
|
pip install agent-redact
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
-
> **Node.js
|
|
25
|
+
> **Node.js 22.18+ is still required.** This package contains only the Python wrapper; the detection engine is the Node.js CLI (see below for how it is found).
|
|
26
26
|
|
|
27
27
|
**Requirements:**
|
|
28
28
|
- Python 3.10+
|
|
29
|
-
- Node.js
|
|
29
|
+
- Node.js 22.18+
|
|
30
30
|
- the CLI, from one of these (checked in order):
|
|
31
31
|
1. `AGENT_REDACT_CLI` set to the **absolute** path of `dist/cli/index.js`;
|
|
32
32
|
2. a global `npm install -g agent-redact`;
|
|
@@ -6,11 +6,11 @@ Python bindings for [agent-redact](https://github.com/TonyDuongg/agent-redact).
|
|
|
6
6
|
pip install agent-redact
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
> **Node.js
|
|
9
|
+
> **Node.js 22.18+ is still required.** This package contains only the Python wrapper; the detection engine is the Node.js CLI (see below for how it is found).
|
|
10
10
|
|
|
11
11
|
**Requirements:**
|
|
12
12
|
- Python 3.10+
|
|
13
|
-
- Node.js
|
|
13
|
+
- Node.js 22.18+
|
|
14
14
|
- the CLI, from one of these (checked in order):
|
|
15
15
|
1. `AGENT_REDACT_CLI` set to the **absolute** path of `dist/cli/index.js`;
|
|
16
16
|
2. a global `npm install -g agent-redact`;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
This package is a thin, dependency-free wrapper around the agent-redact Node.js CLI, so
|
|
4
4
|
Python agents (LangChain, CrewAI, AutoGen, plain SDK code) get exactly the same detection
|
|
5
|
-
engine as the npm package. It needs Node.js
|
|
5
|
+
engine as the npm package. It needs Node.js 22.18+ and one of:
|
|
6
6
|
|
|
7
7
|
* ``AGENT_REDACT_CLI`` set to the absolute path of ``dist/cli/index.js`` (or an executable),
|
|
8
8
|
* a global ``npm install -g agent-redact``, or
|
|
@@ -27,7 +27,7 @@ import tempfile
|
|
|
27
27
|
from dataclasses import dataclass, field
|
|
28
28
|
from typing import Iterable, Mapping, Sequence
|
|
29
29
|
|
|
30
|
-
__version__ = "0.
|
|
30
|
+
__version__ = "0.3.0"
|
|
31
31
|
|
|
32
32
|
__all__ = [
|
|
33
33
|
"AgentRedactError",
|
|
@@ -88,7 +88,7 @@ class Finding:
|
|
|
88
88
|
|
|
89
89
|
|
|
90
90
|
_NOT_FOUND = (
|
|
91
|
-
"agent-redact CLI not found. Install Node.js
|
|
91
|
+
"agent-redact CLI not found. Install Node.js 22.18+ and run `npm install -g agent-redact`, "
|
|
92
92
|
"or set AGENT_REDACT_CLI to the absolute path of dist/cli/index.js."
|
|
93
93
|
)
|
|
94
94
|
|
|
@@ -113,7 +113,7 @@ def _safe_which(name: str) -> str | None:
|
|
|
113
113
|
def _node() -> str:
|
|
114
114
|
node = _safe_which("node")
|
|
115
115
|
if not node:
|
|
116
|
-
raise AgentRedactError("`node` (Node.js
|
|
116
|
+
raise AgentRedactError("`node` (Node.js 22.18+) was not found on PATH. " + _NOT_FOUND)
|
|
117
117
|
return node
|
|
118
118
|
|
|
119
119
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|