headchem / StoryGhostPlotter

0 stars 0 forks source link

Add OpenAI content policy API checks #73

Closed headchem closed 2 years ago

headchem commented 2 years ago

Requirements: https://beta.openai.com/docs/usage-guidelines/default-safety-requirements-for-all-applications

response = openai.Completion.create(
  engine="davinci",
  prompt="This is a test",
  max_tokens=5,
  user="1"
)
headchem commented 2 years ago

I can also use the content filter API to periodically scan existing stories for inappropriate content, which could automatically prevent public sharing? Or to alert me to block an account.

Make a new Service layer dedicated to content checking so I can easily use it for both completions and general scanning.