mcpField
A
assistant-presets

assistant-presets

github.com/itallstartedwithaideaエージェントワークフロー4475 回インストール28 週間前に更新
リポジトリ

assistant-presets について

Assistant Presets は、分野別 AI アシスタントの設定を作成、評価、導入するためのスキルです。プロンプト、例、モデルパラメーター、ツール、出力制約、ベンチマークをまとめ、バージョン管理と A/B テストで改善できます。

主な機能

  1. 01再利用可能なアシスタント設定
  2. 02システムプロンプトと少数例
  3. 03モデル設定とツール設定
  4. 04出力制約とベンチマーク
  5. 05バージョン管理と A/B テスト

活用シーン

  1. 01分野別 AI アシスタントの設定
  2. 02チーム内の動作の標準化
  3. 03再利用可能なプリセット集の作成
  4. 04異なるアシスタント設定のテスト

インストール

コマンドをコピーしてターミナルで実行します。

$npx skills add https://github.com/itallstartedwithaidea/agent-skills --skill assistant-presets

インストール後、Claude Code で/assistant-presetsを入力して読み込まれたか確認します。

詳細

アシスタントプリセット

googleadsagent.ai™によるAgent Skills™の一部です

説明

アシスタントプリセットは、ドメイン固有のタスクに特化した AI アシスタントの設定を作成、テスト、デプロイするためのフレームワークを提供します。各プリセットには、システムプロンプト、モデルパラメーター、ツールへのアクセス権限、出力形式の制約、品質ベンチマークが、再利用やバージョン管理が可能なアーティファクトとしてまとめられており、汎用 LLM をドメインの専門家へと変えます。

そのままの LLM はジェネラリストです。よく練られたプリセットを使えば、責任条項を指摘する法務契約レビュアー、診断プロトコルに従う医療トリアージアシスタント、チームの規約を徹底するコードレビュアー、会社のトーンガイドに従うカスタマーサポートエージェントなど、スペシャリストに変えられます。役に立つ AI アシスタントと、期待外れの AI アシスタントの違いは、ほぼすべてプリセットの設定にあります。

このスキルでは、高品質なプリセットを構築するプロセスを体系化します。ペルソナと制約の定義、フューショット例の作成、出力形式の指定、適切なモデルパラメーター(温度、top-p、最大トークン数)の選択、想定される入力と出力のベンチマークによる検証を行います。プリセットはバージョン管理され、デプロイ前に A/B テストが実施されます。

使用する場面

  • ドメイン固有の AI アシスタント(法務、医療、金融、コードレビュー)を作成する場合
  • チームや組織全体で AI の動作を標準化する場合
  • 再利用可能なアシスタント設定のライブラリを構築する場合
  • 特定のユースケースに合わせてシステムプロンプトを最適化する場合
  • さまざまなアシスタント設定を A/B テストする場合
  • ユーザーが「カスタムアシスタント」、「ペルソナ」、「システムプロンプト」を求めている場合

仕組み

graph TD
    A[Define Domain + Task] --> B[Write System Prompt]
    B --> C[Add Few-Shot Examples]
    C --> D[Configure Parameters]
    D --> E[Define Output Format]
    E --> F[Create Benchmark Dataset]
    F --> G[Evaluate Against Benchmark]
    G --> H{Quality Threshold Met?}
    H -->|No| I[Iterate on Prompt]
    I --> B
    H -->|Yes| J[Version + Deploy]
    J --> K[A/B Test in Production]
    K --> L[Monitor + Maintain]

プリセットの開発サイクルは、作成、ベンチマーク、改良を繰り返す反復的なものです。リグレッションを検出して元に戻せるよう、各反復はバージョン管理されます。本番環境のプリセットは、改善を確認するため、以前のバージョンと比較して A/B テストされます。

実装

interface AssistantPreset {
  id: string;
  version: string;
  name: string;
  description: string;
  domain: string;
  systemPrompt: string;
  fewShotExamples: Array<{ input: string; output: string }>;
  parameters: {
    model: string;
    temperature: number;
    topP: number;
    maxTokens: number;
    stopSequences?: string[];
  };
  outputFormat: {
    type: "text" | "json" | "markdown" | "structured";
    schema?: Record<string, unknown>;
  };
  tools: string[];
  guardrails: {
    maxResponseLength: number;
    blockedTopics: string[];
    requiredDisclaimer?: string;
  };
}

const codeReviewPreset: AssistantPreset = {
  id: "code-review-v3",
  version: "3.1.0",
  name: "Code Reviewer",
  description: "Reviews code for correctness, security, and maintainability",
  domain: "software-engineering",
  systemPrompt: `You are a senior code reviewer. Review the provided code diff with these priorities:
1. Correctness: Does it do what it claims?
2. Security: Are inputs validated? Secrets protected?
3. Performance: Any obvious bottlenecks?
4. Maintainability: Clear naming? Reasonable complexity?

Format findings as:
- [SEVERITY] file:line - Description
- Suggested fix: ...

Severities: CRITICAL, HIGH, MEDIUM, LOW`,
  fewShotExamples: [
    {
      input: "```diff\n+const data = JSON.parse(userInput)\n```",
      output: "[CRITICAL] app.ts:12 - Parsing untrusted user input without try-catch\n- Suggested fix: Wrap in try-catch with input validation",
    },
  ],
  parameters: { model: "claude-sonnet-4-20250514", temperature: 0.2, topP: 0.9, maxTokens: 4096 },
  outputFormat: { type: "markdown" },
  tools: ["read_file", "grep", "git_diff"],
  guardrails: {
    maxResponseLength: 5000,
    blockedTopics: [],
    requiredDisclaimer: undefined,
  },
};

class PresetBenchmark {
  constructor(
    private preset: AssistantPreset,
    private testCases: Array<{ input: string; expectedPatterns: string[] }>
  ) {}

  async evaluate(llm: LLMClient): Promise<{ score: number; failures: string[] }> {
    const failures: string[] = [];
    let passed = 0;

    for (const tc of this.testCases) {
      const response = await llm.generate(this.preset.systemPrompt, tc.input, this.preset.parameters);
      const allPresent = tc.expectedPatterns.every(p => response.includes(p));
      if (allPresent) passed++;
      else failures.push(`Input "${tc.input.slice(0, 50)}..." missing expected patterns`);
    }

    return { score: passed / this.testCases.length, failures };
  }
}

ベストプラクティス

  • システムプロンプトは説明ではなく指示として書きます。「あなたはコードをレビューします」とし、「これはコードレビュアーです」とは書きません
  • 期待する出力形式を正確に示すフューショット例を2~5個含めます
  • 事実確認や分析のタスクでは温度を0.1~0.3に、創造的なタスクでは0.7~0.9に設定します
  • ユーザー向けアシスタントには、ガードレール(禁止トピック、最大文字数、必須の免責事項)を定義します
  • プリセットを変更するたびにバージョンを更新し、変更履歴を維持します
  • 新しいバージョンをデプロイする前に、少なくとも20件のテストケースでベンチマークを実施します

プラットフォームの互換性

プラットフォームサポート備考
Cursor完全Rules + プリセットシステム
VS Code完全カスタムアシスタント設定
Windsurf完全Cascade プリセットのサポート
Claude Code完全AGENTS.md のペルソナ設定
Cline完全カスタム指示セット
aider一部規約ファイルのサポート

関連スキル

キーワード

assistant-presets system-prompt persona domain-specific few-shot prompt-engineering a-b-testing guardrails


© 2026 googleadsagent.ai™ | Agent Skills™ | MIT License

コメント