Skip to Content
GPT API를 활용한 인공지능 앱 개발(2판)
book

GPT API를 활용한 인공지능 앱 개발(2판)

by 올리비에 케일린, 마리 알리스 블레트, 이일섭, 박태환
December 2024
Beginner to intermediate
320 pages
7h 25m
Korean
Hanbit Media, Inc.
Content preview from GPT API를 활용한 인공지능 앱 개발(2판)
162
GPT API를 활용한 인공지능 앱 개발(2판)
3.7
외부
API
와 작업
오픈
AI
API
와 외부 서비스를 함께 사용 시 여러 문제에 직면할 수 있습니다.
API
는 중단 및 예
상치 못한 오류가 발생할 수 있습니다. 오픈
AI
API
는 요청 제한이 있으며,
LLM
생성이 오래
걸릴 수 있어 응답성을 높이는 것이 프로젝트에 난관으로 작용할 수 있습니다. 이 절에서는 에
러 및 요청 제한을 관리하는 팁과 사용자 경험을 개선하는 방법을 다룹니다.
3.7.1
오류 및 예기치 않은 지연 문제 처리
이 절에서 소개된 사례는 오픈
AI
에 한정된 것이 아니며, 어떤
API
나 외부 서비스와 통합할 때
도 유효합니다. 원칙은 다음과 같습니다.
API
실패나 지연은 애플리케이션의 안정성이나 성능
에 영향을 주지 않아야 합니다.
이를 달성하기 위해 가장 흔히 사용하는 프로그래밍 패턴은 다음과 같습니다.
오류 처리
API
호출을
try
/
catch
블록으로 감싸고, 가능한 한 빨리 오류를 처리하세요. 오류를 관리
하면 항상 애플리케이션이 일관된 상태를 유지하고, 오류를 자세히 기록하며, 필요시 사용
자에게 관련된 메시지를 표시하는 것을 의미합니다 (기술적인 세부 사항은 숨깁니다 ). 오
AI
는 발생할 수 있는 예외, 그 원인, 그리고 가능한 해결책 목록(
https
://
oreil
.
ly
/
xlec2
)을 제공합니다. 이 목록을 오류 처리 전략의 기본으로 사용하는 것을 강력히 추천
합니다.
지수 백오프 전략
이 패턴은 재시도를 처리하는 표준 방법입니다. 실패한 요청을 주기적으로 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

개발 7년차, 매니저 1일차

개발 7년차, 매니저 1일차

권원상, 한민주, 카미유 푸르니에
GPT-4를 활용한 인공지능 앱 개발

GPT-4를 활용한 인공지능 앱 개발

올리비에 케일린, 마리 알리스 블레트

Publisher Resources

ISBN: 9791169213295