Community코딩 & 개발github.com

grahama1970/assistant

공유 GPT + 분류기 추론 게이트웨이로, 휴리스틱 → 분류기 → 로컬 GPT → scillm의 4단계 캐스케이드를 통해 유효성 검사와 분류를 라우팅합니다.

assistant란 무엇인가요?

이 스킬은 사용자 정의 태스크(예: QRA 평가자, 브리지 태거)에 대해 효율적이고 비용 최적화된 추론을 제공하는 공유 게이트웨이 역할을 합니다. '워트 연못'(warm pond) 아키텍처를 통해 /assistant가 자율적으로 진화할 수 있도록 설계되었습니다. 즉, /assistant-lab(자기 개선 작업대: create-*, *-lab, 모델 팩토리)에서 추론 스택을 자율적으로 발전시키고, /monitor-skills는 전체 스킬 생태계에 대한 관찰 가능성을 제공합니다. 핵심은 4계층 캐스케이드입니다. Tier 0(휴리스틱, 무료, 마이크로초), Tier 0.5(분류기, 무료, 5-25ms), Tier 0.75(회귀자, 무료, 5-10ms), Tier 1.5(공유 Qwen3-0.6B GGUF, 무료, ~200ms), Tier 2(scillm/DeepSeek V3.2, $0.12/1K 토큰, 2-5초)입니다. 이 스킬은 검증 및 분류를 위해 run.sh CLI와 Python API(assistant.validate, assistant.classify)를 제공합니다. 추가적으로, ModelFactory를 통한 그림자 모드(shadow mode) 및 자동 개선 루프(훈련→평가→승격), /prompt-lab을 통한 프롬프트 반복 규칙(Tier 2로 승격하기 전에 모든 시스템 프롬프트를 반드시 /prompt-lab에서 평가해야 함), /monitor-skills를 통한 관찰 가능성 등이 중요한 기능입니다. 이 스킬은 Cursor, Claude Code 등의 AI 에이전트 환경에서 개발자 워크플로우에 통합되어, 특정 도메인(예: 보안 평가, 브리지 태깅)에 대한 정확하고 비용 효율적인 분류 및 유효성 검사를 자동화하는 데 사용됩니다.

지원 대상✓Claude Code~Codex CLI~Cursor✓Antigravity
npx skills add https://github.com/grahama1970/agent-skills/tree/main/skills/assistant

Installed? Explore more 코딩 & 개발 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

중단. 어떤 엔드포인트도 호출하기 전에 이 SKILL.MD를 전체 읽으십시오.

assistant은(는) 무엇을 하나요?

공유 GPT + 분류기 + 회귀자 추론 게이트웨이 (페르소나 모니터 태스크용)

"워트 연못" — /assistant는 /assistant-lab (자기 개선 작업대: create-*, *-lab, 모델 팩토리)을 통해 추론 스택을 자율적으로 진화시킬 수 있으며 /monitor-skills는 스킬 생태계 전반에 걸친 관찰 가능성을 제공합니다.

프롬프트 반복 규칙 (변경 불가)

/assistant 모델의 모든 시스템 프롬프트는 /create-gpt를 통해 학습 데이터에 포함되기 전에 반드시 /prompt-lab을 통해 반복되어야 합니다. Python 문자열에서 시스템 프롬프트를 직접 작성하지 마십시오.

  • 새 모델 프롬프트 → 먼저 /prompt-lab eval로 기준 진리(Ground Truth) 대비 평가
  • 프롬프트 정체기(80-90% 그림자 일치율) → /prompt-lab compare로 변형 간 비교
  • 모델 재훈련 → /create-gpt 전에 /prompt-lab find-minimum으로 프롬프트 검증

계층 캐스케이드

