Re: [PR] refactor: ai-content-moderation to ai-aws-content-moderation [apisix]

2025-03-07 Thread via GitHub


shreemaan-abhishek merged PR #12010:
URL: https://github.com/apache/apisix/pull/12010


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] refactor: ai-content-moderation to ai-aws-content-moderation [apisix]

2025-03-07 Thread via GitHub


kayx23 commented on code in PR #12010:
URL: https://github.com/apache/apisix/pull/12010#discussion_r1984740667


##
docs/en/latest/plugins/ai-aws-content-moderation.md:
##
@@ -29,23 +29,23 @@ description: This document contains information about the 
Apache APISIX ai-conte
 
 ## Description
 
-The `ai-content-moderation` plugin processes the request body to check for 
toxicity and rejects the request if it exceeds the configured threshold.
+The `ai-aws-content-moderation` plugin processes the request body to check for 
toxicity and rejects the request if it exceeds the configured threshold.
 
 **_This plugin must be used in routes that proxy requests to LLMs only._**
 
 **_As of now, the plugin only supports the integration with [AWS 
Comprehend](https://aws.amazon.com/comprehend/) for content moderation. PRs for 
introducing support for other service providers are welcomed._**
 
 ## Plugin Attributes
 
-| **Field** | **Required** | **Type** | 
**Description** 


|
-| - |  |  | 
---
 |
-| provider.aws_comprehend.access_key_id | Yes  | String   | AWS 
access key ID   


|
-| provider.aws_comprehend.secret_access_key | Yes  | String   | AWS 
secret access key   


|
-| provider.aws_comprehend.region| Yes  | String   | AWS 
region  


|
-| provider.aws_comprehend.endpoint  | No   | String   | AWS 
Comprehend service endpoint. Must match the pattern `^https?://`


|
-| moderation_categories | No   | Object   | 
Key-value pairs of moderation category and their score. In each pair, the key 
should be one of the `PROFANITY`, `HATE_SPEECH`, `INSULT`, 
`HARASSMENT_OR_ABUSE`, `SEXUAL`, or `VIOLENCE_OR_THREAT`; and the value should 
be between 0 and 1 (inclusive). |
-| moderation_threshold| No   | Number   | 
The degree to which content is harmful, offensive, or inappropriate. A higher 
value indicates more toxic content allowed. Range: 0 - 1. Default: 0.5  

  |
-| llm_provider  | Yes  | String   | Name 
of the LLM provider that this route will proxy requests to. 


   |
+| **Field**| **Required** | **Type** | **Description** 


|
+|  |  |  | 
---
 |
+| comprehend.access_key_id | Yes  | String   | AWS access key ID   


|
+| comprehend.secret_access_key | Yes  | String   | AWS secret access 
key 
   

Re: [PR] refactor: ai-content-moderation to ai-aws-content-moderation [apisix]

2025-03-04 Thread via GitHub


membphis commented on PR #12010:
URL: https://github.com/apache/apisix/pull/12010#issuecomment-2699470827

   ci failed


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] refactor: ai-content-moderation to ai-aws-content-moderation [apisix]

2025-03-02 Thread via GitHub


shreemaan-abhishek commented on PR #12010:
URL: https://github.com/apache/apisix/pull/12010#issuecomment-2693523629

   > CI failed, pls fix those first
   
   seems like flaky error, I have re-run the CI.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] refactor: ai-content-moderation to ai-aws-content-moderation [apisix]

2025-03-02 Thread via GitHub


membphis commented on PR #12010:
URL: https://github.com/apache/apisix/pull/12010#issuecomment-2693493701

   CI failed, pls fix those first


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]