Class: GetStream::Generated::Models::AgentReviewSettingsPayload
- Inherits:
-
BaseModel
- Object
- BaseModel
- GetStream::Generated::Models::AgentReviewSettingsPayload
- Defined in:
- lib/getstream_ruby/generated/models/agent_review_settings_payload.rb
Overview
Settings for the moderation agent reviewer, which reviews moderation outcomes and proposes or applies an action.
Instance Attribute Summary collapse
-
#agent_config_id ⇒ String
The app's Accelerate agent config with role agent_moderator.
-
#auto_act_min_confidence ⇒ Float
Minimum verdict confidence (0-1) for auto_act to apply an action.
-
#context_days ⇒ Integer
Days of the user's moderation history given to the agent.
-
#context_messages ⇒ Integer
Surrounding items given to the agent on each side of the reviewed one: chat messages, Feeds comments, or the author's other Feeds activities.
-
#enabled ⇒ Boolean
Turns the agent reviewer on.
-
#max_concurrency ⇒ Integer
Maximum reviews in flight for the app.
-
#mode ⇒ String
Approve_first records the verdict for a moderator to approve; auto_act applies it when its confidence reaches auto_act_min_confidence; export_only changes nothing on the review queue and only exports each verdict for evaluation.
-
#review_images ⇒ Boolean
Sends the images of the content under review to the agent, so it can judge them alongside the text.
-
#rule_ids ⇒ Array<String>
Moderation rule IDs: only items flagged by one of these rules are reviewed, and items flagged only by other sources are left to moderators.
-
#sample_rate ⇒ Float
Fraction (0-1) of checks reviewed with scope all_checks.
-
#scope ⇒ String
Which checks are reviewed: flagged ones only, or all_checks sampled by sample_rate.
Class Method Summary collapse
-
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ AgentReviewSettingsPayload
constructor
Initialize with attributes.
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ AgentReviewSettingsPayload
Initialize with attributes
47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 47 def initialize(attributes = {}) super(attributes) @agent_config_id = attributes.fetch(:agent_config_id) { attributes.fetch('agent_config_id', nil) } @auto_act_min_confidence = attributes.fetch(:auto_act_min_confidence) { attributes.fetch('auto_act_min_confidence', nil) } @context_days = attributes.fetch(:context_days) { attributes.fetch('context_days', nil) } @context_messages = attributes.fetch(:context_messages) { attributes.fetch('context_messages', nil) } @enabled = attributes.fetch(:enabled) { attributes.fetch('enabled', nil) } @max_concurrency = attributes.fetch(:max_concurrency) { attributes.fetch('max_concurrency', nil) } @mode = attributes.fetch(:mode) { attributes.fetch('mode', nil) } @review_images = attributes.fetch(:review_images) { attributes.fetch('review_images', nil) } @sample_rate = attributes.fetch(:sample_rate) { attributes.fetch('sample_rate', nil) } @scope = attributes.fetch(:scope) { attributes.fetch('scope', nil) } @rule_ids = attributes.fetch(:rule_ids) { attributes.fetch('rule_ids', nil) } end |
Instance Attribute Details
#agent_config_id ⇒ String
Returns The app's Accelerate agent config with role agent_moderator.
14 15 16 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 14 def agent_config_id @agent_config_id end |
#auto_act_min_confidence ⇒ Float
Returns Minimum verdict confidence (0-1) for auto_act to apply an action. Defaults to 0.9.
17 18 19 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 17 def auto_act_min_confidence @auto_act_min_confidence end |
#context_days ⇒ Integer
Returns Days of the user's moderation history given to the agent. Defaults to 7, at most 30.
20 21 22 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 20 def context_days @context_days end |
#context_messages ⇒ Integer
Returns Surrounding items given to the agent on each side of the reviewed one: chat messages, Feeds comments, or the author's other Feeds activities. Defaults to 20, at most 100.
23 24 25 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 23 def @context_messages end |
#enabled ⇒ Boolean
Returns Turns the agent reviewer on. It only runs when agent_config_id is set too.
26 27 28 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 26 def enabled @enabled end |
#max_concurrency ⇒ Integer
Returns Maximum reviews in flight for the app. Defaults to 10, at most 100.
29 30 31 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 29 def max_concurrency @max_concurrency end |
#mode ⇒ String
Returns approve_first records the verdict for a moderator to approve; auto_act applies it when its confidence reaches auto_act_min_confidence; export_only changes nothing on the review queue and only exports each verdict for evaluation. Defaults to approve_first.
32 33 34 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 32 def mode @mode end |
#review_images ⇒ Boolean
Returns Sends the images of the content under review to the agent, so it can judge them alongside the text. The agent config must run on a model that sees images. Defaults to false.
35 36 37 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 35 def review_images @review_images end |
#rule_ids ⇒ Array<String>
Returns Moderation rule IDs: only items flagged by one of these rules are reviewed, and items flagged only by other sources are left to moderators. Empty reviews every flagged item. Only used with scope flagged; at most 100.
44 45 46 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 44 def rule_ids @rule_ids end |
#sample_rate ⇒ Float
Returns Fraction (0-1) of checks reviewed with scope all_checks. Defaults to 1.
38 39 40 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 38 def sample_rate @sample_rate end |
#scope ⇒ String
Returns Which checks are reviewed: flagged ones only, or all_checks sampled by sample_rate. Defaults to flagged.
41 42 43 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 41 def scope @scope end |
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 |
# File 'lib/getstream_ruby/generated/models/agent_review_settings_payload.rb', line 63 def self.json_field_mappings { agent_config_id: 'agent_config_id', auto_act_min_confidence: 'auto_act_min_confidence', context_days: 'context_days', context_messages: 'context_messages', enabled: 'enabled', max_concurrency: 'max_concurrency', mode: 'mode', review_images: 'review_images', sample_rate: 'sample_rate', scope: 'scope', rule_ids: 'rule_ids' } end |