묻고 답해요
156만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
환경설정 질문
질문이 있습니다.선생님께서 설정된 toml 파일은 캐럿(^)을 포함한 버전이 설정되어 있는데, 제가 프로젝트를 생성하고 toml을 확인할 경우 명시적으로 범위가 설정되어져 있습니다. 물론 큰 차이는 없겠지만 나중에 실질적인 업무나 개인적인 프로젝트를 진행할 때 영향도가 있을까요?? 만약 있다면 선생님처럼 버전을 지정해서 등록할 수 있는 설정이 따로 있을까요??
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
poetry add python-dotenv langchain langchain-openai gradio 설치 안 되요
패키지 설치:poetry add python-dotenv langchain langchain_openai gradio위를 입력하는데, 아래 처럼 같은 에러가 수십번 납니다 PS D:\mypersonal\myprojects\LANGCHAIN\qa-bot> poetry add python-dotenv langchain langchain-openai gradioUsing version ^1.1.1 for python-dotenvUsing version ^0.3.26 for langchainUsing version ^0.3.27 for langchain-openaiUsing version ^5.35.0 for gradioUpdating dependenciesResolving dependencies... (1.1s)The current project's supported Python range (>=3.10) is not compatible with some of the required packages Python requirement: - langchain-text-splitters requires Python <4.0,>=3.9, so it will not be installable for Python >=4.0Because no versions of langchain match >0.3.26,<0.4.0 and langchain (0.3.26) depends on langchain-text-splitters (>=0.3.8,<1.0.0), langchain (>=0.3.26,<0.4.0) requires langchain-text-splitters (>=0.3.8,<1.0.0).Because langchain-text-splitters (0.3.8) requires Python <4.0,>=3.9 and no versions of langchain-text-splitters match >0.3.8,<1.0.0, langchain-text-splitters is forbidden.Thus, langchain is forbidden.So, because qa-bot depends on langchain (^0.3.26), version solving failed. * Check your dependencies Python requirement: The Python requirement can be specified via the python or markers properties For langchain-text-splitters, a possible solution would be to set the python property to ">=3.10,<4.0"
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
OpenAI API를 활용하여 LLM Chain 구현하기 (실습)
OpenAI API를 활용하여 LLM Chain 구현하기 (실습) 에서 llm.invoke(prompt_text)하면 이런에러가뜹니다..api_key 새로 갱신받아도 계속 이럽니다..
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
OpenAI API를 활용하여 LLM Chain 구현하기 (실습) 에서
OpenAI API를 활용하여 LLM Chain 구현하기 (실습) 에서 All attempts to connect to pypi.org failed.Probable Causes: - the server is not responding to requests at the moment - the hostname cannot be resolved by your DNS - your network is not connected to the internetYou can also run your poetry command with -v to see more information. 이런 에러가뜹니다.. 미치겠네요..
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
커널선택시 poetry env가 보이지 않습니다.
위와 같이 poetry env 가 보이지 않는데 어떻게 해결해야 할까요??
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
환경설정문제
poetry 설치후 실행시 오류가 발생합니다.환경변수도 설정하였는데 이유를 못찾겠습니다.poetry 설치된 폴더 가보면 exe 파일은 미존재하던데 그것때문인건지... 환경설정이 되질 않아서 실습을 하지 못해서 답답하네요..
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
[질문드립니다] poetry export -f requirements.txt --output requirements.txt
선생님께서 알려주신대로 txt 파일 뽑은 후(해시가 담겨있는) requirements.txt 업로드 시 서버에서 아래와 같은 에러가 났었습니다. 혹시 몰라서 pip freeze > requirements.txt로 생성한 뒤 업로드 해보니 제대로 실행이 되더라고요...! 이게 왜 그런걸까요? 선생님께서는 현재도 poetry export -f requirements.txt --output requirements.txt 로 만든 후 업로드 해도 실행이 잘 되시는 걸까요?'에러': ===== Application Startup at 2025-01-09 14:21:54 ===== Traceback (most recent call last): File "/home/user/app/app.py", line 2, in <module> from dotenv import load_dotenv ModuleNotFoundError: No module named 'dotenv'QnA 정리:poetry export -f requirements.txt --output requirements.txt 한 후에 업로드 했더니 서버에서 모듈을 다운로드 하지 못함pip freeze > requirements.txt 로 한 후에 업로드 했더니 서버에서 모듈을 정상적으로 다운로드 하고 app.py를 실행함
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
[심화질문] Gradio ChatInterface로 PDF 챗봇 애플리케이션 구현
안녕하세요. 유익한 콘텐츠 만들어주셔서 흥미롭게 강의를 듣고 있습니다. 이번 강의에서 질문드릴게 있어요.'Gradio ChatInterface로 PDF 챗봇 애플리케이션 구현' 마지막에 논문의 저자(attention all you need 논문)는 몇 명이냐?는 질문에 대한 답이 10명으로 나옵니다. 저도 똑같이 구현하고 chunk size, chuck overlap, temperature를 조절하면서 물어봐도 제대로 된 답변(정답은 8명)을 못하더라고요.그런데 똑같은 모델(gpt-4o-mini)을 Chatgpt 웹상에서 pdf 파일을 업로드 하고 몇 명이냐고 물어보면 정확하게 답변을 합니다.어떤 부분에서 문제가 되길래 이번 프로젝트에서 논문의 저자가 몇 명이냐는 질문에 제대로 된 대답을 못하는 걸까요?
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
creawai Agent 선언 부분 오류 문의
section 5 의 코드 중 crewai 의 Agent 선언에서 오류 발생합니다.search_tool = TavilySearchResults() researcher = Agent( role="Market Researcher", goal=f"Uncover emerging trends and investment opportunities in the cryptocurrency market in 2024. Focus on the topic: {topic}.", backstory="Identify groundbreaking trends and actionable insights.", verbose=True, tools=[search_tool], -> 이 부분 오류 발생 allow_delegation=False, llm=llm, max_iter=3, max_rpm=10, ) pydantic_core._pydantic_core.ValidationError: 1 validation error for Agent tools Value error, Invalid tool type: <class 'langchain_community.tools.tavily_search.tool.TavilySearchResults'>. Tool must be an instance of BaseTool or an object with 'name', 'func', and 'description' attributes. [type=value_error, input_value=[TavilySearchResults(api_...cretStr('**********')))], input_type=list] For further information visit https://errors.pydantic.dev/2.10/v/value_errorcrewai 및 langchain 버전은 아래와 같습니다.crewai 0.86.0crewai-tools 0.17.0langchain 0.3.10langchain-community 0.3.10
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
10강 langchain_community 찾을 수 없는 오류
여기서 langchain_community를 찾을 수 없다고 합니다 분명히 환경에는 잘 설치되있는데..
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
CrewAI 설치시 오류(주신 pyproject.toml 이용)
맥환경에서 아래와 같은 오류가 발생합니다.그래서 pyarrow=="17.0.0"으로 내려서 설치하면 설치는 되는데 main.py 실행시 런타임 오류가 납니다. Terminal에는 output이 있네 그라지오에는 에러라고 나오는 등 poetry install명령을 치면 아래과 같은 설치오류 발생 (CrewAI 설치시) -- Configuring incomplete, errors occurred! error: command '/Library/Frameworks/Python.framework/Versions/3.12/bin/cmake' failed with exit code 1 at ~/Library/Application Support/pypoetry/venv/lib/python3.12/site-packages/poetry/installation/chef.py:164 in _prepare 160│ 161│ error = ChefBuildError("\n\n".join(message_parts)) 162│ 163│ if error is not None: → 164│ raise error from None 165│ 166│ return path 167│ 168│ def preparesdist(self, archive: Path, destination: Path | None = None) -> Path: Note: This error originates from the build backend, and is likely not a problem with poetry but with pyarrow (18.0.0) not supporting PEP 517 builds. You can verify this by running 'pip wheel --no-cache-dir --use-pep517 "pyarrow (==18.0.0)"'. 의존성에 문제가 있는 것 같습니다. 어떻게 해결해야 할까요?
-
해결됨RAG 마스터: 기초부터 고급기법까지 (feat. LangChain)
gradio를 사용하시는 이유에 대해 궁금합니다.
이 강의를 보며 공부하면서 따라하다가 궁금해졌습니다.streamlit을 사용하는 분도 있는데 gradio를 사용하시는 이유가 궁금합니다.그리고 streamlit과 gradio의 차이를 아신다면 알려주시겠습니까?
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
오류문의
다른 컴퓨터에서 해보고있는데 또 똑같은오류가 발생하는거 같아 문의드립니다. 이전 컴퓨터에서는 해당오류 해결하였는데다른컴퓨터에서는 똑같이 발생합니다. lim.invok(prompt_text) 실행시 발생 RateLimitError Traceback (most recent call last) Cell In[21], line 1 ----> 1 response = llm.invoke(prompt_text) File c:\Users\hyunn\AppData\Local\pypoetry\Cache\virtualenvs\qa-bot-uxQSWlcO-py3.11\Lib\site-packages\langchain_core\language_models\chat_models.py:276, in BaseChatModel.invoke(self, input, config, stop, kwargs) 265 def invoke( 266 self, 267 input: LanguageModelInput, (...) 271 kwargs: Any, 272 ) -> BaseMessage: 273 config = ensure_config(config) 274 return cast( 275 ChatGeneration, --> 276 self.generate_prompt( 277 [self._convert_input(input)], 278 stop=stop, 279 callbacks=config.get("callbacks"), 280 tags=config.get("tags"), 281 metadata=config.get("metadata"), 282 run_name=config.get("run_name"), 283 run_id=config.pop("run_id", None), 284 **kwargs, 285 ).generations[0][0],... (...) 1049 retries_taken=options.get_max_retries(self.max_retries) - retries, 1050 ) RateLimitError: Error code: 429 - {'error': {'message': 'You exceeded your current quota, please check your plan and billing details. For more information on this error, read the docs: https://platform.openai.com/docs/guides/error-codes/api-errors.', 'type': 'insufficient_quota', 'param': None, 'code': 'insufficient_quota'}}Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings...
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
llm.invoke(prompt_text) 실행시 에러 발생
llm.invoke(prompt_text) 실행시 에러 발생 강의보고 여러번 다시 설치해보았는데도 똑같은 에러 발생합니다. 해결방법 문의드립니다. --------------------------------------------------------------------------- RateLimitError Traceback (most recent call last) Cell In[7], line 1 ----> 1 llm.invoke(prompt_text) File c:\Users\hyunna.kim\AppData\Local\pypoetry\Cache\virtualenvs\qa-bot-aDTKY8ud-py3.11\Lib\site-packages\langchain_core\language_models\chat_models.py:276, in BaseChatModel.invoke(self, input, config, stop, kwargs) 265 def invoke( 266 self, 267 input: LanguageModelInput, (...) 271 kwargs: Any, 272 ) -> BaseMessage: 273 config = ensure_config(config) 274 return cast( 275 ChatGeneration, --> 276 self.generate_prompt( 277 [self._convert_input(input)], 278 stop=stop, 279 callbacks=config.get("callbacks"), 280 tags=config.get("tags"), 281 metadata=config.get("metadata"), 282 run_name=config.get("run_name"), 283 run_id=config.pop("run_id", None), 284 **kwargs, 285 ).generations[0][0],...(...) 1049 retries_taken=options.get_max_retries(self.max_retries) - retries, 1050 ) RateLimitError: Error code: 429 - {'error': {'message': 'You exceeded your current quota, please check your plan and billing details. For more information on this error, read the docs: https://platform.openai.com/docs/guides/error-codes/api-errors.', 'type': 'insufficient_quota', 'param': None, 'code': 'insufficient_quota'}}Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings...
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
Tavily 검색 도구, CrewAI Sequential Agent 활용 방법 (실습) 수업자료.
안녕하세요! " Tavily 검색 도구, CrewAI Sequential Agent 활용 방법 (실습) "수업에서, dependencies를 제공된 수업자료에서 붙여넣으면 된다고 하셨는데, 제공된 수업자료에는 dependency 부분이 없습니다..수업자료는 test.ipynb밖에 없는데 해당 ipynb 파일에는 dependency 목록이 없어서 인강을 보고 tool poetry dependancies를 직접 쳐야 하는건지 난감한 상황이에요. 시간되실 때, 부디 회신 문의드립니다. 감사합니다.
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
OPENAI_API_KEY 인식중에 에러가 발생하네요,
안녕하세요. .env에서 OPENAI_API_KEY 설정도 제대로 했어요. 실행시 이미지 같은 에러는 어떻게 해야 할까요? 혹시나 해서 openaai에서 api상태도 확인했는데 사용 가능 상태이거든요.
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
ffmpy 설치 실패, ChefBuildError
poetry add python-dotenv langchain langchain_openai gradio 입력하니 powershell에서 이렇게 나옵니다.ffmpy 설치 실패와 함께 ChefBuildError가 뜨는데 어떻게 해야 하나요?아래의 글은 제가 모두 시도해본 방법입니다. 그러나 해결되지 않았습니다. cache 삭제도 해봤습니다.-------------------------------------------------------해결 방법빌드 환경에 setuptools 설치setuptools가 현재 빌드 환경에 설치되어 있는지 확인하고, 설치되어 있지 않다면 설치합니다. 다음 명령어를 사용하여 setuptools를 다시 설치해보세요:pip install --upgrade setuptoolswheel 패키지 설치wheel 패키지도 설치되어 있어야 합니다. 아래 명령어로 설치해 보세요:pip install wheel패키지의 버전 확인ffmpy의 다른 버전을 시도해 볼 수 있습니다. ffmpy의 최신 버전이 문제를 해결할 수 있을지 확인해 보세요. 예를 들어, 최신 버전을 설치하려면:pip install ffmpypip install ffmpy==0.2.3
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
커널에서 poetry env가 보이지 않습니다.
안녕하세요!vs code를 종료하고 재시작해봐도 poetry env 커널이 보이지 않습니다. poetry activate는 했습니다!알려주시면 정말 감사하겠습니다.
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
Chroma 오류
Chroma 오류가 발생합니다.오류가 발생하면서 커널이 끊어집니다.here 눌렀을 때jupyter log 눌렀을 때 입니다.다음 부분에서 오류가 나는 것 같습니다.from langchain_community.vectorstores import Chroma db = Chroma.from_documents(splits, embeddings_model)
-
미해결프로젝트로 배우는 Python 챗봇 & RAG - LangChain, Gradio 활용
RAG에서의 chain 코드
chain 연결하는 | 문법을 사용하지 않는 이유가 있을까요?