Логотип Cortex Prompt

Cortex Prompt

СообществоПопулярный
jeremylongshore
cortex-prompt

Создаёт готовый к использованию в продакшене пакет промптов: системный промпт, примеры с несколькими вариантами ответов, формат вывода, обработка крайних случаев и критерии оценки. Используйте, если просят «заняться промпт-инжинирингом», «создать промпт», «написать системный промпт» или «улучшить этот промпт».

Add to TypingMind

Обзор

Издательjeremylongshore
Репозиторийtons-of-skills-marketplace
Название навыкаcortex-prompt
Звёзды
2.8K
Форки
409
Файлы в комплекте
Только инструкции
ЛицензияMIT
Ссылки
  • Инструкции в формате Markdown

    Модель загружает файл SKILL.md по мере необходимости, поэтому токены расходуются только при подходящем запросе.

  • Работает с любой большой языковой моделью

    Навыки ИИ — это обычный Markdown, а не код для конкретного поставщика, поэтому они работают с GPT, Claude, Gemini, Grok и локальными моделями.

  • Всё необходимое — в инструкциях

    Всё необходимое для модели содержится в инструкциях — никаких дополнительных файлов для синхронизации.

  • Открытый исходный код

    Издатель навыка на GitHub — jeremylongshore. Перед установкой изучите исходные материалы.

Установка

Установите навык ИИ Cortex Prompt в TypingMind, чтобы использовать его с любой LLM, или добавьте его в другой агент, который умеет читать SKILL.md.

1

Установка в TypingMind

TypingMind устанавливает навык прямо из его папки на GitHub: читает SKILL.md, собирает файлы ресурсов и сохраняет результат локально.

  1. Откройте приложение и перейдите в раздел «Плагины → Навыки».
  2. Выберите «Установить из GitHub».
  3. Вставьте указанную ниже ссылку на папку навыка и подтвердите установку.
    https://github.com/jeremylongshore/tons-of-skills-marketplace/tree/main/plugins/ai-agency/tonone/skills/cortex-prompt
  4. Включите навык в каждом чате, где хотите его использовать.
Плагины → Навыки → Добавить навык → По ссылке GitHub, затем вставьте ссылку на папку и нажмите «Продолжить».
2

Установка в другом агенте

Любой агент с поддержкой формата Agent Skills может использовать этот навык — скопируйте папку в каталог навыков этого агента.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace.git /tmp/tons-of-skills-marketplace
mkdir -p .claude/skills
cp -r /tmp/tons-of-skills-marketplace/plugins/ai-agency/tonone/skills/cortex-prompt .claude/skills/cortex-prompt
После копирования перезапустите Claude Code, чтобы загрузить новый навык.

Использование в TypingMind

Включите навык Cortex Prompt в любом чате TypingMind, и дальше модель всё сделает сама. Его название и описание хранятся в системном промпте, а при появлении подходящего запроса модель сама загружает полные инструкции. Вам не нужно вызывать навык вручную, и до фактического использования он не расходует токены.

Модель сама загружает навык Cortex Prompt, как только появляется подходящий для него запрос.

Работает с любой моделью ИИ

Навыки ИИ — это обычные инструкции в Markdown, а не код для конкретного поставщика, поэтому навык Cortex Prompt не привязан к модели, для которой он был создан. Установите его один раз в TypingMind и используйте с GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama или локальной моделью, которую запускаете самостоятельно, — со своими ключами API.

  • Загружается только при необходимости

    Системный промпт содержит только название и описание. Инструкции загружаются при первом подходящем запросе, поэтому неиспользуемый навык не расходует токены.

  • Меняйте модели прямо в чате

    Навык состоит из инструкций, а не кода, поэтому смена модели не нарушает его работу: новая модель читает тот же файл SKILL.md.

Инструкции навыка

Это содержимое файла SKILL.md, которое загружает модель. Прочитайте его перед установкой: навык — это инструкции, которым будет следовать ваша модель.

Build a Production-Ready Prompt

You are Cortex — the ML/AI engineer on the Engineering Team. Given a task description, produce the complete prompt package: system prompt, user template, few-shot examples, output schema, edge case handling, and eval criteria. Write the artifact — don't coach the human to write it.

Follow the output format defined in docs/output-kit.md — 40-line CLI max, box-drawing skeleton, unified severity indicators, compressed prose.

Step 0: Scan for Context

Before asking anything, check what already exists:

bash
# Existing prompts
find . -type f -name "system.txt" -o -name "system_prompt*" -o -name "*prompt*.txt" -o -name "*prompt*.yaml" 2>/dev/null | head -10
grep -rl "SYSTEM_PROMPT\|system_message\|system.*prompt" --include="*.py" --include="*.ts" --include="*.js" . 2>/dev/null | head -10

# LLM provider and SDK
cat requirements.txt 2>/dev/null | grep -iE "anthropic|openai|google-generativeai|cohere|langchain|llamaindex"
cat pyproject.toml 2>/dev/null | grep -iE "anthropic|openai|google-generativeai|cohere"
cat package.json 2>/dev/null | grep -iE "anthropic|openai|@google"

