한국어
OCRTool은 비전 기능을 가진 LLM을 사용하여 로컬 이미지나 이미지 URL에서 텍스트를 추출합니다.
OCRTool
crewai-tools
image_path_url
from crewai_tools import OCRTool print(OCRTool().run(image_path_url="/tmp/receipt.png"))
from crewai import Agent, Task, Crew from crewai_tools import OCRTool ocr = OCRTool() agent = Agent( role="OCR", goal="Extract text", tools=[ocr], ) task = Task( description="Extract text from https://example.com/invoice.jpg", expected_output="All detected text in plain text", agent=agent, ) crew = Crew(agents=[agent], tasks=[task]) result = crew.kickoff()
LLM(model="gpt-4o")
from crewai import Agent, Task, Crew from crewai_tools import OCRTool tool = OCRTool() agent = Agent( role="OCR Specialist", goal="Extract text from images", backstory="Vision‑enabled analyst", tools=[tool], verbose=True, ) task = Task( description="Extract text from https://example.com/receipt.png", expected_output="All detected text in plain text", agent=agent, ) crew = Crew(agents=[agent], tasks=[task]) result = crew.kickoff()
이 페이지가 도움이 되었나요?