Chuyển đến nội dung
Skillpedia
Lập trình chung394k · #17

diffs

Skill này làm gì

Skill cung cấp cho agent AI một công cụ biến văn bản trước và sau khi sửa, hoặc một patch, thành diff trực quan. Nó dành cho những ai muốn xem lại hoặc chia sẻ chính xác các thay đổi.

Khi nào nên dùng

  • ✓Khi bạn muốn cho thấy chính xác những gì đã thay đổi trong một chỉnh sửa văn bản hoặc mã nguồn.
  • ✓Khi bạn cần một diff có thể chia sẻ dưới dạng liên kết, hoặc file PDF hay PNG.
  • ✓Khi một bản tóm tắt viết tay về các thay đổi sẽ không rõ ràng hoặc dễ sai.

Liên kết skill

https://github.com/openclaw/openclaw/blob/main/extensions/diffs/skills/diffs/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/openclaw/openclaw/blob/main/extensions/diffs/skills/diffs/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Cho tôi thấy chính xác điều gì đã thay đổi giữa hai phiên bản ghi chú này, và đưa tôi một file PDF để gửi đi.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Công cụ so sánh văn bản cũ và mới, hoặc đọc một patch, rồi tạo một trang xem, một file, hoặc cả hai. Công cụ báo cho biết có thay đổi gì không và trả về liên kết xem hoặc đường dẫn file.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

When you need to show edits as a real diff, prefer the diffs tool instead of writing a manual summary.

The diffs tool accepts either before + after text, or a unified patch string.

Check details.changed: identical before/after input returns false without creating an artifact; rendered results return true.

Use mode=view when you want an interactive gateway-hosted viewer. After the tool returns, present details.viewerUrl with an available surface-presentation tool. If the deployment uses a loopback trusted proxy (for example Tailscale Serve with gateway.trustedProxies including 127.0.0.1), raw loopback viewer requests can be rejected without forwarded client-IP headers. In that topology, prefer mode=file / mode=both, or use a configured viewerBaseUrl / explicit proxy/public baseUrl when you need a shareable viewer URL.

Use mode=file when you need a rendered file artifact. Set fileFormat=png (default) or fileFormat=pdf. The tool result includes details.filePath.

For large or high-fidelity files, use fileQuality (standard|hq|print) and optionally override fileScale/fileMaxWidth.

When you need to deliver the rendered file to a user or channel, do not rely on the raw tool-result renderer. Instead, use an available file-sending tool to send details.filePath as an attachment.

Use mode=both when you want both the gateway viewer URL and the rendered artifact.

If the user has configured diffs plugin defaults, prefer omitting mode, theme, layout, and related presentation options unless you need to override them for this specific diff.

Include path for before/after text when you know the file name.

Câu hỏi thường gặp

Có tạo file nếu không có gì thay đổi không?

Không. Nếu văn bản trước và sau giống hệt nhau, công cụ báo không có thay đổi và không tạo tài liệu nào.

Tôi có thể gửi file đã render cho người khác không?

Có. Skill có thể gửi file dưới dạng tệp đính kèm qua một công cụ gửi file có sẵn.

Công cụ có thể tạo những định dạng file nào?

Mặc định công cụ tạo ảnh PNG, và tạo file PDF khi bạn yêu cầu.

Chi tiết

Mô tả gốc của tác giả

Use the diffs tool to produce real, shareable diffs (viewer URL, file artifact, or both) instead of manual edit summaries.

repo: openclaw/openclaw

Độ phổ biến

Sao GitHub
394k
Vị trí xếp hạng
#17
Giấy phép
MIT
Cập nhật
2/11/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự