이미지 생성

개요

Atlas Cloud는 통합 API를 통해 다양한 AI 이미지 생성 모델에 접근할 수 있습니다. 텍스트 프롬프트로 멋진 이미지를 생성하고, 기존 이미지를 변환하고, 배경을 제거하고, 얼굴을 교체하는 등 — 모두 단일 API 호출로 가능합니다.

지원 모델 유형

유형설명사용 사례
텍스트-투-이미지텍스트 설명으로 이미지 생성크리에이티브 콘텐츠, 마케팅, 디자인, 프로토타이핑
이미지-투-이미지기존 이미지 변환 및 향상스타일 변환, 인페인팅, 아웃페인팅
이미지 도구고급 이미지 처리 및 조작배경 제거, 얼굴 교체, 업스케일링, 복원

주요 모델

모델제공업체특징
SeedreamByteDance우수한 프롬프트 추종력을 갖춘 고품질 텍스트-투-이미지
FLUXBlack Forest Labs여러 변형(Dev, Schnell, Pro)을 갖춘 빠르고 고충실도 이미지 생성
Qwen-ImageAlibaba강력한 다국어 이미지 생성
IdeogramIdeogram이미지 내 우수한 텍스트 렌더링
HiDreamHiDream크리에이티브하고 예술적인 이미지 생성
DALL-EOpenAI다재다능한 이미지 생성 및 편집
ImagenGoogleGoogle의 최첨단 이미지 생성

모든 이미지 모델의 전체 목록과 사양은 모델 라이브러리를 방문하세요.

API 사용법

텍스트-투-이미지

import requests

response = requests.post(
    "https://api.atlascloud.ai/api/v1/model/generateImage",
    headers={
        "Authorization": "Bearer your-api-key",
        "Content-Type": "application/json"
    },
    json={
        "model": "seedream-3.0",
        "prompt": "A serene Japanese garden with cherry blossoms, watercolor style"
    }
)

result = response.json()
prediction_id = result["data"]["id"]
print(f"Prediction ID: {prediction_id}")

Node.js 예제

const response = await fetch(
  "https://api.atlascloud.ai/api/v1/model/generateImage",
  {
    method: "POST",
    headers: {
      Authorization: "Bearer your-api-key",
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      model: "seedream-3.0",
      prompt:
        "A serene Japanese garden with cherry blossoms, watercolor style",
    }),
  }
);

const { data } = await response.json();
console.log(`Prediction ID: ${data.id}`);

cURL 예제

curl -X POST https://api.atlascloud.ai/api/v1/model/generateImage \
  -H "Authorization: Bearer your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedream-3.0",
    "prompt": "A serene Japanese garden with cherry blossoms, watercolor style"
  }'

이미지 결과 조회

이미지 생성은 비동기적으로 처리됩니다. 예측 ID를 사용하여 결과를 조회하세요:

import requests
import time

def get_image_result(prediction_id, api_key):
    while True:
        response = requests.get(
            f"https://api.atlascloud.ai/api/v1/model/prediction/{prediction_id}",
            headers={"Authorization": f"Bearer {api_key}"}
        )
        result = response.json()

        if result["data"]["status"] == "completed":
            return result["data"]["outputs"][0]
        elif result["data"]["status"] == "failed":
            raise Exception(f"Generation failed: {result['data'].get('error')}")

        time.sleep(2)  # 2초마다 폴링

image_url = get_image_result(prediction_id, "your-api-key")
print(f"Image URL: {image_url}")

LoRA 모델 사용

LoRA(Low-Rank Adaptation) 모델을 사용하여 커스텀 스타일과 세밀한 제어로 이미지 생성을 향상시킬 수 있습니다. LoRA 모델의 검색, 선택, 사용에 대한 자세한 안내는 LoRA 가이드를 참조하세요.

더 나은 결과를 위한 팁

  • 구체적으로 작성하세요: 프롬프트에 스타일, 구도, 조명, 분위기를 설명하세요
  • 부정 프롬프트를 사용하세요: 이미지에 원하지 않는 것을 지정하세요 (모델이 지원하는 경우)
  • 다양한 모델을 실험하세요: 각 모델은 다른 스타일에 특화 — 포토리얼리스틱, 애니메이션, 아트 등
  • 파라미터를 조정하세요: 각 모델에는 고유한 파라미터가 있습니다. 모델 라이브러리에서 사용 가능한 옵션을 확인하세요
  • 시드 값을 사용하세요: 프롬프트를 반복 작업할 때 재현 가능한 결과를 위해 시드를 설정하세요

업계 최고 수준의 속도

Atlas Cloud의 최적화된 추론 인프라는 빠른 이미지 생성 속도를 제공합니다 — 대부분의 모델에서 5초 이내. 경쟁력 있는 가격과 결합하여 프로토타이핑과 프로덕션 워크로드 모두에 이상적입니다.

전체 API 사양 및 모델별 파라미터는 API 레퍼런스를 참조하세요.