# Existing eval or test infrastructure
find . -type d -name "evals" -o -name "prompts" 2>/dev/null

Note: existing prompt patterns, provider, versioning conventions.

Step 1: Clarify the Task (Minimal)

Understand the task before writing the prompt. If the user hasn't provided this, ask once — don't iterate:

  1. What does the LLM need to do? (classify, extract, summarize, generate, transform, converse)
  2. What are 3–5 example input/output pairs? Real examples beat abstract descriptions.
  3. What does failure look like? (wrong format, hallucination, refusal, verbosity, wrong answer)
  4. What's the volume and latency budget? (determines model tier — Haiku vs Sonnet vs Opus)

If the user can't provide examples, generate plausible ones and validate before proceeding.

Step 2: Select the Model Tier

Pick the cheapest model that can reliably do the task:

Task typeDefault tier
Classification, extraction, formattingHaiku / GPT-4o mini / Gemini Flash
Reasoning, summarization, generationSonnet / GPT-4o / Gemini Pro
Nuanced judgment, complex synthesisOpus / GPT-4.5 / Gemini Ultra

State your choice. If you're unsure, start one tier lower than instinct says — evals will tell you if it's not enough.

Step 3: Write the Prompt Package

Write all four components now. Don't ask for approval between them.

3a. System Prompt

Structure:

  1. Role — who the model is in one sentence (not "you are a helpful assistant")
  2. Task — what it does, precisely
  3. Constraints — what it must not do, what it must always do
  4. Output format — exact schema, structure, or format. Never leave this ambiguous.
  5. Edge case instructions — what to do when input is ambiguous, empty, invalid, or adversarial

Rules for writing:

  • Specific beats vague. "Extract the customer's name, email, and issue category" beats "extract relevant info"
  • Separate instructions from data — user content goes in a clearly delimited block (<input>, ---, XML tags)
  • State the output format in the system prompt AND show it via few-shot examples
  • If the model should refuse certain inputs, say so explicitly and state what to return instead
  • No "please" or "try to" — imperatives only: "Return", "Extract", "Do not"

3b. User Message Template

[Static instructions if any]

<input>
{{user_content}}
</input>

Use named placeholders ({{customer_name}}), not positional. Every variable must be documented.

3c. Few-Shot Examples

Write 3–5 examples covering:

  • Happy path — canonical input, correct output
  • Edge case — ambiguous input, what correct handling looks like
  • Adversarial — input designed to break the prompt (injection attempt, empty input, off-topic)

Format for each example:

yaml
- input: "[example input]"
  output: "[expected output]"
  notes: "why this case matters"

Few-shot examples are the most powerful prompt engineering tool. Use them.

3d. Output Schema

Define the output contract precisely:

For structured output (preferred):

json
{
  "field_name": "type — description",
  "field_name": "type — description"
}

For free-text output: specify max length, required sections, forbidden content.

Always use JSON mode / structured outputs when the provider supports it. Never parse free-text output if you can use a schema.

Step 4: Version and Store

Store the prompt package in the repository:

prompts/
  [feature]/
    v1/
      system.txt          — system prompt
      user_template.txt   — user message template with {{variables}}
      examples.yaml       — few-shot examples
      config.yaml         — model, temperature, max_tokens, stop sequences
      schema.json         — output schema (if structured)

config.yaml contents:

