vibes-plug 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
- package/BLUEPRINT.md +125 -0
- package/CHANGELOG.md +195 -0
- package/CONTRIBUTING.md +199 -0
- package/LICENSE +21 -0
- package/README.md +263 -0
- package/SECURITY.md +21 -0
- package/banner.png +0 -0
- package/package.json +25 -0
- package/plugin.json +8 -0
- package/scripts/update_skills.js +75 -0
- package/skills/ai-llm-integration-expert/SKILL.md +162 -0
- package/skills/api-design-expert/SKILL.md +310 -0
- package/skills/app-analyzer-optimizer/SKILL.md +189 -0
- package/skills/asisten_ramah/SKILL.md +41 -0
- package/skills/authentication-identity-expert/SKILL.md +45 -0
- package/skills/auto-doc-updater/SKILL.md +204 -0
- package/skills/bootstrap-to-modern/SKILL.md +87 -0
- package/skills/brainstorming/SKILL.md +353 -0
- package/skills/bun-runtime-expert/SKILL.md +211 -0
- package/skills/ci-cd-devops-architect/SKILL.md +45 -0
- package/skills/cloud-hosting-expert/SKILL.md +244 -0
- package/skills/coderabbit/SKILL.md +192 -0
- package/skills/data-telemetry-expert/SKILL.md +213 -0
- package/skills/database-orm-expert/SKILL.md +294 -0
- package/skills/design-system-architect/SKILL.md +243 -0
- package/skills/e2e-testing-expert/SKILL.md +315 -0
- package/skills/event-driven-architect/SKILL.md +81 -0
- package/skills/firebase-security-expert/SKILL.md +195 -0
- package/skills/fullstack-expert/SKILL.md +202 -0
- package/skills/fullstack-expert/references/api_design_guide.md +466 -0
- package/skills/fullstack-expert/references/devops_infrastructure.md +477 -0
- package/skills/fullstack-expert/references/multi_language_backend.md +528 -0
- package/skills/fullstack-expert/references/system_design_patterns.md +358 -0
- package/skills/fullstack-expert/scripts/api_contract_validator.py +253 -0
- package/skills/fullstack-expert/scripts/architecture_analyzer.py +326 -0
- package/skills/gemini-agent-booster/SKILL.md +135 -0
- package/skills/global-a11y-i18n-expert/SKILL.md +81 -0
- package/skills/go-programming-expert/SKILL.md +295 -0
- package/skills/hig/SKILL.md +188 -0
- package/skills/js-backend-expert/SKILL.md +192 -0
- package/skills/mcp-server-architect/SKILL.md +194 -0
- package/skills/mobile-expo-expert/SKILL.md +186 -0
- package/skills/monday-design-aesthetic/SKILL.md +67 -0
- package/skills/monorepo-architect/SKILL.md +227 -0
- package/skills/mpa-orchestrator/SKILL.md +101 -0
- package/skills/multi-agent-orchestration/SKILL.md +234 -0
- package/skills/multiple-entry-points/SKILL.md +55 -0
- package/skills/mvc-expert/SKILL.md +231 -0
- package/skills/payment-gateway-expert/SKILL.md +45 -0
- package/skills/performance-web-vitals/SKILL.md +332 -0
- package/skills/prd-architect/SKILL.md +191 -0
- package/skills/production-ready-hardener/SKILL.md +469 -0
- package/skills/production-ready-hardener/references/performance_optimization.md +441 -0
- package/skills/production-ready-hardener/references/production_checklist.md +161 -0
- package/skills/production-ready-hardener/references/security_hardening_guide.md +379 -0
- package/skills/production-ready-hardener/scripts/production_readiness_scanner.py +875 -0
- package/skills/python-programming-expert/SKILL.md +271 -0
- package/skills/realtime-collaboration-expert/SKILL.md +45 -0
- package/skills/rust-programming-expert/SKILL.md +235 -0
- package/skills/saas-billing/SKILL.md +377 -0
- package/skills/saas-multi-tenant/SKILL.md +237 -0
- package/skills/saas-mvp-launcher/SKILL.md +231 -0
- package/skills/saas-transformer/SKILL.md +446 -0
- package/skills/saas-transformer/references/billing_integration_guide.md +401 -0
- package/skills/saas-transformer/references/feature_gating_patterns.md +137 -0
- package/skills/saas-transformer/references/saas_transformation_checklist.md +121 -0
- package/skills/saas-transformer/scripts/saas_transformation_scanner.py +254 -0
- package/skills/scalability-clean-code/SKILL.md +229 -0
- package/skills/secure-fuzz-testing/SKILL.md +201 -0
- package/skills/senior-frontend/SKILL.md +161 -0
- package/skills/senior-frontend/references/frontend_best_practices.md +806 -0
- package/skills/senior-frontend/references/nextjs_optimization_guide.md +724 -0
- package/skills/senior-frontend/references/react_patterns.md +746 -0
- package/skills/senior-frontend/scripts/bundle_analyzer.py +407 -0
- package/skills/senior-frontend/scripts/component_generator.py +329 -0
- package/skills/senior-frontend/scripts/frontend_scaffolder.py +1005 -0
- package/skills/senior-fullstack/SKILL.md +167 -0
- package/skills/senior-fullstack/references/architecture_patterns.md +160 -0
- package/skills/senior-fullstack/references/development_workflows.md +222 -0
- package/skills/senior-fullstack/references/tech_stack_guide.md +190 -0
- package/skills/senior-fullstack/scripts/code_quality_analyzer.py +114 -0
- package/skills/senior-fullstack/scripts/fullstack_scaffolder.py +114 -0
- package/skills/senior-fullstack/scripts/project_scaffolder.py +114 -0
- package/skills/seo/SKILL.md +225 -0
- package/skills/seo/references/cwv-thresholds.md +108 -0
- package/skills/seo/references/eeat-framework.md +214 -0
- package/skills/seo/references/quality-gates.md +155 -0
- package/skills/seo/references/schema-types.md +118 -0
- package/skills/seo-aeo-landing-page-writer/SKILL.md +97 -0
- package/skills/seo-geo/SKILL.md +188 -0
- package/skills/session-handoff-resume/SKILL.md +158 -0
- package/skills/skill_baru/SKILL.md +147 -0
- package/skills/spa-orchestrator/SKILL.md +288 -0
- package/skills/state-management-expert/SKILL.md +272 -0
- package/skills/supabase-migration/SKILL.md +45 -0
- package/skills/supabase-security-expert/SKILL.md +243 -0
- package/skills/tailwind-expert/SKILL.md +188 -0
- package/skills/tanstack-query-expert/SKILL.md +199 -0
- package/skills/tauri-expert/SKILL.md +97 -0
- package/skills/token-saver/SKILL.md +111 -0
- package/skills/typescript-expert/SKILL.md +279 -0
- package/skills/ui-components-expert/SKILL.md +63 -0
- package/skills/ui-ux-pro-max/SKILL.md +201 -0
- package/skills/ui-ux-pro-max/data/charts.csv +26 -0
- package/skills/ui-ux-pro-max/data/colors.csv +97 -0
- package/skills/ui-ux-pro-max/data/icons.csv +101 -0
- package/skills/ui-ux-pro-max/data/landing.csv +31 -0
- package/skills/ui-ux-pro-max/data/products.csv +97 -0
- package/skills/ui-ux-pro-max/data/prompts.csv +24 -0
- package/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
- package/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
- package/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
- package/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
- package/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
- package/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
- package/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
- package/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
- package/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
- package/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
- package/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
- package/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
- package/skills/ui-ux-pro-max/data/styles.csv +59 -0
- package/skills/ui-ux-pro-max/data/typography.csv +58 -0
- package/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
- package/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
- package/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
- package/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-310.pyc +0 -0
- package/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-312.pyc +0 -0
- package/skills/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-310.pyc +0 -0
- package/skills/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-312.pyc +0 -0
- package/skills/ui-ux-pro-max/scripts/core.py +257 -0
- package/skills/ui-ux-pro-max/scripts/design_system.py +493 -0
- package/skills/ui-ux-pro-max/scripts/search.py +81 -0
- package/skills/ui_ux_expert/SKILL.md +114 -0
- package/skills/vibe-code-gardener/SKILL.md +173 -0
- package/skills/web-scraper/SKILL.md +205 -0
- package/skills/web-scraper/references/data-transforms.md +397 -0
- package/skills/web-scraper/references/extraction-patterns.md +475 -0
- package/skills/web-scraper/references/output-templates.md +481 -0
- package/skills/zero-to-prod-orchestrator/SKILL.md +180 -0
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ui-ux-expert
|
|
3
|
+
description: "UI/UX Designer & Frontend Specialist / UI/UX Designer & Spesialis Frontend."
|
|
4
|
+
author: "Roedy Rustam"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# UI/UX Expert
|
|
8
|
+
|
|
9
|
+
[English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
<a name="english"></a>
|
|
14
|
+
## English
|
|
15
|
+
|
|
16
|
+
### Description
|
|
17
|
+
This skill establishes Antigravity as a **UI/UX Designer & Frontend Specialist** focusing on building responsive web applications for Desktop and Tablet (landscape 1080x720 px). Prioritizes clean, user-friendly, consistent, responsive, and adaptive layouts.
|
|
18
|
+
|
|
19
|
+
### Trigger Conditions
|
|
20
|
+
Active when the user requests help with:
|
|
21
|
+
- UI/UX Design.
|
|
22
|
+
- Layouts and grid systems.
|
|
23
|
+
- Designing responsive web components.
|
|
24
|
+
- Frontend development (HTML/CSS/JS).
|
|
25
|
+
- Creating wireframes or mockups.
|
|
26
|
+
|
|
27
|
+
### UI (User Interface) Skills
|
|
28
|
+
- **Layout & Grid**: Use CSS Grid/Flexbox, max container width of 1080px, and consistent spacing (8px system).
|
|
29
|
+
- **Typography**: Maximum 2–3 fonts with clear hierarchy (H1: 24–32px, H2: 18–24px, Body: 14–16px).
|
|
30
|
+
- **Color System**: Define Primary, Secondary, and Neutral colors with proper WCAG contrast accessibility.
|
|
31
|
+
- **Reusable Components**: Design modular buttons, cards, navbars, form inputs, and modals.
|
|
32
|
+
|
|
33
|
+
### UX (User Experience) Skills
|
|
34
|
+
- **Responsiveness Strategy**: Focus breakpoints on Desktop (≥1080px) and Tablet Landscape (768px – 1080px).
|
|
35
|
+
- **Navigation**: Easy-to-reach sidebar/topbar navigation, ensuring user journeys require no more than 3 clicks to their destination.
|
|
36
|
+
- **Usability & Interaction**: Prioritize simplicity and clarity. Implement responsive hover states and clear interaction feedback (loading states, success/error messages).
|
|
37
|
+
|
|
38
|
+
### Modern SaaS Design Guidelines (Inspired by Monday.com)
|
|
39
|
+
- **Visual Aesthetic**: Spacious, highly structured, clean white (`#FFFFFF`) or light gray (`#F9F9F9`) backgrounds with vibrant brand accents (e.g., `#0073ea` blue).
|
|
40
|
+
- **Typography**: Geometric sans-serif fonts with high contrast (extra-bold 48-60px for hero, medium 16-18px for body in muted gray `#676879`).
|
|
41
|
+
- **Components**: Rounded corners for buttons (~8px) and large radius for cards (~12-16px) with subtle drop shadows (`shadow-sm`).
|
|
42
|
+
- **Layout Flow**: Centered content with a max-width of 1200-1400px and very generous vertical section padding (80-120px) to create a premium feel.
|
|
43
|
+
|
|
44
|
+
### Modern & Professional Dashboard Design Guidelines
|
|
45
|
+
- **Dashboard Layout**:
|
|
46
|
+
- **Sidebar**: Collapsible navigation bar (240px–280px width open, 64px–80px collapsed). Use semantic `<aside>`, sticky positioning, clear division between top (logo/brand), middle (navigation links), and bottom (user settings/logout).
|
|
47
|
+
- **Header (Topbar)**: Sticky header with breadcrumbs, search, notification icon, and profile menu.
|
|
48
|
+
- **Main Content**: Structured layout utilizing CSS Grid or Flexbox, max-width wrapper, and consistent padding (e.g., 24px/p-6).
|
|
49
|
+
- **Metric Cards (KPIs)**:
|
|
50
|
+
- Place primary metric summaries at the top (usually 3–4 columns grid).
|
|
51
|
+
- Structure: Label (subtle gray), Value (large, bold/semibold, e.g., 24px–32px), Trend Indicator (green positive percentage with arrow up, red negative percentage with arrow down, or gray neutral), and an optional descriptive icon.
|
|
52
|
+
- **Charts & Data Visualization**:
|
|
53
|
+
- Keep charts clean: minimal grid lines, legible labels, custom responsive tooltips, and clear legends.
|
|
54
|
+
- Use colors from the primary/secondary theme. Avoid overloading with too many colors (max 5 variables in a pie/bar chart).
|
|
55
|
+
- **Data Tables & Lists**:
|
|
56
|
+
- Implement structured, highly legible tables with sticky headers for scrolling.
|
|
57
|
+
- Support essential table controls: search, sorting, filtering, row selection, pagination, and bulk actions.
|
|
58
|
+
- **Visual Aesthetics & Spacing**:
|
|
59
|
+
- Background: Off-white/slate-50 (`#F8FAFC`) in light mode, dark-zinc/slate-950 (`#09090B` or `#020617`) in dark mode.
|
|
60
|
+
- Cards: Pure white (`#FFFFFF`) or dark slate-900 (`#1E293B`) cards with subtle borders (`1px border-slate-100/200`) and soft shadows (`shadow-sm` or `shadow-md`).
|
|
61
|
+
- Font: Clean, legible Sans-serif typography (e.g., Inter, Outfit, Plus Jakarta Sans).
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
<a name="bahasa-indonesia"></a>
|
|
66
|
+
## Bahasa Indonesia
|
|
67
|
+
|
|
68
|
+
### Deskripsi
|
|
69
|
+
Skill ini menjadikan Antigravity sebagai **UI/UX Designer & Frontend Specialist** yang berfokus pada pembuatan web aplikasi responsif untuk Desktop dan Tablet (landscape 1080x720 px). Mengutamakan desain yang bersih, mudah digunakan, konsisten, responsif, dan adaptif.
|
|
70
|
+
|
|
71
|
+
### Kondisi Pemicu
|
|
72
|
+
Aktif ketika pengguna meminta bantuan terkait:
|
|
73
|
+
- Desain UI/UX.
|
|
74
|
+
- Layout dan grid system.
|
|
75
|
+
- Pembuatan komponen web responsif.
|
|
76
|
+
- Frontend development (HTML/CSS/JS).
|
|
77
|
+
- Pembuatan wireframe atau mockup.
|
|
78
|
+
|
|
79
|
+
### Kemampuan UI (User Interface)
|
|
80
|
+
- **Layout & Grid**: Gunakan CSS Grid/Flexbox, container width maksimal 1080px, dan spacing konsisten (8px system).
|
|
81
|
+
- **Tipografi**: Maksimal 2–3 font dengan hierarki ukuran yang jelas (H1: 24–32px, H2: 18–24px, Body: 14–16px).
|
|
82
|
+
- **Sistem Warna**: Tentukan warna Primary, Secondary, dan Neutral dengan kontras aksesibilitas WCAG yang memadai.
|
|
83
|
+
- **Komponen Reusable**: Buat button, card, navbar, form input, dan modal yang modular dan dapat digunakan kembali.
|
|
84
|
+
|
|
85
|
+
### Kemampuan UX (User Experience)
|
|
86
|
+
- **Strategi Responsif**: Breakpoint fokus pada Desktop (≥1080px) dan Tablet Landscape (768px – 1080px).
|
|
87
|
+
- **Navigasi**: Navigasi sidebar/topbar yang mudah dijangkau, dengan alur tidak lebih dari 3 klik ke tujuan.
|
|
88
|
+
- **Usability & Interaction**: Utamakan kesederhanaan dan kejelasan, buat hover state yang responsif, dan sediakan feedback interaksi seperti loading state dan status sukses/error.
|
|
89
|
+
|
|
90
|
+
### Panduan Desain SaaS Modern (Terinspirasi Monday.com)
|
|
91
|
+
- **Estetika Visual**: Luas, terstruktur, bersih dengan latar belakang putih (`#FFFFFF`) atau abu-abu terang (`#F9F9F9`), dipadukan dengan aksen merek yang cerah (mis. biru `#0073ea`).
|
|
92
|
+
- **Tipografi**: Font sans-serif geometris dengan kontras tinggi (sangat tebal 48-60px untuk hero, sedang 16-18px abu-abu redup `#676879` untuk teks isi).
|
|
93
|
+
- **Komponen**: Sudut melengkung untuk tombol (~8px) dan radius besar untuk kartu (~12-16px) dengan efek bayangan sangat halus (`shadow-sm`).
|
|
94
|
+
- **Alur Tata Letak**: Konten terpusat dengan lebar maksimal 1200-1400px serta padding vertikal antar bagian yang sangat lega (80-120px) untuk kesan premium.
|
|
95
|
+
|
|
96
|
+
### Panduan Desain Dashboard Modern & Profesional
|
|
97
|
+
- **Tata Letak Dashboard (Layout)**:
|
|
98
|
+
- **Sidebar**: Bar navigasi samping yang dapat dilipat/collapsible (lebar 240px–280px saat terbuka, 64px–80px saat tertutup). Gunakan elemen semantik `<aside>`, sticky positioning, dan pembagian area yang jelas (atas: logo, tengah: navigasi, bawah: profil/setting).
|
|
99
|
+
- **Header (Topbar)**: Header sticky yang memuat breadcrumbs, kolom pencarian, ikon notifikasi, dan menu profil.
|
|
100
|
+
- **Main Content**: Area konten utama menggunakan CSS Grid/Flexbox dengan padding konsisten (misal: 24px/p-6).
|
|
101
|
+
- **Kartu Metrik (KPI Cards)**:
|
|
102
|
+
- Letakkan ringkasan metrik utama di bagian paling atas (biasanya grid 3–4 kolom).
|
|
103
|
+
- Struktur: Label metrik (abu-abu halus), Nilai utama (besar dan tebal, misal: 24px–32px), Indikator Tren (persentase positif warna hijau dengan panah ke atas, persentase negatif warna merah dengan panah ke bawah), dan ikon penjelas.
|
|
104
|
+
- **Visualisasi Data & Grafik (Charts)**:
|
|
105
|
+
- Desain grafik yang bersih: kurangi grid lines yang tidak perlu, label yang mudah dibaca, tooltip interaktif, dan legenda yang jelas.
|
|
106
|
+
- Gunakan warna aksen sesuai dengan tema palet dashboard. Hindari terlalu banyak warna (maksimal 5 warna dalam satu grafik).
|
|
107
|
+
- **Tabel Data & List**:
|
|
108
|
+
- Tampilkan data dalam tabel dengan header yang *sticky* saat di-scroll dan legibilitas tinggi.
|
|
109
|
+
- Sediakan kontrol dasar: pencarian, pengurutan (sorting), penyaringan (filtering), seleksi baris, paginasi, dan aksi massal (bulk actions).
|
|
110
|
+
- **Estetika Visual & Spacing**:
|
|
111
|
+
- Latar Belakang (Background): Off-white/slate-50 (`#F8FAFC`) pada mode terang, dark-zinc/slate-950 (`#09090B` atau `#020617`) pada mode gelap.
|
|
112
|
+
- Kartu (Cards): Berwarna putih bersih (`#FFFFFF`) atau dark slate-900 (`#1E293B`) dengan border halus (`1px border-slate-100/200`) serta drop shadow lembut (`shadow-sm` atau `shadow-md`).
|
|
113
|
+
- Tipografi: Gunakan font Sans-serif yang sangat terbaca (seperti Inter, Outfit, Plus Jakarta Sans).
|
|
114
|
+
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: vibe-code-gardener
|
|
3
|
+
description: "Purger of AI slop, code bloat, context drift, and architectural decay in vibe-coded projects / Pembersih AI slop, kode membengkak, konteks drift, dan pembusukan arsitektur pada proyek vibe coding."
|
|
4
|
+
author: "Roedy Rustam"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Vibe Code Gardener (2026 Edition)
|
|
8
|
+
|
|
9
|
+
[English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
<a name="english"></a>
|
|
14
|
+
## English
|
|
15
|
+
|
|
16
|
+
### Description
|
|
17
|
+
Detects and purges AI-generated code quality issues — AI slop, code bloat, context drift, duplicated logic, dead code, misaligned patterns, and architectural decay in projects that have been heavily vibe-coded.
|
|
18
|
+
|
|
19
|
+
### Trigger Conditions
|
|
20
|
+
- Codebase has grown out of control after many AI-assisted coding sessions.
|
|
21
|
+
- Duplication, inconsistent patterns, or unexplained abstractions detected.
|
|
22
|
+
- Features are getting harder to add or understand.
|
|
23
|
+
- Tests are brittle or missing entirely.
|
|
24
|
+
- The codebase has "AI smell" — overly verbose comments, unnecessary defensive code, duplicate utilities.
|
|
25
|
+
|
|
26
|
+
### AI Slop Detection Heuristics (2026)
|
|
27
|
+
|
|
28
|
+
These are the most common AI-generated code quality issues to look for:
|
|
29
|
+
|
|
30
|
+
#### 1. The "Just In Case" Over-Engineering
|
|
31
|
+
AI models often add features or abstractions "for extensibility" that are never needed:
|
|
32
|
+
```typescript
|
|
33
|
+
// 🔴 AI SLOP: Factory pattern for something that will never change
|
|
34
|
+
const createUserRepository = (type: 'postgres' | 'mysql' | 'sqlite') => {
|
|
35
|
+
if (type === 'postgres') return new PostgresUserRepo();
|
|
36
|
+
// ...never switches in practice
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
// ✅ CLEAN: Just use the implementation
|
|
40
|
+
const userRepo = new PostgresUserRepo();
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
#### 2. The "Belt and Suspenders" Duplicate Guards
|
|
44
|
+
AI adds null checks and validations at every layer unnecessarily:
|
|
45
|
+
```typescript
|
|
46
|
+
// 🔴 AI SLOP: Triple-validated (already validated by Zod + DB schema + here)
|
|
47
|
+
if (!user || !user.id || user.id === undefined || user.id === null || typeof user.id !== 'string') { ... }
|
|
48
|
+
|
|
49
|
+
// ✅ CLEAN: Trust your types
|
|
50
|
+
if (!user.id) { ... }
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
#### 3. The "Graveyard of Dead Utilities"
|
|
54
|
+
AI-generated helper files with functions that are defined but never used:
|
|
55
|
+
- Search for exported functions with 0 usages: `grep -r "export function" --include="*.ts" | while read...`
|
|
56
|
+
- Remove entire files of dead utilities.
|
|
57
|
+
|
|
58
|
+
#### 4. Context Drift — Style Inconsistency
|
|
59
|
+
Different sessions produce different coding styles in the same codebase:
|
|
60
|
+
- Some files use `async/await`, others use `.then()` chains.
|
|
61
|
+
- Some use `const` arrow functions, others use `function` declarations.
|
|
62
|
+
- Mixed naming: `userId`, `user_id`, `UserID` in the same project.
|
|
63
|
+
- **Fix**: Run a style unification pass with Prettier + ESLint rules.
|
|
64
|
+
|
|
65
|
+
#### 5. Comment Pollution
|
|
66
|
+
AI loves to narrate obvious code:
|
|
67
|
+
```typescript
|
|
68
|
+
// 🔴 AI SLOP: Stating the obvious
|
|
69
|
+
// Get the user from the database
|
|
70
|
+
const user = await db.user.findUnique({ where: { id } });
|
|
71
|
+
// Return the user
|
|
72
|
+
return user;
|
|
73
|
+
|
|
74
|
+
// ✅ CLEAN: No comment needed — code is self-explanatory
|
|
75
|
+
const user = await db.user.findUnique({ where: { id } });
|
|
76
|
+
return user;
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
#### 6. The Bloated Component
|
|
80
|
+
AI tends to put too much in one component across sessions:
|
|
81
|
+
- Component renders conditionally across 5+ different states.
|
|
82
|
+
- Component has 10+ props.
|
|
83
|
+
- Component imports from 20+ different modules.
|
|
84
|
+
- **Fix**: Apply Single Responsibility — split into sub-components.
|
|
85
|
+
|
|
86
|
+
#### 7. Dependency Creep
|
|
87
|
+
Each AI session may install new packages for tasks already solvable with existing deps:
|
|
88
|
+
```bash
|
|
89
|
+
# Audit dependencies — find packages doing the same thing
|
|
90
|
+
npx depcheck # Unused dependencies
|
|
91
|
+
npx bundle-phobia-cli # Bundle size of each dep
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### Gardening Protocol
|
|
95
|
+
|
|
96
|
+
#### Phase 1: Discovery (Read Only)
|
|
97
|
+
1. Map the full file tree.
|
|
98
|
+
2. Identify largest files (likely bloated).
|
|
99
|
+
3. Find duplicated logic with semantic search.
|
|
100
|
+
4. Find unused exports and dead code.
|
|
101
|
+
5. Identify inconsistent patterns across files.
|
|
102
|
+
|
|
103
|
+
#### Phase 2: Triage
|
|
104
|
+
Categorize issues:
|
|
105
|
+
- **Critical**: Bugs, security holes, data loss risks.
|
|
106
|
+
- **High**: Duplicate business logic that will diverge.
|
|
107
|
+
- **Medium**: Code smells that slow development.
|
|
108
|
+
- **Low**: Style inconsistencies, over-verbose comments.
|
|
109
|
+
|
|
110
|
+
#### Phase 3: Systematic Refactoring
|
|
111
|
+
Work file by file, smallest changes first:
|
|
112
|
+
1. Remove dead code and unused imports.
|
|
113
|
+
2. Extract duplicated logic into shared utilities.
|
|
114
|
+
3. Simplify over-engineered abstractions.
|
|
115
|
+
4. Standardize naming conventions.
|
|
116
|
+
5. Add missing tests for business-critical paths.
|
|
117
|
+
|
|
118
|
+
#### Phase 4: Prevention
|
|
119
|
+
- Add ESLint rules to catch common AI slop patterns.
|
|
120
|
+
- Add `depcheck` to CI to catch unused dependencies.
|
|
121
|
+
- Add architecture tests (e.g., `arch-unit`) to enforce layer boundaries.
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
<a name="bahasa-indonesia"></a>
|
|
126
|
+
## Bahasa Indonesia
|
|
127
|
+
|
|
128
|
+
### Deskripsi
|
|
129
|
+
Mendeteksi dan membersihkan masalah kualitas kode yang dihasilkan AI — AI slop, kode yang membengkak, context drift, logika yang terduplikasi, kode mati, pola yang tidak konsisten, dan pembusukan arsitektur pada proyek yang banyak menggunakan vibe coding.
|
|
130
|
+
|
|
131
|
+
### Kondisi Pemicu
|
|
132
|
+
- Codebase telah tumbuh tidak terkendali setelah banyak sesi coding berbantuan AI.
|
|
133
|
+
- Duplikasi, pola tidak konsisten, atau abstraksi yang tidak dapat dijelaskan terdeteksi.
|
|
134
|
+
- Fitur semakin sulit ditambahkan atau dipahami.
|
|
135
|
+
- Test rapuh atau tidak ada sama sekali.
|
|
136
|
+
- Codebase memiliki "AI smell" — komentar yang terlalu verbose, kode defensif yang tidak perlu, utilitas yang diduplikasi.
|
|
137
|
+
|
|
138
|
+
### Heuristik Deteksi AI Slop (2026)
|
|
139
|
+
|
|
140
|
+
#### 1. Over-Engineering "Untuk Jaga-Jaga"
|
|
141
|
+
Model AI sering menambahkan fitur atau abstraksi "untuk ekstensibilitas" yang tidak pernah dibutuhkan. Hapus factory pattern, strategy pattern, atau abstraksi lain yang tidak memiliki lebih dari satu implementasi.
|
|
142
|
+
|
|
143
|
+
#### 2. "Belt and Suspenders" — Validasi Ganda Berlebihan
|
|
144
|
+
AI menambahkan null check dan validasi di setiap layer yang sebenarnya sudah divalidasi oleh Zod, TypeScript, atau skema DB. Percayai tipe Anda.
|
|
145
|
+
|
|
146
|
+
#### 3. "Kuburan Utilitas Mati"
|
|
147
|
+
File helper yang dihasilkan AI dengan fungsi yang tidak pernah digunakan. Cari dan hapus ekspor dengan 0 penggunaan.
|
|
148
|
+
|
|
149
|
+
#### 4. Context Drift — Inkonsistensi Gaya
|
|
150
|
+
Sesi yang berbeda menghasilkan gaya koding yang berbeda: sebagian menggunakan `async/await`, yang lain menggunakan `.then()`; penamaan campuran `userId`, `user_id`, `UserID`. Perbaiki dengan satu pass Prettier + aturan ESLint.
|
|
151
|
+
|
|
152
|
+
#### 5. Polusi Komentar
|
|
153
|
+
AI suka mengomentari kode yang sudah jelas sendiri. Hapus komentar yang hanya mengulang apa yang sudah tertulis dalam kode.
|
|
154
|
+
|
|
155
|
+
#### 6. Komponen yang Membengkak
|
|
156
|
+
Komponen dengan terlalu banyak kondisi rendering, prop, atau impor. Terapkan Single Responsibility — pecah menjadi sub-komponen.
|
|
157
|
+
|
|
158
|
+
#### 7. Creep Dependensi
|
|
159
|
+
Setiap sesi AI mungkin menginstal paket baru untuk tugas yang sudah bisa diselesaikan dengan dependensi yang ada. Audit dengan `depcheck` dan `bundle-phobia-cli`.
|
|
160
|
+
|
|
161
|
+
### Protokol Berkebun
|
|
162
|
+
|
|
163
|
+
#### Fase 1: Penemuan (Hanya Baca)
|
|
164
|
+
Peta pohon file lengkap, identifikasi file terbesar, temukan logika yang terduplikasi, temukan ekspor yang tidak digunakan.
|
|
165
|
+
|
|
166
|
+
#### Fase 2: Triase
|
|
167
|
+
Kategorikan masalah: Kritis, Tinggi, Sedang, Rendah.
|
|
168
|
+
|
|
169
|
+
#### Fase 3: Refactoring Sistematis
|
|
170
|
+
Kerja file per file, perubahan terkecil dulu: hapus kode mati, ekstrak logika duplikat, sederhanakan abstraksi berlebih, standarisasi penamaan, tambahkan test yang hilang.
|
|
171
|
+
|
|
172
|
+
#### Fase 4: Pencegahan
|
|
173
|
+
Tambahkan aturan ESLint, `depcheck` di CI, dan architecture test untuk menjaga codebase tetap bersih.
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: web-scraper
|
|
3
|
+
description: "Smart web data extraction capability with multi-strategy scraping (Crawl4AI, Playwright, BeautifulSoup), LLM extraction, pagination support, and structured export / Kemampuan ekstraksi data web cerdas dengan strategi scraping modern (Crawl4AI, Playwright, BeautifulSoup), ekstraksi LLM, paginasi, dan ekspor terstruktur."
|
|
4
|
+
author: "Roedy Rustam"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Web Scraper Expert (2026 Edition)
|
|
8
|
+
|
|
9
|
+
[English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
<a name="english"></a>
|
|
14
|
+
## English
|
|
15
|
+
|
|
16
|
+
### Description
|
|
17
|
+
Smart web data extraction using modern scraping strategies — **Firecrawl** (LLM-ready structured extraction), **Jina Reader API** (clean markdown from any URL), **Crawl4AI** (async Python scraping), **Playwright** (browser automation), and **BeautifulSoup** (lightweight HTML parsing). Supports pagination, dynamic content, structured export (JSON, CSV, Markdown), and AI-powered data extraction.
|
|
18
|
+
|
|
19
|
+
### Trigger Conditions
|
|
20
|
+
- Extracting structured data from websites for analysis, training data, or content pipelines.
|
|
21
|
+
- Scraping dynamic JavaScript-rendered pages (SPAs, React apps).
|
|
22
|
+
- Converting web pages to clean Markdown for LLM context or RAG pipelines.
|
|
23
|
+
- Building an automated data pipeline that scrapes, transforms, and stores data.
|
|
24
|
+
- Extracting data at scale with rate limiting and proxy rotation.
|
|
25
|
+
|
|
26
|
+
### Strategy Selection Guide
|
|
27
|
+
|
|
28
|
+
| Strategy | Tool | Best For | JS Required |
|
|
29
|
+
|---|---|---|---|
|
|
30
|
+
| **Managed API** | Firecrawl / Jina Reader | LLM-ready content, clean Markdown | Handled |
|
|
31
|
+
| **Async Python** | Crawl4AI | High-volume, AI-powered extraction | Optional |
|
|
32
|
+
| **Browser Automation** | Playwright | Complex SPAs, auth-required pages | ✅ |
|
|
33
|
+
| **Lightweight HTML** | BeautifulSoup + httpx | Static HTML, fast extraction | ❌ |
|
|
34
|
+
|
|
35
|
+
### Firecrawl — LLM-Ready Web Scraping (2026 Standard)
|
|
36
|
+
Firecrawl converts any URL to clean, LLM-ready Markdown with a single API call:
|
|
37
|
+
```python
|
|
38
|
+
from firecrawl import FirecrawlApp
|
|
39
|
+
|
|
40
|
+
app = FirecrawlApp(api_key="fc-xxxx")
|
|
41
|
+
|
|
42
|
+
# Single page — clean Markdown
|
|
43
|
+
result = app.scrape_url(
|
|
44
|
+
"https://example.com/article",
|
|
45
|
+
formats=["markdown", "html"],
|
|
46
|
+
only_main_content=True, # removes nav, footer, ads
|
|
47
|
+
)
|
|
48
|
+
print(result.markdown)
|
|
49
|
+
|
|
50
|
+
# Full site crawl
|
|
51
|
+
crawl_result = app.crawl_url(
|
|
52
|
+
"https://docs.example.com",
|
|
53
|
+
limit=50,
|
|
54
|
+
scrape_options={"formats": ["markdown"]},
|
|
55
|
+
)
|
|
56
|
+
|
|
57
|
+
# LLM-powered structured extraction with JSON schema
|
|
58
|
+
from pydantic import BaseModel
|
|
59
|
+
|
|
60
|
+
class ProductInfo(BaseModel):
|
|
61
|
+
name: str
|
|
62
|
+
price: float
|
|
63
|
+
description: str
|
|
64
|
+
in_stock: bool
|
|
65
|
+
|
|
66
|
+
result = app.scrape_url(
|
|
67
|
+
"https://shop.example.com/product/123",
|
|
68
|
+
formats=["extract"],
|
|
69
|
+
extract={"schema": ProductInfo.model_json_schema()},
|
|
70
|
+
)
|
|
71
|
+
product = ProductInfo(**result.extract)
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### Jina Reader API — Clean Markdown from Any URL
|
|
75
|
+
```python
|
|
76
|
+
import httpx
|
|
77
|
+
|
|
78
|
+
async def url_to_markdown(url: str) -> str:
|
|
79
|
+
"""Convert any URL to clean Markdown via Jina Reader API."""
|
|
80
|
+
async with httpx.AsyncClient() as client:
|
|
81
|
+
response = await client.get(
|
|
82
|
+
f"https://r.jina.ai/{url}",
|
|
83
|
+
headers={
|
|
84
|
+
"Accept": "application/json",
|
|
85
|
+
"X-Return-Format": "markdown",
|
|
86
|
+
"Authorization": f"Bearer {JINA_API_KEY}",
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
data = response.json()
|
|
90
|
+
return data["data"]["content"]
|
|
91
|
+
|
|
92
|
+
# Search and get results as Markdown
|
|
93
|
+
async def search_to_markdown(query: str) -> str:
|
|
94
|
+
async with httpx.AsyncClient() as client:
|
|
95
|
+
response = await client.get(
|
|
96
|
+
f"https://s.jina.ai/{query}",
|
|
97
|
+
headers={"Accept": "application/json"}
|
|
98
|
+
)
|
|
99
|
+
return response.json()["data"]
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
### Crawl4AI — Async Python Web Scraper
|
|
103
|
+
```python
|
|
104
|
+
import asyncio
|
|
105
|
+
from crawl4ai import AsyncWebCrawler, BrowserConfig, CrawlerRunConfig, CacheMode
|
|
106
|
+
|
|
107
|
+
async def scrape_with_ai_extraction():
|
|
108
|
+
browser_config = BrowserConfig(headless=True, verbose=False)
|
|
109
|
+
|
|
110
|
+
async with AsyncWebCrawler(config=browser_config) as crawler:
|
|
111
|
+
result = await crawler.arun(
|
|
112
|
+
url="https://news.example.com",
|
|
113
|
+
config=CrawlerRunConfig(
|
|
114
|
+
cache_mode=CacheMode.ENABLED, # cache results
|
|
115
|
+
word_count_threshold=50, # skip short content
|
|
116
|
+
exclude_external_links=True,
|
|
117
|
+
remove_overlay_elements=True, # remove popups/modals
|
|
118
|
+
),
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
print(result.markdown.fit_markdown) # cleaned, AI-optimized Markdown
|
|
122
|
+
print(result.links) # extracted links
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
### Playwright — Complex Dynamic Pages
|
|
126
|
+
```python
|
|
127
|
+
from playwright.async_api import async_playwright
|
|
128
|
+
import asyncio
|
|
129
|
+
|
|
130
|
+
async def scrape_spa(url: str) -> dict:
|
|
131
|
+
async with async_playwright() as pw:
|
|
132
|
+
browser = await pw.chromium.launch(headless=True)
|
|
133
|
+
page = await browser.new_page()
|
|
134
|
+
|
|
135
|
+
# Block images/CSS to speed up
|
|
136
|
+
await page.route("**/*.{png,jpg,jpeg,gif,css,woff2}", lambda r: r.abort())
|
|
137
|
+
|
|
138
|
+
await page.goto(url, wait_until="networkidle")
|
|
139
|
+
|
|
140
|
+
# Wait for dynamic content
|
|
141
|
+
await page.wait_for_selector("[data-testid='product-list']")
|
|
142
|
+
|
|
143
|
+
# Extract structured data via JavaScript
|
|
144
|
+
products = await page.evaluate("""() => {
|
|
145
|
+
return Array.from(document.querySelectorAll('.product-card')).map(card => ({
|
|
146
|
+
name: card.querySelector('.product-name')?.textContent?.trim(),
|
|
147
|
+
price: card.querySelector('.price')?.textContent?.trim(),
|
|
148
|
+
}));
|
|
149
|
+
}""")
|
|
150
|
+
|
|
151
|
+
await browser.close()
|
|
152
|
+
return {"products": products, "url": url}
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
### Ethical Scraping Checklist
|
|
156
|
+
- [ ] Check `robots.txt` and respect `Disallow` rules.
|
|
157
|
+
- [ ] Implement rate limiting — minimum 1-2 seconds between requests.
|
|
158
|
+
- [ ] Use descriptive `User-Agent` header with contact email.
|
|
159
|
+
- [ ] Cache results to avoid repeated requests.
|
|
160
|
+
- [ ] Prefer public APIs or official data feeds when available.
|
|
161
|
+
- [ ] Do not scrape personal/private data without consent.
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
<a name="bahasa-indonesia"></a>
|
|
166
|
+
## Bahasa Indonesia
|
|
167
|
+
|
|
168
|
+
### Deskripsi
|
|
169
|
+
Ekstraksi data web yang cerdas menggunakan strategi scraping modern — **Firecrawl** (ekstraksi terstruktur siap-LLM), **Jina Reader API** (Markdown bersih dari URL manapun), **Crawl4AI** (scraping Python async), **Playwright** (otomasi browser), dan **BeautifulSoup** (parsing HTML ringan). Mendukung paginasi, konten dinamis, ekspor terstruktur, dan ekstraksi data bertenaga AI.
|
|
170
|
+
|
|
171
|
+
### Kondisi Pemicu
|
|
172
|
+
- Mengekstrak data terstruktur dari website untuk analisis, data pelatihan, atau pipeline konten.
|
|
173
|
+
- Scraping halaman yang dirender JavaScript secara dinamis (SPA, aplikasi React).
|
|
174
|
+
- Mengonversi halaman web menjadi Markdown bersih untuk konteks LLM atau pipeline RAG.
|
|
175
|
+
- Membangun pipeline data otomatis yang melakukan scraping, transformasi, dan penyimpanan.
|
|
176
|
+
- Mengekstrak data dalam skala besar dengan rate limiting dan rotasi proxy.
|
|
177
|
+
|
|
178
|
+
### Panduan Pemilihan Strategi
|
|
179
|
+
|
|
180
|
+
| Strategi | Tool | Terbaik Untuk | Perlu JS |
|
|
181
|
+
|---|---|---|---|
|
|
182
|
+
| **API Terkelola** | Firecrawl / Jina Reader | Konten siap LLM, Markdown bersih | Ditangani |
|
|
183
|
+
| **Python Async** | Crawl4AI | Volume tinggi, ekstraksi AI | Opsional |
|
|
184
|
+
| **Otomasi Browser** | Playwright | SPA kompleks, halaman butuh auth | ✅ |
|
|
185
|
+
| **HTML Ringan** | BeautifulSoup + httpx | HTML statis, ekstraksi cepat | ❌ |
|
|
186
|
+
|
|
187
|
+
### Firecrawl — Scraping Web Siap LLM
|
|
188
|
+
Firecrawl mengonversi URL apapun menjadi Markdown bersih siap LLM dengan satu panggilan API. Mendukung crawling seluruh situs, ekstraksi terstruktur berbasis skema JSON, dan penghapusan konten yang tidak relevan (navigasi, footer, iklan).
|
|
189
|
+
|
|
190
|
+
### Jina Reader API — Markdown Bersih dari URL Manapun
|
|
191
|
+
Jina Reader (`r.jina.ai/{url}`) mengonversi halaman web manapun menjadi Markdown yang dioptimalkan untuk LLM. Jina Search (`s.jina.ai/{query}`) melakukan pencarian web dan mengembalikan hasilnya sebagai Markdown.
|
|
192
|
+
|
|
193
|
+
### Crawl4AI — Web Scraper Python Async
|
|
194
|
+
Crawl4AI mendukung caching hasil, ekstraksi Markdown yang dioptimalkan AI, dan konfigurasi browser yang fleksibel untuk scraping konten dinamis.
|
|
195
|
+
|
|
196
|
+
### Playwright — Halaman Dinamis Kompleks
|
|
197
|
+
Gunakan Playwright untuk scraping SPA yang memerlukan eksekusi JavaScript, menunggu elemen dinamis, atau interaksi dengan halaman (klik, scroll, isi form).
|
|
198
|
+
|
|
199
|
+
### Checklist Scraping Etis
|
|
200
|
+
- [ ] Periksa `robots.txt` dan hormati aturan `Disallow`.
|
|
201
|
+
- [ ] Implementasikan rate limiting — minimal 1-2 detik antar permintaan.
|
|
202
|
+
- [ ] Gunakan header `User-Agent` deskriptif dengan email kontak.
|
|
203
|
+
- [ ] Cache hasil untuk menghindari permintaan berulang.
|
|
204
|
+
- [ ] Utamakan API publik atau feed data resmi jika tersedia.
|
|
205
|
+
- [ ] Jangan scraping data pribadi/privat tanpa izin.
|