Skip to main content

Trade Safety Backend

K-pop 굿즈 거래 안전성 AI 분석 Python 패키지

주요 기능

  • LLM 기반 거래글 분석
  • 다국어 지원 (한국어 번역 및 뉘앙스 설명)
  • 위험 신호 탐지 (결제, 판매자, 플랫폼, 가격, 콘텐츠)
  • 시장가 대비 가격 분석
  • Freemium 모델

설치

cd backend
poetry install

사용법

서비스 사용

from aioia_core.settings import OpenAIAPISettings
from trade_safety.service import TradeSafetyService
from trade_safety.settings import TradeSafetyModelSettings

openai_api = OpenAIAPISettings(api_key="sk-...")
model_settings = TradeSafetyModelSettings()
service = TradeSafetyService(
    openai_api=openai_api,
    model_settings=model_settings,
)

analysis = await service.analyze_trade("급처분 양도해요")
print(f"위험도: {analysis.risk_score}/100")

FastAPI 통합

from trade_safety.api.router import create_trade_safety_router

router = create_trade_safety_router(app_config)
app.include_router(router, prefix="/api/v2")

개발

poetry install
poetry run make test
poetry run make lint
poetry run make type-check
poetry run make format

환경 변수

변수명 필수 설명
OPENAI_API_KEY O OpenAI API 키
TWITTER_BEARER_TOKEN X Twitter/X URL 분석용 (미설정 시 URL 분석 불가)

의존성

  • aioia-core (공통 인프라)
  • FastAPI, SQLAlchemy, Pydantic
  • OpenAI API 키 필요

라이선스

Apache 2.0

Metadata

Release files for trade-safety 1.12.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for trade-safety 1.12.1
File Size Uploaded Provenance Actions
trade_safety-1.12.1.tar.gz 21.6 kB With provenance Details for trade_safety-1.12.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for trade-safety 1.12.1
File Interpreter ABI Platform Actions
trade_safety-1.12.1-py3-none-any.whl Python 3 none any Details for trade_safety-1.12.1-py3-none-any.whl

Total release size: 49.2 kB

Release files / trade_safety-1.12.1.tar.gz

Download URL trade_safety-1.12.1.tar.gz
Size 21.6 kB
Tags Source
SHA-256 checksum
How to use checksums
f43e66e6563f8a52ceb297fc55f3afac33e80578d5792a3d8ebf8e274753d9fe
BLAKE2b-256 checksum
How to use checksums
3e410734e7680f5b6335a5b95ef8d7a6766c3b1dd756390b8f264caaefffc148
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Release files / trade_safety-1.12.1-py3-none-any.whl

Download URL trade_safety-1.12.1-py3-none-any.whl
Size 27.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e1efe323dbe70b022f622a023a7bba579c6e3dea00485a15aad3c072046899fc
BLAKE2b-256 checksum
How to use checksums
45ef1eecd0b02abb4c654b29750a3aba87af7b7bd662a63e131caa4919c797cb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

Security for trade-safety 1.12.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for trade_safety-1.12.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page