Getting started¶
Launch Presidio text redaction in your AWS account, connect privately and verify the result of your first task.
1. Launch and wait for startup¶
Use the Software Sushi Marketplace version described on this page, Ubuntu 24.04 x86_64, and at least t3.medium / 4 GiB RAM with 24 GiB encrypted gp3 root storage. Keep IMDSv2 enabled. These are minimum starting sizes, not throughput benchmarks. Inbound application ports must remain closed.
For Session Manager, attach a customer-owned instance role with the required Systems Manager permissions and provide outbound HTTPS/DNS connectivity to the relevant endpoints. Your workstation needs AWS CLI, the Session Manager Plugin and permission to start sessions. SSH is an alternative when TCP 22 is restricted to your administrative CIDR. The application itself does not need a model-provider key.
Connect to your instance, then run the following. The second command starts a login shell as ubuntu; run the remaining commands inside that shell.
sudo cloud-init status --wait
sudo -iu ubuntu
umask 077
sudo systemctl is-active sushi-presidio-api.service
bash /opt/sushi/docs/demo.sh
Wait for cloud-init to finish and every listed service to report active. The demo checks the installed service; it does not validate your own data or workload. A failed service needs diagnosis before you submit work. Do not recreate the instance identity or run a second server to bypass a startup failure.
2. Use the private connection¶
First boot creates a unique TLS identity and ~/.config/sushi/presidio/access.json for the ubuntu account, with mode 0600. The matching server.crt sits beside it. The installed sushi-presidio-api helper reads these files and verifies TLS without printing credentials. Run it on the instance as ubuntu.
To reach port 8443 from your own workstation, open a separate terminal and replace the placeholders below with your customer profile, Region and instance ID:
aws --profile <customer-profile> --region <region> ssm start-session \
--target <instance-id> \
--document-name AWS-StartPortForwardingSession \
--parameters '{"portNumber":["8443"],"localPortNumber":["8443"]}'
Keep that terminal open. Forwarding a port does not install the API helper on your workstation or copy its identity files. For a workstation client, transfer only the required certificate and private client file through an authenticated channel, retain private permissions and configure the client to read credentials from that file. Do not put credentials in URLs, command arguments, user data or support logs. Do not disable certificate verification.
3. Redact a support ticket¶
Start with this invented ticket. Select the entity types required by your policy; omitting entities analyzes all supported types and can return overlapping raw spans. The example independently checks the email offset and complete replacement text.
Run in a new private working directory as ubuntu. The commands write requests and responses there; retain or securely remove them according to your data policy.
python3 - <<'PYTEXT'
import json
from pathlib import Path
Path('request.json').write_text(json.dumps({
'language': 'en', 'text': 'Send the update to dispatch@example.com.',
'entities': ['EMAIL_ADDRESS']}))
PYTEXT
sushi-presidio-api POST /process --input request.json > redacted.json
python3 - <<'PYTEXT'
import json
from pathlib import Path
source = json.loads(Path('request.json').read_text())['text']
result = json.loads(Path('redacted.json').read_text())
email = 'dispatch@example.com'
assert result['text'] == source.replace(email, '<EMAIL_ADDRESS>')
assert {(x['entity_type'], x['start'], x['end']) for x in result['entities']} == {
('EMAIL_ADDRESS', source.index(email), source.index(email) + len(email))}
print(result['text'])
PYTEXT
For Spanish, use language: es and your own independently labelled text. The optional entities list must contain 1–32 distinct recognizer names supported for the requested language. An invalid selection returns HTTP 400. Do not infer complete personal-data removal from a successful example.
Package limits. Text only, 1–32,000 characters per request, one operation at a time. Uses small spaCy models and score threshold 0.6. No PDF/OCR pipeline, database connector, reversible encryption or compliance guarantee. Detection can miss entities or produce false positives; apply your policy and review the output.
The fuller walkthrough and installed operating notes are in /opt/sushi/docs/DEMO.md and /opt/sushi/docs/README.md. These describe this package’s API and defaults. General upstream examples may use different endpoints or include features outside this package.
Last updated October 17, 2026 · Suggest an improvement