基于大模型的 UI 自動化系統
下面是一個完整的 Python 系統,利用大模型實現智能 UI 自動化,結合計算機視覺和自然語言處理技術,實現"看屏操作"的能力。
系統架構設計
完整實現代碼
import os
import time
import json
import base64
import requests
from PIL import Image
from io import BytesIO
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.common.action_chains import ActionChains# 配置大模型 API (以 OpenAI 為例)
class LLMInterface