로컬 LLM 환경을 구축하기 위해 연구하며 정리한 문서 입니다. 구축 환경은 Apple Mac mini M4(RAM:16GB) 입니다. 외부 인공지능 API(OpenAI 등)를 사용하지 않고, 100% 로컬 환경에서 구동되는 RAG(Retrieval-Augmented Generation) 시스템을 만들기 위한 Ollama 설치 및 초기 환경 설정 방법을 설명합니다.
1. Homebrew로 Ollama 설치 및 실행하기
macOS의 패키지 매니저인 Homebrew를 사용하면 터미널 명령어 한 줄로 Ollama를 깔끔하게 설치하고, 백그라운드 서비스로 편리하게 관리할 수 있습니다.
터미널을 열고 아래 명령어를 입력하여 Ollama를 설치합니다.
% brew install ollama
% ollama serve
2. 로컬 AI 모델 다운로드
대화형 언어 모델 (Qwen3)을 다운로드 합니다. 저의 시스템 환경에서 가장 성능을 잘 내어주는 시스템을 AI에 문의한 결과 ‘qwen3:8b’ 모델이라고 답변을 받아 그걸 설치했습니다.
% ollama run qwen3:8b
>>> Send a message (/? for help)
3. 로컬 AI 모델 테스트
잘 동작하는지 질의해 봅니다.
>>> "안녕"을 영어로 번역해줘.
Thinking...
Okay, the user asked to translate "안녕" into English. Let me think about the possible translations.
"안녕" is a common Korean greeting. The most straightforward translation is "Hello." But sometimes people might use "Hi" as
well, which is more casual. Depending on the context, it could also be "Good day" or "How are you?" but those are more formal
or used in specific situations.
I should consider the user's intent. They might just want a simple translation for general use. Since "Hello" is the most
direct and widely understood, that's probably the safest answer. However, I should mention the alternatives like "Hi" to cover
different contexts. Also, maybe note that the tone can vary based on formality. Let me check if there are any other nuances.
For example, in some cases, "안녕" can also be used to say goodbye, but the primary translation for greeting is "Hello." So the
main answer is "Hello," with additional options in parentheses. That should cover it.
...done thinking.
"안녕"은 영어로 **"Hello"**로 번역됩니다.
가벼운 인사나 일상적인 대화에서 사용되며, **"Hi"**로도 표현할 수 있습니다.
문맥에 따라 **"Good day"**나 **"How are you?"**처럼 더 정중하거나 따뜻한 표현도 사용될 수 있습니다. 😊
>>> Send a message (/? for help)
답글 남기기