@techwavedev/agi-agent-kit 1.1.3
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/CHANGELOG.md +59 -0
- package/README.md +147 -0
- package/bin/init.js +471 -0
- package/package.json +36 -0
- package/templates/.agent/agents/backend-specialist.md +263 -0
- package/templates/.agent/agents/code-archaeologist.md +106 -0
- package/templates/.agent/agents/database-architect.md +226 -0
- package/templates/.agent/agents/debugger.md +225 -0
- package/templates/.agent/agents/devops-engineer.md +242 -0
- package/templates/.agent/agents/documentation-writer.md +104 -0
- package/templates/.agent/agents/explorer-agent.md +73 -0
- package/templates/.agent/agents/frontend-specialist.md +556 -0
- package/templates/.agent/agents/game-developer.md +162 -0
- package/templates/.agent/agents/mobile-developer.md +377 -0
- package/templates/.agent/agents/orchestrator.md +416 -0
- package/templates/.agent/agents/penetration-tester.md +188 -0
- package/templates/.agent/agents/performance-optimizer.md +187 -0
- package/templates/.agent/agents/product-manager.md +112 -0
- package/templates/.agent/agents/project-planner.md +403 -0
- package/templates/.agent/agents/qa-automation-engineer.md +109 -0
- package/templates/.agent/agents/security-auditor.md +170 -0
- package/templates/.agent/agents/seo-specialist.md +111 -0
- package/templates/.agent/agents/test-engineer.md +158 -0
- package/templates/.agent/rules/GEMINI.md +253 -0
- package/templates/.agent/workflows/brainstorm.md +113 -0
- package/templates/.agent/workflows/create.md +59 -0
- package/templates/.agent/workflows/debug.md +103 -0
- package/templates/.agent/workflows/deploy.md +176 -0
- package/templates/.agent/workflows/enhance.md +63 -0
- package/templates/.agent/workflows/orchestrate.md +237 -0
- package/templates/.agent/workflows/plan.md +89 -0
- package/templates/.agent/workflows/preview.md +81 -0
- package/templates/.agent/workflows/status.md +86 -0
- package/templates/.agent/workflows/test.md +144 -0
- package/templates/.agent/workflows/ui-ux-pro-max.md +296 -0
- package/templates/base/.env.example +54 -0
- package/templates/base/AGENTS.md +463 -0
- package/templates/base/requirements.txt +6 -0
- package/templates/base/skill-creator/LICENSE.txt +202 -0
- package/templates/base/skill-creator/SKILL_skillcreator.md +389 -0
- package/templates/base/skill-creator/references/output-patterns.md +82 -0
- package/templates/base/skill-creator/references/workflows.md +28 -0
- package/templates/base/skill-creator/scripts/init_skill.py +304 -0
- package/templates/base/skill-creator/scripts/package_skill.py +110 -0
- package/templates/base/skill-creator/scripts/quick_validate.py +95 -0
- package/templates/base/skill-creator/scripts/update_catalog.py +371 -0
- package/templates/skills/core/README.md +21 -0
- package/templates/skills/core/documentation/SKILL.md +351 -0
- package/templates/skills/core/documentation/references/best_practices.md +201 -0
- package/templates/skills/core/documentation/scripts/analyze_code.py +307 -0
- package/templates/skills/core/documentation/scripts/detect_changes.py +460 -0
- package/templates/skills/core/documentation/scripts/generate_changelog.py +312 -0
- package/templates/skills/core/documentation/scripts/sync_docs.py +272 -0
- package/templates/skills/core/documentation/scripts/update_skill_docs.py +366 -0
- package/templates/skills/core/pdf-reader/SKILL.md +104 -0
- package/templates/skills/core/pdf-reader/references/pdf_libraries.md +83 -0
- package/templates/skills/core/pdf-reader/scripts/extract_text.py +295 -0
- package/templates/skills/core/qdrant-memory/SKILL.md +435 -0
- package/templates/skills/core/qdrant-memory/references/advanced_patterns.md +375 -0
- package/templates/skills/core/qdrant-memory/references/collection_schemas.md +229 -0
- package/templates/skills/core/qdrant-memory/references/complete_guide.md +724 -0
- package/templates/skills/core/qdrant-memory/references/embedding_models.md +325 -0
- package/templates/skills/core/qdrant-memory/scripts/benchmark_token_savings.py +640 -0
- package/templates/skills/core/qdrant-memory/scripts/embedding_utils.py +323 -0
- package/templates/skills/core/qdrant-memory/scripts/hybrid_search.py +214 -0
- package/templates/skills/core/qdrant-memory/scripts/init_collection.py +193 -0
- package/templates/skills/core/qdrant-memory/scripts/memory_retrieval.py +345 -0
- package/templates/skills/core/qdrant-memory/scripts/semantic_cache.py +282 -0
- package/templates/skills/core/qdrant-memory/scripts/test_skill.py +655 -0
- package/templates/skills/core/webcrawler/SKILL.md +292 -0
- package/templates/skills/core/webcrawler/references/advanced_crawling.md +181 -0
- package/templates/skills/core/webcrawler/scripts/crawl_docs.py +532 -0
- package/templates/skills/core/webcrawler/scripts/extract_page.py +189 -0
- package/templates/skills/core/webcrawler/scripts/filter_docs.py +200 -0
- package/templates/skills/knowledge/api-patterns/SKILL.md +81 -0
- package/templates/skills/knowledge/api-patterns/api-style.md +42 -0
- package/templates/skills/knowledge/api-patterns/auth.md +24 -0
- package/templates/skills/knowledge/api-patterns/documentation.md +26 -0
- package/templates/skills/knowledge/api-patterns/graphql.md +41 -0
- package/templates/skills/knowledge/api-patterns/rate-limiting.md +31 -0
- package/templates/skills/knowledge/api-patterns/response.md +37 -0
- package/templates/skills/knowledge/api-patterns/rest.md +40 -0
- package/templates/skills/knowledge/api-patterns/scripts/api_validator.py +211 -0
- package/templates/skills/knowledge/api-patterns/security-testing.md +122 -0
- package/templates/skills/knowledge/api-patterns/trpc.md +41 -0
- package/templates/skills/knowledge/api-patterns/versioning.md +22 -0
- package/templates/skills/knowledge/app-builder/SKILL.md +75 -0
- package/templates/skills/knowledge/app-builder/agent-coordination.md +71 -0
- package/templates/skills/knowledge/app-builder/feature-building.md +53 -0
- package/templates/skills/knowledge/app-builder/project-detection.md +34 -0
- package/templates/skills/knowledge/app-builder/scaffolding.md +118 -0
- package/templates/skills/knowledge/app-builder/tech-stack.md +40 -0
- package/templates/skills/knowledge/app-builder/templates/SKILL.md +39 -0
- package/templates/skills/knowledge/app-builder/templates/astro-static/TEMPLATE.md +76 -0
- package/templates/skills/knowledge/app-builder/templates/chrome-extension/TEMPLATE.md +92 -0
- package/templates/skills/knowledge/app-builder/templates/cli-tool/TEMPLATE.md +88 -0
- package/templates/skills/knowledge/app-builder/templates/electron-desktop/TEMPLATE.md +88 -0
- package/templates/skills/knowledge/app-builder/templates/express-api/TEMPLATE.md +83 -0
- package/templates/skills/knowledge/app-builder/templates/flutter-app/TEMPLATE.md +90 -0
- package/templates/skills/knowledge/app-builder/templates/monorepo-turborepo/TEMPLATE.md +90 -0
- package/templates/skills/knowledge/app-builder/templates/nextjs-fullstack/TEMPLATE.md +82 -0
- package/templates/skills/knowledge/app-builder/templates/nextjs-saas/TEMPLATE.md +100 -0
- package/templates/skills/knowledge/app-builder/templates/nextjs-static/TEMPLATE.md +106 -0
- package/templates/skills/knowledge/app-builder/templates/nuxt-app/TEMPLATE.md +101 -0
- package/templates/skills/knowledge/app-builder/templates/python-fastapi/TEMPLATE.md +83 -0
- package/templates/skills/knowledge/app-builder/templates/react-native-app/TEMPLATE.md +93 -0
- package/templates/skills/knowledge/architecture/SKILL.md +55 -0
- package/templates/skills/knowledge/architecture/context-discovery.md +43 -0
- package/templates/skills/knowledge/architecture/examples.md +94 -0
- package/templates/skills/knowledge/architecture/pattern-selection.md +68 -0
- package/templates/skills/knowledge/architecture/patterns-reference.md +50 -0
- package/templates/skills/knowledge/architecture/trade-off-analysis.md +77 -0
- package/templates/skills/knowledge/bash-linux/SKILL.md +199 -0
- package/templates/skills/knowledge/behavioral-modes/SKILL.md +242 -0
- package/templates/skills/knowledge/brainstorming/SKILL.md +163 -0
- package/templates/skills/knowledge/brainstorming/dynamic-questioning.md +350 -0
- package/templates/skills/knowledge/clean-code/SKILL.md +201 -0
- package/templates/skills/knowledge/code-review-checklist/SKILL.md +109 -0
- package/templates/skills/knowledge/database-design/SKILL.md +52 -0
- package/templates/skills/knowledge/database-design/database-selection.md +43 -0
- package/templates/skills/knowledge/database-design/indexing.md +39 -0
- package/templates/skills/knowledge/database-design/migrations.md +48 -0
- package/templates/skills/knowledge/database-design/optimization.md +36 -0
- package/templates/skills/knowledge/database-design/orm-selection.md +30 -0
- package/templates/skills/knowledge/database-design/schema-design.md +56 -0
- package/templates/skills/knowledge/database-design/scripts/schema_validator.py +172 -0
- package/templates/skills/knowledge/deployment-procedures/SKILL.md +241 -0
- package/templates/skills/knowledge/doc.md +177 -0
- package/templates/skills/knowledge/documentation-templates/SKILL.md +194 -0
- package/templates/skills/knowledge/frontend-design/SKILL.md +396 -0
- package/templates/skills/knowledge/frontend-design/animation-guide.md +331 -0
- package/templates/skills/knowledge/frontend-design/color-system.md +311 -0
- package/templates/skills/knowledge/frontend-design/decision-trees.md +418 -0
- package/templates/skills/knowledge/frontend-design/motion-graphics.md +306 -0
- package/templates/skills/knowledge/frontend-design/scripts/accessibility_checker.py +183 -0
- package/templates/skills/knowledge/frontend-design/scripts/ux_audit.py +722 -0
- package/templates/skills/knowledge/frontend-design/typography-system.md +345 -0
- package/templates/skills/knowledge/frontend-design/ux-psychology.md +541 -0
- package/templates/skills/knowledge/frontend-design/visual-effects.md +383 -0
- package/templates/skills/knowledge/game-development/2d-games/SKILL.md +119 -0
- package/templates/skills/knowledge/game-development/3d-games/SKILL.md +135 -0
- package/templates/skills/knowledge/game-development/SKILL.md +167 -0
- package/templates/skills/knowledge/game-development/game-art/SKILL.md +185 -0
- package/templates/skills/knowledge/game-development/game-audio/SKILL.md +190 -0
- package/templates/skills/knowledge/game-development/game-design/SKILL.md +129 -0
- package/templates/skills/knowledge/game-development/mobile-games/SKILL.md +108 -0
- package/templates/skills/knowledge/game-development/multiplayer/SKILL.md +132 -0
- package/templates/skills/knowledge/game-development/pc-games/SKILL.md +144 -0
- package/templates/skills/knowledge/game-development/vr-ar/SKILL.md +123 -0
- package/templates/skills/knowledge/game-development/web-games/SKILL.md +150 -0
- package/templates/skills/knowledge/geo-fundamentals/SKILL.md +156 -0
- package/templates/skills/knowledge/geo-fundamentals/scripts/geo_checker.py +289 -0
- package/templates/skills/knowledge/i18n-localization/SKILL.md +154 -0
- package/templates/skills/knowledge/i18n-localization/scripts/i18n_checker.py +241 -0
- package/templates/skills/knowledge/intelligent-routing/SKILL.md +334 -0
- package/templates/skills/knowledge/lint-and-validate/SKILL.md +45 -0
- package/templates/skills/knowledge/lint-and-validate/scripts/lint_runner.py +172 -0
- package/templates/skills/knowledge/lint-and-validate/scripts/type_coverage.py +173 -0
- package/templates/skills/knowledge/mcp-builder/SKILL.md +176 -0
- package/templates/skills/knowledge/mobile-design/SKILL.md +394 -0
- package/templates/skills/knowledge/mobile-design/decision-trees.md +516 -0
- package/templates/skills/knowledge/mobile-design/mobile-backend.md +491 -0
- package/templates/skills/knowledge/mobile-design/mobile-color-system.md +420 -0
- package/templates/skills/knowledge/mobile-design/mobile-debugging.md +122 -0
- package/templates/skills/knowledge/mobile-design/mobile-design-thinking.md +357 -0
- package/templates/skills/knowledge/mobile-design/mobile-navigation.md +458 -0
- package/templates/skills/knowledge/mobile-design/mobile-performance.md +767 -0
- package/templates/skills/knowledge/mobile-design/mobile-testing.md +356 -0
- package/templates/skills/knowledge/mobile-design/mobile-typography.md +433 -0
- package/templates/skills/knowledge/mobile-design/platform-android.md +666 -0
- package/templates/skills/knowledge/mobile-design/platform-ios.md +561 -0
- package/templates/skills/knowledge/mobile-design/scripts/mobile_audit.py +670 -0
- package/templates/skills/knowledge/mobile-design/touch-psychology.md +537 -0
- package/templates/skills/knowledge/nextjs-best-practices/SKILL.md +203 -0
- package/templates/skills/knowledge/nodejs-best-practices/SKILL.md +333 -0
- package/templates/skills/knowledge/parallel-agents/SKILL.md +175 -0
- package/templates/skills/knowledge/performance-profiling/SKILL.md +143 -0
- package/templates/skills/knowledge/performance-profiling/scripts/lighthouse_audit.py +76 -0
- package/templates/skills/knowledge/plan-writing/SKILL.md +152 -0
- package/templates/skills/knowledge/powershell-windows/SKILL.md +167 -0
- package/templates/skills/knowledge/python-patterns/SKILL.md +441 -0
- package/templates/skills/knowledge/react-patterns/SKILL.md +198 -0
- package/templates/skills/knowledge/red-team-tactics/SKILL.md +199 -0
- package/templates/skills/knowledge/seo-fundamentals/SKILL.md +129 -0
- package/templates/skills/knowledge/seo-fundamentals/scripts/seo_checker.py +219 -0
- package/templates/skills/knowledge/server-management/SKILL.md +161 -0
- package/templates/skills/knowledge/systematic-debugging/SKILL.md +109 -0
- package/templates/skills/knowledge/tailwind-patterns/SKILL.md +269 -0
- package/templates/skills/knowledge/tdd-workflow/SKILL.md +149 -0
- package/templates/skills/knowledge/testing-patterns/SKILL.md +178 -0
- package/templates/skills/knowledge/testing-patterns/scripts/test_runner.py +219 -0
- package/templates/skills/knowledge/vulnerability-scanner/SKILL.md +276 -0
- package/templates/skills/knowledge/vulnerability-scanner/checklists.md +121 -0
- package/templates/skills/knowledge/vulnerability-scanner/scripts/security_scan.py +458 -0
- package/templates/skills/knowledge/webapp-testing/SKILL.md +187 -0
- package/templates/skills/knowledge/webapp-testing/scripts/playwright_runner.py +173 -0
|
@@ -0,0 +1,463 @@
|
|
|
1
|
+
# Agent Instructions
|
|
2
|
+
|
|
3
|
+
> `CLAUDE.md` and `GEMINI.md` are symlinks to this file, so the same instructions load in any AI environment.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Getting Started
|
|
8
|
+
|
|
9
|
+
### Installation
|
|
10
|
+
|
|
11
|
+
Run this command in any directory where you want to scaffold a new AI agent:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npx @techwavedev/agi-agent-kit init
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
### Dependencies
|
|
18
|
+
|
|
19
|
+
This toolkit relies on Python scripts for deterministic execution. Ensure you have the following installed:
|
|
20
|
+
|
|
21
|
+
1. **Python 3.8+**: `python3 --version`
|
|
22
|
+
2. **Pip Dependencies**:
|
|
23
|
+
```bash
|
|
24
|
+
pip install requests beautifulsoup4 html2text lxml qdrant-client
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### Updates
|
|
28
|
+
|
|
29
|
+
To update the kit to the latest version:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
# Clear npx cache to force latest version download
|
|
33
|
+
rm -rf ~/.npm/_npx
|
|
34
|
+
npx @techwavedev/agi-agent-kit init
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## Core Philosophy: Determinism Over Probability
|
|
40
|
+
|
|
41
|
+
LLMs are probabilistic, but business logic requires consistency. This system fixes that mismatch by **pushing complexity into deterministic code** and letting the agent focus on intelligent decision-making.
|
|
42
|
+
|
|
43
|
+
**Why it matters:** 90% accuracy per step = 59% success over 5 steps. The solution is to minimize probabilistic steps by delegating execution to reliable scripts.
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## The 3-Layer Architecture
|
|
48
|
+
|
|
49
|
+
### Layer 1: Directives (Intent)
|
|
50
|
+
|
|
51
|
+
**Location:** `directives/`
|
|
52
|
+
|
|
53
|
+
Directives are SOPs written in Markdown that define:
|
|
54
|
+
|
|
55
|
+
- **Goal**: What needs to be accomplished
|
|
56
|
+
- **Inputs**: Required data, context, or parameters
|
|
57
|
+
- **Tools**: Which execution scripts to use
|
|
58
|
+
- **Outputs**: Expected deliverables and their format
|
|
59
|
+
- **Edge Cases**: Known failure modes and how to handle them
|
|
60
|
+
|
|
61
|
+
Think of directives as instructions you'd give a capable but literal-minded employee. They bridge human intent to machine execution.
|
|
62
|
+
|
|
63
|
+
```markdown
|
|
64
|
+
# Example: directives/scrape_competitor_pricing.md
|
|
65
|
+
|
|
66
|
+
## Goal
|
|
67
|
+
|
|
68
|
+
Scrape pricing data from competitor websites and compile into a comparison sheet.
|
|
69
|
+
|
|
70
|
+
## Inputs
|
|
71
|
+
|
|
72
|
+
- `competitors.json` - List of competitor URLs and selectors
|
|
73
|
+
- Target date range (optional, defaults to current)
|
|
74
|
+
|
|
75
|
+
## Execution
|
|
76
|
+
|
|
77
|
+
1. Run `execution/scrape_single_site.py` for each competitor
|
|
78
|
+
2. Run `execution/normalize_pricing.py` to standardize formats
|
|
79
|
+
3. Run `execution/export_to_sheets.py` to push to Google Sheets
|
|
80
|
+
|
|
81
|
+
## Outputs
|
|
82
|
+
|
|
83
|
+
- Google Sheet with pricing comparison (link in `.tmp/output_links.json`)
|
|
84
|
+
- Raw data preserved in `.tmp/scraped/`
|
|
85
|
+
|
|
86
|
+
## Edge Cases
|
|
87
|
+
|
|
88
|
+
- **Rate limiting**: Script auto-retries with exponential backoff (max 3 attempts)
|
|
89
|
+
- **Selector changes**: Log failure, continue with others, alert user at end
|
|
90
|
+
- **Auth required**: Skip site, note in output sheet
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
### Layer 2: Orchestration (Decision-Making)
|
|
96
|
+
|
|
97
|
+
**This is the agent's role.**
|
|
98
|
+
|
|
99
|
+
The agent is the intelligent router between intent and execution:
|
|
100
|
+
|
|
101
|
+
| Responsibility | Description |
|
|
102
|
+
| ------------------------- | ------------------------------------------------------- |
|
|
103
|
+
| **Read directives** | Understand what needs to be done before acting |
|
|
104
|
+
| **Sequence execution** | Call scripts in the right order with correct parameters |
|
|
105
|
+
| **Handle errors** | Diagnose failures and apply self-annealing (see below) |
|
|
106
|
+
| **Ask for clarification** | When requirements are ambiguous, ask—don't guess |
|
|
107
|
+
| **Update directives** | Capture learnings to prevent future failures |
|
|
108
|
+
|
|
109
|
+
**Critical principle:** The agent does NOT perform complex data transformations, API calls, or file operations directly. Instead, it invokes execution scripts that handle these deterministically.
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
❌ Wrong: Agent writes inline Python to scrape a website
|
|
113
|
+
✅ Right: Agent reads directive → invokes execution/scrape_single_site.py → handles result
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
### Layer 3: Execution (Deterministic Work)
|
|
119
|
+
|
|
120
|
+
**Location:** `execution/`
|
|
121
|
+
|
|
122
|
+
Python scripts that handle:
|
|
123
|
+
|
|
124
|
+
- API calls and external integrations
|
|
125
|
+
- Data processing and transformations
|
|
126
|
+
- File operations and I/O
|
|
127
|
+
- Database interactions
|
|
128
|
+
- Export to cloud services (Google Sheets, Slides, etc.)
|
|
129
|
+
|
|
130
|
+
**Script requirements:**
|
|
131
|
+
|
|
132
|
+
- Well-commented and self-documenting
|
|
133
|
+
- Accept clear inputs via CLI arguments or stdin
|
|
134
|
+
- Return structured output (JSON preferred) or exit codes
|
|
135
|
+
- Handle their own error cases gracefully
|
|
136
|
+
- Idempotent where possible (safe to retry)
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
# Example invocation
|
|
140
|
+
python execution/scrape_single_site.py \
|
|
141
|
+
--url "https://competitor.com/pricing" \
|
|
142
|
+
--selector ".price-table" \
|
|
143
|
+
--output ".tmp/scraped/competitor_2024.json"
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
---
|
|
147
|
+
|
|
148
|
+
## Operating Principles
|
|
149
|
+
|
|
150
|
+
### 1. Memory-First (Automatic)
|
|
151
|
+
|
|
152
|
+
**All operations use the Qdrant-powered memory system by default.**
|
|
153
|
+
|
|
154
|
+
```
|
|
155
|
+
┌─────────────────────────────────────────────────────────────┐
|
|
156
|
+
│ QUERY RECEIVED │
|
|
157
|
+
│ ↓ │
|
|
158
|
+
│ 1. Check for opt-out flags ("no cache", "fresh", etc.) │
|
|
159
|
+
│ ↓ │
|
|
160
|
+
│ 2. SEMANTIC CACHE CHECK (similarity > 0.92) │
|
|
161
|
+
│ └─ Hit? → Return cached response (100% token savings) │
|
|
162
|
+
│ ↓ │
|
|
163
|
+
│ 3. CONTEXT RETRIEVAL (top 5 relevant memories) │
|
|
164
|
+
│ └─ Inject decisions, patterns, solutions (80-95% saved) │
|
|
165
|
+
│ ↓ │
|
|
166
|
+
│ 4. EXECUTE QUERY with enriched context │
|
|
167
|
+
│ ↓ │
|
|
168
|
+
│ 5. STORE RESPONSE for future cache hits │
|
|
169
|
+
└─────────────────────────────────────────────────────────────┘
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
**Opt-out:** User says "don't use cache", "no cache", "skip memory", or "fresh"
|
|
173
|
+
|
|
174
|
+
**Auto-stored memories:**
|
|
175
|
+
|
|
176
|
+
- `decision` — Architecture choices, design decisions
|
|
177
|
+
- `code` — Script patterns, reusable implementations
|
|
178
|
+
- `error` — Bug resolutions with root cause
|
|
179
|
+
- `technical` — Documentation, API knowledge
|
|
180
|
+
|
|
181
|
+
> See `directives/memory_integration.md` for full details.
|
|
182
|
+
|
|
183
|
+
### 2. Check for Existing Tools First
|
|
184
|
+
|
|
185
|
+
Before writing any new script:
|
|
186
|
+
|
|
187
|
+
1. **Check `execution/`** for existing scripts that might handle the task
|
|
188
|
+
2. **Review the relevant directive** to see if a workflow already exists
|
|
189
|
+
3. **Search Knowledge Items** for documented patterns and learnings
|
|
190
|
+
|
|
191
|
+
Only create new scripts when truly necessary. Reuse and extend existing tools.
|
|
192
|
+
|
|
193
|
+
### 3. Self-Anneal When Things Break
|
|
194
|
+
|
|
195
|
+
Errors are learning opportunities, not failures. When something breaks:
|
|
196
|
+
|
|
197
|
+
```
|
|
198
|
+
┌─────────────────────────────────────────────────────────┐
|
|
199
|
+
│ ERROR DETECTED │
|
|
200
|
+
│ ↓ │
|
|
201
|
+
│ 1. Read error message and full stack trace │
|
|
202
|
+
│ ↓ │
|
|
203
|
+
│ 2. Diagnose root cause │
|
|
204
|
+
│ ↓ │
|
|
205
|
+
│ 3. Fix the script or adjust parameters │
|
|
206
|
+
│ ↓ │
|
|
207
|
+
│ 4. Test the fix (⚠️ confirm with user if uses paid │
|
|
208
|
+
│ tokens, credits, or has side effects) │
|
|
209
|
+
│ ↓ │
|
|
210
|
+
│ 5. Update directive with what was learned │
|
|
211
|
+
│ ↓ │
|
|
212
|
+
│ SYSTEM IS NOW STRONGER │
|
|
213
|
+
└─────────────────────────────────────────────────────────┘
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
**Example:** You hit an API rate limit → investigate API docs → find batch endpoint → rewrite script to use batching → test → update directive with rate limit info and new approach.
|
|
217
|
+
|
|
218
|
+
### 4. Update Directives as You Learn
|
|
219
|
+
|
|
220
|
+
Directives are **living documents**. Update them when you discover:
|
|
221
|
+
|
|
222
|
+
- API constraints or rate limits
|
|
223
|
+
- Better approaches or optimizations
|
|
224
|
+
- Common errors and their solutions
|
|
225
|
+
- Timing expectations (how long things take)
|
|
226
|
+
- New edge cases
|
|
227
|
+
|
|
228
|
+
**Rules:**
|
|
229
|
+
|
|
230
|
+
- Always ask before creating or overwriting directives (unless explicitly told to proceed)
|
|
231
|
+
- Append learnings to existing directives rather than replacing content
|
|
232
|
+
- Date your additions for future reference
|
|
233
|
+
|
|
234
|
+
### 5. Validate Before Delivering
|
|
235
|
+
|
|
236
|
+
Before marking a task complete:
|
|
237
|
+
|
|
238
|
+
- Verify outputs exist and are accessible
|
|
239
|
+
- Spot-check data quality where possible
|
|
240
|
+
- Confirm deliverables are in the expected location (cloud service, output file, etc.)
|
|
241
|
+
|
|
242
|
+
---
|
|
243
|
+
|
|
244
|
+
## File Organization
|
|
245
|
+
|
|
246
|
+
### Directory Structure
|
|
247
|
+
|
|
248
|
+
```
|
|
249
|
+
project/
|
|
250
|
+
├── .agent/
|
|
251
|
+
│ └── workflows/ # Quick-reference workflows for common tasks
|
|
252
|
+
├── .env # Environment variables and API keys
|
|
253
|
+
├── .gitignore # Excludes credentials and .tmp/
|
|
254
|
+
├── .tmp/ # Intermediate files (always regenerable)
|
|
255
|
+
│ ├── scraped/ # Raw scraped data
|
|
256
|
+
│ ├── processed/ # Transformed data
|
|
257
|
+
│ └── output_links.json # Links to cloud deliverables
|
|
258
|
+
├── credentials.json # Google OAuth credentials
|
|
259
|
+
├── token.json # Google OAuth token
|
|
260
|
+
├── directives/ # SOPs in Markdown
|
|
261
|
+
├── docs/ # Project documentation, guides, and references
|
|
262
|
+
│ ├── guides/ # How-to guides and tutorials
|
|
263
|
+
│ ├── api/ # API references and specifications
|
|
264
|
+
│ └── architecture/ # System design and architecture docs
|
|
265
|
+
├── execution/ # Deterministic Python scripts
|
|
266
|
+
├── skill-creator/ # Skill creation toolkit (use to create new skills)
|
|
267
|
+
├── skills/ # Modular capabilities (PDF reading, web scraping, etc.)
|
|
268
|
+
│ └── <skill-name>/
|
|
269
|
+
│ ├── SKILL.md # Skill instructions and triggers
|
|
270
|
+
│ ├── scripts/ # Executable tools
|
|
271
|
+
│ └── references/ # Documentation loaded on-demand
|
|
272
|
+
└── AGENTS.md # This file (symlinked as CLAUDE.md, GEMINI.md)
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
### Skills
|
|
276
|
+
|
|
277
|
+
Skills are modular packages that extend agent capabilities with specialized workflows, scripts, and domain knowledge. Each skill contains:
|
|
278
|
+
|
|
279
|
+
- **SKILL.md** — Instructions with YAML frontmatter (`name`, `description`) for triggering
|
|
280
|
+
- **scripts/** — Deterministic tools the agent can execute
|
|
281
|
+
- **references/** — Documentation loaded only when needed
|
|
282
|
+
|
|
283
|
+
**Key Resources:**
|
|
284
|
+
|
|
285
|
+
- **Skills Catalog:** `skills/SKILLS_CATALOG.md` — Complete documentation of all available skills
|
|
286
|
+
- **Skill Creator Guide:** `skill-creator/SKILL_skillcreator.md` — How to create new skills
|
|
287
|
+
|
|
288
|
+
**Commands:**
|
|
289
|
+
|
|
290
|
+
```bash
|
|
291
|
+
# Create a new skill
|
|
292
|
+
python3 skill-creator/scripts/init_skill.py <name> --path skills/
|
|
293
|
+
|
|
294
|
+
# Update the skills catalog (MANDATORY after any skill change)
|
|
295
|
+
python3 skill-creator/scripts/update_catalog.py --skills-dir skills/
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
### Deliverables vs. Intermediates
|
|
299
|
+
|
|
300
|
+
| Type | Location | Examples |
|
|
301
|
+
| ----------------- | -------------- | ---------------------------------------------------- |
|
|
302
|
+
| **Deliverables** | Cloud services | Google Sheets, Slides, Drive files, database records |
|
|
303
|
+
| **Intermediates** | `.tmp/` | Scraped HTML, processed JSON, temp exports |
|
|
304
|
+
|
|
305
|
+
**Key principle:** Everything in `.tmp/` can be deleted and regenerated. Deliverables live in the cloud where users can access them.
|
|
306
|
+
|
|
307
|
+
---
|
|
308
|
+
|
|
309
|
+
## Integration with Agent Tools
|
|
310
|
+
|
|
311
|
+
### Reading and Research
|
|
312
|
+
|
|
313
|
+
- Use `view_file` to read directives before starting work
|
|
314
|
+
- Use `grep_search` to find relevant scripts in `execution/`
|
|
315
|
+
- Use `find_by_name` to locate files across the project
|
|
316
|
+
- Search Knowledge Items for prior solutions to similar problems
|
|
317
|
+
|
|
318
|
+
### Execution
|
|
319
|
+
|
|
320
|
+
- Use `run_command` to invoke execution scripts
|
|
321
|
+
- Capture output and exit codes for decision-making
|
|
322
|
+
- Use `command_status` to monitor long-running scripts
|
|
323
|
+
|
|
324
|
+
### Writing and Updating
|
|
325
|
+
|
|
326
|
+
- Use `write_to_file` for new scripts (with clear documentation)
|
|
327
|
+
- Use `replace_file_content` to update existing directives with learnings
|
|
328
|
+
- Create new workflows in `.agent/workflows/` for repeatable processes
|
|
329
|
+
|
|
330
|
+
---
|
|
331
|
+
|
|
332
|
+
## Workflow Quick Reference
|
|
333
|
+
|
|
334
|
+
For frequently-used processes, create workflows in `.agent/workflows/`:
|
|
335
|
+
|
|
336
|
+
```markdown
|
|
337
|
+
# .agent/workflows/refresh-pricing.md
|
|
338
|
+
|
|
339
|
+
---
|
|
340
|
+
|
|
341
|
+
## description: Refresh competitor pricing data and update comparison sheet
|
|
342
|
+
|
|
343
|
+
1. Verify `.env` contains required API keys
|
|
344
|
+
2. Run `python execution/scrape_all_competitors.py`
|
|
345
|
+
// turbo
|
|
346
|
+
3. Run `python execution/normalize_pricing.py --input .tmp/scraped/ --output .tmp/processed/`
|
|
347
|
+
// turbo
|
|
348
|
+
4. Run `python execution/export_to_sheets.py --input .tmp/processed/pricing.json`
|
|
349
|
+
5. Verify Google Sheet is updated and share link with user
|
|
350
|
+
```
|
|
351
|
+
|
|
352
|
+
> **Note:** Steps marked with `// turbo` can be auto-run. Use `// turbo-all` at the top to auto-run all command steps.
|
|
353
|
+
|
|
354
|
+
---
|
|
355
|
+
|
|
356
|
+
## Best Practices for Execution Scripts
|
|
357
|
+
|
|
358
|
+
### Script Template
|
|
359
|
+
|
|
360
|
+
```python
|
|
361
|
+
#!/usr/bin/env python3
|
|
362
|
+
"""
|
|
363
|
+
Script: script_name.py
|
|
364
|
+
Purpose: Brief description of what this script does
|
|
365
|
+
|
|
366
|
+
Usage:
|
|
367
|
+
python script_name.py --input <file> --output <file> [--verbose]
|
|
368
|
+
|
|
369
|
+
Arguments:
|
|
370
|
+
--input Path to input file (required)
|
|
371
|
+
--output Path to output file (required)
|
|
372
|
+
--verbose Enable detailed logging (optional)
|
|
373
|
+
|
|
374
|
+
Exit Codes:
|
|
375
|
+
0 - Success
|
|
376
|
+
1 - Invalid arguments
|
|
377
|
+
2 - Input file not found
|
|
378
|
+
3 - API/Network error
|
|
379
|
+
4 - Processing error
|
|
380
|
+
"""
|
|
381
|
+
|
|
382
|
+
import argparse
|
|
383
|
+
import json
|
|
384
|
+
import sys
|
|
385
|
+
from pathlib import Path
|
|
386
|
+
|
|
387
|
+
def main():
|
|
388
|
+
parser = argparse.ArgumentParser(description=__doc__)
|
|
389
|
+
parser.add_argument('--input', required=True, help='Input file path')
|
|
390
|
+
parser.add_argument('--output', required=True, help='Output file path')
|
|
391
|
+
parser.add_argument('--verbose', action='store_true', help='Verbose output')
|
|
392
|
+
args = parser.parse_args()
|
|
393
|
+
|
|
394
|
+
# Your logic here
|
|
395
|
+
try:
|
|
396
|
+
result = process(args.input)
|
|
397
|
+
Path(args.output).write_text(json.dumps(result, indent=2))
|
|
398
|
+
print(json.dumps({"status": "success", "output": args.output}))
|
|
399
|
+
sys.exit(0)
|
|
400
|
+
except Exception as e:
|
|
401
|
+
print(json.dumps({"status": "error", "message": str(e)}), file=sys.stderr)
|
|
402
|
+
sys.exit(4)
|
|
403
|
+
|
|
404
|
+
if __name__ == '__main__':
|
|
405
|
+
main()
|
|
406
|
+
```
|
|
407
|
+
|
|
408
|
+
### Naming Conventions
|
|
409
|
+
|
|
410
|
+
| Type | Convention | Example |
|
|
411
|
+
| ---------- | --------------------- | -------------------------------------------- |
|
|
412
|
+
| Scripts | `verb_noun.py` | `scrape_website.py`, `export_to_sheets.py` |
|
|
413
|
+
| Directives | `noun_or_task.md` | `competitor_analysis.md`, `weekly_report.md` |
|
|
414
|
+
| Temp files | Descriptive with date | `.tmp/scraped/competitor_2024-01-19.json` |
|
|
415
|
+
|
|
416
|
+
---
|
|
417
|
+
|
|
418
|
+
## Error Handling Patterns
|
|
419
|
+
|
|
420
|
+
### In Scripts
|
|
421
|
+
|
|
422
|
+
```python
|
|
423
|
+
# Always return structured errors
|
|
424
|
+
try:
|
|
425
|
+
result = risky_operation()
|
|
426
|
+
except RateLimitError as e:
|
|
427
|
+
print(json.dumps({
|
|
428
|
+
"status": "rate_limited",
|
|
429
|
+
"retry_after": e.retry_after,
|
|
430
|
+
"message": str(e)
|
|
431
|
+
}))
|
|
432
|
+
sys.exit(3)
|
|
433
|
+
except Exception as e:
|
|
434
|
+
print(json.dumps({
|
|
435
|
+
"status": "error",
|
|
436
|
+
"type": type(e).__name__,
|
|
437
|
+
"message": str(e)
|
|
438
|
+
}))
|
|
439
|
+
sys.exit(4)
|
|
440
|
+
```
|
|
441
|
+
|
|
442
|
+
### As the Agent
|
|
443
|
+
|
|
444
|
+
When a script returns an error:
|
|
445
|
+
|
|
446
|
+
1. Parse the structured error output
|
|
447
|
+
2. Determine if it's recoverable (rate limit → wait and retry) or fatal (auth error → ask user)
|
|
448
|
+
3. Apply the fix or escalate to the user
|
|
449
|
+
4. **Update the directive** with the failure mode and solution
|
|
450
|
+
|
|
451
|
+
---
|
|
452
|
+
|
|
453
|
+
## Summary
|
|
454
|
+
|
|
455
|
+
You are the intelligent orchestrator between human intent (directives) and deterministic execution (Python scripts). Your role is to:
|
|
456
|
+
|
|
457
|
+
1. **Understand** what needs to be done by reading directives
|
|
458
|
+
2. **Execute** by calling the right scripts in the right order
|
|
459
|
+
3. **Adapt** by handling errors and edge cases gracefully
|
|
460
|
+
4. **Learn** by updating directives with new knowledge
|
|
461
|
+
5. **Deliver** by ensuring outputs reach their intended destination
|
|
462
|
+
|
|
463
|
+
**Be pragmatic. Be reliable. Self-anneal.**
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright [yyyy] [name of copyright owner]
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|