With Scriptsのロゴ

With Scripts

コミュニティ
nicolasmelo1
with-scripts

Bundled Gmail CLI example demonstrating the scripts/ entrypoint + src/ implementation split. Use as a template when your course ships real code that goes beyond a single shell script. Shows how to organize a course bundle that owns its codebase — no runtime package installation, all dependencies stdlib-only. Replaces the "tell the user to npm install my CLI" anti-pattern.

概要

公開者nicolasmelo1
リポジトリlogion
スキル名with-scripts
スター
38
フォーク
3
同梱ファイル
7
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 7個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    nicolasmelo1がGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルWith ScriptsをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/nicolasmelo1/logion/tree/main/examples/courses/with-scripts
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nicolasmelo1/logion.git /tmp/logion
mkdir -p .claude/skills
cp -r /tmp/logion/examples/courses/with-scripts .claude/skills/with-scripts
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでWith Scriptsを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にWith Scriptsを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、With Scriptsは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

With-Scripts: Bundled Gmail CLI Example

This example shows how to ship a real working tool inside a Logion course bundle. The course owns its codebase — there is no pip install, no npm install, no transitive dependency tree. Everything the agent needs to call the Gmail API lives in this bundle and was reviewed once when the course was published.

This is the canonical pattern for replacing "tell the user to install my CLI from npm" with "the course bundles the CLI."

Structure

with-scripts/
├── SKILL.md                  # this file
├── course/
│   └── capabilities.yaml     # file + terminal + web; gmail.googleapis.com; OAuth env
├── scripts/                  # thin entrypoints the agent invokes
│   ├── search.sh             # search messages
│   └── list-labels.sh        # list user labels
└── src/
    └── gmailcli/             # actual implementation
        ├── __init__.py
        ├── __main__.py       # python -m gmailcli {search,labels}
        ├── api.py            # Gmail REST client (stdlib urllib only)
        └── auth.py           # reads OAuth token from env

scripts/ holds short entrypoints — bash wrappers that set PYTHONPATH and invoke the Python module. src/ holds the real implementation. The separation is deliberate:

  • The agent only invokes scripts/search.sh "query". Simple, discoverable surface.
  • The bulk of the logic — API calls, error handling, JSON parsing — lives in src/gmailcli/. Reviewable, testable, organized.
  • The bundle stays self-contained: stdlib only (urllib.request, json), no pip install anywhere.

When to use this template

Copy this structure when your course:

  • Ships a non-trivial amount of code (more than one short script).
  • Wants scripts/ to remain a clean surface for the agent to discover commands.
  • Has real implementation worth organizing into modules.

If your course is a single 50-line script, the simpler with-references-and-scripts/ example is a better starting point.

How to use

1. Obtain a Gmail OAuth token

The course does not authenticate. The user obtains a token externally — via the Google OAuth playground, their own auth flow, or another tool — and exports it.

This is the trust-clean pattern: OAuth is the user's separate, informed consent decision, outside Logion's trust loop. The course only reads the token from GMAIL_OAUTH_TOKEN.

2. Export the token and invoke

export GMAIL_OAUTH_TOKEN="ya29...."
bash scripts/search.sh "from:alice subject:invoice"
bash scripts/list-labels.sh

Both print JSON to stdout. The agent should redirect output if persistence is needed.

Capability declarations

  • tools: [file, terminal, web] — reads its own bundle, runs Python, makes HTTPS calls.
  • network.allow_domains: [gmail.googleapis.com] — exactly the one host the bundled code contacts.
  • secrets.env: [GMAIL_OAUTH_TOKEN] — the only env var the bundle reads.
  • No filesystem.write — output goes to stdout.
  • No human_approval — the user already consented by exporting the token.

What an author should change when copying

  1. name: in frontmatter (must match the directory name).
  2. description: (specific about what, when, why).
  3. Replace src/gmailcli/ with your own package directory.
  4. Update scripts/*.sh entrypoints to dispatch to your package.
  5. Update course/capabilities.yaml to declare only what your code actually does — drop the network domain if you don't need it, etc.
  6. Keep the stdlib-only constraint. If you find yourself wanting pip install, see the "Self-contained bundle rule" in examples/courses/README.md.

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「With Scripts」では何ができますか?

Bundled Gmail CLI example demonstrating the scripts/ entrypoint + src/ implementation split. Use as a template when your course ships real code that goes beyond a single shell script. Shows how to organize a course bundle that owns its codebase — no runtime package installation, all dependencies stdlib-only. Replaces the "tell the user to npm install my CLI" anti-pattern.

TypingMindでWith Scriptsを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。With Scriptsはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにWith Scriptsをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/nicolasmelo1/logion/tree/main/examples/courses/with-scriptsを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

With Scriptsを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

With Scriptsは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもWith Scriptsを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「With Scripts」は無料ですか?

はい。nicolasmelo1がGitHubでMITライセンスの下で公開しています。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