oh-my-agent-commandcode 0.0.0-stage → 20.38.4
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/README.md +35 -2
- package/filter-test-output.sh +52 -0
- package/mods/oma.ts +347 -0
- package/package.json +30 -4
- package/skills/_shared/conditional/experiment-ledger.md +28 -0
- package/skills/_shared/conditional/exploration-loop.md +22 -0
- package/skills/_shared/conditional/quality-score.md +33 -0
- package/skills/_shared/core/anti-ai-prose.md +191 -0
- package/skills/_shared/core/api-contracts/README.md +28 -0
- package/skills/_shared/core/api-contracts/template.md +90 -0
- package/skills/_shared/core/clarification-protocol.md +23 -0
- package/skills/_shared/core/code-intelligence.md +46 -0
- package/skills/_shared/core/collaboration-policy.md +28 -0
- package/skills/_shared/core/common-checklist.md +28 -0
- package/skills/_shared/core/context-budget.md +22 -0
- package/skills/_shared/core/context-loading.md +34 -0
- package/skills/_shared/core/difficulty-guide.md +26 -0
- package/skills/_shared/core/execution-policy.md +31 -0
- package/skills/_shared/core/lessons-learned.md +33 -0
- package/skills/_shared/core/prompt-structure.md +18 -0
- package/skills/_shared/core/quality-principles.md +11 -0
- package/skills/_shared/core/session-metrics.md +35 -0
- package/skills/_shared/core/skill-routing.md +39 -0
- package/skills/_shared/core/test-approach.md +54 -0
- package/skills/_shared/core/vendor-detection.md +52 -0
- package/skills/_shared/runtime/memory-protocol.md +118 -0
- package/skills/_shared/runtime/result-contract.md +64 -0
- package/skills/_shared/ui-interaction-quality.md +133 -0
- package/skills/oma-academic-writing/SKILL.md +181 -0
- package/skills/oma-academic-writing/resources/abstract-guide.md +51 -0
- package/skills/oma-academic-writing/resources/academic-verb-tiers.md +42 -0
- package/skills/oma-academic-writing/resources/anti-ai-checklist.md +52 -0
- package/skills/oma-academic-writing/resources/hedging-guide.md +132 -0
- package/skills/oma-academic-writing/resources/sentence-structure-reference.md +151 -0
- package/skills/oma-architecture/SKILL.md +203 -0
- package/skills/oma-architecture/resources/api-evolution.md +41 -0
- package/skills/oma-architecture/resources/checklist.md +42 -0
- package/skills/oma-architecture/resources/execution-protocol.md +115 -0
- package/skills/oma-architecture/resources/methodology-selection.md +92 -0
- package/skills/oma-architecture/resources/migration-patterns.md +28 -0
- package/skills/oma-architecture/resources/output-templates.md +111 -0
- package/skills/oma-architecture/resources/stakeholder-synthesis.md +80 -0
- package/skills/oma-backend/SKILL.md +202 -0
- package/skills/oma-backend/resources/checklist.md +45 -0
- package/skills/oma-backend/resources/error-playbook.md +97 -0
- package/skills/oma-backend/resources/execution-protocol.md +39 -0
- package/skills/oma-backend/resources/orm-reference.md +61 -0
- package/skills/oma-backend/variants/node/api-template.ts +315 -0
- package/skills/oma-backend/variants/node/snippets.md +475 -0
- package/skills/oma-backend/variants/node/stack.yaml +21 -0
- package/skills/oma-backend/variants/node/tech-stack.md +33 -0
- package/skills/oma-backend/variants/python/api-template.py +378 -0
- package/skills/oma-backend/variants/python/snippets.md +199 -0
- package/skills/oma-backend/variants/python/stack.yaml +18 -0
- package/skills/oma-backend/variants/python/tech-stack.md +45 -0
- package/skills/oma-backend/variants/rust/api-template.rs +635 -0
- package/skills/oma-backend/variants/rust/snippets.md +471 -0
- package/skills/oma-backend/variants/rust/stack.yaml +20 -0
- package/skills/oma-backend/variants/rust/tech-stack.md +36 -0
- package/skills/oma-backend/variants/stack.schema.json +73 -0
- package/skills/oma-brainstorm/SKILL.md +166 -0
- package/skills/oma-brainstorm/resources/triz-lite.md +117 -0
- package/skills/oma-coordination/SKILL.md +171 -0
- package/skills/oma-db/SKILL.md +201 -0
- package/skills/oma-db/resources/anti-patterns.md +177 -0
- package/skills/oma-db/resources/checklist.md +67 -0
- package/skills/oma-db/resources/document-templates.md +107 -0
- package/skills/oma-db/resources/error-playbook.md +50 -0
- package/skills/oma-db/resources/examples.md +170 -0
- package/skills/oma-db/resources/execution-protocol.md +127 -0
- package/skills/oma-db/resources/iso-controls.md +98 -0
- package/skills/oma-db/resources/migration-playbook.md +93 -0
- package/skills/oma-db/resources/query-tuning.md +57 -0
- package/skills/oma-db/resources/vector-db.md +159 -0
- package/skills/oma-debug/SKILL.md +146 -0
- package/skills/oma-debug/resources/bug-report-template.md +327 -0
- package/skills/oma-debug/resources/checklist.md +31 -0
- package/skills/oma-debug/resources/common-patterns.md +734 -0
- package/skills/oma-debug/resources/debugging-checklist.md +364 -0
- package/skills/oma-debug/resources/error-playbook.md +94 -0
- package/skills/oma-debug/resources/execution-protocol.md +40 -0
- package/skills/oma-design/SKILL.md +135 -0
- package/skills/oma-design/resources/asset-strategy.md +34 -0
- package/skills/oma-design/resources/checklist.md +63 -0
- package/skills/oma-design/resources/data-grid.md +48 -0
- package/skills/oma-design/resources/design-md-spec.md +107 -0
- package/skills/oma-design/resources/design-tokens.md +53 -0
- package/skills/oma-design/resources/error-playbook.md +18 -0
- package/skills/oma-design/resources/execution-protocol.md +95 -0
- package/skills/oma-design/resources/external-design-skills.md +130 -0
- package/skills/oma-design/resources/getdesign-fetcher.md +104 -0
- package/skills/oma-design/resources/product-interface-review.md +59 -0
- package/skills/oma-design/resources/redesign-protocol.md +52 -0
- package/skills/oma-design/resources/stitch-integration.md +244 -0
- package/skills/oma-dev-workflow/SKILL.md +375 -0
- package/skills/oma-dev-workflow/resources/affected-checks.py +58 -0
- package/skills/oma-dev-workflow/resources/api-workflows.md +58 -0
- package/skills/oma-dev-workflow/resources/database-patterns.md +107 -0
- package/skills/oma-dev-workflow/resources/i18n-patterns.md +63 -0
- package/skills/oma-dev-workflow/resources/release-coordination.md +240 -0
- package/skills/oma-dev-workflow/resources/tooling-profiles.md +217 -0
- package/skills/oma-dev-workflow/resources/troubleshooting.md +78 -0
- package/skills/oma-dev-workflow/resources/validation-pipeline.md +246 -0
- package/skills/oma-docs/SKILL.md +77 -0
- package/skills/oma-docs/resources/commands.md +76 -0
- package/skills/oma-explanation/SKILL.md +212 -0
- package/skills/oma-explanation/resources/document-structure.md +115 -0
- package/skills/oma-explanation/resources/draft-format.md +199 -0
- package/skills/oma-explanation/resources/html-contract.md +102 -0
- package/skills/oma-frontend/SKILL.md +227 -0
- package/skills/oma-frontend/resources/angular-rules.md +110 -0
- package/skills/oma-frontend/resources/checklist.md +76 -0
- package/skills/oma-frontend/resources/error-playbook.md +125 -0
- package/skills/oma-frontend/resources/execution-protocol.md +46 -0
- package/skills/oma-frontend/resources/snippets.md +354 -0
- package/skills/oma-frontend/resources/specialized-visual-implementation.md +193 -0
- package/skills/oma-frontend/resources/tailwind-rules.md +83 -0
- package/skills/oma-frontend/resources/tech-stack.md +156 -0
- package/skills/oma-hwp/SKILL.md +166 -0
- package/skills/oma-hwp/config/hwp-config.yaml +35 -0
- package/skills/oma-hwp/resources/balanced-tables.ts +39 -0
- package/skills/oma-hwp/resources/execution-protocol.md +145 -0
- package/skills/oma-hwp/resources/flatten-tables.ts +101 -0
- package/skills/oma-hwp/resources/package.json +13 -0
- package/skills/oma-hwp/resources/troubleshooting.md +70 -0
- package/skills/oma-hwp/resources/tsconfig.json +10 -0
- package/skills/oma-hwp/resources/turndown-plugin-gfm.d.ts +9 -0
- package/skills/oma-image/SKILL.md +142 -0
- package/skills/oma-image/config/image-config.yaml +70 -0
- package/skills/oma-image/resources/checklist.md +18 -0
- package/skills/oma-image/resources/execution-protocol.md +117 -0
- package/skills/oma-image/resources/invocation.md +105 -0
- package/skills/oma-image/resources/prompt-tips.md +71 -0
- package/skills/oma-image/resources/vendor-matrix.md +90 -0
- package/skills/oma-market/SKILL.md +142 -0
- package/skills/oma-market/resources/checklist.md +12 -0
- package/skills/oma-market/resources/error-playbook.md +12 -0
- package/skills/oma-market/resources/execution-protocol.md +60 -0
- package/skills/oma-market/resources/frameworks/pestel.md +101 -0
- package/skills/oma-market/resources/frameworks/porters-5f.md +90 -0
- package/skills/oma-market/resources/frameworks/swot.md +61 -0
- package/skills/oma-market/resources/intent-rules.md +35 -0
- package/skills/oma-market/resources/output-laws.md +53 -0
- package/skills/oma-mobile/SKILL.md +168 -0
- package/skills/oma-mobile/resources/checklist.md +77 -0
- package/skills/oma-mobile/resources/error-playbook.md +198 -0
- package/skills/oma-mobile/resources/execution-protocol.md +47 -0
- package/skills/oma-mobile/resources/screen-template.dart +331 -0
- package/skills/oma-mobile/resources/screen-template.swift +239 -0
- package/skills/oma-mobile/resources/screen-template.tsx +179 -0
- package/skills/oma-mobile/resources/tech-stack.md +69 -0
- package/skills/oma-mobile/variants/README.md +45 -0
- package/skills/oma-mobile/variants/flutter/api-template.dart +461 -0
- package/skills/oma-mobile/variants/flutter/snippets.md +1353 -0
- package/skills/oma-mobile/variants/flutter/stack.yaml +21 -0
- package/skills/oma-mobile/variants/flutter/tech-stack.md +201 -0
- package/skills/oma-mobile/variants/kotlin-android/api-template.kt +182 -0
- package/skills/oma-mobile/variants/kotlin-android/snippets.md +871 -0
- package/skills/oma-mobile/variants/kotlin-android/stack.yaml +32 -0
- package/skills/oma-mobile/variants/kotlin-android/tech-stack.md +159 -0
- package/skills/oma-mobile/variants/react-native/api-template.ts +531 -0
- package/skills/oma-mobile/variants/react-native/snippets.md +1014 -0
- package/skills/oma-mobile/variants/react-native/stack.yaml +22 -0
- package/skills/oma-mobile/variants/react-native/tech-stack.md +192 -0
- package/skills/oma-mobile/variants/stack.schema.json +68 -0
- package/skills/oma-mobile/variants/swift-ios/api-template.swift +165 -0
- package/skills/oma-mobile/variants/swift-ios/snippets.md +1028 -0
- package/skills/oma-mobile/variants/swift-ios/stack.yaml +25 -0
- package/skills/oma-mobile/variants/swift-ios/tech-stack.md +174 -0
- package/skills/oma-observability/SKILL.md +225 -0
- package/skills/oma-observability/resources/anti-patterns.md +555 -0
- package/skills/oma-observability/resources/boundaries/cross-application.md +348 -0
- package/skills/oma-observability/resources/boundaries/multi-tenant.md +290 -0
- package/skills/oma-observability/resources/boundaries/release.md +372 -0
- package/skills/oma-observability/resources/boundaries/slo.md +225 -0
- package/skills/oma-observability/resources/checklist.md +123 -0
- package/skills/oma-observability/resources/examples.md +448 -0
- package/skills/oma-observability/resources/execution-protocol.md +166 -0
- package/skills/oma-observability/resources/incident-forensics.md +348 -0
- package/skills/oma-observability/resources/intent-rules.md +307 -0
- package/skills/oma-observability/resources/layers/L3-network.md +281 -0
- package/skills/oma-observability/resources/layers/L4-transport.md +299 -0
- package/skills/oma-observability/resources/layers/L7-application/crash-analytics.md +359 -0
- package/skills/oma-observability/resources/layers/L7-application/mobile-rum.md +278 -0
- package/skills/oma-observability/resources/layers/L7-application/waf.md +246 -0
- package/skills/oma-observability/resources/layers/L7-application/web-rum.md +350 -0
- package/skills/oma-observability/resources/layers/mesh.md +368 -0
- package/skills/oma-observability/resources/matrix.md +177 -0
- package/skills/oma-observability/resources/meta-observability.md +605 -0
- package/skills/oma-observability/resources/observability-as-code.md +666 -0
- package/skills/oma-observability/resources/signals/audit.md +310 -0
- package/skills/oma-observability/resources/signals/cost.md +303 -0
- package/skills/oma-observability/resources/signals/logs.md +263 -0
- package/skills/oma-observability/resources/signals/metrics.md +478 -0
- package/skills/oma-observability/resources/signals/privacy.md +351 -0
- package/skills/oma-observability/resources/signals/profiles.md +245 -0
- package/skills/oma-observability/resources/signals/traces.md +360 -0
- package/skills/oma-observability/resources/standards.md +214 -0
- package/skills/oma-observability/resources/transport/collector-topology.md +308 -0
- package/skills/oma-observability/resources/transport/otlp-grpc-vs-http.md +256 -0
- package/skills/oma-observability/resources/transport/sampling-recipes.md +297 -0
- package/skills/oma-observability/resources/transport/udp-statsd-mtu.md +167 -0
- package/skills/oma-observability/resources/vendor-categories.md +352 -0
- package/skills/oma-orchestration/SKILL.md +302 -0
- package/skills/oma-orchestration/config/cli-config.yaml +92 -0
- package/skills/oma-orchestration/resources/memory-schema.md +232 -0
- package/skills/oma-orchestration/resources/subagent-prompt-template.md +30 -0
- package/skills/oma-orchestration/scripts/parallel-run.sh +6 -0
- package/skills/oma-orchestration/scripts/spawn-agent.sh +5 -0
- package/skills/oma-orchestration/scripts/verify.sh +20 -0
- package/skills/oma-orchestration/templates/backend-task.md +19 -0
- package/skills/oma-orchestration/templates/debug-task.md +16 -0
- package/skills/oma-orchestration/templates/frontend-task.md +18 -0
- package/skills/oma-orchestration/templates/mobile-task.md +18 -0
- package/skills/oma-orchestration/templates/qa-task.md +16 -0
- package/skills/oma-orchestration/templates/tasks-example.yaml +15 -0
- package/skills/oma-pdf/SKILL.md +162 -0
- package/skills/oma-pdf/config/pdf-config.yaml +27 -0
- package/skills/oma-pdf/resources/execution-protocol.md +127 -0
- package/skills/oma-pm/SKILL.md +157 -0
- package/skills/oma-pm/resources/error-playbook.md +75 -0
- package/skills/oma-pm/resources/examples.md +439 -0
- package/skills/oma-pm/resources/execution-protocol.md +62 -0
- package/skills/oma-pm/resources/iso-planning.md +110 -0
- package/skills/oma-pm/resources/plan-phase-protocol.md +66 -0
- package/skills/oma-pm/resources/task-template.json +86 -0
- package/skills/oma-qa/SKILL.md +141 -0
- package/skills/oma-qa/resources/checklist.md +339 -0
- package/skills/oma-qa/resources/error-playbook.md +98 -0
- package/skills/oma-qa/resources/execution-protocol.md +169 -0
- package/skills/oma-qa/resources/iso-quality.md +82 -0
- package/skills/oma-qa/resources/verify-ship-protocol.md +116 -0
- package/skills/oma-recap/SKILL.md +245 -0
- package/skills/oma-recap/resources/output-formats.md +83 -0
- package/skills/oma-refactor/SKILL.md +184 -0
- package/skills/oma-refactor/resources/definition.md +108 -0
- package/skills/oma-refactor/resources/governance.md +33 -0
- package/skills/oma-refactor/resources/hotspots.py +44 -0
- package/skills/oma-refactor/resources/measurement.md +93 -0
- package/skills/oma-scholar/SKILL.md +276 -0
- package/skills/oma-scholar/config/scholar-config.yaml +79 -0
- package/skills/oma-scholar/resources/api-endpoints.md +174 -0
- package/skills/oma-scholar/resources/checklist.md +92 -0
- package/skills/oma-scholar/resources/execution-protocol.md +224 -0
- package/skills/oma-scholar/resources/fallback-providers.md +143 -0
- package/skills/oma-scholar/resources/setup-openalex.md +85 -0
- package/skills/oma-scholar/resources/sidecar-spec.md +341 -0
- package/skills/oma-scholar/resources/upstream-spec-cache.md +972 -0
- package/skills/oma-scm/SKILL.md +103 -0
- package/skills/oma-scm/resources/cm-operations.md +56 -0
- package/skills/oma-scm/resources/codeowners-playbook.md +45 -0
- package/skills/oma-scm/resources/conventional-commits.md +108 -0
- package/skills/oma-scm/resources/merge-risk.md +76 -0
- package/skills/oma-scm/resources/onboarding-risk-signals.md +71 -0
- package/skills/oma-search/SKILL.md +125 -0
- package/skills/oma-search/resources/checklist.md +36 -0
- package/skills/oma-search/resources/error-playbook.md +66 -0
- package/skills/oma-search/resources/examples.md +80 -0
- package/skills/oma-search/resources/execution-protocol.md +86 -0
- package/skills/oma-search/resources/intent-rules.md +47 -0
- package/skills/oma-search/resources/trust-registry.md +53 -0
- package/skills/oma-security/SKILL.md +172 -0
- package/skills/oma-security/resources/artex.md +108 -0
- package/skills/oma-security/resources/ci.md +134 -0
- package/skills/oma-security/resources/cisco-source.md +108 -0
- package/skills/oma-security/resources/deepsec-config.md +45 -0
- package/skills/oma-security/resources/deepsec-matchers.md +35 -0
- package/skills/oma-security/resources/deepsec-scanning.md +45 -0
- package/skills/oma-security/resources/deepsec-setup.md +41 -0
- package/skills/oma-security/resources/findings-contract.md +408 -0
- package/skills/oma-security/resources/mcp-scanning.md +122 -0
- package/skills/oma-security/resources/skill-scanning.md +106 -0
- package/skills/oma-security/resources/validation.md +71 -0
- package/skills/oma-skill-creation/SKILL.md +84 -0
- package/skills/oma-skill-creation/resources/prompt-evaluation.md +36 -0
- package/skills/oma-skill-creation/resources/ssl-lite-template.md +108 -0
- package/skills/oma-skill-creation/resources/validation-checklist.md +101 -0
- package/skills/oma-slide/SKILL.md +277 -0
- package/skills/oma-slide/resources/animation-patterns.md +245 -0
- package/skills/oma-slide/resources/assets/deck-stage.js +514 -0
- package/skills/oma-slide/resources/assets/viewport-base.css +257 -0
- package/skills/oma-slide/resources/canva-integration.md +203 -0
- package/skills/oma-slide/resources/checklist.md +46 -0
- package/skills/oma-slide/resources/design-doctrine.md +260 -0
- package/skills/oma-slide/resources/fixed-stage.md +232 -0
- package/skills/oma-slide/resources/generation-protocol.md +393 -0
- package/skills/oma-slide/resources/native-pptx.md +84 -0
- package/skills/oma-slide/resources/selection-index.json +461 -0
- package/skills/oma-slide/resources/style-presets.LICENSE +10 -0
- package/skills/oma-slide/resources/style-presets.md +520 -0
- package/skills/oma-tf-infra/SKILL.md +201 -0
- package/skills/oma-tf-infra/resources/checklist.md +53 -0
- package/skills/oma-tf-infra/resources/cost-optimization.md +574 -0
- package/skills/oma-tf-infra/resources/error-playbook.md +68 -0
- package/skills/oma-tf-infra/resources/examples.md +38 -0
- package/skills/oma-tf-infra/resources/execution-protocol.md +129 -0
- package/skills/oma-tf-infra/resources/iso-42001-infra.md +229 -0
- package/skills/oma-tf-infra/resources/multi-cloud-examples.md +241 -0
- package/skills/oma-tf-infra/resources/policy-testing-examples.md +332 -0
- package/skills/oma-translation/SKILL.md +229 -0
- package/skills/oma-translation/resources/anti-ai-patterns.md +104 -0
- package/skills/oma-translation/resources/lang/_template.md +73 -0
- package/skills/oma-translation/resources/lang/en.md +123 -0
- package/skills/oma-translation/resources/lang/ja.md +274 -0
- package/skills/oma-translation/resources/lang/ko.md +228 -0
- package/skills/oma-translation/resources/lang/zh.md +285 -0
- package/skills/oma-translation/resources/style-skills.md +104 -0
- package/skills/oma-translation/resources/translation-rubric.md +126 -0
- package/skills/oma-video/SKILL.md +229 -0
- package/skills/oma-video/config/video-config.yaml +60 -0
- package/skills/oma-video/resources/checklist.md +26 -0
- package/skills/oma-video/resources/execution-protocol.md +122 -0
- package/skills/oma-video/resources/existing-media.md +185 -0
- package/skills/oma-video/resources/hyperframes-authoring/README.md +44 -0
- package/skills/oma-video/resources/hyperframes-authoring/demo.md +31 -0
- package/skills/oma-video/resources/hyperframes-authoring/explainer.md +10 -0
- package/skills/oma-video/resources/hyperframes-authoring/shorts.md +10 -0
- package/skills/oma-video/resources/motion-principles.md +81 -0
- package/skills/oma-video/resources/mpt/driver.py +301 -0
- package/skills/oma-video/resources/prompt-tips.md +75 -0
- package/skills/oma-video/resources/script-schema.md +81 -0
- package/skills/oma-video/resources/sound-design.md +127 -0
- package/skills/oma-video/resources/strudel/package.json +11 -0
- package/skills/oma-video/resources/strudel/page.html +87 -0
- package/skills/oma-video/resources/strudel/render.mjs +295 -0
- package/skills/oma-video/resources/vendor-matrix.md +124 -0
- package/skills/oma-voice/SKILL.md +249 -0
- package/skills/oma-voice/config/voice-config.yaml +30 -0
- package/skills/oma-voice/resources/audio-processing.md +119 -0
- package/skills/oma-voice/resources/checklist.md +47 -0
- package/skills/oma-voice/resources/execution-protocol.md +215 -0
- package/skills/oma-voice/resources/prompt-tips.md +43 -0
- package/skills/oma-voice/resources/voice-matrix.md +51 -0
- package/skills/oma-voice/resources/voicestudio.md +87 -0
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
# Scholar - Execution Protocol
|
|
2
|
+
|
|
3
|
+
Choose the mode based on user intent, then follow its steps.
|
|
4
|
+
|
|
5
|
+
## Mode 1: Generate
|
|
6
|
+
|
|
7
|
+
Create a `.knows.yaml` sidecar from a paper, draft, or research notes.
|
|
8
|
+
|
|
9
|
+
### Step 0: Gather Source
|
|
10
|
+
|
|
11
|
+
1. Identify input: PDF path, LaTeX file, plain text, or pasted content
|
|
12
|
+
2. If PDF and only path is given -> chain via `oma-pdf` first to extract markdown
|
|
13
|
+
3. Determine output path: `{base}.knows.yaml` next to input (or as configured)
|
|
14
|
+
|
|
15
|
+
### Step 1: Read Source Thoroughly
|
|
16
|
+
|
|
17
|
+
- Read the entire source: abstract, methods, results, discussion, limitations
|
|
18
|
+
- Identify: claims, methods, evidence (tables/figures), datasets, code/repo links, cited works, assumptions
|
|
19
|
+
- Note paper metadata: title, authors, venue, year, DOI (only if visible)
|
|
20
|
+
|
|
21
|
+
### Step 2: Draft Sidecar Structure
|
|
22
|
+
|
|
23
|
+
Use the local production compatibility rules in `sidecar-spec.md`; they do not establish full canonical-schema conformance. Top-level structure:
|
|
24
|
+
|
|
25
|
+
- `knows_version: "0.9.0"`, `profile: "paper@1"`, `subject_ref: art:paper`
|
|
26
|
+
- **Top-level metadata**: `title`, `authors`, `venue`, `year` (no `metadata` wrapper); omit `doi`/`venue`/`year` if not visible
|
|
27
|
+
- `summary`: one-paragraph overview
|
|
28
|
+
- `coverage`: object with `statements` and `evidence` enums (NOT a single value)
|
|
29
|
+
- `provenance`: `origin`, single `actor` object (`type: tool|person|org`), `generated_at`, `method`
|
|
30
|
+
- `version`: `{spec, record, source}`
|
|
31
|
+
- `freshness`: `{as_of, update_policy}`
|
|
32
|
+
- `artifacts`: list (`art:` prefix, `artifact_type`, `role: subject|supporting|cited`); include `representations` for the source
|
|
33
|
+
- `statements`: list (`stmt:` prefix, `statement_type`, `modality`, `status`, `confidence` object, `source_anchors`)
|
|
34
|
+
- `evidence`: list (`ev:` prefix, `evidence_type`)
|
|
35
|
+
- `relations`: list (`rel:` prefix, `predicate` in present tense, `subject_ref`, `object_ref`)
|
|
36
|
+
- `actions`: usually empty for paper profile
|
|
37
|
+
|
|
38
|
+
### Step 3: Wire Relations
|
|
39
|
+
|
|
40
|
+
Use relations appropriate to the statement type and supported by the source.
|
|
41
|
+
Claims with evidence use `supported_by`; methods may use `uses`, `implements`,
|
|
42
|
+
or `evaluates_on`. Definitions and open questions can remain source-anchored
|
|
43
|
+
without invented empirical support. The lint ratio target of 1.5 is a coverage
|
|
44
|
+
diagnostic, not a requirement to pad the graph. Common patterns:
|
|
45
|
+
|
|
46
|
+
| Subject | Predicate | Object |
|
|
47
|
+
|---------|-----------|--------|
|
|
48
|
+
| Claim | `supported_by` | Evidence |
|
|
49
|
+
| Claim | `depends_on` | Assumption |
|
|
50
|
+
| Method | `evaluates_on` | Dataset |
|
|
51
|
+
| Method | `implements` | Code repo |
|
|
52
|
+
| Paper | `cites` | Other paper (optional `citation_intent`) |
|
|
53
|
+
| Claim | `challenged_by` | Counter-claim / prior work |
|
|
54
|
+
|
|
55
|
+
### Step 4: Optional Metadata Enrichment
|
|
56
|
+
|
|
57
|
+
If `OPENALEX_API_KEY` is set and DOI/venue/year are missing:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
# PAPER_TITLE is the source title; inspect candidates before selecting a record.
|
|
61
|
+
curl -s --get "https://api.openalex.org/works" \
|
|
62
|
+
--data-urlencode "search=$PAPER_TITLE" \
|
|
63
|
+
--data-urlencode "api_key=$OPENALEX_API_KEY" \
|
|
64
|
+
| jq '.results[] | {id, title, doi, publication_year, authorships, primary_location}'
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
If the key is not set, skip enrichment and tell the user how to set it (point to `setup-openalex.md`).
|
|
68
|
+
|
|
69
|
+
Verify candidate identity against the source title, authors, year, and any
|
|
70
|
+
existing DOI/arXiv identifier before enrichment. A title-search ranking is not
|
|
71
|
+
identity proof. Confirm a selected DOI with a DOI lookup; omit disputed fields
|
|
72
|
+
when candidates remain ambiguous. A curated catalog is an external source,
|
|
73
|
+
and local structural lint cannot verify that it describes the same paper.
|
|
74
|
+
Mention in the final report which fields were enriched rather than extracted from source.
|
|
75
|
+
|
|
76
|
+
### Step 5: Lint
|
|
77
|
+
|
|
78
|
+
Always validate before reporting done:
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
oma scholar lint {output}.knows.yaml
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
For newly generated local-profile output, fix reported issues and re-run. For imported canonical records, preserve valid wider shapes, report local-lint incompatibilities, and do not silently normalize away information.
|
|
85
|
+
|
|
86
|
+
### Step 6: Report
|
|
87
|
+
|
|
88
|
+
Tell the user:
|
|
89
|
+
- Output path
|
|
90
|
+
- Statement count, evidence count, relations/statement ratio
|
|
91
|
+
- Any fields omitted due to anti-fabrication (e.g., "DOI not extracted; visible in source? If yes, paste it.")
|
|
92
|
+
- Lint status
|
|
93
|
+
|
|
94
|
+
## Mode 2: Validate
|
|
95
|
+
|
|
96
|
+
Lint an existing `.knows.yaml`.
|
|
97
|
+
|
|
98
|
+
### Steps
|
|
99
|
+
|
|
100
|
+
1. Confirm input file exists and ends with `.knows.yaml`, `.yaml`, or `.json`
|
|
101
|
+
2. Decide strictness based on origin:
|
|
102
|
+
- **Own Generate output** → strict (default)
|
|
103
|
+
- **Third-party / remote sidecar** → `--lenient` (dangling refs become warnings)
|
|
104
|
+
3. Run lint:
|
|
105
|
+
```bash
|
|
106
|
+
oma scholar lint {input}
|
|
107
|
+
# OR for fetched sidecars:
|
|
108
|
+
oma scholar lint --lenient {input}
|
|
109
|
+
```
|
|
110
|
+
4. Read output; group findings by severity (error/warning)
|
|
111
|
+
5. Report file:line for each issue with the rule violated and the fix
|
|
112
|
+
6. Offer to apply fixes if the user agrees
|
|
113
|
+
|
|
114
|
+
## Mode 3: Review
|
|
115
|
+
|
|
116
|
+
Generate a peer-review sidecar covering what claims need stronger evidence, what assumptions are unstated, and what limitations are missing.
|
|
117
|
+
|
|
118
|
+
### Steps
|
|
119
|
+
|
|
120
|
+
1. Read the source paper (or its existing sidecar)
|
|
121
|
+
2. For each statement in the paper, evaluate:
|
|
122
|
+
- Is `supported_by` evidence sufficient?
|
|
123
|
+
- Is `depends_on` assumption explicit?
|
|
124
|
+
- Are limitations acknowledged?
|
|
125
|
+
3. Produce review sidecar at `{base}.review.knows.yaml` with:
|
|
126
|
+
- `profile: "review@1"` (not `paper@1`)
|
|
127
|
+
- top-level `coverage`: `{statements: key_claims_and_limitations, evidence: partial}`
|
|
128
|
+
- `statements` capturing reviewer assertions using the **closed `statement_type`
|
|
129
|
+
enum**: weaknesses and strengths as `claim`, identified gaps as `limitation`,
|
|
130
|
+
open issues as `question` (there is no `review_comment` type)
|
|
131
|
+
- `relations` linking the reviewed paper's claims to reviewer weaknesses via
|
|
132
|
+
`predicate: challenged_by`, using the **cross-record reference grammar**
|
|
133
|
+
`record_id#local_id` for the original paper's side:
|
|
134
|
+
|
|
135
|
+
```yaml
|
|
136
|
+
relations:
|
|
137
|
+
- id: rel:generalization-challenges-main-claim
|
|
138
|
+
predicate: challenged_by
|
|
139
|
+
subject_ref: "knows:examples/resnet/1.0.0#stmt:main-contribution" # original paper's claim
|
|
140
|
+
object_ref: "stmt:missing-ablation-study" # this review's weakness
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
4. Lint and report (same as Generate). `oma scholar lint` recognizes
|
|
144
|
+
`record_id#local_id` cross-record refs and does not flag them as dangling.
|
|
145
|
+
|
|
146
|
+
## Mode 4: Analyze / Query
|
|
147
|
+
|
|
148
|
+
Answer natural-language questions over an existing sidecar.
|
|
149
|
+
|
|
150
|
+
### Steps
|
|
151
|
+
|
|
152
|
+
1. Locate sidecar: local path or `oma scholar get "{record_id}"` from knows.academy
|
|
153
|
+
2. For token efficiency, prefer **partial fetch** when only a subset is needed.
|
|
154
|
+
The query param is **`section` (singular)**; allowed values are `statements|evidence|relations|artifacts|citation`:
|
|
155
|
+
- "What claims does this paper make?" -> `?section=statements`
|
|
156
|
+
- "What are the experimental results?" -> `?section=evidence`
|
|
157
|
+
- "Who do they cite?" -> `?section=citation` (or `?section=artifacts` filtered by `role: cited`)
|
|
158
|
+
3. Parse YAML, traverse structure to answer
|
|
159
|
+
4. Cite IDs (`stmt:...`, `ev:...`) so the user can verify
|
|
160
|
+
|
|
161
|
+
## Mode 5: Compare
|
|
162
|
+
|
|
163
|
+
Structural diff between two sidecars.
|
|
164
|
+
|
|
165
|
+
### Steps
|
|
166
|
+
|
|
167
|
+
1. Load both sidecars (local or remote)
|
|
168
|
+
2. Build comparison table:
|
|
169
|
+
- **Claims overlap**: shared `statement_type` themes
|
|
170
|
+
- **Method differences**: same dataset? different metrics?
|
|
171
|
+
- **Evidence quality**: relations-per-statement ratio for each
|
|
172
|
+
- **Citation overlap**: shared `artifacts` with `role: cited`
|
|
173
|
+
3. Output a markdown table; cite specific IDs from each paper
|
|
174
|
+
4. Optional: surface opposing claims (search for `predicate: challenged_by` relations or `citation_intent: contradicts` on `cites`)
|
|
175
|
+
|
|
176
|
+
## Mode 6: Remote (with OpenAlex / Semantic Scholar fallback)
|
|
177
|
+
|
|
178
|
+
Search and fetch from knows.academy first, then fall back to OpenAlex when the
|
|
179
|
+
paper isn't in the (2026-only) knows.academy index, then to Semantic Scholar
|
|
180
|
+
(AI TL;DR + citation counts) when OpenAlex also has nothing.
|
|
181
|
+
|
|
182
|
+
### Recommended path: `oma scholar` (handles cascade automatically)
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
# Hybrid search
|
|
186
|
+
oma scholar search "<query>"
|
|
187
|
+
|
|
188
|
+
# Cross-source resolve (decides which source has the right paper)
|
|
189
|
+
oma scholar resolve "<title>"
|
|
190
|
+
|
|
191
|
+
# Get specific record (knows id, OpenAlex W-id, DOI, arXiv:<id>, CorpusId:<n>)
|
|
192
|
+
oma scholar get [--section <one>] "<id>"
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
See `resources/fallback-providers.md` for full cascade design.
|
|
196
|
+
|
|
197
|
+
### Manual cascade (raw curl)
|
|
198
|
+
|
|
199
|
+
1. **knows.academy search**: `curl -s "{base}/api/proxy/search?q={query}"`
|
|
200
|
+
2. If hits → fetch sidecar:
|
|
201
|
+
- Full: `/api/proxy/sidecars/{record_id}`
|
|
202
|
+
- Partial: `/api/proxy/partial?record_id={id}§ion=statements|evidence|relations|artifacts|citation`
|
|
203
|
+
3. If no hits OR clearly wrong paper (cross-source title similarity < 0.7) →
|
|
204
|
+
**OpenAlex fallback**:
|
|
205
|
+
- `curl -s "https://api.openalex.org/works?search={query}"` (anonymous OK)
|
|
206
|
+
- Or by DOI: `https://api.openalex.org/works/doi:{doi}`
|
|
207
|
+
- Reconstruct abstract from `abstract_inverted_index`
|
|
208
|
+
4. If user wants a sidecar from the OpenAlex result → transition to **Mode 1 Generate**
|
|
209
|
+
using the abstract as the source text. The local sidecar will not be on
|
|
210
|
+
knows.academy but is structurally identical.
|
|
211
|
+
5. **Stats** (health check): `curl -s "{base}/api/proxy/jobs/stats"`
|
|
212
|
+
6. If user asks for analysis after fetch, transition to **Mode 4** (Analyze)
|
|
213
|
+
|
|
214
|
+
## Error Recovery
|
|
215
|
+
|
|
216
|
+
| Error | Recovery |
|
|
217
|
+
|-------|----------|
|
|
218
|
+
| `oma scholar` not found | Run `oma install` to install / update the CLI |
|
|
219
|
+
| Lint script reports many errors | Fix top error first; re-run; cascading errors often resolve together |
|
|
220
|
+
| Remote API timeout | Retry once; if still failing, check `/api/proxy/jobs/stats` |
|
|
221
|
+
| Empty search results | Broaden query; remove quotes; try keyword-only |
|
|
222
|
+
| YAML parse error after Generate | Re-emit with stricter quoting on string values containing `:` `#` `&` `*` |
|
|
223
|
+
| Source PDF has no text layer | Chain via `oma-pdf` with hybrid OCR mode first |
|
|
224
|
+
| OpenAlex 403/429 | Tell user to set `OPENALEX_API_KEY`; see `setup-openalex.md` |
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
# Fallback Provider Cascade
|
|
2
|
+
|
|
3
|
+
`oma-scholar` queries `knows.academy` first, then falls back to OpenAlex, then
|
|
4
|
+
Semantic Scholar for records the platform doesn't have. The fallback is what
|
|
5
|
+
makes the skill useful beyond the (currently 2026-only) knows.academy index.
|
|
6
|
+
|
|
7
|
+
## Coverage Matrix
|
|
8
|
+
|
|
9
|
+
| Source | Coverage | Gives | Doesn't give |
|
|
10
|
+
|--------|----------|-------|--------------|
|
|
11
|
+
| **knows.academy** | **2026 only**, mostly arXiv (verified empirically; current counts via `/api/proxy/jobs/stats`) | Full v0.9 sidecar (claims, evidence, relations, methods) | Pre-2026 papers, full text |
|
|
12
|
+
| **OpenAlex** | ~240M works, all years | Title, authors, year, venue, DOI, abstract (reconstructed), OA PDF URL, citation count, references | Structured claims/evidence (no sidecar) |
|
|
13
|
+
| **Semantic Scholar** | ~214M papers, all years (Ai2) | AI TL;DR, abstract (verbatim), citation + influential-citation counts, arXiv/DOI/CorpusId cross-ids, OA PDF URL | Structured claims/evidence; anonymous access 429s under load |
|
|
14
|
+
|
|
15
|
+
When a paper is in **both**, prefer knows.academy (richer structure). When a
|
|
16
|
+
paper is **only in OpenAlex** (most pre-2026 work), use OpenAlex metadata as
|
|
17
|
+
the source for **Mode 1 Generate**, where the host LLM produces a local sidecar from
|
|
18
|
+
the abstract.
|
|
19
|
+
|
|
20
|
+
## Cascade Logic
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
search "query"
|
|
24
|
+
│
|
|
25
|
+
├─ knows.academy ── any hits? ──► return immediately (sidecars available)
|
|
26
|
+
│ │
|
|
27
|
+
│ no hits
|
|
28
|
+
│ ▼
|
|
29
|
+
├─ openalex ──── any hits? ────► return metadata + abstract (no sidecar)
|
|
30
|
+
│ │
|
|
31
|
+
│ no hits
|
|
32
|
+
│ ▼
|
|
33
|
+
└─ semanticscholar ───────────► return metadata + TL;DR + citations
|
|
34
|
+
↓
|
|
35
|
+
user wants deeper? → Mode 1 Generate locally
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
`--always-fallback` includes every tier regardless of earlier hits.
|
|
39
|
+
|
|
40
|
+
## CLI Reference (`oma scholar`)
|
|
41
|
+
|
|
42
|
+
### Search both sources
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
oma scholar search "vision language action"
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Returns JSON with:
|
|
49
|
+
- `primary`: which source returned hits
|
|
50
|
+
- `fallback`: which source was used as fallback (if any)
|
|
51
|
+
- `results`: unified list with `source: "knows.academy" | "openalex"` per item
|
|
52
|
+
|
|
53
|
+
### Get a specific record
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
# knows.academy sidecar
|
|
57
|
+
oma scholar get "knows:generated/reconvla/1.0.0"
|
|
58
|
+
|
|
59
|
+
# Partial fetch (saves up to 93% tokens)
|
|
60
|
+
oma scholar get --section statements "knows:generated/reconvla/1.0.0"
|
|
61
|
+
|
|
62
|
+
# OpenAlex by DOI
|
|
63
|
+
oma scholar get "10.48550/arXiv.1706.03762"
|
|
64
|
+
|
|
65
|
+
# OpenAlex by W-id
|
|
66
|
+
oma scholar get "W2147144213"
|
|
67
|
+
|
|
68
|
+
# Semantic Scholar: TL;DR + citation/influential-citation counts
|
|
69
|
+
oma scholar get "arXiv:1706.03762"
|
|
70
|
+
oma scholar get "CorpusId:13756489"
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
When `oma scholar get` is asked for a `knows:...` id and the platform is
|
|
74
|
+
unreachable, the command extracts the slug from the record_id and searches
|
|
75
|
+
OpenAlex for the same paper, returning metadata with a `fallback: "openalex"`
|
|
76
|
+
marker. The user can then run **Mode 1 Generate** from the abstract.
|
|
77
|
+
|
|
78
|
+
### Resolve a title across all sources
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
oma scholar resolve "Attention Is All You Need"
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Returns the best match from each source (knows.academy, OpenAlex, Semantic
|
|
85
|
+
Scholar) side-by-side, plus a recommendation.
|
|
86
|
+
|
|
87
|
+
## When Fallback is Needed
|
|
88
|
+
|
|
89
|
+
Fallback to OpenAlex is the right move when:
|
|
90
|
+
|
|
91
|
+
- **Pre-2026 papers**: knows.academy doesn't index them
|
|
92
|
+
- **Cross-archive coverage**: non-arXiv venues, journals, books
|
|
93
|
+
- **Citation counts**: knows.academy doesn't track citations; OpenAlex does
|
|
94
|
+
- **Reference resolution**: when a sidecar's `cites` predicate points to a paper not in knows.academy
|
|
95
|
+
|
|
96
|
+
Fallback is NOT needed for:
|
|
97
|
+
- Recent (2026) arXiv papers, since knows.academy has them with rich sidecars
|
|
98
|
+
- Full-text reading, since neither source provides full text; fetch the OA PDF and use `oma-pdf`
|
|
99
|
+
|
|
100
|
+
## Local Generate from Fallback Result
|
|
101
|
+
|
|
102
|
+
When OpenAlex returns metadata + abstract, but you want a structured sidecar:
|
|
103
|
+
|
|
104
|
+
```
|
|
105
|
+
1. oma scholar get <doi> → get title, authors, year, venue, abstract
|
|
106
|
+
2. (optional) download OA PDF → oma-pdf to extract full text
|
|
107
|
+
3. Mode 1 Generate → host LLM produces .knows.yaml using sidecar-spec.md
|
|
108
|
+
4. oma scholar lint → validate locally
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
The locally-generated sidecar is **not registered** with knows.academy; it's
|
|
112
|
+
yours. If you want it shared, that's a separate publishing flow (out of scope
|
|
113
|
+
for this skill).
|
|
114
|
+
|
|
115
|
+
## Authentication
|
|
116
|
+
|
|
117
|
+
OpenAlex anonymous use is free up to ~$1/day. For higher limits or polite
|
|
118
|
+
pool access, see `setup-openalex.md`. The skill works without any key.
|
|
119
|
+
|
|
120
|
+
`oma scholar` reads:
|
|
121
|
+
- `OPENALEX_API_KEY`: passed as `?api_key=` (recommended)
|
|
122
|
+
- `OPENALEX_EMAIL`: passed as `?mailto=` (polite pool, no signup)
|
|
123
|
+
- `S2_API_KEY`: Semantic Scholar key, passed as the `x-api-key` header
|
|
124
|
+
|
|
125
|
+
None are required. Without `S2_API_KEY`, Semantic Scholar uses the shared
|
|
126
|
+
anonymous pool, which 429s under load; the CLI retries once after a short
|
|
127
|
+
delay, then skips the source. Request a free key via the form at
|
|
128
|
+
https://www.semanticscholar.org/product/api (delivered by email; grants a
|
|
129
|
+
dedicated 1 req/sec).
|
|
130
|
+
|
|
131
|
+
## Trust Considerations
|
|
132
|
+
|
|
133
|
+
- **knows.academy sidecars are AI-generated**: all have `provenance.origin: machine`. Verified `lint_passed: true` is platform-internal; our local `oma scholar lint` finds dangling refs in ~47% (use `--lenient` when consuming)
|
|
134
|
+
- **OpenAlex metadata is curated**: generally reliable for title/authors/DOI/year, but venue and abstract can be missing for older works
|
|
135
|
+
- **Reconstructed abstracts** from OpenAlex's inverted index are exact (no paraphrasing), but punctuation/formatting may be lossy
|
|
136
|
+
- **Semantic Scholar TL;DRs are AI-generated** (Ai2's TLDR model): good `summary` seeds for Mode 1 Generate, but verify against the abstract before citing; citation counts differ from OpenAlex's (different corpora)
|
|
137
|
+
|
|
138
|
+
## Limitations
|
|
139
|
+
|
|
140
|
+
- arXiv-only papers without DOI may show `doi: None` in OpenAlex
|
|
141
|
+
- Some 2026 papers exist in both sources with slightly different titles; `resolve` does case-insensitive contain matching as a heuristic
|
|
142
|
+
- knows.academy proxy can timeout under load; fallback to OpenAlex is automatic
|
|
143
|
+
- OpenAlex rate-limits: respect ~10 req/sec courtesy limit
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# OpenAlex API Key Setup (Optional)
|
|
2
|
+
|
|
3
|
+
OpenAlex powers metadata enrichment during Generate mode by backfilling missing DOI, venue, and year from a vast academic catalog. **The skill works without a key**, but enrichment is skipped.
|
|
4
|
+
|
|
5
|
+
## When you need this
|
|
6
|
+
|
|
7
|
+
- You frequently generate sidecars from raw text/LaTeX where DOI is not visible
|
|
8
|
+
- You want DOI/venue auto-resolved from the title
|
|
9
|
+
- You hit anonymous rate limits ("$1/day" allowance exhausted)
|
|
10
|
+
|
|
11
|
+
## Free Tier (Generous)
|
|
12
|
+
|
|
13
|
+
Without any key, OpenAlex grants $1/day equivalent free quota:
|
|
14
|
+
- **Unlimited** single-entity lookups
|
|
15
|
+
- **10,000** list/filter calls per day
|
|
16
|
+
- **1,000** search calls per day
|
|
17
|
+
- **100** content downloads per day
|
|
18
|
+
|
|
19
|
+
For most users, anonymous use is enough.
|
|
20
|
+
|
|
21
|
+
## Get a Key (30 seconds)
|
|
22
|
+
|
|
23
|
+
1. Sign up: https://openalex.org/
|
|
24
|
+
2. Generate key: https://openalex.org/settings/api
|
|
25
|
+
3. Copy the key
|
|
26
|
+
|
|
27
|
+
## Configure
|
|
28
|
+
|
|
29
|
+
### Option A: Per-shell environment
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
export OPENALEX_API_KEY="your_key_here"
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
### Option B: Persisted in `~/.claude/.env` (recommended)
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
mkdir -p ~/.claude
|
|
39
|
+
echo 'OPENALEX_API_KEY=your_key_here' >> ~/.claude/.env
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Some Claude Code setups source this file automatically; if not, source it from your shell rc:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
echo '[ -f ~/.claude/.env ] && set -a && . ~/.claude/.env && set +a' >> ~/.zshrc
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### Option C: Polite-pool email only (no key)
|
|
49
|
+
|
|
50
|
+
If you don't want to sign up but want priority, set just an email:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
export OPENALEX_EMAIL="you@example.com"
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
This puts you in the "polite pool" with better latency, no key required.
|
|
57
|
+
|
|
58
|
+
## Verify
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
curl -s "https://api.openalex.org/works?search=attention+is+all+you+need&api_key=$OPENALEX_API_KEY" \
|
|
62
|
+
| head -c 500
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
A 200 response with JSON results means the key is live.
|
|
66
|
+
|
|
67
|
+
## Pricing Beyond Free Tier
|
|
68
|
+
|
|
69
|
+
OpenAlex uses pay-as-you-go past the daily free allowance, with no monthly subscription. Most academic users never exceed the free tier. See https://openalex.org/pricing for current rates.
|
|
70
|
+
|
|
71
|
+
## Skill Behavior
|
|
72
|
+
|
|
73
|
+
When this skill needs metadata enrichment:
|
|
74
|
+
|
|
75
|
+
1. Check `OPENALEX_API_KEY` env var
|
|
76
|
+
2. If set -> use authenticated calls
|
|
77
|
+
3. If not set, check `OPENALEX_EMAIL` -> anonymous polite-pool
|
|
78
|
+
4. If neither, fall back to anonymous calls
|
|
79
|
+
5. On 403/429 -> stop enrichment, tell user to set the key, leave fields omitted (anti-fabrication)
|
|
80
|
+
|
|
81
|
+
## Privacy
|
|
82
|
+
|
|
83
|
+
- The key (or email) is sent to OpenAlex servers as a query parameter
|
|
84
|
+
- No source paper content is sent to OpenAlex; only title/author search strings
|
|
85
|
+
- OpenAlex is operated by OurResearch (a non-profit); see their privacy policy at https://openalex.org/
|