$ show openclaw/docs
This repository serves as the internationalized documentation site for the OpenClaw AI agent platform, including a sophisticated automated translation pipeline, Cloudflare Worker serving infrastructure, and CI/CD workflows. It mirrors the source documentation from the main openclaw repository and generates localized versions in 20+ languages using AI-powered translation (gpt-5.6). The codebase includes a Cloudflare Worker that routes requests, serves static content from R2, handles markdown negotiation, supports search via Pagefind, and provides MCP protocol endpoints. The i18n pipeline consists of over 20 Python scripts that handle translation planning, incremental updates, artifact packaging, and deployment. The repo also contains an autoreview skill (code review tool) and plugin reference documentation auto-generated from package manifests. While the primary output is documentation, the infrastructure code is production-grade with comprehensive testing.
The LLM identified 3 files worth highlighting for reuse:
A Cloudflare Worker that serves the documentation site from R2 storage. Implements clean URL routing, markdown content negotiation via Accept header, in-memory caching with caches.default, search API integration with Pagefind, MCP protocol endpoints, and custom 404 handling. The caching logic is robust, using cache keys based on the full URL including query strings, and respects cache-control headers. This is a self-contained, reusable pattern for serving statically generated sites with advanced features.
A shared Python module used by full and incremental translation workflows. It handles locale selection, source document counting, shard expansion, and output generation for translation manifests. The module uses dataclasses for typed configuration, environment variable fallbacks, and writes structured outputs to GITHUB_OUTPUT and GITHUB_STEP_SUMMARY. It is well-documented with docstrings and examples, and is designed to be reusable across different workflow entry points.
A security-hardened code review tool that bundles repository changes and submits them to AI engines (codex, claude, pi) for review. It supports local, commit, and branch modes, with parallel test execution, secret detection, and safe environment isolation. The script includes a complex secret_text_risk function that patterns credentials across many languages and contexts. The output is structured JSON with validated review patches. This is a standalone, reusable tool that could be adapted for any repository requiring AI-assisted code review.