Solitude Docs

Local Search

Generate a local XML index and enable the Solitude 4 search module.

Install an XML search-index generator in the Hexo blog:

npm install hexo-generator-search
pnpm add hexo-generator-search
yarn add hexo-generator-search

Configure Hexo _config.yml:

search:
  path: search.xml
  field: post
  content: true

Configure _config.solitude.yml:

search:
  enable: true
  type: local
  tags: [Solitude, Hexo]
  ai:
    enable: true
    url: https://example.com/ai-search
  local:
    preload: false
    CDN: /search.xml

search.ai.url is an external link displayed in local search, not an AI request endpoint. After generation, verify /search.xml and search by title, tag, and body text.