Skip to main content

The official filtro python package.

Project description

filtro-python

The official Python API package for filtro.ai. Empowering your applications with AI, while safeguarding sensitive data across all third-party models, in just a few lines of Python code.

⚙️ Install

pip install filtro

🗣️ Usage

from filtro import mask, clear

masked, mapping = mask(
    "Hi my name is Giovanni, I work at Google. What's up?"
)

from langchain.llms import OpenAI
llm = OpenAI(temperature=0.9)
response = llm(masked)

cleared = clear(response, mapping)

🥽 Examples

python examples/basic.py
Show output

[YOUR INPUT] Hi my name is Gianmarco Rengucci! I am a Software Engineer at Apple, here in Milan. Whats up?

[FILTRO.AI] Hi my name is Terri Clark! I am a Software Engineer at Compton-Krueger, here in Lake Erin. Whats up?

[OPENAI] Hey there Terri, nice to meet you! Im doing great, but Im curious to learn more about what you do at Compton-Krueger. Could you tell me a little bit about your role at the company?

[FILTRO.AI] Hey there Gianmarco, nice to meet you! Im doing great, but Im curious to learn more about what you do at Apple. Could you tell me a little bit about your role at the company?

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

filtro-0.1.1.tar.gz (1.7 kB view hashes)

Uploaded Source

Built Distribution

filtro-0.1.1-py3-none-any.whl (2.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page