deep learning 23

[딥러닝, 검색엔진] HNSW, IVFFlat 바닥부터 탐색하기 (Vector Search)

RAG를 위해서 벡터 스토어를 사용하신건 알겠어요, 그런데.. 인덱스를 위한 옵션을 어떤 것을 사용하셨나요? 필자가 면접에서 굉장히 당황스러워했던 질문 중에 하나였습니다. 인덱스...? 데이터베이스에서 쿼리 반환을 위해 사용하는 옵티마이저 중 하나인 인덱스를 말하는 것 같은데.. 여러 프로젝트를 진행하면서 벡터 검색을 하는데에 있어서는 옵션이 있는지도 몰랐었습니다 기껏 해봐야 임베딩 차원? 아니면 거리 유사도 계산법이 다른건가? 등 여러가지로 복합적인 생각이 많이 들었습니다. 벡터 검색에서의 인덱스 오늘의 포스팅에서는 Postgres와 Pgvector의 맥락에서 벡터 인덱스와 그 장단점을 살펴보겠습니다. 특히 빌드 시간, 크기, 속도를 비교하고 이를 바탕으로 특정 애플리케이션에 어떤 것을 선택할..

[딥러닝, 정보 이론] KL Divergence와 엔트로피 완전 정복

정보량부터 손실 함수까지, 분류 문제에 숨어 있는 수학적 원리 풀어보기왜 KL Divergence가 중요한가?딥러닝에서 KL Divergence는 단순히 두 분포의 차이를 계산하는 수학적 도구를 넘어서,모델의 학습 방향을 정의하는 핵심 지표로 쓰입니다.예를 들어,이미지 생성 모델에서는 정해진 분포(예: 정규 분포)로부터 생성된 latent vector가 실제 데이터 분포와 얼마나 다른지를 KL Divergence로 측정하고,강화학습(Reinforcement Learning)에서는 정책(policy)이 바뀔 때 이전 정책과의 거리 차이를 KL Divergence로 제약하여 안정적인 학습을 유도합니다.특히 DeepSeek과 같은 최신 LLM 학습에서도 KL penalty를 포함한 RLHF(강화학습 기반 미세..

[딥러닝, 논문리뷰] GPT3 - Language Models are Few-Shot Learners

https://arxiv.org/abs/2005.14165 Language Models are Few-Shot LearnersRecent work has demonstrated substantial gains on many NLP tasks and benchmarks by pre-training on a large corpus of text followed by fine-tuning on a specific task. While typically task-agnostic in architecture, this method still requires task-specific fiarxiv.org 1. Abstract  1. 최근 NLP 연구의 흐름  방대한 텍스트를 통해서 사전학습을 한 후에, 특정 태스크..

[딥러닝, 논문리뷰] Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks

https://arxiv.org/abs/1908.10084 Sentence-BERT: Sentence Embeddings using Siamese BERT-NetworksBERT (Devlin et al., 2018) and RoBERTa (Liu et al., 2019) has set a new state-of-the-art performance on sentence-pair regression tasks like semantic textual similarity (STS). However, it requires that both sentences are fed into the network, which causes aarxiv.org SBERT란? BERT기반으로 한 문장 임베딩 모델임(양방향 학습을..

[멀티모달 기초논문] VIT - An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale

https://arxiv.org/abs/2010.11929 An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleWhile the Transformer architecture has become the de-facto standard for natural language processing tasks, its applications to computer vision remain limited. In vision, attention is either applied in conjunction with convolutional networks, or used to reparxiv.org 1. Abstract 기존 트랜스포머는 자연어..

[개인 프로젝트] LLM을 활용한 서비스 구축 사례 - 1

시작하면서 여태 논문을 통해 공부하면서, 과연 나는 딥러닝을 통해서 어떠한 서비스를 만들 수 있을까 많은 시간 고민하며 지내왔습니다. 그러면서 최근 "쿠팡", "마켓컬리" 등 온라인커머스 시장을 알게 되고, 그에 따른 시장규모에 대한 간단한 조사를 실시하였습니다.  상기 차트를 보면 알 수 있지만, 생각보다 시장 비용이 크게 증가한 것을 알 수 있습니다. 개인적인 추론으로는, 과거에는 짬나는 시간에 가족들과 함께 마트에 가서 장을 보며 물품을 구매하는 '오프라인 구매'가 주류였지만, 코로나 사태 이후로는 소비 심리 자체가 오프라인에서 온라인 구매로 전환되기 시작한 것으로 보입니다. 왜 그런것일까요?    그 원천은 새벽배송이라고 볼 수 있습니다. 대표적인 기업으로는 "쿠팡", "컬리", "SSG" 등 굴..

프로젝트 2025.03.11

[딥러닝, 논문리뷰] Attention Is All You Need 3 - Residual Connection, 나머지 내용들

https://arxiv.org/abs/1706.03762  Attention Is All You NeedThe dominant sequence transduction models are based on complex recurrent or convolutional neural networks in an encoder-decoder configuration. The best performing models also connect the encoder and decoder through an attention mechanism. We propose a newarxiv.org 이번 시간은 트랜스포머 메커니즘 마지막 단계인 Residual Connection에 대해서 정리하면서 트랜스포머 이론편은 마무리 하도..

[딥러닝, 논문리뷰] Distilling the Knowledge in a Neural Network

https://arxiv.org/abs/1503.02531 Distilling the Knowledge in a Neural NetworkA very simple way to improve the performance of almost any machine learning algorithm is to train many different models on the same data and then to average their predictions. Unfortunately, making predictions using a whole ensemble of models is cumbersomearxiv.org 트랜스포머 기반으로 딥러닝의 급속한 발전을 토대로 많은 인공지능 모델들이 서비스 현장에 나와있음에도..

[딥러닝] A Study of BFLOAT16 for Deep Learning Training - 부동소수점

https://arxiv.org/abs/1905.12322 A Study of BFLOAT16 for Deep Learning TrainingThis paper presents the first comprehensive empirical study demonstrating the efficacy of the Brain Floating Point (BFLOAT16) half-precision format for Deep Learning training across image classification, speech recognition, language modeling, generative nearxiv.org 딥러닝 연산에 꼭 필요한 부동소수점  일단 논문 내용을 훑기 전에 기본 개념에 대해서 정리할 필..

[딥러닝, 논문리뷰] GPT-2 Language Models are Unsupervised Multitask Learners

https://cdn.openai.com/better-language-models/language_models_are_unsupervised_multitask_learners.pdf  https://cheorish.tistory.com/28 [딥러닝, 논문리뷰] GPT-1 Improving Language Understandingby Generative Pre-Traininghttps://cdn.openai.com/research-covers/language-unsupervised/language_understanding_paper.pdf 1. Abstract 기존 NLU(자연어의 이해)에는 문장의 논리적 관계를 분석하는 "문장간의 함의 관계", QA태스크, 의미적 유사성 평cheorish.tistory..