diff --git a/README.md b/README.md index 1b3bfbf..a6a2d07 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ English | [简体中文](https://github.com/yusufkaraaslan/Skill_Seekers/blob/ma [](https://x.com/_yUSyUS_) [](https://github.com/yusufkaraaslan/Skill_Seekers) -**The universal preprocessing layer for AI systems: Convert documentation, GitHub repos, and PDFs into production-ready formats for RAG pipelines, Claude AI skills, and AI coding assistants—in minutes, not hours.** +**The universal preprocessor for any AI system: Convert documentation, GitHub repos, and PDFs into production-ready formats for LangChain, LlamaIndex, Pinecone, Cursor, Windsurf, Cline, Continue.dev, Claude, and any RAG pipeline—in minutes, not hours.** > 🌐 **[Visit SkillSeekersWeb.com](https://skillseekersweb.com/)** - Browse 24+ preset configs, share your configs, and access complete documentation! @@ -42,7 +42,10 @@ skill-seekers package output/react --target langchain # or llama-index, pinecon | **LangChain** | `Documents` | QA chains, agents, retrievers | [Guide](docs/integrations/LANGCHAIN.md) | | **LlamaIndex** | `TextNodes` | Query engines, chat engines | [Guide](docs/integrations/LLAMA_INDEX.md) | | **Pinecone** | Ready for upsert | Production vector search | [Guide](docs/integrations/PINECONE.md) | -| **Cursor IDE** | `.cursorrules` | AI coding assistant context | [Guide](docs/integrations/CURSOR.md) | +| **Cursor IDE** | `.cursorrules` | AI coding (VS Code fork) | [Guide](docs/integrations/CURSOR.md) | +| **Windsurf** | `.windsurfrules` | AI coding (Codeium IDE) | [Guide](docs/integrations/WINDSURF.md) | +| **Cline** | `.clinerules` + MCP | AI coding (VS Code ext) | [Guide](docs/integrations/CLINE.md) | +| **Continue.dev** | HTTP context | AI coding (any IDE) | [Guide](docs/integrations/CONTINUE_DEV.md) | | **Claude AI** | Skills (ZIP) | Claude Code skills | Default | | **Gemini** | tar.gz | Google Gemini skills | `--target gemini` | | **OpenAI** | ChatGPT format | Custom GPTs | `--target openai` | @@ -246,9 +249,13 @@ pip install skill-seekers[all-llms] - Example: [Pinecone Upsert](examples/pinecone-upsert/) - Guide: [Pinecone Integration](docs/integrations/PINECONE.md) -- ✅ **Cursor IDE (.cursorrules)** - Generate custom rules for AI coding assistant - - Perfect for: Framework-specific code suggestions, persistent AI context - - Guide: [Cursor Integration](docs/integrations/CURSOR.md) +- ✅ **AI Coding Assistants** - Expert context for 4+ IDE AI tools + - **Cursor IDE** - `.cursorrules` format for VS Code fork | [Guide](docs/integrations/CURSOR.md) + - **Windsurf** - `.windsurfrules` format for Codeium IDE | [Guide](docs/integrations/WINDSURF.md) + - **Cline** - `.clinerules` + MCP for VS Code extension | [Guide](docs/integrations/CLINE.md) + - **Continue.dev** - HTTP context providers for any IDE | [Guide](docs/integrations/CONTINUE_DEV.md) + - Perfect for: Framework-specific code generation, consistent team patterns + - Hub: [All AI Coding Integrations](docs/integrations/INTEGRATIONS.md) **Quick Export:** ```bash @@ -267,6 +274,71 @@ skill-seekers package output/django --target markdown **Complete RAG Pipeline Guide:** [RAG Pipelines Documentation](docs/integrations/RAG_PIPELINES.md) +--- + +### 🧠 AI Coding Assistant Integrations (**NEW - v2.10.0**) + +Transform any framework documentation into expert coding context for 4+ AI assistants: + +- ✅ **Cursor IDE** - Generate `.cursorrules` for AI-powered code suggestions + - Perfect for: Framework-specific code generation, consistent patterns + - Works with: Cursor IDE (VS Code fork) + - Guide: [Cursor Integration](docs/integrations/CURSOR.md) + - Example: [Cursor React Skill](examples/cursor-react-skill/) + +- ✅ **Windsurf** - Customize Windsurf's AI assistant context with `.windsurfrules` + - Perfect for: IDE-native AI assistance, flow-based coding + - Works with: Windsurf IDE by Codeium + - Guide: [Windsurf Integration](docs/integrations/WINDSURF.md) + - Example: [Windsurf FastAPI Context](examples/windsurf-fastapi-context/) + +- ✅ **Cline (VS Code)** - System prompts + MCP for VS Code agent + - Perfect for: Agentic code generation in VS Code, Cursor Composer equivalent + - Works with: Cline extension for VS Code + - Guide: [Cline Integration](docs/integrations/CLINE.md) + - Example: [Cline Django Assistant](examples/cline-django-assistant/) + +- ✅ **Continue.dev** - Context servers for IDE-agnostic AI + - Perfect for: Multi-IDE environments (VS Code, JetBrains, Vim), custom LLM providers + - Works with: Any IDE with Continue.dev plugin + - Guide: [Continue Integration](docs/integrations/CONTINUE_DEV.md) + - Example: [Continue Universal Context](examples/continue-dev-universal/) + +**Quick Export for AI Coding Tools:** +```bash +# For any AI coding assistant (Cursor, Windsurf, Cline, Continue.dev) +skill-seekers scrape --config configs/django.json +skill-seekers package output/django --target markdown # or --target claude + +# Copy to your project (example for Cursor) +cp output/django-markdown/SKILL.md my-project/.cursorrules + +# Or for Windsurf +cp output/django-markdown/SKILL.md my-project/.windsurf/rules/django.md + +# Or for Cline +cp output/django-markdown/SKILL.md my-project/.clinerules + +# Or for Continue.dev (HTTP server) +python examples/continue-dev-universal/context_server.py +# Configure in ~/.continue/config.json +``` + +**Multi-IDE Team Consistency:** +```bash +# Use Continue.dev for teams with mixed IDEs +skill-seekers scrape --config configs/react.json +python context_server.py --host 0.0.0.0 --port 8765 + +# Team members configure Continue.dev (same config works in ALL IDEs): +# VS Code, IntelliJ, PyCharm, WebStorm, Vim... +# Result: Identical AI suggestions across all environments! +``` + +**Integration Hub:** [All AI System Integrations](docs/integrations/INTEGRATIONS.md) + +--- + ### 🌊 Three-Stream GitHub Architecture (**NEW - v2.6.0**) - ✅ **Triple-Stream Analysis** - Split GitHub repos into Code, Docs, and Insights streams - ✅ **Unified Codebase Analyzer** - Works with GitHub URLs AND local paths diff --git a/docs/integrations/CLINE.md b/docs/integrations/CLINE.md new file mode 100644 index 0000000..3c2bfea --- /dev/null +++ b/docs/integrations/CLINE.md @@ -0,0 +1,1052 @@ +# Using Skill Seekers with Cline (VS Code Extension) + +**Last Updated:** February 7, 2026 +**Status:** Production Ready +**Difficulty:** Medium ⭐⭐ + +--- + +## 🎯 The Problem + +Cline (formerly Claude Dev) is a powerful autonomous coding agent for VS Code, but: + +- **Generic Knowledge** - AI doesn't know your project-specific frameworks or internal patterns +- **Manual Context** - Copy-pasting documentation into chat breaks autonomous workflow +- **No Framework Memory** - Cline forgets framework details between sessions +- **Custom Instructions Limit** - Built-in custom instructions are limited in scope + +**Example:** +> "When using Cline to build a Django app, the agent might use outdated patterns or miss framework-specific conventions. You want Cline to automatically reference comprehensive framework documentation without manual prompting." + +--- + +## ✨ The Solution + +Use Skill Seekers to create **custom rules and MCP tools** for Cline: + +1. **Generate structured docs** from any framework or codebase +2. **Package as .clinerules** - Cline's markdown rules format +3. **MCP Integration** - Expose documentation via Model Context Protocol +4. **Memory Bank** - Persistent framework knowledge across sessions + +**Result:** +Cline becomes an expert in your frameworks with automatic context and autonomous access to documentation via MCP tools. + +--- + +## 🚀 Quick Start (10 Minutes) + +### Prerequisites + +- VS Code installed (https://code.visualstudio.com/) +- Cline extension installed (https://marketplace.visualstudio.com/items?itemName=saoudrizwan.claude-dev) +- Python 3.10+ (for Skill Seekers) +- Claude API key (recommended) or other LLM + +### Installation + +```bash +# Install Skill Seekers with MCP support +pip install skill-seekers[mcp] + +# Verify installation +skill-seekers --version +``` + +### Generate .clinerules + +```bash +# Example: Django framework +skill-seekers scrape --config configs/django.json + +# Package for Cline (markdown format) +skill-seekers package output/django --target markdown + +# Extract SKILL.md (this becomes your .clinerules content) +# output/django-markdown/SKILL.md +``` + +### Setup in Cline + +**Option 1: Project-Specific Rules** (recommended) + +```bash +# Copy to project root as .clinerules +cp output/django-markdown/SKILL.md /path/to/your/project/.clinerules +``` + +**Option 2: Custom Instructions** (per-project settings) + +1. Open Cline settings in VS Code (Cmd+, → search "Cline") +2. Find "Custom Instructions" +3. Add framework knowledge: + +``` +You are an expert in Django. Follow these patterns: + +[Paste contents of SKILL.md here] +``` + +**Option 3: MCP Server** (for dynamic access) + +```bash +# Configure Cline's MCP settings +# In Cline panel → Settings → MCP Servers → Add Server + +# Add Skill Seekers MCP server: +{ + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"], + "env": {} + } +} +``` + +### Test in Cline + +1. Open your project in VS Code +2. Open Cline panel (click Cline icon in sidebar) +3. Start a new task: + ``` + Create a Django model for users with email authentication + ``` +4. Verify Cline references your documentation patterns + +--- + +## 📖 Detailed Setup Guide + +### Step 1: Choose Your Documentation Source + +**Option A: Use Preset Configs** (24+ frameworks) + +```bash +# List available presets +ls configs/ + +# Popular presets: +# - react.json, vue.json, angular.json (Frontend) +# - django.json, fastapi.json, flask.json (Backend) +# - kubernetes.json, docker.json (Infrastructure) +``` + +**Option B: Custom Documentation** + +Create `myframework-config.json`: + +```json +{ + "name": "myframework", + "description": "Custom framework documentation for Cline", + "base_url": "https://docs.myframework.com/", + "selectors": { + "main_content": "article", + "title": "h1", + "code_blocks": "pre code" + }, + "categories": { + "getting_started": ["intro", "quickstart"], + "core_concepts": ["concepts", "architecture"], + "api": ["api", "reference"], + "best_practices": ["best-practices", "patterns"] + } +} +``` + +**Option C: GitHub Repository** + +```bash +# Analyze codebase patterns +skill-seekers github --repo facebook/react + +# Or local codebase +skill-seekers analyze --directory /path/to/repo --comprehensive +``` + +### Step 2: Optimize for Cline + +**File-Based Rules** + +Cline rules are markdown files with NO special syntax required: + +```markdown + +# Django Expert + +You are an expert in Django. Follow these patterns: + +## Models + +Always include these fields in models: + +\```python +from django.db import models + +class MyModel(models.Model): + created_at = models.DateTimeField(auto_now_add=True) + updated_at = models.DateTimeField(auto_now=True) + + class Meta: + ordering = ['-created_at'] +\``` + +## Views + +Use class-based views for CRUD operations: + +\```python +from django.views.generic import ListView, DetailView + +class UserListView(ListView): + model = User + template_name = 'users/list.html' + context_object_name = 'users' +\``` +``` + +**Hierarchical Rules** + +Create multiple rules files for organization: + +``` +my-django-project/ +├── .clinerules # Core framework patterns +├── .clinerules.models # Model-specific rules +├── .clinerules.views # View-specific rules +├── .clinerules.testing # Testing patterns +└── .clinerules.project # Project-specific conventions +``` + +Cline automatically loads all `.clinerules*` files. + +**Memory Bank Integration** + +Combine rules with Cline's Memory Bank: + +```bash +# Create memory bank structure +mkdir -p .cline/memory-bank + +# Initialize memory bank +echo "# Project Memory Bank + +## Tech Stack +- Django 5.x +- PostgreSQL 16 +- Redis for caching + +## Architecture +- Modular apps structure +- API-first design +- Async views for I/O-bound operations + +## Conventions +- All models include timestamps +- Use class-based views +- pytest for testing +" > .cline/memory-bank/README.md + +# Ask Cline to initialize +# In Cline chat: "Initialize a memory bank for this Django project" +``` + +### Step 3: Configure MCP Integration + +**MCP Server Setup** (for dynamic documentation access) + +1. **Install Skill Seekers MCP server:** + +```bash +pip install skill-seekers[mcp] +``` + +2. **Configure in Cline settings:** + +Open Cline panel → Settings → MCP Servers → Configure + +Add this configuration: + +```json +{ + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": [ + "-m", + "skill_seekers.mcp.server_fastmcp", + "--transport", + "stdio" + ], + "env": {} + } + } +} +``` + +3. **Restart VS Code** + +4. **Verify MCP tools available:** + +In Cline panel, check "Available Tools" - you should see: +- `list_configs` - List preset configurations +- `scrape_docs` - Scrape documentation dynamically +- `package_skill` - Package skills for Cline +- ... (18 total MCP tools) + +**Using MCP Tools** + +Now Cline can access documentation on-demand: + +``` +In Cline chat: + +"Use the skill-seekers MCP tool to scrape React documentation +and generate .clinerules for this project" + +Cline will: +1. Call list_configs to find react.json +2. Call scrape_docs with config +3. Call package_skill to create .clinerules +4. Load rules automatically +``` + +### Step 4: Test and Refine + +**Test Cline's Knowledge** + +Start autonomous tasks: + +``` +"Create a complete Django REST API for blog posts with: +- Post model with author foreign key +- Serializers with nested author data +- ViewSets with filtering and pagination +- URL routing +- Tests with pytest" +``` + +Verify Cline follows your documented patterns. + +**Refine Rules** + +Add project-specific patterns: + +```markdown + +# Project-Specific Conventions + +## Database Queries + +ALWAYS use select_related/prefetch_related for foreign keys: + +\```python +# BAD +posts = Post.objects.all() # N+1 queries + +# GOOD +posts = Post.objects.select_related('author').all() +\``` + +## API Responses + +NEVER return sensitive fields: + +\```python +class UserSerializer(serializers.ModelSerializer): + class Meta: + model = User + fields = ['id', 'username', 'email'] + # Exclude: password, is_staff, etc. +\``` +``` + +**Monitor Cline's Behavior** + +Watch for: +- ✅ Cline references rules in explanations +- ✅ Generated code follows patterns +- ✅ Autonomous decisions align with documentation +- ❌ Generic patterns not from your rules (needs refinement) + +--- + +## 🎨 Advanced Usage + +### Multi-Framework Projects + +**Full-Stack Django + React** + +```bash +# Generate backend rules +skill-seekers scrape --config configs/django.json +cp output/django-markdown/SKILL.md .clinerules.backend + +# Generate frontend rules +skill-seekers scrape --config configs/react.json +cp output/react-markdown/SKILL.md .clinerules.frontend + +# Add project conventions +cat > .clinerules.project << 'EOF' +# Project Conventions + +## Backend +- Django REST framework for API +- JWT authentication +- Async views for heavy operations + +## Frontend +- React 18 with TypeScript +- Tanstack Query for API calls +- Zustand for state management + +## Communication +- Backend exposes /api/v1/* endpoints +- Frontend proxies to localhost:8000 in dev +EOF + +# Now Cline knows both Django AND React patterns +``` + +**Testing with Multiple Frameworks** + +```bash +# Backend testing rules +cat > .clinerules.testing-backend << 'EOF' +# Django Testing Patterns + +Use pytest with pytest-django: + +\```python +import pytest +from django.test import Client + +@pytest.mark.django_db +def test_create_post(client: Client): + response = client.post('/api/v1/posts/', { + 'title': 'Test Post', + 'content': 'Test content' + }) + assert response.status_code == 201 +\``` +EOF + +# Frontend testing rules +cat > .clinerules.testing-frontend << 'EOF' +# React Testing Patterns + +Use React Testing Library: + +\```typescript +import { render, screen } from '@testing-library/react'; +import { Post } from './Post'; + +test('renders post title', () => { + render(); + expect(screen.getByText('Test')).toBeInTheDocument(); +}); +\``` +EOF +``` + +### Dynamic Context with MCP Tools + +**Custom MCP Tool for Framework Search** + +Create `custom_mcp_tool.py`: + +```python +from fastmcp import FastMCP + +mcp = FastMCP("Custom Framework Search") + +@mcp.tool() +def search_framework_docs(framework: str, query: str) -> str: + """ + Search framework documentation dynamically. + + Args: + framework: Framework name (django, react, etc.) + query: Search query + + Returns: + Relevant documentation snippets + """ + # Use Skill Seekers to search + from skill_seekers.cli.adaptors import get_adaptor + + adaptor = get_adaptor('markdown') + results = adaptor.search(framework, query) + + return results +``` + +Register in Cline's MCP config: + +```json +{ + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + }, + "custom-search": { + "command": "python", + "args": ["custom_mcp_tool.py"] + } + } +} +``` + +Now Cline can search docs on-demand: + +``` +In Cline: "Use custom-search MCP tool to find Django async views best practices" +``` + +### Cline + RAG Pipeline + +**Combine Rules with Vector Search** + +```python +# setup_cline_rag.py +from skill_seekers.cli.doc_scraper import main as scrape +from skill_seekers.cli.package_skill import main as package + +# Scrape documentation +scrape(["--config", "configs/django.json"]) + +# Create Cline rules +package(["output/django", "--target", "markdown"]) + +# Also create RAG pipeline +package(["output/django", "--target", "langchain", "--chunk-for-rag"]) + +# Now you have: +# 1. .clinerules for Cline's context +# 2. LangChain documents for deep vector search +``` + +**MCP Tool for RAG Query** + +```python +# mcp_rag_tool.py +from fastmcp import FastMCP +from langchain_community.vectorstores import Chroma +from langchain_openai import OpenAIEmbeddings + +mcp = FastMCP("RAG Search") + +# Load vector store +embeddings = OpenAIEmbeddings() +vectorstore = Chroma(persist_directory="./chroma_db", embedding_function=embeddings) + +@mcp.tool() +def rag_search(query: str, k: int = 5) -> str: + """ + Search documentation using RAG. + + Args: + query: Search query + k: Number of results + + Returns: + Top-k relevant documentation snippets + """ + results = vectorstore.similarity_search(query, k=k) + return "\n\n".join([doc.page_content for doc in results]) +``` + +--- + +## 💡 Best Practices + +### 1. Keep Rules Focused + +**Bad: Everything in One File** + +```markdown + +# Django Complete Guide +[... massive unstructured documentation ...] +``` + +**Good: Modular Rules** + +```markdown + +# Django Core Patterns +[... focused on common patterns ...] + + +# Django Models Best Practices +[... focused on database patterns ...] + + +# Django REST Framework +[... focused on API patterns ...] +``` + +### 2. Use Hierarchical Loading + +Cline loads all `.clinerules*` files. Use naming for precedence: + +``` +.clinerules # Core framework (loaded first) +.clinerules.01-models # Database patterns +.clinerules.02-views # View patterns +.clinerules.03-testing # Testing patterns +.clinerules.99-project # Project overrides (loaded last) +``` + +### 3. Include Code Examples + +Don't just describe patterns - show them: + +```markdown +## Creating Django Models + +\```python +from django.db import models +from django.contrib.auth.models import AbstractUser + +class User(AbstractUser): + email = models.EmailField(unique=True) + bio = models.TextField(blank=True) + + created_at = models.DateTimeField(auto_now_add=True) + updated_at = models.DateTimeField(auto_now=True) + + class Meta: + ordering = ['-created_at'] + + def __str__(self): + return self.username +\``` + +Use this exact pattern for all models. +``` + +### 4. Leverage MCP for Dynamic Context + +**Static Rules** (in .clinerules): +- Core patterns that rarely change +- Framework conventions +- Code style preferences + +**Dynamic MCP Tools**: +- Search latest documentation +- Query GitHub for code examples +- Fetch API references on-demand + +``` +In Cline: +"Use skill-seekers MCP to search Django 5.0 async views documentation" + +Cline calls MCP tool → gets latest docs → applies to task +``` + +### 5. Update Rules Regularly + +```bash +# Quarterly framework updates +skill-seekers scrape --config configs/django.json +cp output/django-markdown/SKILL.md .clinerules + +# Check what changed +diff .clinerules.old .clinerules + +# Test with Cline +# Ask: "What's new in Django 5.0?" +``` + +--- + +## 🔥 Real-World Examples + +### Example 1: Django REST API with Cline + +**Project Structure:** + +``` +my-django-api/ +├── .clinerules # Core Django patterns +├── .clinerules.api # DRF patterns +├── .clinerules.testing # pytest patterns +├── .clinerules.project # Project conventions +├── app/ +│ ├── models.py +│ ├── serializers.py +│ ├── views.py +│ └── urls.py +└── tests/ +``` + +**.clinerules (Core Django)** + +```markdown +# Django Expert + +You are an expert in Django 5.0. Follow these patterns: + +## Models + +Always include timestamps and __str__: + +\```python +from django.db import models + +class BaseModel(models.Model): + created_at = models.DateTimeField(auto_now_add=True) + updated_at = models.DateTimeField(auto_now=True) + + class Meta: + abstract = True + +class Post(BaseModel): + title = models.CharField(max_length=200) + content = models.TextField() + author = models.ForeignKey('auth.User', on_delete=models.CASCADE) + + def __str__(self): + return self.title +\``` + +## Queries + +Use select_related/prefetch_related: + +\```python +# BAD +posts = Post.objects.all() + +# GOOD +posts = Post.objects.select_related('author').all() +\``` +``` + +**.clinerules.api (Django REST Framework)** + +```markdown +# Django REST Framework Patterns + +## Serializers + +Use nested serializers for relationships: + +\```python +from rest_framework import serializers + +class AuthorSerializer(serializers.ModelSerializer): + class Meta: + model = User + fields = ['id', 'username', 'email'] + +class PostSerializer(serializers.ModelSerializer): + author = AuthorSerializer(read_only=True) + + class Meta: + model = Post + fields = ['id', 'title', 'content', 'author', 'created_at'] +\``` + +## ViewSets + +Use ViewSets with filtering: + +\```python +from rest_framework import viewsets, filters + +class PostViewSet(viewsets.ModelViewSet): + queryset = Post.objects.select_related('author').all() + serializer_class = PostSerializer + filter_backends = [filters.SearchFilter] + search_fields = ['title', 'content'] +\``` +``` + +**Using Cline:** + +``` +Start Cline task: + +"Create a complete blog API with posts and comments: +- Post model with author, title, content, created_at +- Comment model with author, post foreign key, content +- Serializers with nested data +- ViewSets with filtering +- URL routing +- Full test suite with pytest" + +Cline will: +1. ✅ Use BaseModel with timestamps (from .clinerules) +2. ✅ Add __str__ methods (from .clinerules) +3. ✅ Use select_related in viewsets (from .clinerules) +4. ✅ Create nested serializers (from .clinerules.api) +5. ✅ Add filtering (from .clinerules.api) +6. ✅ Write pytest tests (from .clinerules.testing) + +Result: Production-ready API following all your patterns! +``` + +### Example 2: React + TypeScript with Cline + +**Project Structure:** + +``` +my-react-app/ +├── .clinerules # Core React patterns +├── .clinerules.typescript # TypeScript patterns +├── .clinerules.testing # Testing Library patterns +├── src/ +│ ├── components/ +│ ├── hooks/ +│ └── utils/ +└── tests/ +``` + +**.clinerules (Core React)** + +```markdown +# React 18 + TypeScript Expert + +## Components + +Use functional components with TypeScript: + +\```typescript +import { FC } from 'react'; + +interface PostProps { + title: string; + content: string; + author: { + name: string; + email: string; + }; +} + +export const Post: FC = ({ title, content, author }) => { + return ( + + {title} + {content} + + + ); +}; +\``` + +## Hooks + +Use custom hooks for logic: + +\```typescript +import { useState, useEffect } from 'react'; + +interface UseFetchResult { + data: T | null; + loading: boolean; + error: Error | null; +} + +export function useFetch(url: string): UseFetchResult { + const [data, setData] = useState(null); + const [loading, setLoading] = useState(true); + const [error, setError] = useState(null); + + useEffect(() => { + fetch(url) + .then(res => res.json()) + .then(setData) + .catch(setError) + .finally(() => setLoading(false)); + }, [url]); + + return { data, loading, error }; +} +\``` +``` + +--- + +## 🐛 Troubleshooting + +### Issue: .clinerules Not Loading + +**Symptoms:** +- Cline doesn't reference documentation +- Rules file exists but ignored + +**Solutions:** + +1. **Check file location** + ```bash + # Must be at project root + ls -la .clinerules + + # Not in subdirectory + # NOT: src/.clinerules + ``` + +2. **Verify file format** + ```bash + # Must be plain markdown + file .clinerules + # Should show: ASCII text + + # Not binary or encoded + ``` + +3. **Reload VS Code** + ``` + Cmd+Shift+P → "Developer: Reload Window" + ``` + +4. **Check Cline logs** + ``` + In Cline panel → Settings → Show Logs + # Look for "Loaded rules from .clinerules" + ``` + +### Issue: MCP Server Not Connecting + +**Error:** +> "Failed to connect to MCP server: skill-seekers" + +**Solutions:** + +1. **Verify installation** + ```bash + pip show skill-seekers + # Check [mcp] extra is installed + ``` + +2. **Test MCP server directly** + ```bash + python -m skill_seekers.mcp.server_fastmcp --transport stdio + # Should start without errors + ``` + +3. **Check Python path** + ```json + // MCP config - use absolute path + { + "mcpServers": { + "skill-seekers": { + "command": "/usr/local/bin/python3", // Absolute path + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } + } + } + ``` + +4. **Check environment variables** + ```json + { + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"], + "env": { + "ANTHROPIC_API_KEY": "${env:ANTHROPIC_API_KEY}" + } + } + } + } + ``` + +### Issue: Cline Not Using Rules + +**Symptoms:** +- Rules loaded but Cline ignores them +- Generic code patterns + +**Solutions:** + +1. **Add explicit instructions** + ```markdown + # Django Expert + + You MUST follow these patterns in ALL Django code: + - Use timestamps in all models + - Use select_related for foreign keys + - Write tests for all views + + Never deviate from these patterns. + ``` + +2. **Use memory bank** + ``` + In Cline chat: + "Remember to ALWAYS follow the patterns in .clinerules" + ``` + +3. **Reference rules explicitly** + ``` + In Cline task: + "Create a Django model following the patterns in .clinerules" + ``` + +4. **Check custom instructions** + ``` + Cline Settings → Custom Instructions + # Should NOT conflict with .clinerules + ``` + +--- + +## 📊 Before vs After Comparison + +| Aspect | Before Skill Seekers | After Skill Seekers | +|--------|---------------------|---------------------| +| **Context Source** | Copy-paste into chat | Auto-loaded .clinerules | +| **AI Knowledge** | Generic patterns | Framework-specific patterns | +| **Setup Time** | Manual curation (hours) | Automated scraping (10 min) | +| **Consistency** | Varies per task | Persistent across tasks | +| **Updates** | Manual editing | Re-run scraper | +| **MCP Integration** | Manual tool creation | Pre-built MCP tools | +| **Multi-Framework** | Context confusion | Modular rules per framework | +| **Autonomous Workflow** | Frequent interruptions | Autonomous with correct patterns | + +--- + +## 🤝 Community & Support + +- **Questions:** [GitHub Discussions](https://github.com/yusufkaraaslan/Skill_Seekers/discussions) +- **Issues:** [GitHub Issues](https://github.com/yusufkaraaslan/Skill_Seekers/issues) +- **Website:** [skillseekersweb.com](https://skillseekersweb.com/) +- **Cline Docs:** [docs.cline.bot](https://docs.cline.bot/) +- **Cline GitHub:** [github.com/cline/cline](https://github.com/cline/cline) + +--- + +## 📚 Related Guides + +- [Cursor Integration](CURSOR.md) - Similar IDE, different approach +- [Windsurf Integration](WINDSURF.md) - Alternative AI IDE +- [Continue.dev Integration](CONTINUE_DEV.md) - IDE-agnostic assistant +- [LangChain Integration](LANGCHAIN.md) - Build RAG pipelines +- [MCP Setup Guide](../MCP_SETUP.md) - Detailed MCP configuration + +--- + +## 📖 Next Steps + +1. **Try another framework:** `skill-seekers scrape --config configs/fastapi.json` +2. **Set up MCP server:** Dynamic documentation access +3. **Create memory bank:** Persistent project knowledge +4. **Build RAG pipeline:** Deep documentation search with `--target langchain` +5. **Contribute examples:** Share your .clinerules patterns + +--- + +**Sources:** +- [Cline VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=saoudrizwan.claude-dev) +- [Cline GitHub Repository](https://github.com/cline/cline) +- [Cline Documentation](https://docs.cline.bot/getting-started/installing-cline) +- [Cline Rules Documentation](https://deepwiki.com/cline/cline/7.1-cline-rules) +- [Cline Prompt Engineering Guide](https://medium.com/@evanmusick.dev/cline-prompt-engineering-crash-course-custom-instructions-that-actually-work-520ef1162fc2) +- [VS Code MCP Integration](https://code.visualstudio.com/docs/copilot/customization/mcp-servers) +- [MCP Developer Guide](https://code.visualstudio.com/api/extension-guides/ai/mcp) +- [Cline MCP Setup Guide](https://4sysops.com/archives/install-mcp-server-with-vs-code-extension-cline-for-ai-driven-aws-automation/) diff --git a/docs/integrations/CONTINUE_DEV.md b/docs/integrations/CONTINUE_DEV.md new file mode 100644 index 0000000..24db3ea --- /dev/null +++ b/docs/integrations/CONTINUE_DEV.md @@ -0,0 +1,1118 @@ +# Using Skill Seekers with Continue.dev + +**Last Updated:** February 7, 2026 +**Status:** Production Ready +**Difficulty:** Easy ⭐ + +--- + +## 🎯 The Problem + +Continue.dev is a powerful IDE-agnostic AI coding assistant, but: + +- **Generic Knowledge** - AI doesn't know your project-specific frameworks or patterns +- **Manual Context** - Typing @-mentions for every framework detail is tedious +- **Multi-IDE Consistency** - Context varies between VS Code, JetBrains, and other IDEs +- **Limited Built-in Providers** - Few pre-configured documentation sources + +**Example:** +> "When using Continue in VS Code and JetBrains simultaneously, you want consistent framework knowledge across both IDEs without manual setup duplication. Continue's built-in @docs provider requires manual indexing." + +--- + +## ✨ The Solution + +Use Skill Seekers to create **custom context providers** for Continue.dev: + +1. **Generate structured docs** from any framework or codebase +2. **Package as HTTP context provider** - Continue's universal format +3. **MCP Integration** - Expose documentation via Model Context Protocol +4. **IDE-Agnostic** - Same context in VS Code, JetBrains, and future IDEs + +**Result:** +Continue becomes an expert in your frameworks across all IDEs with consistent, automatic context. + +--- + +## 🚀 Quick Start (5 Minutes) + +### Prerequisites + +- Continue.dev installed in your IDE: + - **VS Code:** https://marketplace.visualstudio.com/items?itemName=Continue.continue + - **JetBrains:** Settings → Plugins → Search "Continue" +- Python 3.10+ (for Skill Seekers) + +### Installation + +```bash +# Install Skill Seekers with MCP support +pip install skill-seekers[mcp] + +# Verify installation +skill-seekers --version +``` + +### Generate Documentation + +```bash +# Example: Vue.js framework +skill-seekers scrape --config configs/vue.json + +# Package for Continue (markdown format) +skill-seekers package output/vue --target markdown + +# Extract documentation +# output/vue-markdown/SKILL.md +``` + +### Setup in Continue.dev + +**Option 1: Custom Context Provider** (recommended) + +Edit `~/.continue/config.json`: + +```json +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs", + "displayTitle": "Vue.js Documentation", + "description": "Vue.js framework expert knowledge" + } + } + ] +} +``` + +**Option 2: MCP Server** (for dynamic access) + +```bash +# Start Skill Seekers MCP server +skill-seekers mcp-server --port 8765 + +# Or as systemd service (Linux) +sudo systemctl enable skill-seekers-mcp +sudo systemctl start skill-seekers-mcp +``` + +Add to `~/.continue/config.json`: + +```json +{ + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } + } +} +``` + +**Option 3: Built-in @docs Provider** + +```json +{ + "contextProviders": [ + { + "name": "docs", + "params": { + "sites": [ + { + "title": "Vue.js", + "startUrl": "https://vuejs.org/guide/", + "rootUrl": "https://vuejs.org/" + } + ] + } + } + ] +} +``` + +### Test in Continue + +1. Open any project in your IDE +2. Open Continue panel (Cmd+L or Ctrl+L) +3. Type @ and select your context provider: + ``` + @vue-docs Create a Vue 3 component with Composition API + ``` +4. Verify Continue references your documentation + +--- + +## 📖 Detailed Setup Guide + +### Step 1: Choose Your Documentation Source + +**Option A: Use Preset Configs** (24+ frameworks) + +```bash +# List available presets +ls configs/ + +# Popular presets: +# - react.json, vue.json, angular.json (Frontend) +# - django.json, fastapi.json, flask.json (Backend) +# - kubernetes.json, docker.json (Infrastructure) +``` + +**Option B: Custom Documentation** + +Create `myframework-config.json`: + +```json +{ + "name": "myframework", + "description": "Custom framework documentation for Continue.dev", + "base_url": "https://docs.myframework.com/", + "selectors": { + "main_content": "article", + "title": "h1", + "code_blocks": "pre code" + }, + "categories": { + "getting_started": ["intro", "quickstart"], + "core_concepts": ["concepts", "architecture"], + "api": ["api", "reference"], + "best_practices": ["best-practices", "patterns"] + } +} +``` + +**Option C: GitHub Repository** + +```bash +# Analyze codebase patterns +skill-seekers github --repo facebook/react + +# Or local codebase +skill-seekers analyze --directory /path/to/repo --comprehensive +``` + +### Step 2: Optimize for Continue.dev + +**HTTP Context Provider** + +Continue supports HTTP-based context providers for maximum flexibility: + +```python +# custom_context_server.py +from fastapi import FastAPI +from skill_seekers.cli.doc_scraper import load_skill + +app = FastAPI() + +# Load documentation +vue_docs = load_skill("output/vue-markdown/SKILL.md") + +@app.get("/docs/{framework}") +async def get_framework_docs(framework: str, query: str = None): + """ + Return framework documentation as context. + + Args: + framework: Framework name (vue, react, django, etc.) + query: Optional search query for filtering + + Returns: + Context items for Continue.dev + """ + if query: + # Filter by query + filtered = search_docs(vue_docs, query) + content = "\n\n".join(filtered) + else: + # Return full docs + content = vue_docs + + return { + "contextItems": [ + { + "name": f"{framework.title()} Documentation", + "description": f"Complete {framework} framework knowledge", + "content": content + } + ] + } + +# Run with: uvicorn custom_context_server:app --port 8765 +``` + +**MCP Context Provider** + +For advanced users, expose via MCP: + +```json +{ + "contextProviders": [ + { + "name": "mcp", + "params": { + "serverName": "skill-seekers", + "contextItem": { + "type": "docs", + "name": "Framework Documentation" + } + } + } + ], + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } + } +} +``` + +**Built-in @docs Provider** + +Simplest approach for public documentation: + +```json +{ + "contextProviders": [ + { + "name": "docs", + "params": { + "sites": [ + { + "title": "Vue.js", + "startUrl": "https://vuejs.org/guide/", + "rootUrl": "https://vuejs.org/" + }, + { + "title": "Pinia", + "startUrl": "https://pinia.vuejs.org/", + "rootUrl": "https://pinia.vuejs.org/" + } + ] + } + } + ] +} +``` + +### Step 3: Configure for Multiple IDEs + +**VS Code Configuration** + +Location: `~/.continue/config.json` (global) or `.vscode/continue.json` (project) + +```json +{ + "models": [ + { + "title": "Claude Sonnet 4.5", + "provider": "anthropic", + "model": "claude-sonnet-4-5-20250929", + "apiKey": "${ANTHROPIC_API_KEY}" + } + ], + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs", + "displayTitle": "Vue.js Docs", + "description": "Vue.js framework knowledge" + } + } + ] +} +``` + +**JetBrains Configuration** + +Location: `~/.continue/config.json` (same file!) + +Continue.dev uses the SAME config file across all IDEs: + +```bash +# Edit once, works everywhere +vim ~/.continue/config.json + +# Test in VS Code +code my-vue-project/ + +# Test in IntelliJ IDEA +idea my-vue-project/ + +# Same context providers in both! +``` + +**Per-Project Configuration** + +```bash +# Create project-specific config +mkdir -p /path/to/project/.continue +cp ~/.continue/config.json /path/to/project/.continue/config.json + +# Edit for project needs +vim /path/to/project/.continue/config.json + +# Add project-specific context: +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs" + } + }, + { + "name": "http", + "params": { + "url": "http://localhost:8765/project/conventions", + "title": "project-conventions", + "displayTitle": "Project Conventions", + "description": "Company-specific patterns" + } + } + ] +} +``` + +### Step 4: Test and Refine + +**Test Context Access** + +In Continue panel: + +``` +@vue-docs Show me how to create a Vue 3 component with Composition API and TypeScript + +Expected: Continue references your documentation, shows correct patterns +``` + +**Verify Multi-IDE Consistency** + +```bash +# Open same project in VS Code +code my-project/ +# Type: @vue-docs Create a component +# Note the response + +# Open same project in IntelliJ +idea my-project/ +# Type: @vue-docs Create a component +# Response should be IDENTICAL +``` + +**Monitor Context Usage** + +Check Continue logs: + +```bash +# VS Code +Cmd+Shift+P → "Continue: Show Logs" + +# JetBrains +Tools → Continue → Show Logs + +# Look for: +# "Loaded context from http://localhost:8765/docs/vue" +# "Context items: 1, tokens: 5420" +``` + +--- + +## 🎨 Advanced Usage + +### Multi-Framework Projects + +**Full-Stack Vue + FastAPI** + +```bash +# Generate frontend context +skill-seekers scrape --config configs/vue.json +# Generate backend context +skill-seekers scrape --config configs/fastapi.json + +# Start context server with both +python custom_multi_context_server.py +``` + +**custom_multi_context_server.py:** + +```python +from fastapi import FastAPI +from skill_seekers.cli.doc_scraper import load_skill + +app = FastAPI() + +# Load multiple frameworks +vue_docs = load_skill("output/vue-markdown/SKILL.md") +fastapi_docs = load_skill("output/fastapi-markdown/SKILL.md") + +@app.get("/docs/{framework}") +async def get_docs(framework: str): + docs = { + "vue": vue_docs, + "fastapi": fastapi_docs + } + + if framework not in docs: + return {"error": "Framework not found"} + + return { + "contextItems": [ + { + "name": f"{framework.title()} Documentation", + "description": f"Expert knowledge for {framework}", + "content": docs[framework] + } + ] + } +``` + +**Continue config:** + +```json +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs", + "displayTitle": "Vue.js Frontend" + } + }, + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/fastapi", + "title": "fastapi-docs", + "displayTitle": "FastAPI Backend" + } + } + ] +} +``` + +Now use both: + +``` +@vue-docs @fastapi-docs Create a full-stack feature: +- Vue component for user registration +- FastAPI endpoint with validation +- Database model with SQLAlchemy +``` + +### Dynamic Context with RAG + +**Combine with Vector Search** + +```python +# rag_context_server.py +from fastapi import FastAPI +from langchain_community.vectorstores import Chroma +from langchain_openai import OpenAIEmbeddings +from skill_seekers.cli.package_skill import main as package + +app = FastAPI() + +# Load RAG pipeline +embeddings = OpenAIEmbeddings() +vectorstore = Chroma(persist_directory="./chroma_db", embedding_function=embeddings) + +@app.get("/docs/search") +async def search_docs(query: str, k: int = 5): + """ + Search documentation using RAG. + + Args: + query: Search query + k: Number of results + + Returns: + Top-k relevant snippets as context + """ + results = vectorstore.similarity_search(query, k=k) + + return { + "contextItems": [ + { + "name": f"Result {i+1}", + "description": doc.metadata.get("source", "Documentation"), + "content": doc.page_content + } + for i, doc in enumerate(results) + ] + } +``` + +**Continue config:** + +```json +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/search?query={query}", + "title": "rag-search", + "displayTitle": "RAG Search", + "description": "Search all documentation" + } + } + ] +} +``` + +### TypeScript Custom Context Provider + +**For Advanced Customization** + +Create `~/.continue/context/custom-rag.ts`: + +```typescript +import { ContextProvider, ContextItem } from "@continuedev/core"; + +class CustomRAGProvider implements ContextProvider { + title = "rag"; + displayTitle = "RAG Search"; + description = "Search internal documentation"; + + async getContextItems( + query: string, + extras: any + ): Promise { + // Query your RAG pipeline + const response = await fetch( + `http://localhost:8765/docs/search?query=${encodeURIComponent(query)}` + ); + + const data = await response.json(); + + return data.contextItems.map((item: any) => ({ + name: item.name, + description: item.description, + content: item.content, + })); + } +} + +export default CustomRAGProvider; +``` + +Register in `config.json`: + +```json +{ + "contextProviders": [ + { + "name": "custom", + "params": { + "modulePath": "~/.continue/context/custom-rag.ts" + } + } + ] +} +``` + +### Continue + Skill Seekers MCP Integration + +**Full MCP Setup** + +```bash +# Install Skill Seekers with MCP +pip install skill-seekers[mcp] + +# Start MCP server +python -m skill_seekers.mcp.server_fastmcp --transport stdio +``` + +**Continue config with MCP:** + +```json +{ + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": [ + "-m", + "skill_seekers.mcp.server_fastmcp", + "--transport", + "stdio" + ], + "env": { + "ANTHROPIC_API_KEY": "${env:ANTHROPIC_API_KEY}" + } + } + }, + "contextProviders": [ + { + "name": "mcp", + "params": { + "serverName": "skill-seekers", + "contextItem": { + "type": "docs", + "name": "Framework Documentation" + } + } + } + ] +} +``` + +Now Continue can: +- Query documentation via MCP +- Scrape docs on-demand +- Package skills dynamically + +--- + +## 💡 Best Practices + +### 1. Use IDE-Agnostic Configuration + +**Bad: Duplicate Configs** + +```bash +# Different configs for each IDE +~/.continue/vscode-config.json +~/.continue/jetbrains-config.json +~/.continue/vim-config.json +``` + +**Good: Single Source of Truth** + +```bash +# One config for all IDEs +~/.continue/config.json + +# Continue automatically loads from here in: +# - VS Code +# - JetBrains (IntelliJ, PyCharm, WebStorm) +# - Vim/Neovim (with Continue plugin) +``` + +### 2. Organize Context Providers + +```json +{ + "contextProviders": [ + // Core frameworks (always needed) + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-core", + "displayTitle": "Vue.js Core" + } + }, + // Ecosystem libraries (optional) + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/pinia", + "title": "pinia", + "displayTitle": "Pinia State Management" + } + }, + // Project-specific (highest priority) + { + "name": "http", + "params": { + "url": "http://localhost:8765/project/conventions", + "title": "conventions", + "displayTitle": "Project Conventions" + } + } + ] +} +``` + +### 3. Cache Documentation Locally + +```python +# cached_context_server.py +from fastapi import FastAPI +from functools import lru_cache +import hashlib + +app = FastAPI() + +@lru_cache(maxsize=100) +def get_cached_docs(framework: str) -> str: + """Cache documentation in memory.""" + return load_skill(f"output/{framework}-markdown/SKILL.md") + +@app.get("/docs/{framework}") +async def get_docs(framework: str): + # Returns cached version (fast!) + content = get_cached_docs(framework) + + return { + "contextItems": [{ + "name": f"{framework.title()} Docs", + "content": content + }] + } +``` + +### 4. Use Environment Variables + +```json +{ + "models": [ + { + "title": "Claude Sonnet", + "provider": "anthropic", + "model": "claude-sonnet-4-5-20250929", + "apiKey": "${ANTHROPIC_API_KEY}" // From environment + } + ], + "contextProviders": [ + { + "name": "http", + "params": { + "url": "${CONTEXT_SERVER_URL}/docs/vue", // Configurable + "title": "vue-docs" + } + } + ] +} +``` + +### 5. Update Documentation Regularly + +```bash +# Quarterly update script +#!/bin/bash + +# Update Vue docs +skill-seekers scrape --config configs/vue.json +skill-seekers package output/vue --target markdown + +# Update FastAPI docs +skill-seekers scrape --config configs/fastapi.json +skill-seekers package output/fastapi --target markdown + +# Restart context server +systemctl restart skill-seekers-context-server + +echo "✅ Documentation updated!" +``` + +--- + +## 🔥 Real-World Examples + +### Example 1: Vue.js Full-Stack Development + +**Project Structure:** + +``` +my-vue-app/ +├── .continue/ +│ └── config.json # Project-specific Continue config +├── frontend/ # Vue 3 app +└── backend/ # FastAPI server +``` + +**.continue/config.json:** + +```json +{ + "models": [ + { + "title": "Claude Sonnet", + "provider": "anthropic", + "model": "claude-sonnet-4-5-20250929", + "apiKey": "${ANTHROPIC_API_KEY}" + } + ], + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs", + "displayTitle": "Vue.js 3", + "description": "Vue 3 Composition API patterns" + } + }, + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/pinia", + "title": "pinia-docs", + "displayTitle": "Pinia", + "description": "State management patterns" + } + }, + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/fastapi", + "title": "fastapi-docs", + "displayTitle": "FastAPI", + "description": "Backend API patterns" + } + } + ] +} +``` + +**Using in Continue (Any IDE):** + +``` +In Continue panel: + +@vue-docs @pinia-docs Create a Vue component: +- User profile display +- Load data from Pinia store +- Composition API with TypeScript +- Responsive design + +Continue will: +1. ✅ Use Composition API (from vue-docs) +2. ✅ Access Pinia store correctly (from pinia-docs) +3. ✅ Add TypeScript types (from vue-docs) +4. ✅ Follow Vue 3 best practices + +Then: + +@fastapi-docs Create backend endpoint: +- GET /api/v1/users/:id +- Async database query +- Pydantic response model + +Continue will: +1. ✅ Use async/await (from fastapi-docs) +2. ✅ Dependency injection (from fastapi-docs) +3. ✅ Pydantic models (from fastapi-docs) +``` + +### Example 2: Multi-IDE Consistency + +**Scenario:** Team uses different IDEs + +**Team Members:** +- Alice: VS Code +- Bob: IntelliJ IDEA +- Charlie: PyCharm + +**Setup (Once):** + +```bash +# 1. Generate documentation +skill-seekers scrape --config configs/django.json +skill-seekers package output/django --target markdown + +# 2. Start context server (team server) +python context_server.py --host 0.0.0.0 --port 8765 + +# 3. Share config (Git repository) +cat > .continue/config.json << 'EOF' +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://team-server:8765/docs/django", + "title": "django-docs", + "displayTitle": "Django", + "description": "Team Django patterns" + } + } + ] +} +EOF + +git add .continue/config.json +git commit -m "Add Continue.dev configuration" +git push +``` + +**Result:** + +- ✅ Alice (VS Code) gets Django patterns +- ✅ Bob (IntelliJ) gets SAME Django patterns +- ✅ Charlie (PyCharm) gets SAME Django patterns +- ✅ One config file, three IDEs, consistent AI suggestions + +--- + +## 🐛 Troubleshooting + +### Issue: Context Provider Not Loading + +**Symptoms:** +- @mention doesn't show your provider +- Continue ignores documentation + +**Solutions:** + +1. **Check config location** + ```bash + # Global config + cat ~/.continue/config.json + + # Project config (takes precedence) + cat .continue/config.json + + # Verify contextProviders array exists + ``` + +2. **Verify HTTP server is running** + ```bash + curl http://localhost:8765/docs/vue + + # Should return JSON with contextItems + ``` + +3. **Check Continue logs** + ``` + VS Code: Cmd+Shift+P → "Continue: Show Logs" + JetBrains: Tools → Continue → Show Logs + + Look for errors like: + "Failed to load context from http://localhost:8765/docs/vue" + ``` + +4. **Reload Continue** + ``` + VS Code: Cmd+Shift+P → "Developer: Reload Window" + JetBrains: File → Invalidate Caches → Restart + ``` + +### Issue: MCP Server Not Connecting + +**Error:** +> "Failed to start MCP server: skill-seekers" + +**Solutions:** + +1. **Verify installation** + ```bash + pip show skill-seekers + # Check [mcp] extra is installed + ``` + +2. **Test MCP server directly** + ```bash + python -m skill_seekers.mcp.server_fastmcp --transport stdio + # Should start without errors + # Ctrl+C to exit + ``` + +3. **Check Python path** + ```json + { + "mcpServers": { + "skill-seekers": { + "command": "/usr/local/bin/python3", // Absolute path + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } + } + } + ``` + +4. **Check environment variables** + ```bash + echo $ANTHROPIC_API_KEY + # Should be set for AI enhancement features + ``` + +### Issue: Different Results in Different IDEs + +**Symptoms:** +- VS Code suggestions differ from JetBrains +- Context inconsistent across IDEs + +**Solutions:** + +1. **Use same config file** + ```bash + # Ensure both IDEs use ~/.continue/config.json + # NOT project-specific configs + + # Check VS Code + ls ~/.continue/config.json + + # Check JetBrains (uses same file!) + ls ~/.continue/config.json + ``` + +2. **Verify context server URL** + ```bash + # Must be accessible from all IDEs + # Use localhost or team server IP + + # Test from both IDEs: + curl http://localhost:8765/docs/vue + ``` + +3. **Clear Continue cache** + ```bash + # Remove cached context + rm -rf ~/.continue/cache/ + + # Restart IDEs + ``` + +--- + +## 📊 Before vs After Comparison + +| Aspect | Before Skill Seekers | After Skill Seekers | +|--------|---------------------|---------------------| +| **Context Source** | Manual @-mentions | Automatic context providers | +| **IDE Consistency** | Different across IDEs | Same config, all IDEs | +| **Setup Time** | Manual per IDE (hours) | One config (5 min) | +| **AI Knowledge** | Generic patterns | Framework-specific best practices | +| **Updates** | Manual editing | Re-scrape + restart | +| **Multi-Framework** | Context juggling | Multiple providers | +| **Team Sharing** | Manual duplication | Git-tracked config | +| **Documentation** | Built-in @docs only | Custom HTTP providers + MCP | + +--- + +## 🤝 Community & Support + +- **Questions:** [GitHub Discussions](https://github.com/yusufkaraaslan/Skill_Seekers/discussions) +- **Issues:** [GitHub Issues](https://github.com/yusufkaraaslan/Skill_Seekers/issues) +- **Website:** [skillseekersweb.com](https://skillseekersweb.com/) +- **Continue.dev Docs:** [docs.continue.dev](https://docs.continue.dev/) +- **Continue.dev GitHub:** [github.com/continuedev/continue](https://github.com/continuedev/continue) + +--- + +## 📚 Related Guides + +- [Cursor Integration](CURSOR.md) - IDE-specific approach +- [Windsurf Integration](WINDSURF.md) - Alternative IDE +- [Cline Integration](CLINE.md) - VS Code extension with MCP +- [LangChain Integration](LANGCHAIN.md) - Build RAG pipelines +- [Context Providers Reference](https://docs.continue.dev/customization/context-providers) + +--- + +## 📖 Next Steps + +1. **Try another framework:** `skill-seekers scrape --config configs/react.json` +2. **Set up team server:** Share context across team +3. **Build RAG pipeline:** Deep search with `--target langchain` +4. **Create custom TypeScript provider:** Advanced customization +5. **Multi-IDE setup:** Test consistency across VS Code + JetBrains + +--- + +**Sources:** +- [Continue.dev Documentation](https://docs.continue.dev/) +- [config.json Reference](https://docs.continue.dev/reference/config) +- [Context Providers Guide](https://docs.continue.dev/customization/context-providers) +- [MCP with Continue.dev](https://medium.com/@ashfaqbs/model-context-protocol-mcp-with-continue-dev-95f04752299a) +- [Continue.dev Configuration Guide](https://www.askcodi.com/documentation/integrations/continue/complete-guide-to-continue-dev) +- [MCP Server Implementation Guide](https://skywork.ai/skypage/en/Model-Context-Protocol-(MCP)-Server-A-Comprehensive-Guide-to-Continue-MCP-Server-for-AI-Engineers/1972129737880076288) diff --git a/docs/integrations/INTEGRATIONS.md b/docs/integrations/INTEGRATIONS.md new file mode 100644 index 0000000..e195769 --- /dev/null +++ b/docs/integrations/INTEGRATIONS.md @@ -0,0 +1,549 @@ +# AI System Integrations with Skill Seekers + +**Universal Preprocessor:** Transform documentation into structured knowledge for any AI system + +--- + +## 🤔 Which Integration Should I Use? + +| Your Goal | Recommended Tool | Format | Setup Time | Guide | +|-----------|-----------------|--------|------------|-------| +| Build RAG with Python | LangChain | `--target langchain` | 5 min | [Guide](LANGCHAIN.md) | +| Query engine from docs | LlamaIndex | `--target llama-index` | 5 min | [Guide](LLAMA_INDEX.md) | +| Vector database only | Pinecone/Weaviate | `--target [db]` | 3 min | [Guide](PINECONE.md) | +| AI coding (VS Code fork) | Cursor | `--target claude` | 5 min | [Guide](CURSOR.md) | +| AI coding (Windsurf) | Windsurf | `--target markdown` | 5 min | [Guide](WINDSURF.md) | +| AI coding (VS Code ext) | Cline (MCP) | `--target claude` | 10 min | [Guide](CLINE.md) | +| AI coding (any IDE) | Continue.dev | `--target markdown` | 5 min | [Guide](CONTINUE_DEV.md) | +| Claude AI chat | Claude | `--target claude` | 3 min | [Guide](CLAUDE.md) | +| Chunked for RAG | Any + chunking | `--chunk-for-rag` | + 2 min | [RAG Guide](RAG_PIPELINES.md) | + +--- + +## 📚 RAG & Vector Databases + +### Production-Ready RAG Frameworks + +Transform documentation into RAG-ready formats for AI-powered search and retrieval: + +| Framework | Users | Format | Best For | Guide | +|-----------|-------|--------|----------|-------| +| **[LangChain](LANGCHAIN.md)** | 500K+ | Document | Python RAG, most popular | [Setup →](LANGCHAIN.md) | +| **[LlamaIndex](LLAMA_INDEX.md)** | 200K+ | TextNode | Q&A focus, query engine | [Setup →](LLAMA_INDEX.md) | +| **[Haystack](HAYSTACK.md)** | 50K+ | Document | Enterprise, multi-language | *Coming in v2.11.0* | + +**Quick Example:** +```bash +# Generate LangChain documents +skill-seekers scrape --config configs/react.json +skill-seekers package output/react --target langchain + +# Use in RAG pipeline +python examples/langchain-rag-pipeline/quickstart.py +``` + +### Vector Database Integrations + +Direct upload to vector databases without RAG frameworks: + +| Database | Type | Best For | Guide | +|----------|------|----------|-------| +| **[Pinecone](PINECONE.md)** | Cloud | Production, serverless | [Setup →](PINECONE.md) | +| **[Weaviate](WEAVIATE.md)** | Self-hosted/Cloud | Enterprise, GraphQL | [Setup →](WEAVIATE.md) | +| **[Chroma](CHROMA.md)** | Local | Development, embeddings included | [Setup →](CHROMA.md) | +| **[FAISS](FAISS.md)** | Local | High performance, Facebook | [Setup →](FAISS.md) | +| **[Qdrant](QDRANT.md)** | Self-hosted/Cloud | Rust engine, filtering | [Setup →](QDRANT.md) | + +**Quick Example:** +```bash +# Generate Pinecone format +skill-seekers scrape --config configs/fastapi.json +skill-seekers package output/fastapi --target pinecone + +# Upsert to Pinecone +python examples/pinecone-upsert/quickstart.py +``` + +--- + +## 💻 AI Coding Assistants + +### IDE-Native AI Tools + +Give AI coding assistants expert knowledge of your frameworks: + +| Tool | Type | IDEs | Format | Setup | Guide | +|------|------|------|--------|-------|-------| +| **[Cursor](CURSOR.md)** | IDE (VS Code fork) | Cursor IDE | `.cursorrules` | 5 min | [Setup →](CURSOR.md) | +| **[Windsurf](WINDSURF.md)** | IDE (Codeium) | Windsurf IDE | `.windsurfrules` | 5 min | [Setup →](WINDSURF.md) | +| **[Cline](CLINE.md)** | VS Code Extension | VS Code | `.clinerules` + MCP | 10 min | [Setup →](CLINE.md) | +| **[Continue.dev](CONTINUE_DEV.md)** | Plugin | VS Code, JetBrains, Vim | HTTP context | 5 min | [Setup →](CONTINUE_DEV.md) | + +**Quick Example:** +```bash +# For any AI coding assistant (Cursor, Windsurf, Cline, Continue.dev) +skill-seekers scrape --config configs/django.json +skill-seekers package output/django --target markdown # or --target claude + +# Copy to your project +cp output/django-markdown/SKILL.md my-project/.cursorrules # or appropriate config +``` + +**Comparison:** + +| Feature | Cursor | Windsurf | Cline | Continue.dev | +|---------|--------|----------|-------|--------------| +| **IDE Type** | Fork (VS Code) | Native IDE | Extension | Plugin (multi-IDE) | +| **Config File** | `.cursorrules` | `.windsurfrules` | `.clinerules` | HTTP context provider | +| **Multi-IDE** | ❌ (Cursor only) | ❌ (Windsurf only) | ❌ (VS Code only) | ✅ (All IDEs) | +| **MCP Support** | ✅ | ✅ | ✅ | ✅ | +| **Character Limit** | No limit | 12K chars (6K per file) | No limit | No limit | +| **Setup Complexity** | Easy ⭐ | Easy ⭐ | Medium ⭐⭐ | Easy ⭐ | +| **Team Sharing** | Git-tracked file | Git-tracked files | Git-tracked file | HTTP server | + +--- + +## 🎯 AI Chat Platforms + +Upload documentation as custom skills to AI chat platforms: + +| Platform | Provider | Format | Best For | Guide | +|----------|----------|--------|----------|-------| +| **[Claude](CLAUDE.md)** | Anthropic | ZIP + YAML | Claude.ai Projects | [Setup →](CLAUDE.md) | +| **[Gemini](GEMINI_INTEGRATION.md)** | Google | tar.gz | Gemini AI | [Setup →](GEMINI_INTEGRATION.md) | +| **[ChatGPT](OPENAI_INTEGRATION.md)** | OpenAI | ZIP + Vector Store | GPT Actions | [Setup →](OPENAI_INTEGRATION.md) | + +**Quick Example:** +```bash +# Generate Claude skill +skill-seekers scrape --config configs/vue.json +skill-seekers package output/vue --target claude + +# Upload to Claude +skill-seekers upload output/vue-claude.zip --target claude +``` + +--- + +## 🧠 Choosing the Right Integration + +### By Use Case + +| Your Goal | Best Integration | Why? | Setup Time | +|-----------|-----------------|------|------------| +| **Build Python RAG pipeline** | LangChain | Most popular, 500K+ users, extensive docs | 5 min | +| **Query engine from docs** | LlamaIndex | Optimized for Q&A, built-in persistence | 5 min | +| **Enterprise RAG system** | Haystack | Production-ready, multi-language support | 10 min | +| **Vector DB only (no framework)** | Pinecone/Weaviate/Chroma | Direct upload, no framework overhead | 3 min | +| **AI coding (VS Code fork)** | Cursor | Best integration, native `.cursorrules` | 5 min | +| **AI coding (flow-based)** | Windsurf | Unique flow paradigm, Codeium AI | 5 min | +| **AI coding (VS Code ext)** | Cline | Claude in VS Code, MCP integration | 10 min | +| **AI coding (any IDE)** | Continue.dev | Works everywhere, open-source | 5 min | +| **Chat with documentation** | Claude/Gemini/ChatGPT | Direct upload as custom skill | 3 min | + +### By Technical Requirements + +| Requirement | Compatible Integrations | +|-------------|-------------------------| +| **Python required** | LangChain, LlamaIndex, Haystack, all vector DBs | +| **No dependencies** | Cursor, Windsurf, Cline, Continue.dev (markdown export) | +| **Cloud-hosted** | Pinecone, Claude, Gemini, ChatGPT | +| **Self-hosted** | Chroma, FAISS, Qdrant, Continue.dev | +| **Multi-language** | Haystack, Continue.dev | +| **VS Code specific** | Cursor, Cline, Continue.dev | +| **IDE agnostic** | LangChain, LlamaIndex, Continue.dev | +| **Real-time updates** | Continue.dev (HTTP server), MCP servers | + +### By Team Size + +| Team Size | Recommended Stack | Why? | +|-----------|------------------|------| +| **Solo developer** | Cursor + Claude + Chroma (local) | Simple setup, no infrastructure | +| **Small team (2-5)** | Continue.dev + LangChain + Pinecone | IDE-agnostic, cloud vector DB | +| **Medium team (5-20)** | Windsurf/Cursor + LlamaIndex + Weaviate | Good balance of features | +| **Enterprise (20+)** | Continue.dev + Haystack + Qdrant/Weaviate | Production-ready, scalable | + +### By Development Environment + +| Environment | Recommended Tools | Setup | +|-------------|------------------|-------| +| **VS Code Only** | Cursor (fork) or Cline (extension) | `.cursorrules` or `.clinerules` | +| **JetBrains Only** | Continue.dev | HTTP context provider | +| **Mixed IDEs** | Continue.dev | Same config, all IDEs | +| **Vim/Neovim** | Continue.dev | Plugin + HTTP server | +| **Multiple Frameworks** | Continue.dev + RAG pipeline | HTTP server + vector search | + +--- + +## 🚀 Quick Decision Tree + +``` +Do you need RAG/search? +├─ Yes → Use RAG framework (LangChain/LlamaIndex/Haystack) +│ ├─ Beginner? → LangChain (most docs) +│ ├─ Q&A focus? → LlamaIndex (optimized for queries) +│ └─ Enterprise? → Haystack (production-ready) +│ +└─ No → Use AI coding tool or chat platform + ├─ Need AI coding assistant? + │ ├─ Use VS Code? + │ │ ├─ Want native fork? → Cursor + │ │ └─ Want extension? → Cline + │ ├─ Use other IDE? → Continue.dev + │ ├─ Use Windsurf? → Windsurf + │ └─ Team uses mixed IDEs? → Continue.dev + │ + └─ Just chat with docs? → Claude/Gemini/ChatGPT +``` + +--- + +## 🎨 Common Patterns + +### Pattern 1: RAG + AI Coding + +**Best for:** Deep documentation search + context-aware coding + +```bash +# 1. Generate RAG pipeline (LangChain) +skill-seekers scrape --config configs/django.json +skill-seekers package output/django --target langchain --chunk-for-rag + +# 2. Generate AI coding context (Cursor) +skill-seekers package output/django --target claude + +# 3. Use both: +# - Cursor: Quick context for common patterns +# - RAG: Deep search for complex questions + +# Copy to project +cp output/django-claude/SKILL.md my-project/.cursorrules + +# Query RAG when needed +python rag_search.py "How to implement custom Django middleware?" +``` + +### Pattern 2: Multi-IDE Team Consistency + +**Best for:** Teams using different IDEs + +```bash +# 1. Generate documentation +skill-seekers scrape --config configs/react.json + +# 2. Set up Continue.dev HTTP server (team server) +python context_server.py --host 0.0.0.0 --port 8765 + +# 3. Team members configure Continue.dev: +# ~/.continue/config.json (same for all IDEs) +{ + "contextProviders": [{ + "name": "http", + "params": { + "url": "http://team-server:8765/docs/react", + "title": "react-docs" + } + }] +} + +# Result: VS Code, IntelliJ, PyCharm all use same context! +``` + +### Pattern 3: Full-Stack Development + +**Best for:** Backend + Frontend with different frameworks + +```bash +# 1. Generate backend context (FastAPI) +skill-seekers scrape --config configs/fastapi.json +skill-seekers package output/fastapi --target markdown + +# 2. Generate frontend context (Vue) +skill-seekers scrape --config configs/vue.json +skill-seekers package output/vue --target markdown + +# 3. For Cursor (modular rules): +cat output/fastapi-markdown/SKILL.md >> .cursorrules +echo "\n\n# Frontend Framework\n" >> .cursorrules +cat output/vue-markdown/SKILL.md >> .cursorrules + +# 4. For Continue.dev (multiple providers): +{ + "contextProviders": [ + {"name": "http", "params": {"url": "http://localhost:8765/docs/fastapi"}}, + {"name": "http", "params": {"url": "http://localhost:8765/docs/vue"}} + ] +} + +# Now AI knows BOTH backend AND frontend patterns! +``` + +### Pattern 4: Documentation + Codebase Analysis + +**Best for:** Custom internal frameworks + +```bash +# 1. Scrape public documentation +skill-seekers scrape --config configs/custom-framework.json + +# 2. Analyze internal codebase +skill-seekers analyze --directory /path/to/internal/repo --comprehensive + +# 3. Merge both: +skill-seekers merge-sources \ + --docs output/custom-framework \ + --codebase output/internal-repo \ + --output output/complete-knowledge + +# 4. Package for any platform +skill-seekers package output/complete-knowledge --target [platform] + +# Result: Documentation + Real-world code patterns! +``` + +--- + +## 💡 Best Practices + +### 1. Start Simple, Scale Up + +**Phase 1:** Single framework, single tool +```bash +# Week 1: Just Cursor + React +skill-seekers scrape --config configs/react.json +skill-seekers package output/react --target claude +cp output/react-claude/SKILL.md .cursorrules +``` + +**Phase 2:** Add RAG for deep search +```bash +# Week 2: Add LangChain for complex queries +skill-seekers package output/react --target langchain --chunk-for-rag +# Now you have: Cursor (quick) + RAG (deep) +``` + +**Phase 3:** Scale to team +```bash +# Week 3: Continue.dev HTTP server for team +python context_server.py --host 0.0.0.0 +# Team members configure Continue.dev +``` + +### 2. Layer Your Context + +**Priority order:** + +1. **Project conventions** (highest priority) + - Custom patterns + - Team standards + - Company guidelines + +2. **Framework documentation** (medium priority) + - Official best practices + - Common patterns + - API reference + +3. **RAG search** (lowest priority) + - Deep documentation search + - Edge cases + - Historical context + +**Example (Cursor):** +```bash +# Layer 1: Project conventions (loaded first) +cat > .cursorrules << 'EOF' +# Project-Specific Patterns (HIGHEST PRIORITY) +Always use async/await for database operations. +Never use 'any' type in TypeScript. +EOF + +# Layer 2: Framework docs (loaded second) +cat output/react-markdown/SKILL.md >> .cursorrules + +# Layer 3: RAG search (when needed) +# Query separately for deep questions +``` + +### 3. Update Regularly + +**Monthly:** Framework documentation +```bash +# Check for framework updates +skill-seekers scrape --config configs/react.json +# If new version, re-package +skill-seekers package output/react --target [your-platform] +``` + +**Quarterly:** Codebase analysis +```bash +# Re-analyze internal codebase for new patterns +skill-seekers analyze --directory . --comprehensive +``` + +**Yearly:** Architecture review +```bash +# Review and update project conventions +# Check if new integrations are available +``` + +### 4. Measure Effectiveness + +**Track these metrics:** + +- **Context hit rate:** How often AI references your documentation +- **Code quality:** Fewer pattern violations after adding context +- **Development speed:** Time saved on common tasks +- **Team consistency:** Similar code patterns across team members + +**Example monitoring:** +```python +# Track Cursor suggestions quality +# Compare before/after adding .cursorrules + +# Before: 60% generic suggestions, 40% framework-specific +# After: 20% generic suggestions, 80% framework-specific +# Improvement: 2x better context awareness +``` + +### 5. Share with Team + +**Git-tracked configs:** +```bash +# Add to version control +git add .cursorrules +git add .clinerules +git add .continue/config.json +git commit -m "Add AI assistant configuration" + +# Team benefits immediately +git pull # New team member gets context +``` + +**Documentation:** +```markdown +# README.md + +## AI Assistant Setup + +This project uses Cursor with custom rules: + +1. Install Cursor: https://cursor.sh/ +2. Open project: `cursor .` +3. Rules auto-load from `.cursorrules` +4. Start coding with AI context! +``` + +--- + +## 📖 Complete Guides + +### RAG & Vector Databases +- **[LangChain Integration](LANGCHAIN.md)** - 500K+ users, Document format +- **[LlamaIndex Integration](LLAMA_INDEX.md)** - 200K+ users, TextNode format +- **[Pinecone Integration](PINECONE.md)** - Cloud-native vector database +- **[Weaviate Integration](WEAVIATE.md)** - Enterprise-grade, GraphQL API +- **[Chroma Integration](CHROMA.md)** - Local-first, embeddings included +- **[RAG Pipelines Guide](RAG_PIPELINES.md)** - End-to-end RAG setup + +### AI Coding Assistants +- **[Cursor Integration](CURSOR.md)** - VS Code fork with AI (`.cursorrules`) +- **[Windsurf Integration](WINDSURF.md)** - Codeium's IDE with AI flows +- **[Cline Integration](CLINE.md)** - Claude in VS Code (MCP integration) +- **[Continue.dev Integration](CONTINUE_DEV.md)** - Multi-platform, open-source + +### AI Chat Platforms +- **[Claude Integration](CLAUDE.md)** - Anthropic's AI assistant +- **[Gemini Integration](GEMINI_INTEGRATION.md)** - Google's AI +- **[ChatGPT Integration](OPENAI_INTEGRATION.md)** - OpenAI + +### Advanced Topics +- **[Multi-LLM Support](MULTI_LLM_SUPPORT.md)** - Platform comparison +- **[MCP Setup Guide](../MCP_SETUP.md)** - Model Context Protocol + +--- + +## 🚀 Quick Start Examples + +### For RAG Pipelines: +```bash +# Generate LangChain documents +skill-seekers scrape --config configs/react.json +skill-seekers package output/react --target langchain + +# Use in RAG pipeline +python examples/langchain-rag-pipeline/quickstart.py +``` + +### For AI Coding: +```bash +# Generate Cursor rules +skill-seekers scrape --config configs/django.json +skill-seekers package output/django --target claude + +# Copy to project +cp output/django-claude/SKILL.md my-project/.cursorrules +``` + +### For Vector Databases: +```bash +# Generate Pinecone format +skill-seekers scrape --config configs/fastapi.json +skill-seekers package output/fastapi --target pinecone + +# Upsert to Pinecone +python examples/pinecone-upsert/quickstart.py +``` + +### For Multi-IDE Teams: +```bash +# Generate documentation +skill-seekers scrape --config configs/vue.json + +# Start HTTP context server +python examples/continue-dev-universal/context_server.py + +# Configure Continue.dev (same config, all IDEs) +# ~/.continue/config.json +``` + +--- + +## 🎯 Platform Comparison Matrix + +| Feature | LangChain | LlamaIndex | Cursor | Windsurf | Cline | Continue.dev | Claude Chat | +|---------|-----------|------------|--------|----------|-------|--------------|-------------| +| **Setup Time** | 5 min | 5 min | 5 min | 5 min | 10 min | 5 min | 3 min | +| **Python Required** | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ | +| **Works Offline** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | +| **Multi-IDE** | ✅ | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | +| **Real-time Updates** | ✅ | ✅ | ❌ | ❌ | ✅ (MCP) | ✅ | ❌ | +| **Team Sharing** | Git | Git | Git | Git | Git | HTTP server | Cloud | +| **Context Limit** | No limit | No limit | No limit | 12K chars | No limit | No limit | 200K tokens | +| **Custom Search** | ✅ | ✅ | ❌ | ❌ | ❌ | ✅ | ❌ | +| **Best For** | RAG pipelines | Q&A engines | VS Code users | Windsurf users | Claude in VS Code | Multi-IDE teams | Quick chat | + +--- + +## 🤝 Community & Support + +- **Questions:** [GitHub Discussions](https://github.com/yusufkaraaslan/Skill_Seekers/discussions) +- **Issues:** [GitHub Issues](https://github.com/yusufkaraaslan/Skill_Seekers/issues) +- **Website:** [skillseekersweb.com](https://skillseekersweb.com/) +- **Examples:** [GitHub Examples](https://github.com/yusufkaraaslan/Skill_Seekers/tree/main/examples) + +--- + +## 📖 What's Next? + +1. **Choose your integration** from the table above +2. **Follow the setup guide** (5-10 minutes) +3. **Test with your framework** using provided examples +4. **Customize for your project** with project-specific patterns +5. **Share with your team** via Git or HTTP server + +**Need help deciding?** Ask in [GitHub Discussions](https://github.com/yusufkaraaslan/Skill_Seekers/discussions) + +--- + +**Last Updated:** February 7, 2026 +**Skill Seekers Version:** v2.10.0+ diff --git a/docs/integrations/WINDSURF.md b/docs/integrations/WINDSURF.md new file mode 100644 index 0000000..b92322d --- /dev/null +++ b/docs/integrations/WINDSURF.md @@ -0,0 +1,986 @@ +# Using Skill Seekers with Windsurf IDE + +**Last Updated:** February 7, 2026 +**Status:** Production Ready +**Difficulty:** Easy ⭐ + +--- + +## 🎯 The Problem + +Windsurf IDE (by Codeium) offers powerful AI flows and Cascade agent, but: + +- **Generic Knowledge** - AI doesn't know your project-specific frameworks or internal patterns +- **Manual Context** - Copy-pasting documentation into chat is tedious and breaks flow +- **Limited Memory** - Memory feature requires manual teaching through conversations +- **Context Limits** - Rules files are limited to 12,000 characters combined + +**Example:** +> "When building a FastAPI app in Windsurf, Cascade might suggest outdated patterns or miss framework-specific best practices. You want the AI to reference comprehensive documentation without hitting character limits." + +--- + +## ✨ The Solution + +Use Skill Seekers to create **custom rules** for Windsurf's Cascade agent: + +1. **Generate structured docs** from any framework or codebase +2. **Package as .windsurfrules** - Windsurf's markdown rules format +3. **Automatic Context** - Cascade references your docs in AI flows +4. **Modular Rules** - Split large docs into multiple rule files (6K chars each) + +**Result:** +Windsurf's Cascade becomes an expert in your frameworks with persistent, automatic context that fits within character limits. + +--- + +## 🚀 Quick Start (5 Minutes) + +### Prerequisites + +- Windsurf IDE installed (https://windsurf.com/) +- Python 3.10+ (for Skill Seekers) + +### Installation + +```bash +# Install Skill Seekers +pip install skill-seekers + +# Verify installation +skill-seekers --version +``` + +### Generate .windsurfrules + +```bash +# Example: FastAPI framework +skill-seekers scrape --config configs/fastapi.json + +# Package for Windsurf (markdown format) +skill-seekers package output/fastapi --target markdown + +# Extract SKILL.md +# output/fastapi-markdown/SKILL.md +``` + +### Setup in Windsurf + +**Option 1: Project-Specific Rules** (recommended) + +```bash +# Create rules directory +mkdir -p /path/to/your/project/.windsurf/rules + +# Copy as rules.md +cp output/fastapi-markdown/SKILL.md /path/to/your/project/.windsurf/rules/fastapi.md +``` + +**Option 2: Legacy .windsurfrules** (single file) + +```bash +# Copy to project root (legacy format) +cp output/fastapi-markdown/SKILL.md /path/to/your/project/.windsurfrules +``` + +**Option 3: Split Large Documentation** (for >6K char files) + +```bash +# Skill Seekers automatically splits large files +skill-seekers package output/react --target markdown --split-rules + +# This creates multiple rule files: +# output/react-markdown/rules/ +# ├── core-concepts.md (5,800 chars) +# ├── hooks-reference.md (5,400 chars) +# ├── components-guide.md (5,900 chars) +# └── best-practices.md (4,200 chars) + +# Copy all rules +cp -r output/react-markdown/rules/* /path/to/your/project/.windsurf/rules/ +``` + +### Test in Windsurf + +1. Open your project in Windsurf +2. Start Cascade (Cmd+L or Ctrl+L) +3. Test knowledge: + ``` + "Create a FastAPI endpoint with async database queries using best practices" + ``` +4. Verify Cascade references your documentation + +--- + +## 📖 Detailed Setup Guide + +### Step 1: Choose Your Documentation Source + +**Option A: Use Preset Configs** (24+ frameworks) + +```bash +# List available presets +ls configs/ + +# Popular presets: +# - react.json, vue.json, angular.json (Frontend) +# - django.json, fastapi.json, flask.json (Backend) +# - godot.json, unity.json (Game Development) +# - kubernetes.json, docker.json (Infrastructure) +``` + +**Option B: Custom Documentation** + +Create `myframework-config.json`: + +```json +{ + "name": "myframework", + "description": "Custom framework documentation for Windsurf", + "base_url": "https://docs.myframework.com/", + "selectors": { + "main_content": "article", + "title": "h1", + "code_blocks": "pre code" + }, + "categories": { + "getting_started": ["intro", "quickstart", "installation"], + "core_concepts": ["concepts", "architecture", "patterns"], + "api": ["api", "reference", "methods"], + "guides": ["guide", "tutorial", "how-to"], + "best_practices": ["best-practices", "tips", "patterns"] + } +} +``` + +**Option C: GitHub Repository** + +```bash +# Analyze open-source codebase +skill-seekers github --repo facebook/react + +# Or local codebase +skill-seekers analyze --directory /path/to/repo --comprehensive +``` + +### Step 2: Optimize for Windsurf + +**Character Limit Awareness** + +Windsurf has strict limits: +- **Per rule file:** 6,000 characters max +- **Combined global + local:** 12,000 characters max + +**Use split-rules flag:** + +```bash +# Automatically split large documentation +skill-seekers package output/django --target markdown --split-rules + +# This creates modular rules: +# - core-concepts.md (Always On) +# - api-reference.md (Model Decision) +# - best-practices.md (Always On) +# - troubleshooting.md (Manual @mention) +``` + +**Rule Activation Modes** + +Configure each rule file's activation mode in frontmatter: + +```markdown +--- +name: "FastAPI Core Concepts" +activation: "always-on" +priority: "high" +--- + +# FastAPI Framework Expert + +You are an expert in FastAPI... +``` + +Activation modes: +- **Always On** - Applied to every request (use for core concepts) +- **Model Decision** - AI decides when to use (use for specialized topics) +- **Manual** - Only when @mentioned (use for troubleshooting) +- **Scheduled** - Time-based activation (use for context switching) + +### Step 3: Configure Windsurf Settings + +**Enable Rules** + +1. Open Windsurf Settings (Cmd+, or Ctrl+,) +2. Search for "rules" +3. Enable "Use Custom Rules" +4. Set rules directory: `.windsurf/rules` + +**Memory Integration** + +Combine rules with Windsurf's Memory feature: + +```bash +# Generate initial rules from docs +skill-seekers package output/fastapi --target markdown + +# Windsurf Memory learns from your usage: +# - Coding patterns you use frequently +# - Variable naming conventions +# - Architecture decisions +# - Team-specific practices + +# Rules provide documentation, Memory provides personalization +``` + +**MCP Server Integration** + +For live documentation access: + +```bash +# Install Skill Seekers MCP server +pip install skill-seekers[mcp] + +# Configure in Windsurf's mcp_config.json +{ + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } + } +} +``` + +### Step 4: Test and Refine + +**Test Cascade Knowledge** + +```bash +# Start Cascade (Cmd+L) +# Ask framework-specific questions: + +"Show me FastAPI async database patterns" +"Create a React component with TypeScript best practices" +"Implement Django REST framework viewset with pagination" +``` + +**Refine Rules** + +```bash +# Add project-specific patterns +cat >> .windsurf/rules/project-conventions.md << 'EOF' +--- +name: "Project Conventions" +activation: "always-on" +priority: "highest" +--- + +# Project-Specific Patterns + +## Database Models +- Always use async SQLAlchemy +- Include created_at/updated_at timestamps +- Add __repr__ for debugging + +## API Endpoints +- Use dependency injection for database sessions +- Return Pydantic models, not ORM instances +- Include OpenAPI documentation strings +EOF + +# Reload Windsurf window (Cmd+Shift+P → "Reload Window") +``` + +**Monitor Character Usage** + +```bash +# Check rule file sizes +find .windsurf/rules -name "*.md" -exec wc -c {} \; + +# Ensure no file exceeds 6,000 characters +# If too large, split further: +skill-seekers package output/react --target markdown --split-rules --max-chars 5000 +``` + +--- + +## 🎨 Advanced Usage + +### Multi-Framework Projects + +**Backend + Frontend Stack** + +```bash +# Generate backend rules (FastAPI) +skill-seekers scrape --config configs/fastapi.json +skill-seekers package output/fastapi --target markdown --split-rules + +# Generate frontend rules (React) +skill-seekers scrape --config configs/react.json +skill-seekers package output/react --target markdown --split-rules + +# Organize rules directory: +.windsurf/rules/ +├── backend/ +│ ├── fastapi-core.md (Always On) +│ ├── fastapi-database.md (Model Decision) +│ └── fastapi-testing.md (Manual) +├── frontend/ +│ ├── react-hooks.md (Always On) +│ ├── react-components.md (Model Decision) +│ └── react-performance.md (Manual) +└── project/ + └── conventions.md (Always On, Highest Priority) +``` + +### Dynamic Context per Workflow + +**Context Switching Based on Task** + +```markdown +--- +name: "Testing Context" +activation: "model-decision" +description: "Use when user is writing or debugging tests" +keywords: ["test", "pytest", "unittest", "mock", "fixture"] +--- + +# Testing Best Practices + +When writing tests, follow these patterns... +``` + +**Scheduled Rules for Time-Based Context** + +```markdown +--- +name: "Code Review Mode" +activation: "scheduled" +schedule: "0 14 * * 1-5" # 2 PM on weekdays +priority: "high" +--- + +# Code Review Checklist + +During code review, verify: +- Type annotations are complete +- Tests cover edge cases +- Documentation is updated +``` + +### Windsurf + RAG Pipeline + +**Combine Rules with Vector Search** + +```python +# Use Skill Seekers to create both: +# 1. Windsurf rules (for Cascade context) +# 2. RAG chunks (for deep search) + +from skill_seekers.cli.doc_scraper import main as scrape +from skill_seekers.cli.package_skill import main as package +from skill_seekers.cli.adaptors import get_adaptor + +# Scrape documentation +scrape(["--config", "configs/react.json"]) + +# Create Windsurf rules +package(["output/react", "--target", "markdown", "--split-rules"]) + +# Also create RAG pipeline for deep search +package(["output/react", "--target", "langchain", "--chunk-for-rag"]) + +# Now you have: +# - .windsurf/rules/*.md (for Cascade) +# - output/react-langchain/ (for custom RAG search) +``` + +**MCP Tool for Dynamic Context** + +Create custom MCP tool that queries RAG pipeline: + +```python +# mcp_custom_search.py +from skill_seekers.mcp.tools import search_docs + +@mcp.tool() +def search_react_docs(query: str) -> str: + """Search React documentation for specific patterns.""" + # Query your RAG pipeline + results = vector_store.similarity_search(query, k=5) + return "\n\n".join([doc.page_content for doc in results]) +``` + +Register in `mcp_config.json`: + +```json +{ + "mcpServers": { + "custom-search": { + "command": "python", + "args": ["mcp_custom_search.py"] + } + } +} +``` + +--- + +## 💡 Best Practices + +### 1. Keep Rules Focused + +**Bad: Single Monolithic Rule (15,000 chars - exceeds limit!)** + +```markdown +--- +name: "Everything React" +--- +# React Framework (Complete Guide) +[... 15,000 characters of documentation ...] +``` + +**Good: Modular Rules (5,000 chars each)** + +```markdown + +--- +name: "React Core Concepts" +activation: "always-on" +--- +# React Fundamentals +[... focused on hooks, components, state ...] + + +--- +name: "React Performance" +activation: "model-decision" +description: "Use when optimizing React performance" +--- +# Performance Optimization +[... focused on memoization, lazy loading ...] + + +--- +name: "React Testing" +activation: "manual" +--- +# Testing React Components +[... focused on testing patterns ...] +``` + +### 2. Use Activation Modes Wisely + +| Mode | Use Case | Example | +|------|----------|---------| +| **Always On** | Core concepts, common patterns | Framework fundamentals, project conventions | +| **Model Decision** | Specialized topics | Performance optimization, advanced patterns | +| **Manual** | Troubleshooting, rare tasks | Debugging guides, migration docs | +| **Scheduled** | Time-based context | Code review checklists, release procedures | + +### 3. Prioritize Rules + +```markdown +--- +name: "Project Conventions" +activation: "always-on" +priority: "highest" # This overrides framework defaults +--- + +# Project-Specific Rules + +Always use: +- Async/await for all database operations +- Pydantic V2 (not V1) +- pytest-asyncio for async tests +``` + +### 4. Include Code Examples + +**Don't just describe patterns:** + +```markdown +## Creating Database Models + +Use SQLAlchemy with async patterns. +``` + +**Show actual code:** + +```markdown +## Creating Database Models + +```python +from sqlalchemy import Column, Integer, String, DateTime +from sqlalchemy.ext.asyncio import AsyncSession +from datetime import datetime + +class User(Base): + __tablename__ = "users" + + id = Column(Integer, primary_key=True) + email = Column(String, unique=True, nullable=False) + created_at = Column(DateTime, default=datetime.utcnow) + + def __repr__(self): + return f"" + +# Usage in endpoint +async def create_user(email: str, db: AsyncSession): + user = User(email=email) + db.add(user) + await db.commit() + await db.refresh(user) + return user +``` +\``` + +Use this pattern in all endpoints. +``` + +### 5. Update Rules Regularly + +```bash +# Framework updates quarterly +skill-seekers scrape --config configs/react.json +skill-seekers package output/react --target markdown --split-rules + +# Check what changed +diff -r .windsurf/rules/react-old/ .windsurf/rules/react-new/ + +# Merge updates +cp -r .windsurf/rules/react-new/* .windsurf/rules/ + +# Test with Cascade +# Ask: "What's new in React 19?" +``` + +--- + +## 🔥 Real-World Examples + +### Example 1: FastAPI + PostgreSQL Microservice + +**Project Structure:** + +``` +my-api/ +├── .windsurf/ +│ └── rules/ +│ ├── fastapi-core.md (5,200 chars, Always On) +│ ├── fastapi-database.md (5,800 chars, Always On) +│ ├── fastapi-testing.md (4,100 chars, Manual) +│ └── project-conventions.md (3,500 chars, Always On, Highest) +├── app/ +│ ├── models.py +│ ├── schemas.py +│ └── routers/ +└── tests/ +``` + +**fastapi-core.md** + +```markdown +--- +name: "FastAPI Core Patterns" +activation: "always-on" +priority: "high" +--- + +# FastAPI Expert + +You are an expert in FastAPI. Use these patterns: + +## Endpoint Structure + +Always use dependency injection: + +\```python +from fastapi import APIRouter, Depends +from sqlalchemy.ext.asyncio import AsyncSession +from app.database import get_db + +router = APIRouter(prefix="/api/v1") + +@router.post("/users/", response_model=UserResponse) +async def create_user( + user: UserCreate, + db: AsyncSession = Depends(get_db) +): + """Create a new user.""" + # Implementation +\``` + +## Error Handling + +Use HTTPException with proper status codes: + +\```python +from fastapi import HTTPException + +if not user: + raise HTTPException( + status_code=404, + detail="User not found" + ) +\``` +``` + +**project-conventions.md** + +```markdown +--- +name: "Project Conventions" +activation: "always-on" +priority: "highest" +--- + +# Project-Specific Patterns + +## Database Sessions + +ALWAYS use async sessions with context managers: + +\```python +async with get_session() as db: + result = await db.execute(query) +\``` + +## Response Models + +NEVER return ORM instances directly. Use Pydantic: + +\```python +# BAD +return user # SQLAlchemy model + +# GOOD +return UserResponse.model_validate(user) +\``` + +## Testing + +All tests MUST use pytest-asyncio: + +\```python +import pytest + +@pytest.mark.asyncio +async def test_create_user(): + # Test implementation +\``` +``` + +**Result:** + +When you ask Cascade: +> "Create an endpoint to list all users with pagination" + +Cascade will: +1. ✅ Use async/await (from project-conventions.md) +2. ✅ Add dependency injection (from fastapi-core.md) +3. ✅ Return Pydantic models (from project-conventions.md) +4. ✅ Use proper database patterns (from fastapi-database.md) + +### Example 2: Godot Game Engine + +**Godot-Specific Rules** + +```bash +# Generate Godot documentation + codebase analysis +skill-seekers github --repo godotengine/godot-demo-projects +skill-seekers package output/godot-demo-projects --target markdown --split-rules + +# Create rules structure: +.windsurf/rules/ +├── godot-core.md (GDScript syntax, node system) +├── godot-signals.md (Signal patterns, EventBus) +├── godot-scenes.md (Scene tree, node access) +└── project-patterns.md (Custom patterns from codebase) +``` + +**godot-signals.md** + +```markdown +--- +name: "Godot Signal Patterns" +activation: "model-decision" +description: "Use when working with signals and events" +keywords: ["signal", "connect", "emit", "EventBus"] +--- + +# Godot Signal Patterns + +## Signal Declaration + +\```gdscript +signal health_changed(new_health: int, max_health: int) +signal item_collected(item_type: String, quantity: int) +\``` + +## Connection Pattern + +\```gdscript +func _ready(): + player.health_changed.connect(_on_health_changed) + +func _on_health_changed(new_health: int, max_health: int): + health_bar.value = (new_health / float(max_health)) * 100 +\``` + +## EventBus Pattern (from codebase analysis) + +\```gdscript +# EventBus.gd (autoload singleton) +extends Node + +signal game_started +signal game_over(score: int) +signal player_died + +# Usage in game scenes: +EventBus.game_started.emit() +EventBus.game_over.emit(final_score) +\``` +``` + +--- + +## 🐛 Troubleshooting + +### Issue: Rules Not Loading + +**Symptoms:** +- Cascade doesn't reference documentation +- Rules directory exists but ignored + +**Solutions:** + +1. **Check rules directory location** + ```bash + # Must be exactly: + .windsurf/rules/ + + # Not: + .windsurf/rule/ # Missing 's' + windsurf/rules/ # Missing leading dot + ``` + +2. **Verify file extensions** + ```bash + # Rules must be .md files + ls .windsurf/rules/ + # Should show: fastapi.md, react.md, etc. + # NOT: fastapi.txt, rules.json + ``` + +3. **Check Windsurf settings** + ``` + Cmd+, → Search "rules" → Enable "Use Custom Rules" + ``` + +4. **Reload Windsurf** + ``` + Cmd+Shift+P → "Reload Window" + ``` + +5. **Verify frontmatter syntax** + ```markdown + --- + name: "Rule Name" + activation: "always-on" + --- + + # Content starts here + ``` + +### Issue: Rules Exceeding Character Limit + +**Error:** +> "Rule file exceeds 6,000 character limit" + +**Solutions:** + +1. **Use split-rules flag** + ```bash + skill-seekers package output/react --target markdown --split-rules + ``` + +2. **Set custom max-chars** + ```bash + skill-seekers package output/django --target markdown --split-rules --max-chars 5000 + ``` + +3. **Manual splitting** + ```bash + # Split SKILL.md by sections + csplit SKILL.md '/^## /' '{*}' + + # Rename files + mv xx00 core-concepts.md + mv xx01 api-reference.md + mv xx02 best-practices.md + ``` + +4. **Use activation modes strategically** + ```markdown + + --- + name: "Core Concepts" + activation: "always-on" + --- + + + --- + name: "Advanced Patterns" + activation: "manual" + --- + ``` + +### Issue: Cascade Not Using Rules + +**Symptoms:** +- Rules loaded but AI doesn't reference them +- Generic responses despite custom documentation + +**Solutions:** + +1. **Check activation mode** + ```markdown + # Change from Model Decision to Always On + --- + activation: "always-on" # Not "model-decision" + --- + ``` + +2. **Increase priority** + ```markdown + --- + priority: "highest" # Override framework defaults + --- + ``` + +3. **Add explicit instructions** + ```markdown + # FastAPI Expert + + You MUST follow these patterns in all FastAPI code: + - Use async/await + - Dependency injection for database + - Pydantic response models + ``` + +4. **Test with explicit mention** + ``` + In Cascade chat: + "@fastapi Create an endpoint with async database access" + ``` + +5. **Combine with Memory** + ``` + Ask Cascade to remember: + "Remember to always use the patterns from fastapi.md rules file" + ``` + +### Issue: Conflicting Rules + +**Symptoms:** +- AI mixes patterns from different frameworks +- Inconsistent code suggestions + +**Solutions:** + +1. **Use priority levels** + ```markdown + + --- + priority: "highest" + --- + + + --- + priority: "medium" + --- + ``` + +2. **Make project conventions always-on** + ```markdown + --- + name: "Project Conventions" + activation: "always-on" + priority: "highest" + --- + + These rules OVERRIDE all framework defaults: + - [List project-specific patterns] + ``` + +3. **Use model-decision for conflicting patterns** + ```markdown + + --- + activation: "model-decision" + description: "Use when creating REST APIs (not GraphQL)" + --- + + + --- + activation: "model-decision" + description: "Use when creating GraphQL APIs (not REST)" + --- + ``` + +--- + +## 📊 Before vs After Comparison + +| Aspect | Before Skill Seekers | After Skill Seekers | +|--------|---------------------|---------------------| +| **Context Source** | Copy-paste docs into chat | Automatic rules files | +| **Character Limits** | Hit 12K limit easily | Modular rules fit perfectly | +| **AI Knowledge** | Generic framework patterns | Project-specific best practices | +| **Setup Time** | Manual doc curation (hours) | Automated scraping (5 min) | +| **Consistency** | Varies per conversation | Persistent across all flows | +| **Updates** | Manual doc editing | Re-run scraper for latest docs | +| **Multi-Framework** | Context switching confusion | Separate rule files | +| **Code Quality** | Hit-or-miss | Follows documented patterns | + +--- + +## 🤝 Community & Support + +- **Questions:** [GitHub Discussions](https://github.com/yusufkaraaslan/Skill_Seekers/discussions) +- **Issues:** [GitHub Issues](https://github.com/yusufkaraaslan/Skill_Seekers/issues) +- **Website:** [skillseekersweb.com](https://skillseekersweb.com/) +- **Windsurf Docs:** [docs.windsurf.com](https://docs.windsurf.com/) +- **Windsurf Rules Directory:** [windsurf.com/editor/directory](https://windsurf.com/editor/directory) + +--- + +## 📚 Related Guides + +- [Cursor Integration](CURSOR.md) - Similar IDE, different rules format +- [Cline Integration](CLINE.md) - VS Code extension with MCP +- [Continue.dev Integration](CONTINUE_DEV.md) - IDE-agnostic AI assistant +- [LangChain Integration](LANGCHAIN.md) - Build RAG pipelines +- [RAG Pipelines Guide](RAG_PIPELINES.md) - End-to-end RAG setup + +--- + +## 📖 Next Steps + +1. **Try another framework:** `skill-seekers scrape --config configs/vue.json` +2. **Combine multiple frameworks:** Create modular rules for full-stack projects +3. **Integrate with MCP:** Add live documentation access via MCP servers +4. **Build RAG pipeline:** Use `--target langchain` for deep search +5. **Share your rules:** Contribute to [awesome-windsurfrules](https://github.com/SchneiderSam/awesome-windsurfrules) + +--- + +**Sources:** +- [Windsurf Official Site](https://windsurf.com/) +- [Windsurf Documentation](https://docs.windsurf.com/windsurf/getting-started) +- [Windsurf MCP Setup Guide](https://www.braingrid.ai/blog/windsurf-mcp) +- [Awesome Windsurfrules Repository](https://github.com/SchneiderSam/awesome-windsurfrules) +- [Windsurf Rules Directory](https://windsurf.com/editor/directory) +- [Mastering .windsurfrules Guide](https://blog.stackademic.com/mastering-windsurfrules-react-typescript-projects-aee1e3fe4376) diff --git a/examples/cline-django-assistant/README.md b/examples/cline-django-assistant/README.md new file mode 100644 index 0000000..4227b8d --- /dev/null +++ b/examples/cline-django-assistant/README.md @@ -0,0 +1,363 @@ +# Cline + Django Assistant Example + +Complete example showing how to use Skill Seekers to generate Cline rules for Django development with MCP integration. + +## What This Example Does + +- ✅ Generates Django documentation skill +- ✅ Creates .clinerules for Cline agent +- ✅ Sets up MCP server for dynamic documentation access +- ✅ Shows autonomous Django code generation + +## Quick Start + +### 1. Generate Django Skill + +```bash +# Install Skill Seekers with MCP support +pip install skill-seekers[mcp] + +# Generate Django documentation skill +skill-seekers scrape --config configs/django.json + +# Package for Cline (markdown format) +skill-seekers package output/django --target markdown +``` + +### 2. Copy to Django Project + +```bash +# Copy rules to project root +cp output/django-markdown/SKILL.md my-django-project/.clinerules + +# Or use the automation script +python generate_clinerules.py --project my-django-project +``` + +### 3. Configure MCP Server + +```bash +# In VS Code Cline panel: +# Settings → MCP Servers → Add Server + +# Add this configuration: +{ + "skill-seekers": { + "command": "python", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"], + "env": {} + } +} + +# Reload VS Code +``` + +### 4. Test in Cline + +```bash +# Open project in VS Code +code my-django-project/ + +# Open Cline panel (sidebar icon) +# Start autonomous task: + +"Create a Django blog app with: +- Post model with author, title, content, created_at +- Comment model with post foreign key +- Admin registration +- REST API with DRF +- Full test suite with pytest" + +# Cline will autonomously generate code following Django best practices +``` + +## Expected Results + +### Before (Without .clinerules) + +**Cline Task:** "Create a Django user model" + +**Output:** +```python +from django.db import models + +class User(models.Model): + username = models.CharField(max_length=100) + email = models.EmailField() +``` + +❌ Missing timestamps +❌ No __str__ method +❌ No Meta class +❌ Not using AbstractUser + +### After (With .clinerules) + +**Cline Task:** "Create a Django user model" + +**Output:** +```python +from django.contrib.auth.models import AbstractUser +from django.db import models + +class User(AbstractUser): + email = models.EmailField(unique=True) + bio = models.TextField(blank=True) + + created_at = models.DateTimeField(auto_now_add=True) + updated_at = models.DateTimeField(auto_now=True) + + class Meta: + ordering = ['-created_at'] + verbose_name = 'User' + verbose_name_plural = 'Users' + + def __str__(self): + return self.username +``` + +✅ Uses AbstractUser +✅ Includes timestamps +✅ Has __str__ method +✅ Proper Meta class +✅ Email uniqueness + +## Files in This Example + +- `generate_clinerules.py` - Automation script +- `mcp_config.json` - MCP server configuration +- `requirements.txt` - Python dependencies +- `example-project/` - Minimal Django project + - `manage.py` + - `app/models.py` + - `app/views.py` + - `tests/` + +## MCP Integration Benefits + +With MCP server configured, Cline can: + +1. **Search documentation dynamically** + ``` + Cline task: "Use skill-seekers MCP to search Django async views" + ``` + +2. **Generate fresh rules** + ``` + Cline task: "Use skill-seekers MCP to scrape latest Django 5.0 docs" + ``` + +3. **Package skills on-demand** + ``` + Cline task: "Use skill-seekers MCP to package React docs for this project" + ``` + +## Rule Files Structure + +After setup, your project has: + +``` +my-django-project/ +├── .clinerules # Core Django patterns (auto-loaded) +├── .clinerules.models # Model-specific patterns (optional) +├── .clinerules.views # View-specific patterns (optional) +├── .clinerules.testing # Testing patterns (optional) +├── .clinerules.project # Project conventions (highest priority) +└── .cline/ + └── memory-bank/ # Persistent project knowledge + └── README.md +``` + +Cline automatically loads all `.clinerules*` files. + +## Customization + +### Add Project-Specific Patterns + +Create `.clinerules.project`: + +```markdown +# Project-Specific Conventions + +## Database Queries + +ALWAYS use select_related/prefetch_related: + +\```python +# BAD +posts = Post.objects.all() # N+1 queries! + +# GOOD +posts = Post.objects.select_related('author').prefetch_related('comments').all() +\``` + +## API Responses + +NEVER expose sensitive fields: + +\```python +class UserSerializer(serializers.ModelSerializer): + class Meta: + model = User + fields = ['id', 'username', 'email', 'bio'] + # NEVER include: password, is_staff, is_superuser +\``` +``` + +### Memory Bank Setup + +```bash +# Initialize memory bank +mkdir -p .cline/memory-bank + +# Add project context +cat > .cline/memory-bank/README.md << 'EOF' +# Project Memory Bank + +## Tech Stack +- Django 5.0 +- PostgreSQL 16 +- Redis for caching +- Celery for background tasks + +## Architecture +- Modular apps (users, posts, comments) +- API-first with Django REST Framework +- Async views for I/O-bound operations + +## Conventions +- All models inherit from BaseModel (timestamps) +- Use pytest for testing +- API versioning: /api/v1/ +EOF + +# Ask Cline to initialize +# In Cline: "Initialize memory bank from README" +``` + +## Troubleshooting + +### Issue: .clinerules not loading + +**Solution:** Check file location +```bash +# Must be at project root +ls -la .clinerules + +# Reload VS Code +# Cmd+Shift+P → "Developer: Reload Window" +``` + +### Issue: MCP server not connecting + +**Solution 1:** Verify installation +```bash +pip show skill-seekers +# Should show: [mcp] extra installed +``` + +**Solution 2:** Test MCP server directly +```bash +python -m skill_seekers.mcp.server_fastmcp --transport stdio +# Should start without errors +``` + +**Solution 3:** Use absolute Python path +```json +{ + "skill-seekers": { + "command": "/usr/local/bin/python3", + "args": ["-m", "skill_seekers.mcp.server_fastmcp", "--transport", "stdio"] + } +} +``` + +### Issue: Cline not using rules + +**Solution:** Add explicit instructions +```markdown +# Django Expert + +You MUST follow these patterns in ALL Django code: +- Include timestamps in models +- Use select_related for queries +- Write tests with pytest + +NEVER deviate from these patterns. +``` + +## Advanced Usage + +### Multi-Framework Project (Django + React) + +```bash +# Backend rules +skill-seekers package output/django --target markdown +cp output/django-markdown/SKILL.md .clinerules.backend + +# Frontend rules +skill-seekers package output/react --target markdown +cp output/react-markdown/SKILL.md .clinerules.frontend + +# Now Cline knows BOTH Django AND React patterns +``` + +### Cline + RAG Pipeline + +```python +# Create both .clinerules and RAG pipeline +from skill_seekers.cli.doc_scraper import main as scrape +from skill_seekers.cli.package_skill import main as package + +# Scrape +scrape(["--config", "configs/django.json"]) + +# For Cline +package(["output/django", "--target", "markdown"]) + +# For RAG search +package(["output/django", "--target", "langchain", "--chunk-for-rag"]) + +# Now you have: +# 1. .clinerules (for Cline context) +# 2. LangChain docs (for deep search) +``` + +## Real-World Workflow + +### Complete Blog API with Cline + +**Task:** "Create production-ready blog API" + +**Cline Autonomous Steps:** + +1. ✅ Creates models (Post, Comment) with timestamps, __str__, Meta +2. ✅ Adds select_related to querysets (from .clinerules) +3. ✅ Creates serializers with nested data (from .clinerules) +4. ✅ Implements ViewSets with filtering (from .clinerules) +5. ✅ Sets up URL routing (from .clinerules) +6. ✅ Writes pytest tests (from .clinerules.testing) +7. ✅ Adds admin registration (from .clinerules) + +**Result:** Production-ready API in minutes, following all best practices! + +## Related Examples + +- [Cursor Example](../cursor-react-skill/) - Similar IDE approach +- [Windsurf Example](../windsurf-fastapi-context/) - Windsurf IDE +- [Continue.dev Example](../continue-dev-universal/) - IDE-agnostic +- [LangChain RAG Example](../langchain-rag-pipeline/) - RAG integration + +## Next Steps + +1. Add more frameworks (React, Vue) for full-stack +2. Create memory bank for project knowledge +3. Build RAG pipeline with `--target langchain` +4. Share your .clinerules patterns with community +5. Integrate custom MCP tools for project-specific needs + +## Support + +- **Skill Seekers Issues:** [GitHub](https://github.com/yusufkaraaslan/Skill_Seekers/issues) +- **Cline Docs:** [docs.cline.bot](https://docs.cline.bot/) +- **Integration Guide:** [CLINE.md](../../docs/integrations/CLINE.md) diff --git a/examples/cline-django-assistant/generate_clinerules.py b/examples/cline-django-assistant/generate_clinerules.py new file mode 100644 index 0000000..c27e38b --- /dev/null +++ b/examples/cline-django-assistant/generate_clinerules.py @@ -0,0 +1,226 @@ +#!/usr/bin/env python3 +""" +Automation script to generate Cline rules from Django documentation. + +Usage: + python generate_clinerules.py --project /path/to/project + python generate_clinerules.py --project . --with-mcp +""" + +import argparse +import json +import shutil +import subprocess +import sys +from pathlib import Path + + +def run_command(cmd: list[str], description: str) -> bool: + """Run a shell command and return success status.""" + print(f"\n{'='*60}") + print(f"STEP: {description}") + print(f"{'='*60}") + print(f"Running: {' '.join(cmd)}\n") + + result = subprocess.run(cmd, capture_output=True, text=True) + + if result.stdout: + print(result.stdout) + if result.stderr: + print(result.stderr, file=sys.stderr) + + if result.returncode != 0: + print(f"❌ ERROR: {description} failed with code {result.returncode}") + return False + + print(f"✅ SUCCESS: {description}") + return True + + +def setup_mcp_server(project_path: Path) -> bool: + """Set up MCP server configuration for Cline.""" + print(f"\n{'='*60}") + print(f"STEP: Configuring MCP Server") + print(f"{'='*60}") + + # Create MCP config + mcp_config = { + "mcpServers": { + "skill-seekers": { + "command": "python", + "args": [ + "-m", + "skill_seekers.mcp.server_fastmcp", + "--transport", + "stdio" + ], + "env": {} + } + } + } + + # Save to project + vscode_dir = project_path / ".vscode" + vscode_dir.mkdir(exist_ok=True) + + mcp_config_file = vscode_dir / "mcp_config.json" + with open(mcp_config_file, 'w') as f: + json.dump(mcp_config, f, indent=2) + + print(f"✅ Created: {mcp_config_file}") + print(f"\nTo activate in Cline:") + print(f"1. Open Cline panel in VS Code") + print(f"2. Settings → MCP Servers → Load Configuration") + print(f"3. Select: {mcp_config_file}") + print(f"4. Reload VS Code window") + + return True + + +def main(): + parser = argparse.ArgumentParser( + description="Generate Cline rules from Django documentation" + ) + parser.add_argument( + "--project", + type=str, + default=".", + help="Path to your project directory (default: current directory)", + ) + parser.add_argument( + "--skip-scrape", + action="store_true", + help="Skip scraping step (use existing output/django)", + ) + parser.add_argument( + "--with-mcp", + action="store_true", + help="Set up MCP server configuration", + ) + parser.add_argument( + "--modular", + action="store_true", + help="Create modular rules files (.clinerules.models, .clinerules.views, etc.)", + ) + args = parser.parse_args() + + project_path = Path(args.project).resolve() + output_dir = Path("output/django") + + print("=" * 60) + print("Cline Rules Generator for Django") + print("=" * 60) + print(f"Project: {project_path}") + print(f"Modular rules: {args.modular}") + print(f"MCP integration: {args.with_mcp}") + print("=" * 60) + + # Step 1: Scrape Django documentation (unless skipped) + if not args.skip_scrape: + if not run_command( + [ + "skill-seekers", + "scrape", + "--config", + "configs/django.json", + ], + "Scraping Django documentation", + ): + return 1 + else: + print(f"\n⏭️ SKIPPED: Using existing {output_dir}") + + if not output_dir.exists(): + print(f"❌ ERROR: {output_dir} does not exist!") + print(f"Run without --skip-scrape to generate documentation first.") + return 1 + + # Step 2: Package for Cline + if not run_command( + [ + "skill-seekers", + "package", + str(output_dir), + "--target", + "markdown", + ], + "Packaging for Cline", + ): + return 1 + + # Step 3: Copy rules to project + print(f"\n{'='*60}") + print(f"STEP: Copying rules to project") + print(f"{'='*60}") + + markdown_output = output_dir.parent / "django-markdown" + source_skill = markdown_output / "SKILL.md" + + if not source_skill.exists(): + print(f"❌ ERROR: {source_skill} does not exist!") + return 1 + + if args.modular: + # Split into modular files + print("Creating modular rules files...") + + with open(source_skill, 'r') as f: + content = f.read() + + # Split by major sections + sections = content.split('\n## ') + + # Core rules (first part) + core_rules = project_path / ".clinerules" + with open(core_rules, 'w') as f: + f.write(sections[0]) + print(f"✅ Created: {core_rules}") + + # Try to extract specific sections (simplified) + # In a real implementation, this would be more sophisticated + models_content = next((s for s in sections if 'Model' in s), None) + if models_content: + models_rules = project_path / ".clinerules.models" + with open(models_rules, 'w') as f: + f.write('## ' + models_content) + print(f"✅ Created: {models_rules}") + + views_content = next((s for s in sections if 'View' in s), None) + if views_content: + views_rules = project_path / ".clinerules.views" + with open(views_rules, 'w') as f: + f.write('## ' + views_content) + print(f"✅ Created: {views_rules}") + + else: + # Single file + dest_file = project_path / ".clinerules" + shutil.copy(source_skill, dest_file) + print(f"✅ Copied: {dest_file}") + + # Step 4: Set up MCP server (optional) + if args.with_mcp: + if not setup_mcp_server(project_path): + print("⚠️ WARNING: MCP setup failed, but rules were created successfully") + + print(f"\n{'='*60}") + print(f"✅ SUCCESS: Cline rules generated!") + print(f"{'='*60}") + print(f"\nNext steps:") + print(f"1. Open project in VS Code: code {project_path}") + print(f"2. Install Cline extension (if not already)") + print(f"3. Reload VS Code window: Cmd+Shift+P → 'Reload Window'") + print(f"4. Open Cline panel (sidebar icon)") + print(f"5. Start autonomous task:") + print(f" 'Create a Django blog app with posts and comments'") + + if args.with_mcp: + print(f"\n📡 MCP Server configured at:") + print(f" {project_path / '.vscode' / 'mcp_config.json'}") + print(f" Load in Cline: Settings → MCP Servers → Load Configuration") + + return 0 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/examples/cline-django-assistant/requirements.txt b/examples/cline-django-assistant/requirements.txt new file mode 100644 index 0000000..f3f7f4f --- /dev/null +++ b/examples/cline-django-assistant/requirements.txt @@ -0,0 +1,5 @@ +skill-seekers[mcp]>=2.9.0 +django>=5.0.0 +djangorestframework>=3.15.0 +pytest>=8.0.0 +pytest-django>=4.8.0 diff --git a/examples/continue-dev-universal/README.md b/examples/continue-dev-universal/README.md new file mode 100644 index 0000000..cf4a4b0 --- /dev/null +++ b/examples/continue-dev-universal/README.md @@ -0,0 +1,597 @@ +# Continue.dev + Universal Context Example + +Complete example showing how to use Skill Seekers to create IDE-agnostic context providers for Continue.dev across VS Code, JetBrains, and other IDEs. + +## What This Example Does + +- ✅ Generates framework documentation (Vue.js example) +- ✅ Creates HTTP context provider server +- ✅ Works across all IDEs (VS Code, IntelliJ, PyCharm, WebStorm, etc.) +- ✅ Single configuration, consistent results + +## Quick Start + +### 1. Generate Documentation + +```bash +# Install Skill Seekers +pip install skill-seekers[mcp] + +# Generate Vue.js documentation +skill-seekers scrape --config configs/vue.json +skill-seekers package output/vue --target markdown +``` + +### 2. Start Context Server + +```bash +# Use the provided HTTP context server +python context_server.py + +# Server runs on http://localhost:8765 +# Serves documentation at /docs/{framework} +``` + +### 3. Configure Continue.dev + +Edit `~/.continue/config.json`: + +```json +{ + "contextProviders": [ + { + "name": "http", + "params": { + "url": "http://localhost:8765/docs/vue", + "title": "vue-docs", + "displayTitle": "Vue.js Documentation", + "description": "Vue.js framework expert knowledge" + } + } + ] +} +``` + +### 4. Test in Any IDE + +**VS Code:** +```bash +code my-vue-project/ +# Open Continue panel (Cmd+L) +# Type: @vue-docs Create a Vue 3 component with Composition API +``` + +**IntelliJ IDEA:** +```bash +idea my-vue-project/ +# Open Continue panel (Cmd+L) +# Type: @vue-docs Create a Vue 3 component with Composition API +``` + +**Result:** IDENTICAL suggestions in both IDEs! + +## Expected Results + +### Before (Without Context Provider) + +**Prompt:** "Create a Vue component" + +**Continue Output:** +```javascript +export default { + name: 'MyComponent', + data() { + return { + message: 'Hello' + } + } +} +``` + +❌ Uses Options API (outdated) +❌ No TypeScript +❌ No Composition API +❌ Generic patterns + +### After (With Context Provider) + +**Prompt:** "@vue-docs Create a Vue component" + +**Continue Output:** +```typescript + + + + + {{ props.title }} + {{ message }} - Count: {{ displayCount }} + + + + +``` + +✅ Composition API with `
{content}
{{ message }} - Count: {{ displayCount }}