Lightpanda

Lightpanda는 기계 전용으로 처음부터 제작된 헤드리스 브라우저 엔진입니다. 즉시 시작되며, 크롬보다 메모리 사용량이 10배 적고 실행 속도가 10배 빠릅니다.

agent-browser는 크롬을 관리하는 방식과 동일하게 Lightpanda를 관리합니다 — 프로세스를 생성하고, CDP를 통해 연결한 후 종료합니다. 모든 하류 명령어(스냅샷, 클릭, 채우기, 스크린샷 등)는 동일한 CDP 프로토콜 경로를 통해 작동합니다.

설치

agent-browser와 함께 사용하기 전에 Lightpanda 바이너리를 설치하세요:

플랫폼명령어
macOS (Apple Silicon)curl -L -o lightpanda https://github.com/lightpanda-io/browser/releases/download/nightly/lightpanda-aarch64-macos && chmod a+x ./lightpanda
Linux (x86_64)curl -L -o lightpanda https://github.com/lightpanda-io/browser/releases/download/nightly/lightpanda-x86_64-linux && chmod a+x ./lightpanda

바이너리를 PATH에 있는 어디든지 이동하세요 (예: /usr/local/bin/lightpanda 또는 ~/.local/bin/lightpanda).

추가 옵션에 대해서는 Lightpanda 설치 문서를 참조하세요.

사용법

--engine 플래그를 사용하여 Lightpanda를 선택하세요:

agent-browser --engine lightpanda open example.com
agent-browser --engine lightpanda snapshot
agent-browser --engine lightpanda screenshot

또는 환경 변수를 통해 기본값으로 설정할 수 있습니다:

export AGENT_BROWSER_ENGINE=lightpanda
agent-browser open example.com

또는 agent-browser.json 구성 파일에서 설정할 수도 있습니다:

{
  "engine": "lightpanda"
}

사용자 지정 바이너리 경로

lightpanda 바이너리가 PATH에 없을 경우 --executable-path를 사용하세요:

agent-browser --engine lightpanda --executable-path /path/to/lightpanda open example.com

Chrome과의 차이점

Lightpanda는 목적에 맞게 설계된 헤드리스 엔진입니다. 일부 크롬 전용 기능은 사용할 수 없습니다:

기능상태
확장 프로그램 (--extension)지원되지 않음
지속적 프로파일 (--profile)지원되지 않음
저장 상태 (--state)지원되지 않음
파일 접근 (--allow-file-access)지원되지 않음
헤드드 모드 (--headed)해당 없음 (헤드리스 전용)
스크린샷Lightpanda의 CDP 지원 여부에 따라 다름

agent-browser는 --engine lightpanda와 지원되지 않는 플래그를 함께 사용하려 할 때 명확한 오류를 반환합니다.

언제 Lightpanda를 사용할까?

Lightpanda는 다음에 적합합니다:

  • 빠른 웹 스크래핑 및 데이터 추출
  • 속도와 낮은 메모리 사용이 중요한 인공지능 에이전트 워크플로우
  • 자원 제약이 있는 CI/CD 환경
  • 고성능 병렬 자동화

완전한 브라우저 충실도, 확장 프로그램 또는 지속적 프로파일이 필요한 경우 크롬을 사용하세요.