계층방법비용지연 시간생성 위치
0휴리스틱 (정규식/키워드/스키마)무료마이크로초직접 코딩
0.5분류기 (DistilBERT/sklearn)무료5-25ms/create-classifier
0.75회귀자 (sklearn/XGB)무료5-10ms/create-regressor
1.5공유 GPT (Qwen3-0.6B GGUF)무료~200ms/create-gpt
2scillm (DeepSeek V3.2 via Chutes)$0.12/1K2-5초페르소나 교사

모델 생명 주기 (워트 연못)

Tier 2 페르소나 교사가 레이블 생성
    ↓ harvest.py가 shadow.jsonl 추출
    ↓
ModelFactory.auto_improve(task)
    ↓ 그림자 일치율 읽기
    ├─ >= 90%: 승격 (shadow_mode → false)
    ├─ 80-90%: 정체기 → /prompt-lab 재설계
    ├─ 70-80%: /create-gpt 또는 /create-classifier 재훈련
    └─ < 70%: 적극적 재훈련 + 아키텍처 변경
    ↓
/gpt-lab 벤치마크 또는 /classifier-lab 평가
    ↓ 통과? → 레지스트리로 승격
    ↓
/monitor-skills 드리프트 또는 건강 문제 감지
    ↓
/assistant-lab auto-improve (진단 → 훈련 → 평가 → 승격)

사용법

# 계층 캐스케이드를 통해 데이터 검증
./run.sh validate --task qra-assessor --scope brandon_bailey --input '{"question":"...", "answer":"..."}'

# 텍스트 분류
./run.sh classify --task bridge-tagger --text "satellite vulnerability assessment"

# 새 모델 등록
./run.sh register --task NAME --model-path PATH --type gpt|classifier --threshold 0.85

# 등록된 모델, 적중률, 계층 분포 확인
./run.sh status

# 모든 계층에 합성 입력 실행
./run.sh self-test

# Tier 2로 이스케이프된 데이터를 학습 데이터로 추출
./run.sh harvest --since 24h

Python API

from assistant import validate, classify

# 4계층 캐스케이드로 검증
result = validate(
    input_data={"question": "What is CWE-79?", "answer": "Cross-site scripting..."},
    task="qra-assessor",
    scope="brandon_bailey",
)
print(result.tier, result.confidence, result.result)

# 3계층 캐스케이드로 분류
result = classify(
    text="satellite vulnerability assessment",
    task="bridge-tagger",
)
print(result.prediction, result.confidence, result.source)

계약 조건

  • 입력: 태스크별 딕셔너리 (검증기) 또는 텍스트 문자열 (분류기)
  • 출력: GatewayResult 또는 ClassifyResult (계층, 신뢰도, 지연 시간 포함)
  • 의존성: loguru, typer; 선택 사항: llama-cpp-python, torch, joblib
  • 메트릭: ~/.pi/assistant/metrics.jsonl에 JSONL로 추가

모델 팩토리

# 태스크에 필요한 모델 확인
./run.sh factory needs --task stress-test-grader

# 수집된 교사 레이블에서 GPT 훈련
./run.sh factory train-gpt --task stress-test-grader

# /gpt-lab을 통해 평가
./run.sh factory evaluate --task stress-test-grader --type gpt

# 통과한 모델 승격 (그림자 모드 비활성화)
./run.sh factory promote --task stress-test-grader --type gpt

# 자율 개선 루프 (결정 + 훈련 + 평가 + 승격)
./run.sh factory auto-improve --task stress-test-grader
from model_factory import ModelFactory

factory = ModelFactory()
result = factory.auto_improve("stress-test-grader")
# → 그림자 일치율을 읽고 필요에 따라 훈련/평가/승격 수행

