### Portless Quick Start Source: https://orchestkit.vercel.app/docs/reference/skills/portless A quick start guide for Portless, including global installation, starting the proxy, and running your application with Portless. ```bash # Install globally npm install -g portless # Start the proxy (once, no sudo needed) portless proxy start # Run your app (auto-starts the proxy if needed) portless run next dev # -> http://.localhost:1355 # Or with an explicit name portless myapp next dev # -> http://myapp.localhost:1355 ``` -------------------------------- ### Quick Start Commands Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Commands for installing the emulate package, starting services, and initializing configuration files. ```bash # Install (packages published under @emulators/* scope) npm install --save-dev emulate # Start all services npx emulate # Start specific services with seed data npx emulate --service github,stripe --seed ./emulate.config.yaml # Generate a starter config npx emulate init --service github ``` -------------------------------- ### Install and Start Ollama Source: https://orchestkit.vercel.app/docs/reference/skills/llm-integration Quick start commands for installing Ollama, pulling necessary models, and starting the server. ```bash # Install Ollama curl -fsSL https://ollama.ai/install.sh | sh # Pull models ollama pull deepseek-r1:70b # Reasoning (GPT-4 level) ollama pull qwen2.5-coder:32b # Coding ollama pull nomic-embed-text # Embeddings # Start server ollama serve ``` -------------------------------- ### Setup OrchestKit Backend Source: https://orchestkit.vercel.app/docs/reference/skills/golden-dataset Install backend dependencies using Poetry and start the PostgreSQL database using Docker Compose. ```bash # Step 2: Setup backend cd backend poetry install # Step 3: Start PostgreSQL cd .. docker compose up -d postgres # Wait for PostgreSQL to be ready sleep 5 ``` -------------------------------- ### OrchestKit Setup Quick Start Commands Source: https://orchestkit.vercel.app/docs/reference/skills/setup Various flags available for the setup command to control the wizard's behavior. ```bash /ork:setup # Full 8-phase wizard /ork:setup --rescan # Re-scan after changes (skip safety phase) /ork:setup --score-only # Just show readiness score /ork:setup --plan-only # Just show improvement plan /ork:setup --channel # Just show release channel /ork:setup --configure # Jump directly to Phase 3.5: project configuration wizard ``` -------------------------------- ### Setup OrchestKit Frontend Source: https://orchestkit.vercel.app/docs/reference/skills/golden-dataset Install frontend dependencies using npm and start the development server. Access the frontend at http://localhost:5173. ```bash # Step 9: Setup frontend cd frontend npm install npm run dev # Open http://localhost:5173 ``` -------------------------------- ### Quick Start Commit Source: https://orchestkit.vercel.app/docs/reference/skills/commit Basic usage examples for the commit command. ```bash /ork:commit /ork:commit fix typo in auth module ``` -------------------------------- ### Quick Start Implementations Source: https://orchestkit.vercel.app/docs/reference/skills/implement Examples of how to invoke the implement feature for different scenarios. You can specify the feature description and optionally override the default model. ```bash /ork:implement user authentication ``` ```bash /ork:implement --model=opus real-time notifications ``` ```bash /ork:implement dashboard analytics ``` -------------------------------- ### Generate Starter Emulate Configuration Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Creates a basic `emulate` configuration file in the current directory. Useful for starting custom setups. ```bash emulate init ``` -------------------------------- ### Install and Configure Storybook MCP Source: https://orchestkit.vercel.app/docs/foundations/mcp-servers Setup steps for component discovery and testing using Storybook MCP. ```bash # Install the addon npx storybook add @storybook/addon-mcp # Enable docs toolset in .storybook/main.ts # experimentalComponentsManifest: true # Register with Claude Code npx mcp-add --type http --url "http://localhost:6006/mcp" --scope project ``` -------------------------------- ### Assess Quick Start Examples Source: https://orchestkit.vercel.app/docs/reference/skills/assess Common usage patterns for assessing files, strategies, and schemas with optional model overrides. ```text /ork:assess backend/app/services/auth.py /ork:assess our caching strategy /ork:assess --model=opus the current database schema /ork:assess frontend/src/components/Dashboard ``` -------------------------------- ### LangGraph Quick Start Example Source: https://orchestkit.vercel.app/docs/reference/skills/langgraph Defines a simple stateful graph with a supervisor and a worker node. Use this as a starting point for building more complex workflows. ```python from langgraph.graph import StateGraph, START, END from langgraph.types import Command from typing import TypedDict, Annotated, Literal from operator import add class State(TypedDict): input: str results: Annotated[list[str], add] def supervisor(state) -> Command[Literal["worker", END]]: if not state.get("results"): return Command(update={"input": state["input"]}, goto="worker") return Command(goto=END) def worker(state) -> dict: return {"results": [f"Processed: {state['input']}"]} graph = StateGraph(State) graph.add_node("supervisor", supervisor) graph.add_node("worker", worker) graph.add_edge(START, "supervisor") graph.add_edge("worker", "supervisor") app = graph.compile() ``` -------------------------------- ### Verify Quick Start Examples Source: https://orchestkit.vercel.app/docs/reference/skills/verify Common usage patterns for the verify command with scope and model arguments. ```bash /ork:verify authentication flow /ork:verify --model=opus user profile feature /ork:verify --scope=backend database migrations ``` -------------------------------- ### Cover Quick Start Examples Source: https://orchestkit.vercel.app/docs/reference/skills/cover Common usage patterns for the cover command with various arguments and flags. ```bash /ork:cover authentication flow /ork:cover --model=opus payment processing /ork:cover --tier=unit,integration user service /ork:cover --real-services checkout pipeline ``` -------------------------------- ### New Environment Setup with Golden Dataset (Bash) Source: https://orchestkit.vercel.app/docs/reference/skills/golden-dataset This guide details setting up a new development environment, including cloning the repository, setting up the database with Alembic, restoring the golden dataset, and running verification tests. ```bash # Fresh dev environment, need golden dataset # 1. Clone repo (includes backup) git clone https://github.com/your-org/orchestkit cd orchestkit/backend # 2. Setup DB docker compose up -d postgres alembic upgrade head # 3. Restore golden dataset poetry run python scripts/backup_golden_dataset.py restore # 4. Verify poetry run pytest tests/integration/test_retrieval_quality.py ``` -------------------------------- ### LLM Test Environment Setup Source: https://orchestkit.vercel.app/docs/reference/skills/testing-llm Commands to install necessary dependencies for LLM testing. ```bash pip install deepeval ``` ```bash pip install ragas ``` -------------------------------- ### Running Celery Beat Source: https://orchestkit.vercel.app/docs/reference/skills/async-jobs Command-line examples for starting the Celery beat process in various configurations. ```bash # Standalone beat process (recommended for production) celery -A app beat --loglevel=INFO # With database scheduler celery -A app beat --scheduler django_celery_beat.schedulers:DatabaseScheduler # With PID file for process management celery -A app beat --pidfile=/var/run/celery/beat.pid # Embedded beat in worker (development only) celery -A app worker --beat --loglevel=INFO ``` -------------------------------- ### Python stdio Server Setup Source: https://orchestkit.vercel.app/docs/reference/skills/mcp-patterns Configure a Server instance and use the stdio transport for CLI or desktop applications. This example shows basic server initialization. ```python from mcp.server import Server from mcp.server.stdio import stdio_server server = Server("my-tools") ``` -------------------------------- ### Basic OpenTelemetry Node.js Setup Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability Initialize the OpenTelemetry Node.js SDK with a trace exporter and auto-instrumentations. Ensure the SDK is started to begin collecting traces. ```javascript import { NodeSDK } from '@opentelemetry/sdk-node'; import { getNodeAutoInstrumentations } from '@opentelemetry/auto-instrumentations-node'; const sdk = new NodeSDK({ traceExporter: new JaegerExporter(), instrumentations: [getNodeAutoInstrumentations()], }); sdk.start(); ``` -------------------------------- ### Start Emulated Services with Seed Configuration Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Initializes emulation using a provided YAML or JSON configuration file. This allows for custom service setups. ```bash emulate --seed config.yaml ``` -------------------------------- ### Core agent-browser Workflow Example Source: https://orchestkit.vercel.app/docs/reference/skills/browser-tools Demonstrates the fundamental workflow of browser automation: opening a URL, taking a snapshot to get element references, filling form fields, clicking a button, and re-snapshotting to verify the result. ```bash agent-browser open https://example.com/form agent-browser snapshot -i # Output: @e1 [input type="email"], @e2 [input type="password"], @e3 [button] "Submit" agent-browser fill @e1 "user@example.com" agent-browser fill @e2 "password123" agent-browser click @e3 agent-browser wait --load networkidle agent-browser snapshot -i # Check result ``` -------------------------------- ### Complete Production Zustand Store Setup Source: https://orchestkit.vercel.app/docs/reference/skills/zustand-patterns A comprehensive example demonstrating how to create a Zustand store with multiple middleware for production. It includes state definition, actions, persistence, developer tools, and migration logic. ```typescript import { create } from 'zustand'; import { devtools, persist, subscribeWithSelector, createJSONStorage } from 'zustand/middleware'; import { immer } from 'zustand/middleware/immer'; import type {} from '@redux-devtools/extension'; // Required for devtools typing interface AppState { // UI State sidebarOpen: boolean; theme: 'light' | 'dark' | 'system'; // User preferences notifications: { email: boolean; push: boolean; sms: boolean; }; // Actions toggleSidebar: () => void; setTheme: (theme: 'light' | 'dark' | 'system') => void; updateNotification: (key: keyof AppState['notifications'], value: boolean) => void; reset: () => void; } const initialState = { sidebarOpen: true, theme: 'system' as const, notifications: { email: true, push: true, sms: false, }, }; export const useAppStore = create()( persist( devtools( subscribeWithSelector( immer((set, get) => ({ ...initialState, toggleSidebar: () => set( (state) => { state.sidebarOpen = !state.sidebarOpen; }, undefined, 'ui/toggleSidebar' // Action name for devtools ), setTheme: (theme) => set( (state) => { state.theme = theme; }, undefined, 'ui/setTheme' ), updateNotification: (key, value) => set( (state) => { state.notifications[key] = value; }, undefined, `notifications/update/${key}` ), reset: () => set( () => initialState, true, // Replace entire state 'app/reset' ), })) ), { name: 'AppStore', enabled: process.env.NODE_ENV === 'development', // Sanitize sensitive data from devtools serialize: { replacer: (key, value) => { if (key === 'password' || key === 'token') return '[REDACTED]'; return value; }, }, } ), { name: 'app-storage', storage: createJSONStorage(() => localStorage), version: 2, // Only persist specific fields partialize: (state) => ({ theme: state.theme, notifications: state.notifications, // Don't persist: sidebarOpen (session-only UI state) }), // Handle migrations between versions migrate: (persistedState: unknown, version: number) => { const state = persistedState as Partial; if (version === 0) { // v0 → v1: Added notifications return { ...state, notifications: { email: true, push: true, sms: false }, }; } if (version === 1) { // v1 → v2: Changed theme from boolean to union return { ...state, theme: (state as any).darkMode ? 'dark' : 'light', }; } return state as AppState; }, // Called when hydration completes onRehydrateStorage: () => (state, error) => { if (error) { console.error('Failed to rehydrate store:', error); } else { console.log('Store rehydrated:', state?.theme); } }, } ) ); ``` -------------------------------- ### Codebase Reading Pattern Example Source: https://orchestkit.vercel.app/docs/reference/skills/audit-full Illustrates reading files in batches for efficiency, starting with entry points and configuration, followed by core modules. This approach helps manage token limits. ```javascript # Batch 1: Entry points and config Read("src/index.ts") Read("src/app.ts") Read("package.json") Read("tsconfig.json") # ... up to 15 files # Batch 2: Core modules Read("src/api/routes.ts") Read("src/db/connection.ts") # ... next batch ``` -------------------------------- ### Initialize Environment Source: https://orchestkit.vercel.app/docs/reference/skills/browser-tools Create necessary directories and prepare the report file for a new session. ```bash mkdir -p {OUTPUT_DIR}/screenshots {OUTPUT_DIR}/videos ``` ```bash cp {SKILL_DIR}/templates/dogfood-report-template.md {OUTPUT_DIR}/report.md ``` -------------------------------- ### Retrieve Resource via GET Source: https://orchestkit.vercel.app/docs/reference/skills/api-design Example of a standard GET endpoint returning a 200 OK status. ```python @router.get("/analyses/{analysis_id}") async def get_analysis(analysis_id: uuid.UUID) -> AnalysisResponse: return AnalysisResponse(...) # 200 OK ``` -------------------------------- ### Start Portless Proxy on Port 80 with Sudo Source: https://orchestkit.vercel.app/docs/reference/skills/portless Starts the Portless proxy on port 80, which requires administrator privileges (`sudo`). This is an example of starting the proxy on a privileged port. ```bash sudo portless proxy start -p 80 ``` -------------------------------- ### Install Project Dependencies Source: https://orchestkit.vercel.app/docs/reference/skills/ui-components Standard command set for initializing theme, styling, and form management libraries. ```bash npm install next-themes # Theme switching npm install class-variance-authority # CVA variants npm install clsx tailwind-merge # Class merging npm install react-hook-form # Form management npm install lucide-react # Icons ``` -------------------------------- ### Project Setup Commands Source: https://orchestkit.vercel.app/docs/reference/skills/agent-orchestration Commands to create the necessary directory structure and copy the orchestrator implementation. ```bash # At project root mkdir -p backend/app/workflows/multi_scenario cp src/skills/multi-scenario-orchestration/references/langgraph-implementation.py \ backend/app/workflows/multi_scenario/orchestrator.py ``` -------------------------------- ### Configure few-shot prompting Source: https://orchestkit.vercel.app/docs/reference/skills/llm-integration Uses a list of diverse examples to guide model output, placing the most similar examples last to leverage recency bias. ```python from langchain_core.prompts import FewShotChatMessagePromptTemplate # Use 3-5 diverse, representative examples examples = [ex1, ex2, ex3, ex4, ex5] few_shot = FewShotChatMessagePromptTemplate( examples=examples, example_prompt=ChatPromptTemplate.from_messages([ ("human", "{input}"), ("ai", "{output}"), ]), ) # Most similar examples last (recency bias helps) final_prompt = ChatPromptTemplate.from_messages([ ("system", "You are a helpful assistant. Answer concisely."), few_shot, ("human", "{input}"), ]) ``` -------------------------------- ### Apply configuration presets Source: https://orchestkit.vercel.app/docs/reference/skills/setup Set the base configuration using the setup command. ```text /ork:setup --preset complete /ork:setup --preset lite ``` -------------------------------- ### Incorrect Server Installation Source: https://orchestkit.vercel.app/docs/reference/skills/mcp-patterns Example of insecurely adding an unvetted server to the configuration. ```python # Grabbed a random server name from a blog post config = {"mcpServers": {"sketchy-db": {"command": "npx", "args": ["@unknown/mcp-db"]}}} ``` -------------------------------- ### JavaScript v3 to v4 Migration Example Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability This JavaScript snippet shows a migration example from Langfuse JavaScript SDK v3 to v4, focusing on package and setup changes. ```javascript // v3 example (conceptual) // import { init } from '@langfuse/core'; // init({ publicKey: '...', secretKey: '...' }); // v4 example import { Langfuse } from '@langfuse/sdk'; const langfuse = new Langfuse(); ``` -------------------------------- ### Prompt user for keybinding installation Source: https://orchestkit.vercel.app/docs/reference/skills/setup Use this structure to prompt the user to install recommended keyboard shortcuts. ```json AskUserQuestion(questions=[{ "question": "Install recommended keybindings for top OrchestKit skills?", "header": "Keyboard shortcuts", "options": [ {"label": "Yes, install keybindings (Recommended)", "description": "Adds 5 shortcuts: commit, verify, implement, explore, review-pr"}, {"label": "Skip", "description": "No keyboard shortcuts"} ], "multiSelect": false }]) ``` -------------------------------- ### Get Session Start Timestamp Source: https://orchestkit.vercel.app/docs/reference/skills/analytics Retrieves the timestamp of the first event in the session log. ```shell jq -r '.timestamp' "$SESSION_FILE" | head -1 ``` -------------------------------- ### Verify Environment Setup Source: https://orchestkit.vercel.app/docs/reference/skills/golden-dataset Commands to ensure infrastructure components like PostgreSQL, migrations, API keys, and disk space are ready. ```bash docker compose ps postgres # Expected: State = "running" ``` ```bash cd /Users/yonatangross/coding/OrchestKit/backend poetry run alembic current # Expected: Shows latest migration revision ``` ```bash echo $OPENAI_API_KEY # Expected: sk-... (valid API key) # OR check .env file grep OPENAI_API_KEY backend/.env # Expected: OPENAI_API_KEY=sk-... ``` ```bash df -h /Users/yonatangross/coding/OrchestKit/backend/data # Expected: At least 1 GB free ``` -------------------------------- ### Install and Manage Observability Dashboard Source: https://orchestkit.vercel.app/docs/reference/skills/browser-tools The dashboard provides live monitoring of browser sessions. Install it once, start the server to view sessions, and stop it when not needed. Sessions automatically stream to the dashboard. ```bash # Install the dashboard once agent-browser dashboard install ``` ```bash # Start the dashboard server (background, port 4848) agent-browser dashboard start ``` ```bash # All sessions are automatically visible in the dashboard agent-browser open example.com ``` ```bash # Stop the dashboard agent-browser dashboard stop ``` -------------------------------- ### CSF3 Story with Play Function Example Source: https://orchestkit.vercel.app/docs/reference/skills/storybook-testing Example of a CSF3 story for a Button component, including interaction tests using `play()` functions and assertions with `@storybook/test`. Ensure `storybook/test` is installed. ```typescript // Button.stories.tsx import type { Meta, StoryObj } from '@storybook/react' import { expect, fn, userEvent, within } from 'storybook/test' import { Button } from './Button' const meta = { component: Button, args: { onClick: fn(), }, } satisfies Meta export default meta type Story = StoryObj export const Primary: Story = { args: { label: 'Click me', variant: 'primary', }, play: async ({ canvasElement, args }) => { const canvas = within(canvasElement) const button = canvas.getByRole('button', { name: /click me/i }) await userEvent.click(button) await expect(args.onClick).toHaveBeenCalledOnce() await expect(button).toHaveStyle({ backgroundColor: 'rgb(37, 99, 235)' }) }, } ``` -------------------------------- ### GPTQ Quantization Setup Source: https://orchestkit.vercel.app/docs/reference/skills/performance Initial setup for loading calibration data for GPTQ quantization. ```python from gptqmodel import GPTQModel, QuantizeConfig from datasets import load_dataset # Load calibration data calibration_data = load_dataset( "allenai/c4", data_files="en/c4-train.00001-of-01024.json.gz", split="train", ).select(range(1024))["text"] ``` -------------------------------- ### Quick Start Issue Resolution Source: https://orchestkit.vercel.app/docs/reference/skills/fix-issue Examples of invoking the fix-issue command with specific issue numbers. ```text /ork:fix-issue 123 /ork:fix-issue 456 ``` -------------------------------- ### Common Patterns - Create Project and Deploy with Vercel Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Example demonstrating how to create a project and deploy it using the Vercel emulator. This is useful for testing Vercel integration workflows. ```javascript import fetch from 'node-fetch'; // or your preferred fetch implementation async function createProjectAndDeploy() { const vercelApiUrl = process.env.VERCEL_API_URL; // 1. Create a project const createProjectResponse = await fetch(`${vercelApiUrl}/v9/projects`, { method: 'POST', headers: { 'Content-Type': 'application/json', // Add Authorization header if required by your emulator setup }, body: JSON.stringify({ name: 'my-emulated-project', // other project settings... }), }); const projectData = await createProjectResponse.json(); const projectId = projectData.id; // 2. Create a deployment (simplified - actual deployment involves more steps like uploading build artifacts) const createDeploymentResponse = await fetch(`${vercelApiUrl}/v10/deployments`, { method: 'POST', headers: { 'Content-Type': 'application/json', // Add Authorization header if required }, body: JSON.stringify({ projectId: projectId, name: 'my-emulated-deployment', // deployment specific details... }), }); const deploymentData = await createDeploymentResponse.json(); console.log('Project created:', projectData); console.log('Deployment created:', deploymentData); } createProjectAndDeploy().catch(console.error); ``` -------------------------------- ### Install Storybook MCP Standalone for Chromatic Source: https://orchestkit.vercel.app/docs/reference/skills/storybook-mcp-integration For Chromatic remote setups, install the standalone Storybook MCP package. This package offers the same tool surface without requiring a local Storybook instance. ```bash npm i -D @storybook/mcp npx storybook-mcp --registry https://chromatic.storybook.cloud ``` -------------------------------- ### Demonstrate Correct Upgrade Workflow Source: https://orchestkit.vercel.app/docs/reference/skills/upgrade-assessment Example of a structured, multi-phase upgrade process that identifies and resolves blockers before applying changes. ```bash # Phase 1: Detect environment ./detect-environment.sh # Phase 2: Score dimensions (finds 3 CRITICAL issues) ./score-compatibility.sh # Phase 3: Fix P0 blockers BEFORE upgrade ./fix-model-refs.sh && ./migrate-hooks.sh # Then upgrade safely ``` -------------------------------- ### Quick Start Review PR Source: https://orchestkit.vercel.app/docs/reference/skills/review-pr Examples of invoking the review skill with a PR number or branch name. ```bash /ork:review-pr 123 /ork:review-pr feature-branch ``` -------------------------------- ### Start All Emulated Services Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Launches all available services (Vercel, GitHub, Google) with their default ports. This is the zero-configuration command. ```bash emulate ``` -------------------------------- ### Create Project Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Initializes a new project with a specified name and framework. This is a POST request to the projects endpoint. ```bash curl -X POST $BASE/v11/projects \ -H "Authorization: Bearer $TOKEN" \ -H "Content-Type: application/json" \ -d '{"name": "my-app", "framework": "nextjs"}' ``` -------------------------------- ### Programmatic SDK - Multi-Service Setup Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Shows how to configure multiple services (e.g., GitHub, Vercel, Google) with specific ports when creating an emulator instance programmatically. ```javascript import { createEmulate } from "@emulators/core"; const emulator = await createEmulate({ services: ["github", "vercel", "google"], ports: { github: 4001, vercel: 4000, google: 4002, }, }); ``` -------------------------------- ### Langfuse Basic Tracing Setup with @observe Decorator (Python v3) Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability Demonstrates the basic setup for distributed tracing using Langfuse's @observe decorator in Python. Ensure Langfuse SDK is installed and configured. ```python from langfuse import Langfuse from langfuse.decorators import observe langfuse = Langfuse() @observe() def my_function(input_data): # Your function logic here return "Processed: " + input_data result = my_function("sample input") ``` -------------------------------- ### Session Resume Hint Example Source: https://orchestkit.vercel.app/docs/reference/skills/implement Provides an example command for capturing implementation session context using `/ork:remember`, including completed phases, remaining tasks, key decisions, and blockers. ```shell /ork:remember Implementation of {feature}: Completed: phases 1-6 Remaining: verification, docs Key decisions: [list] Blockers: [if any] ``` -------------------------------- ### Start GitHub Emulator via CLI Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Starts the GitHub emulator using the npx command. ```bash # GitHub only npx emulate --service github # Default port # http://localhost:4001 ``` -------------------------------- ### Layer 2: OrchestKit JSONL (Hook Analytics) Setup Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability This example demonstrates the setup for Layer 2 observability using OrchestKit's JSONL format for hook analytics. This captures detailed event data. ```python from langfuse import Langfuse langfuse = Langfuse() with langfuse.trace("hook-analytics-example") as trace: trace.log_event("llm_call", { "prompt": "What is OrchestKit?", "response": "OrchestKit is an observability platform...", "model": "gpt-3.5-turbo" }) ``` -------------------------------- ### Global Scope Prompt Example Source: https://orchestkit.vercel.app/docs/hooks/memory-hooks Prompts starting with `@global` or mentioning cross-project/all projects trigger global scope. ```plaintext [Memory Context] For relevant past cross-project decisions... ``` -------------------------------- ### Invoke OrchestKit Setup Source: https://orchestkit.vercel.app/docs/reference/skills/setup Command to initiate the OrchestKit setup wizard. ```bash /ork:setup ``` -------------------------------- ### Start Emulate Services via CLI Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Commands to launch multiple services or customize ports for local development and testing. ```bash # Start GitHub + Vercel together npx emulate --service github,vercel --seed ./emulate.config.yaml # Custom ports npx emulate --service github --port 5001 ``` -------------------------------- ### OpenTelemetry SpanProcessor Setup Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability Example of configuring an OpenTelemetry SpanProcessor. This is a fundamental component for processing and exporting telemetry data. ```python from opentelemetry.sdk.trace import TracerProvider from opentelemetry.sdk.trace.export import BatchSpanProcessor from opentelemetry.exporter.otlp.proto.grpc.trace_exporter import OTLPSpanExporter # Assuming tracer_provider is already configured tracer_provider = TracerProvider() span_processor = BatchSpanProcessor( OTLPSpanExporter(endpoint="your-otlp-collector-endpoint:4317") ) tracer_provider.add_span_processor(span_processor) ``` -------------------------------- ### Launch the Demo Producer Pipeline Source: https://orchestkit.vercel.app/docs/cookbook/create-demo-video Initiate the video production pipeline by providing a natural language description of the feature to be demonstrated. ```bash /ork:demo-producer "Demo the new authentication flow — login, OAuth, and token refresh" ``` -------------------------------- ### Start Emulated Services via CLI Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Commands to launch services with various configurations, seed data, and port overrides. ```bash # Start all services with defaults npx emulate # Specific services npx emulate --service github npx emulate --service github,vercel npx emulate --service github,vercel,google # With seed data npx emulate --seed ./emulate.config.yaml npx emulate --service github --seed .emulate/dev.yaml # Custom port (overrides default for first service) npx emulate --service github --port 5001 # Combine flags npx emulate --service github,vercel --port 3000 --seed ./config.yaml ``` -------------------------------- ### Start Development Server Source: https://orchestkit.vercel.app/docs/reference/skills/verify Initiates the development server in the background for visual capture. ```python Bash( command=f"{start_command} &", description="Start dev server for visual capture", run_in_background=True ) ``` -------------------------------- ### Configure Responsive Image Attributes Source: https://orchestkit.vercel.app/docs/reference/skills/performance Examples demonstrating the importance of including sizes attributes in img tags to guide browser selection. ```html Photo ``` ```html Photo ``` -------------------------------- ### Node.js Structured Logging with pino Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability Example of configuring and using pino for high-performance structured logging in Node.js. Ensure pino is installed via npm. ```javascript const pino = require('pino')(); pino.info({ message: 'User logged in', userId: 123, ipAddress: '192.168.1.1' }); pino.error({ message: 'Failed to process request', requestId: 'abc', errorDetails: { code: 500, message: 'Internal Server Error' } }); ``` -------------------------------- ### Tutorial Demo Template Source: https://orchestkit.vercel.app/docs/reference/skills/demo-producer A template for creating tutorial videos. Includes phases for problem statement, solution setup, code writing, and execution, with placeholders for commands, code content, and output. ```markdown # Phase 1: Problem Statement (3s) # {problem_description} # Phase 2: Solution Setup (5s) > {setup_commands} # Phase 3: Code Writing (15-30s) # Show typing code with explanations > cat {file} {code_content} # Phase 4: Execution (5s) > {run_command} {output} ``` -------------------------------- ### Configure GitHub Actions E2E Workflow Source: https://orchestkit.vercel.app/docs/reference/skills/testing-e2e Defines the CI pipeline for E2E testing, including service setup, dependency installation, and test execution. ```yaml name: E2E Tests on: [push, pull_request] jobs: test: runs-on: ubuntu-latest services: postgres: image: postgres:15 env: POSTGRES_PASSWORD: postgres options: >- --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 redis: image: redis:7 options: >- --health-cmd "redis-cli ping" --health-interval 10s --health-timeout 5s --health-retries 5 steps: - uses: actions/checkout@v4 - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: '22' - name: Install dependencies run: npm ci - name: Install Playwright browsers run: npx playwright install --with-deps - name: Start backend run: | cd backend poetry install poetry run uvicorn app.main:app --host 0.0.0.0 --port 8500 & sleep 5 - name: Start frontend run: | npm run build npm run preview & sleep 3 - name: Run E2E tests run: npx playwright test - name: Upload test results if: always() uses: actions/upload-artifact@v3 with: name: playwright-report path: playwright-report/ retention-days: 30 ``` -------------------------------- ### Create Notebook and Add Sources Source: https://orchestkit.vercel.app/docs/reference/skills/notebooklm Initiate a new notebook for your project and add various types of sources such as URLs, text content, or local files. Ensure sources are appropriately formatted for optimal retrieval. ```python notebook_create(title="Auth Refactor Research") ``` ```python source_add(notebook_id="...", type="url", url="https://oauth.net/2.1/") ``` ```python source_add(notebook_id="...", type="text", content="Our current auth uses...") ``` ```python source_add(notebook_id="...", type="file", path="/docs/auth-design.md") ``` -------------------------------- ### Instrumenting OpenAI LLM Calls with Langfuse (Python) Source: https://orchestkit.vercel.app/docs/reference/skills/monitoring-observability Example of instrumenting OpenAI LLM calls for tracing with Langfuse in Python. Requires the 'openai' library to be installed. ```python from langfuse import Langfuse from langfuse.openai import openai langfuse = Langfuse() # Use the instrumented OpenAI client client = openai.OpenAI() response = client.chat.completions.create( model="gpt-3.5-turbo", messages=[{"role": "user", "content": "Hello world"}] ) ``` -------------------------------- ### AAA Pattern TypeScript Example Source: https://orchestkit.vercel.app/docs/reference/skills/testing-unit Illustrates the Arrange-Act-Assert (AAA) pattern in TypeScript using Vitest. Clearly separates test setup, execution, and assertion phases. ```typescript describe('calculateDiscount', () => { test('applies 10% discount for orders over $100', () => { // Arrange const order = { items: [{ price: 150 }] }; // Act const result = calculateDiscount(order); // Assert expect(result).toBe(15); }); }); ``` -------------------------------- ### Configure Production vLLM Server Source: https://orchestkit.vercel.app/docs/reference/skills/performance Production-ready server startup commands with various performance and security flags. ```bash # Production vLLM server vllm serve meta-llama/Meta-Llama-3.1-70B-Instruct \ --host 0.0.0.0 \ --port 8000 \ --tensor-parallel-size 4 \ --max-model-len 8192 \ --max-num-seqs 128 \ --gpu-memory-utilization 0.9 \ --enable-prefix-caching \ --disable-log-requests \ --api-key $VLLM_API_KEY # With quantization vllm serve meta-llama/Meta-Llama-3.1-70B-Instruct \ --quantization awq \ --dtype half \ --tensor-parallel-size 2 \ --gpu-memory-utilization 0.85 ``` -------------------------------- ### Start Google Emulator (CLI) Source: https://orchestkit.vercel.app/docs/reference/skills/emulate-seed Command-line instruction to start the Google OAuth 2.0 / OIDC emulator. ```bash # Google only npx emulate --service google # Default port # http://localhost:4002 ``` -------------------------------- ### Example Planner Output Source: https://orchestkit.vercel.app/docs/reference/skills/testing-llm A sample test plan generated by the Planner in markdown format. ```markdown # Test Plan: Guest Checkout Flow ## Test Scenario 1: Happy Path - Complete Guest Purchase **Given:** User is not logged in **When:** User completes checkout as guest **Then:** Order is placed successfully ### Steps: 1. Navigate to product page 2. Click "Add to Cart" 3. Navigate to cart 4. Click "Checkout as Guest" 5. Fill shipping form: - Full Name: "John Doe" - Email: "john@example.com" - Address: "123 Main St" - City: "Seattle" - ZIP: "98101" 6. Click "Continue to Payment" 7. Enter credit card: - Number: "4242424242424242" (test card) - Expiry: "12/25" - CVC: "123" 8. Click "Place Order" 9. Verify: - URL contains "/order-confirmation" - Page displays "Order #" with order number - Email confirmation message shown ## Test Scenario 2: Edge Case - Empty Cart Checkout **Given:** User has empty cart **When:** User attempts checkout **Then:** Checkout button is disabled ### Steps: 1. Navigate to cart 2. Verify message "Your cart is empty" 3. Verify "Checkout" button has `disabled` attribute 4. Verify button is grayed out visually ## Test Scenario 3: Error Handling - Invalid Credit Card **Given:** User completes shipping info **When:** User enters invalid credit card **Then:** Error message is displayed ### Steps: 1-6. (Same as Scenario 1) 7. Enter invalid card: "1111222233334444" 8. Click "Place Order" 9. Verify: - Error message "Invalid card number" - Form stays on payment page - No order created in system ``` -------------------------------- ### Memory Context System Message Source: https://orchestkit.vercel.app/docs/hooks/memory-hooks Example system message generated by the memory context hook to guide Claude in searching for relevant past project decisions. ```text [Memory Context] For relevant past project decisions, use mcp__memory__search_nodes with query="cursor pagination orders" ```