user-file-ops

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
Overview
Summarize text files that come from the user or from other skills. This skill can compute basic statistics (lines, words, bytes) and capture a short preview of the file.
User-provided files are typically exposed under
work/inputs/
(for example, when a host directory is mounted as inputs). Files produced by other skills are usually written under
out/
and can be summarized directly from there.
Examples
  1. Summarize a text file already present in the workspace
    Command:
    bash scripts/summarize_file.sh
    work/inputs/example.txt
    out/example_summary.txt
  2. Summarize a different file
    Command:
    bash scripts/summarize_file.sh
    work/inputs/notes.txt
    out/notes_summary.txt
  3. Summarize a file produced by another skill
    Command:
    bash scripts/summarize_file.sh
    out/sample_fib.txt
    out/sample_fib_summary.txt
Output Files
  • out/example_summary.txt
  • out/notes_summary.txt
  • out/sample_fib_summary.txt
概述
对来自用户或其他skill的文本文件生成摘要。 该skill可以计算基本统计信息(行数、单词数、字节数),并 捕获文件的简短预览。
用户提供的文件通常位于
work/inputs/
目录下(例如,当主机目录被挂载为输入目录时)。其他skill生成的文件通常会写入
out/
目录,可直接从该目录对其生成摘要。
示例
  1. 对工作区中已有的文本文件生成摘要
    命令:
    bash scripts/summarize_file.sh
    work/inputs/example.txt
    out/example_summary.txt
  2. 对另一个文件生成摘要
    命令:
    bash scripts/summarize_file.sh
    work/inputs/notes.txt
    out/notes_summary.txt
  3. 对其他skill生成的文件生成摘要
    命令:
    bash scripts/summarize_file.sh
    out/sample_fib.txt
    out/sample_fib_summary.txt
输出文件
  • out/example_summary.txt
  • out/notes_summary.txt
  • out/sample_fib_summary.txt