주요 동작

  1. 지연 모델 로딩: 첫 호출 시 가중치 로드, 프로세스 내 캐싱
  2. 메모리 주입: 페르소나 범위에서 회상, GPT 시스템 프롬프트 앞에 추가
  3. 통과 모드: 로컬 모델이 없으면 직접 scillm으로 전달
  4. 그림자 모드: "shadow_mode": true인 태스크는 로컬 모델과 scillm을 병렬로 실행하고, 불일치를 shadow.jsonl에 기록하며, 교사(scillm) 결과를 반환. 새로운 학생 모델의 안전한 도입을 가능하게 함.
  5. 수확: 밤마다 Tier 2로 이스케이프된 데이터를 교사 레이블로 추출
  6. 모델 팩토리: /assistant-lab을 통해, 그림자 모드가 태스크에 개선이 필요함을 보여줄 때 자율적으로 모델을 훈련, 평가, 승격
  7. 워트 연못: /monitor-skills가 생태계를 감시하고(관찰 가능성), /assistant-lab이 문제를 수정(자기 개선). 이 둘이 함께 /assistant가 진화하는 워트 연못을 형성합니다.

흔한 실수

잘못된 예: Python 문자열에서 시스템 프롬프트 직접 작성

SYSTEM_PROMPT = "당신은 QRA 검증기입니다. 답변이 올바른지 확인하세요..."

올바른 예: 학습 데이터에 포함시키기 전에 /prompt-lab을 통해 프롬프트 반복

.pi/skills/prompt-lab/run.sh eval --prompt qra_validator_v1 --model deepseek
# prompt-lab 검증 후에야 학습 데이터 생성

잘못된 예: 불충분한 데이터로 훈련 (클래스당 200개 미만 샘플)

./run.sh factory train-gpt --task sparta-intent  # 50개 샘플, 12개 클래스 = 클래스당 4개!

올바른 예: Tier 2에 머물며 먼저 더 많은 교사 레이블 수집

./run.sh harvest --since 7d  # 그림자 레이블 축적
./run.sh status              # 훈련 전 샘플 수 확인

잘못된 예: 그림자 모드를 건너뛰고 테스트되지 않은 모델 승격

./run.sh factory promote --task stress-test-grader  # 그림자 비교 없음!

올바른 예: 그림자 모드 실행, 일치율 확인 후 승격

./run.sh factory auto-improve --task stress-test-grader
# auto-improve가 그림자 일치율을 읽고 결정

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

grahama1970/acceptance-contract

Turn a client brief, zip bundle, directory, or single requirements file into a typed acceptance-contract bundle with extracted requirements, acceptance checks, open questions, an immutable-goal draft, and a create-report-backed decision report. Use when users say acceptance contract, brief to requirements, freeze the goal, create immutable goal, amend immutable goal, build a Battle requirements bundle, or extract requirements from this bundle.

grahama1970/agent-ecosystem

Canonical map and shared contracts for the agent-governance ecosystem: the pi.receipt_envelope.v1 boundary envelope, the component graph, and the rules for which component owns which schema. Use when wiring a skill or extension into the shared receipt world, when asking how shame, triage-error, tau, ask, project-watchdog, ops-herdr, ponytail, and Memory fit together, or when validating an envelope.

grahama1970/agentic-evals

Agentic evaluation of skills using multi-trial fixtures, deterministic command assertions, trajectory checks, safety constraints, and evidence-backed readiness scoring. Use when users ask for agentic evals, multi-trial skill evaluation, skill trajectory validation, or readiness scoring for a skill workflow.

grahama1970/agent-inbox

File-based inter-agent messaging with headless dispatch. Check inbox, send bugs/requests to other projects, automatically spawn headless agents to fix bugs, and track progress via task-monitor.

grahama1970/agents-registry

