@@ -52,11 +52,6 @@ class Gptimage(SimpleService): '1024x1536': 1372, }, } - MODERATION = { - 'Авто': 'auto', - 'Низкая': 'low', - } - def __init__(self, store: BaseStore) -> None: super().__init__(store) self.logger = logging.getLogger(self.__class__.__name__) @@ -109,13 +104,14 @@ class Gptimage(SimpleService): ): raise InsufficientBalance(balance, cost) for proxy in Proxy.objects.all(): + moderation = 'low' if self.store.user.account_type == 'regular' else 'auto' json_data = { 'prompt': input_message.content, 'model': 'gpt-image-2', 'n': 1, 'quality': quality, 'size': size, - 'moderation': self.MODERATION[info.get('moderation', 'Авто')], + 'moderation': moderation, 'output_format': 'png', } with httpx.Client(