Bỏ qua tới nội dung
TakoAPI
Quay lại kỹ năng

code-cache

bởi ryx2

Search & Research
487Lượt tải do clawskills.sh công bố
0Lượt xem
0 lượt thíchĐăng nhập để thích kỹ năng này
—Chưa có đánh giá
Đánh giá của bạn

Tóm tắt

Semantic code caching for AI agents.

Mô tả

Kỹ năng này làm gì

Stores code generated during agent executions and retrieves semantically similar code for future tasks. Uses the Raysurfer API to search, upload, and vote on cached snippets. Cuts redundant generation by reusing validated solutions from prior runs.

Retrieving pre-validated cached code avoids the latency and token cost of having an LLM regenerate the same patterns on every run.

Khi nào nên dùng

  • Reusing a prior data pipeline script without regenerating it
  • Retrieving cached chart-building code for a recurring report
  • Searching past executions before writing new API fetch code
  • Uploading a successful script to the cache after an agent run
  • Downvoting a broken cached snippet to improve future retrieval quality

Quy trình ví dụ

ĐẦU VÀO

User asks: 'Fetch GitHub trending repos'

AGENT
  1. 1

    Search cache with /code-cache search "Fetch GitHub trending repos" --show-code

  2. 2

    Review the top match score and inspect the returned snippet

  3. 3

    Retrieve execution-ready files with /code-cache files "Fetch GitHub trending repos"

  4. 4

    Run the retrieved code in the agent sandbox

  5. 5

    Upload the result with /code-cache upload "Fetch GitHub trending repos" --files fetch.py

ĐẦU RA

GitHub trending repos fetched using cached code, with the execution stored and auto-voted for future reuse

Yêu cầu

  • RAYSURFER_API_KEY environment variable
  • Raysurfer account (sign up at raysurfer.com to access the API key dashboard)

Cài đặt

clawhub install ryx2/code-cache

Chạy lệnh CLI, hoặc dán prompt vào Claude Code, Cursor, Codex hay coding agent bạn đang dùng.

Liên kết