Generate and query the centralized agent identity registry. Scans .pi/agents/*/AGENTS.md, parses frontmatter, outputs agents-registry.json and optionally syncs to /memory for semantic search.

grahama1970/agent-status

Artifact-driven status surfaces for long-running project-agent work. Maintains status.json, events.jsonl, proof manifests, and a stale-aware STATUS.html so humans can tell where the agent is, what passed, what is still unproven, and what decision or action is next — without dashboard theater.

grahama1970/align

Round-based context alignment before execution. Use when the human, project agent, WebGPT, scillm, ask, dogpile, memory, or project-knowledge may each hold different facts about a task; especially before ambiguous design, infographic, product workflow, high-stakes implementation, plan-iterate, project-infographic, or multi-review work.

grahama1970/analytics

Flexible data science analytics for any dataset. Auto-discovers schema, recommends charts, exports to create-figure. Works with JSONL, JSON, CSV from any source.

grahama1970/analyze-chatterbox-emotions

Evaluate generated Chatterbox voice files as voice-quality artifacts: affect match, arousal/valence proxies, pause placement, intelligibility inputs, clipping, loudness, and discontinuity flags. Use when reviewing Chatterbox emotional tags, pauses, Turbo/base affect delivery, Persona Dream utterance renders, or whether generated speech matches an intended product-facing affect.

grahama1970/analyze-elf

Reverse-engineer features from ELF binaries. Extracts CLI commands, state machines, protocols, Zod schemas, and data models. Automatically generates a /create-walkthrough prosecution brief with Mermaid diagrams. Uses /treesitter for AST analysis of bundled JS/TS source.

grahama1970/animation-vocabulary

Reverse-lookup glossary that turns a vague description of a web animation or motion effect into its exact term ("the bouncy thing when a popover opens" → Pop in; "the iOS rubber-band scroll" → Rubber-banding). Use when the user asks "what's it called when…", or describes a motion effect without knowing its name and wants the right word to prompt an AI or designer with. For naming an effect, not designing or building one.

grahama1970/anonymize-data

Anonymize supported CSV, JSON, UTF-8 text, and SQLite files using an explicit policy through the oai-trial project. Use for anonymize data, pseudonymize exports, redact policy literals, or discover and explicitly approve fuzzy name aliases. The skill is a thin CLI/Docker interface, not another engine.

grahama1970/anvil

Heavy-duty "No-Vibes" debugging and hardening orchestrator. Use this for complex, stubborn bugs where `review-code` has failed, or for "Red Teaming" (hardening) a codebase. Runs multiple agents in parallel (Thunderdome) using git worktree isolation.

grahama1970/apple-design

Apple's approach to interface design and fluid, physical motion, translated for the web. Use when building or reviewing gesture-driven UI, spring animations, drag/swipe/sheet interactions, momentum and interruptible transitions, translucent materials and depth, typography (optical sizing, tracking, leading), reduced-motion, or the design foundations (feedback, spatial consistency, restraint) behind Apple-style interfaces.

grahama1970/argue

Multi-persona structured debate orchestrator. Personas research via /dogpile, consult colleagues via /ask, and argue toward nuanced synthesis on complex questions.

grahama1970/arxiv

Search arXiv for papers and extract knowledge into memory. Use `search` to find papers, `learn` to extract knowledge.

grahama1970/ask

Use when the user asks to query project memory, ask an oracle, use supported browser-backed reviewers, run Tau roundtable/single-handler workflows, ask Pi-native subagents from within Pi, run persona/deep-review workflows, generate image prompts, check OS/project health through composed skills, or run an ask DAG. This skill is the executable /ask runtime; do not replace it with an informal subagent, plain web search, or hand-written review; inside Pi, explicit Pi-native subagent targets are routed through the pi-subagents tool as an Ask target type.

grahama1970/assess

Step back and critically reassess project state. Use when asked to "assess", "step back", "fresh eyes", "check alignment", "sanity check", "health check", "prune documentation", or "evaluate what's working". Offers documentation pruning and doc-code alignment analysis. Offer to run after major changes (don't auto-run).

grahama1970/assistant-lab

Self-improvement workbench for /assistant. All the tools needed to diagnose, train, evaluate, and promote models in a continuous loop. The "warm pond" where /assistant evolves its own inference stack.

grahama1970/batch-quality

Pre-flight validation and quality gates for batch LLM operations. ACTUALLY tests samples through LLM before burning tokens. Uses SPARTA contracts for DuckDB validation queries. Integrates with task-monitor for enforced quality gates.

관련 스킬