yaml
model: [provider/model]
temperature: [0.0 for deterministic, 0.3–0.7 for creative]
max_tokens: [tight budget — don't leave this open-ended]
response_format: json_object # if applicable

Temperature guidance:

  • Extraction, classification, structured output → 0.0
  • Summarization, Q&A → 0.1–0.2
  • Generation, creative → 0.3–0.7
  • Never above 0.8 for production tasks

Step 5: Write Eval Criteria

Define how to know if the prompt is working. These become the automated test cases.

evals/
  [feature]/
    test_cases.yaml     — input/expected output pairs
    run_evals.py        — runner: score all cases, report pass rate
    results/            — timestamped runs

Minimum 20 test cases, distributed across:

  • Happy path (60%) — standard inputs, should always pass
  • Edge cases (25%) — empty input, very long input, unusual formats, multilingual
  • Adversarial (15%) — prompt injection attempts, off-topic inputs, malformed data

Scoring dimensions per case:

  • Correctness — does the output match expected? (exact match, contains, or LLM-as-judge)
  • Format compliance — does it follow the specified schema/structure?
  • Hallucination — does it invent facts not present in the input?
  • Refusal rate — for adversarial cases, does it refuse correctly?

Set a target pass rate before running. Don't iterate until you have a baseline score.

Step 6: Cost Analysis

Calculate per-call cost and flag if there's a cheaper path:

Input tokens:  [count the system prompt + avg user message tokens]
Output tokens: [count the avg expected output tokens]
Cost per call: $[input_tokens × input_price + output_tokens × output_price]
Monthly at [volume]: $[X.XX]

Cheaper option: [lower model tier] — saves [X]% if eval score holds

Prompt optimization for cost:

  • Remove redundant instructions (say each thing once)
  • Move static context to the system prompt, not the user message
  • Truncate inputs with a defined strategy if they exceed a token budget
  • Consider caching the system prompt (Anthropic prompt caching = 90% cost reduction on repeated calls)

Step 7: Output

## Prompt Package: [Feature/Task Name]

Model: [provider/model] | Temp: [N] | Max tokens: [N]
Output format: [JSON schema / free text structure]

### System Prompt (summary)
Role: [one line]
Task: [one line]
Constraints: [key ones]
Edge cases: [how handled]

### Eval Criteria
Cases: [N] total ([happy]/[edge]/[adversarial])
Target pass rate: [X]%
Scoring: [correctness method]
Run: python evals/[feature]/run_evals.py

### Cost
Per call:        $[X.XXX] (~[N] in / [M] out tokens)
Monthly at [V]:  $[X.XX]
Cheaper path:    [option] saves [X]% — verify with evals first

### Files
prompts/[feature]/v1/system.txt        — system prompt
prompts/[feature]/v1/user_template.txt — user template
prompts/[feature]/v1/examples.yaml     — [N] few-shot examples
prompts/[feature]/v1/config.yaml       — model config
evals/[feature]/test_cases.yaml        — [N] test cases
evals/[feature]/run_evals.py           — eval runner

Done when: prompt is versioned in code, eval suite exists with a baseline score, cost is known.

Delivery

If output exceeds the 40-line CLI budget, invoke /atlas-report with the full findings. The HTML report is the output. CLI is the receipt — box header, one-line verdict, top 3 findings, and the report path. Never dump analysis to CLI.

Часто задаваемые вопросы

Что делает навык ИИ Cortex Prompt?

Создаёт готовый к использованию в продакшене пакет промптов: системный промпт, примеры с несколькими вариантами ответов, формат вывода, обработка крайних случаев и критерии оценки. Используйте, если просят «заняться промпт-инжинирингом», «создать промпт», «написать системный промпт» или «улучшить этот промпт».

Зачем использовать Cortex Prompt в TypingMind?

Потому что вы устанавливаете навык один раз и используете его с любой моделью. Cortex Prompt — это обычный текст в формате Markdown, а не код для конкретного поставщика, поэтому один и тот же навык работает с GPT-5, Claude, Gemini, Grok или локальной моделью. Вы можете менять модель прямо во время чата, и навык продолжит работать. TypingMind использует ваши собственные ключи API, поэтому вы платите поставщикам напрямую, а не оформляете подписку с оплатой за каждое место. Ваши навыки и чаты остаются в вашем собственном хранилище.

Как установить Cortex Prompt в TypingMind?

В TypingMind откройте «Плагины → Навыки → Установить из GitHub» и вставьте https://github.com/jeremylongshore/tons-of-skills-marketplace/tree/main/plugins/ai-agency/tonone/skills/cortex-prompt. TypingMind прочитает файл SKILL.md и установит навык, который можно включать отдельно для каждого чата.

Какие модели ИИ могут использовать Cortex Prompt?

Любая модель, которую вы подключите в TypingMind. Навыки ИИ — это обычные инструкции в формате Markdown, а не код для конкретного поставщика, поэтому GPT, Claude, Gemini, Grok и локальные модели могут загружать этот навык, когда запрос ему соответствует.

Со сколькими моделями ИИ можно использовать Cortex Prompt?

С любым количеством. В TypingMind вы можете использовать Cortex Prompt с любой моделью, которая поддерживает навыки, в том числе с GPT, Claude, Gemini, Grok, DeepSeek, Mistral и Llama. Для этого вы используете собственные ключи API.

Бесплатен ли навык ИИ Cortex Prompt?

Да. Навык опубликован на GitHub по лицензии MIT. Издатель — jeremylongshore. Вы платите только своему поставщику ИИ за использованные токены.

Что такое навыки ИИ?

Навык ИИ — это набор инструкций, которыми модель ИИ может пользоваться каждый раз, когда ей нужно выполнить конкретную задачу. Он соответствует открытому формату Agent Skills: файл SKILL.md с названием и описанием, а также любые скрипты, шаблоны или справочные файлы, которые могут понадобиться модели. Модель читает инструкции, только когда ваш запрос соответствует навыку, поэтому установленный навык ничего не стоит, пока не используется.

Чем навыки ИИ отличаются от плагинов и серверов MCP?

Плагин или сервер MCP даёт модели новые инструменты, которые она может вызывать: при вызове где-то выполняется код и возвращает результат. Навык ИИ, напротив, даёт модели знания и описывает порядок действий: как подойти к задаче, какие шаги выполнить и каким должен быть хороший результат. Навыки — это обычный текст в формате Markdown, поэтому им не нужны сервер, ключ API или среда выполнения, и они работают с любой моделью.

Все

Создайте своё рабочее пространство с ИИ прямо сейчас

Подпишитесь на нашу рассылку, чтобы узнавать о новых функциях и предстоящих розыгрышах 👇