1. ollama在mac os下部署。使用沉浸式翻译插件配置翻译
在下列路径创建plist 文件 ~/Library/LaunchAgents/com.example.ollama.plist


<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Label</key>
  <string>com.example.ollama</string>
  <key>ProgramArguments</key>
  <array>
    <string>/usr/local/bin/ollama</string>
    <string>serve</string>
  </array>
  <key>EnvironmentVariables</key>
  <dict>
    <key>OLLAMA_ORIGINS</key>
    <string>*</string>
  </dict>
  <key>RunAtLoad</key>
  <true/>
  <key>StandardErrorPath</key>
  <string>/tmp/ollama.err</string>
  <key>StandardOutPath</key>
  <string>/tmp/ollama.out</string>
</dict>
</plist>
  1. launchctl load ~/Library/LaunchAgents/com.example.ollama.plist
  2. launchctl start com.example.ollama