myaidev-method 0.3.3 → 0.3.5
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/.claude-plugin/plugin.json +0 -1
- package/.env.example +5 -4
- package/CHANGELOG.md +2 -2
- package/CONTENT_CREATION_GUIDE.md +489 -3211
- package/DEVELOPER_USE_CASES.md +1 -1
- package/MODULAR_INSTALLATION.md +2 -2
- package/README.md +39 -33
- package/TECHNICAL_ARCHITECTURE.md +1 -1
- package/USER_GUIDE.md +242 -190
- package/agents/content-editor-agent.md +90 -0
- package/agents/content-planner-agent.md +97 -0
- package/agents/content-research-agent.md +62 -0
- package/agents/content-seo-agent.md +101 -0
- package/agents/content-writer-agent.md +69 -0
- package/agents/infographic-analyzer-agent.md +63 -0
- package/agents/infographic-designer-agent.md +72 -0
- package/bin/cli.js +777 -535
- package/{content-rules.example.md → content-rules-example.md} +2 -2
- package/dist/mcp/health-check.js +82 -68
- package/dist/mcp/mcp-config.json +8 -0
- package/dist/mcp/openstack-server.js +1746 -1262
- package/dist/server/.tsbuildinfo +1 -1
- package/extension.json +21 -4
- package/package.json +181 -184
- package/skills/company-config/SKILL.md +133 -0
- package/skills/configure/SKILL.md +1 -1
- package/skills/myai-configurator/SKILL.md +77 -0
- package/skills/myai-configurator/content-creation-configurator/SKILL.md +516 -0
- package/skills/myai-configurator/content-maintenance-configurator/SKILL.md +397 -0
- package/skills/myai-content-enrichment/SKILL.md +114 -0
- package/skills/myai-content-ideation/SKILL.md +288 -0
- package/skills/myai-content-ideation/evals/evals.json +182 -0
- package/skills/myai-content-production-coordinator/SKILL.md +946 -0
- package/skills/{content-rules-setup → myai-content-rules-setup}/SKILL.md +1 -1
- package/skills/{content-verifier → myai-content-verifier}/SKILL.md +1 -1
- package/skills/myai-content-writer/SKILL.md +333 -0
- package/skills/myai-content-writer/agents/editor-agent.md +138 -0
- package/skills/myai-content-writer/agents/planner-agent.md +121 -0
- package/skills/myai-content-writer/agents/research-agent.md +83 -0
- package/skills/myai-content-writer/agents/seo-agent.md +139 -0
- package/skills/myai-content-writer/agents/visual-planner-agent.md +110 -0
- package/skills/myai-content-writer/agents/writer-agent.md +85 -0
- package/skills/{infographic → myai-infographic}/SKILL.md +1 -1
- package/skills/myai-proprietary-content-verifier/SKILL.md +175 -0
- package/skills/myai-proprietary-content-verifier/evals/evals.json +36 -0
- package/skills/myai-skill-builder/SKILL.md +699 -0
- package/skills/myai-skill-builder/agents/analyzer-agent.md +137 -0
- package/skills/myai-skill-builder/agents/comparator-agent.md +77 -0
- package/skills/myai-skill-builder/agents/grader-agent.md +103 -0
- package/skills/myai-skill-builder/assets/eval_review.html +131 -0
- package/skills/myai-skill-builder/references/schemas.md +211 -0
- package/skills/myai-skill-builder/scripts/aggregate_benchmark.py +190 -0
- package/skills/myai-skill-builder/scripts/generate_review.py +381 -0
- package/skills/myai-skill-builder/scripts/package_skill.py +91 -0
- package/skills/myai-skill-builder/scripts/run_eval.py +105 -0
- package/skills/myai-skill-builder/scripts/run_loop.py +211 -0
- package/skills/myai-skill-builder/scripts/utils.py +123 -0
- package/skills/myai-visual-generator/SKILL.md +125 -0
- package/skills/myai-visual-generator/evals/evals.json +155 -0
- package/skills/myai-visual-generator/references/infographic-pipeline.md +73 -0
- package/skills/myai-visual-generator/references/research-visuals.md +57 -0
- package/skills/myai-visual-generator/references/services.md +89 -0
- package/skills/myai-visual-generator/scripts/visual-generation-utils.js +1272 -0
- package/skills/myaidev-analyze/agents/dependency-mapper-agent.md +236 -0
- package/skills/myaidev-analyze/agents/pattern-detector-agent.md +240 -0
- package/skills/myaidev-analyze/agents/structure-scanner-agent.md +171 -0
- package/skills/myaidev-analyze/agents/tech-profiler-agent.md +291 -0
- package/skills/myaidev-architect/agents/compliance-checker-agent.md +287 -0
- package/skills/myaidev-architect/agents/requirements-analyst-agent.md +194 -0
- package/skills/myaidev-architect/agents/system-designer-agent.md +315 -0
- package/skills/myaidev-coder/agents/implementer-agent.md +185 -0
- package/skills/myaidev-coder/agents/integration-agent.md +168 -0
- package/skills/myaidev-coder/agents/pattern-scanner-agent.md +161 -0
- package/skills/myaidev-coder/agents/self-reviewer-agent.md +168 -0
- package/skills/myaidev-debug/agents/fix-agent-debug.md +317 -0
- package/skills/myaidev-debug/agents/hypothesis-agent.md +226 -0
- package/skills/myaidev-debug/agents/investigator-agent.md +250 -0
- package/skills/myaidev-debug/agents/symptom-collector-agent.md +231 -0
- package/skills/myaidev-documenter/agents/code-reader-agent.md +172 -0
- package/skills/myaidev-documenter/agents/doc-validator-agent.md +174 -0
- package/skills/myaidev-documenter/agents/doc-writer-agent.md +379 -0
- package/skills/myaidev-figma/SKILL.md +212 -0
- package/skills/myaidev-figma/capture.js +133 -0
- package/skills/myaidev-figma/crawl.js +130 -0
- package/skills/myaidev-figma-configure/SKILL.md +130 -0
- package/skills/myaidev-migrate/agents/migration-planner-agent.md +237 -0
- package/skills/myaidev-migrate/agents/migration-writer-agent.md +248 -0
- package/skills/myaidev-migrate/agents/schema-analyzer-agent.md +190 -0
- package/skills/myaidev-performance/agents/benchmark-agent.md +281 -0
- package/skills/myaidev-performance/agents/optimizer-agent.md +277 -0
- package/skills/myaidev-performance/agents/profiler-agent.md +252 -0
- package/skills/myaidev-refactor/agents/refactor-executor-agent.md +221 -0
- package/skills/myaidev-refactor/agents/refactor-planner-agent.md +213 -0
- package/skills/myaidev-refactor/agents/regression-guard-agent.md +242 -0
- package/skills/myaidev-refactor/agents/smell-detector-agent.md +233 -0
- package/skills/myaidev-reviewer/agents/auto-fixer-agent.md +238 -0
- package/skills/myaidev-reviewer/agents/code-analyst-agent.md +220 -0
- package/skills/myaidev-reviewer/agents/security-scanner-agent.md +262 -0
- package/skills/myaidev-tester/agents/coverage-analyst-agent.md +163 -0
- package/skills/myaidev-tester/agents/tdd-driver-agent.md +242 -0
- package/skills/myaidev-tester/agents/test-runner-agent.md +176 -0
- package/skills/myaidev-tester/agents/test-strategist-agent.md +154 -0
- package/skills/myaidev-tester/agents/test-writer-agent.md +242 -0
- package/skills/myaidev-workflow/agents/analyzer-agent.md +317 -0
- package/skills/myaidev-workflow/agents/coordinator-agent.md +253 -0
- package/skills/openstack-manager/SKILL.md +1 -1
- package/skills/payloadcms-publisher/SKILL.md +141 -77
- package/skills/payloadcms-publisher/references/field-mapping.md +142 -0
- package/skills/payloadcms-publisher/references/lexical-format.md +97 -0
- package/skills/security-auditor/SKILL.md +1 -1
- package/src/cli/commands/addon.js +184 -123
- package/src/config/workflows.js +172 -228
- package/src/lib/ascii-banner.js +197 -182
- package/src/lib/{content-coordinator.js → content-production-coordinator.js} +649 -459
- package/src/lib/installation-detector.js +93 -59
- package/src/lib/payloadcms-utils.js +285 -510
- package/src/lib/update-manager.js +120 -61
- package/src/lib/workflow-installer.js +55 -0
- package/src/mcp/health-check.js +82 -68
- package/src/mcp/openstack-server.js +1746 -1262
- package/src/scripts/configure-visual-apis.js +224 -173
- package/src/scripts/configure-wordpress-mcp.js +96 -66
- package/src/scripts/init/install.js +109 -85
- package/src/scripts/init-project.js +138 -67
- package/src/scripts/utils/write-content.js +67 -52
- package/src/scripts/wordpress/publish-to-wordpress.js +128 -128
- package/src/templates/claude/CLAUDE.md +131 -0
- package/hooks/hooks.json +0 -26
- package/skills/content-coordinator/SKILL.md +0 -130
- package/skills/content-enrichment/SKILL.md +0 -80
- package/skills/content-writer/SKILL.md +0 -285
- package/skills/visual-generator/SKILL.md +0 -140
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
{
|
|
2
|
+
"skill_name": "myai-visual-generator",
|
|
3
|
+
"evals": [
|
|
4
|
+
{
|
|
5
|
+
"id": 1,
|
|
6
|
+
"name": "hero-image-generation",
|
|
7
|
+
"category": "image",
|
|
8
|
+
"prompt": "Generate a hero image for my article about Kubernetes horizontal pod autoscaling. Something modern, abstract, with a cloud-native feel. Save it to my project.",
|
|
9
|
+
"expected_output": "A hero image generated via an AI image service, saved with proper naming and path.",
|
|
10
|
+
"files": [],
|
|
11
|
+
"assertions": [
|
|
12
|
+
"Output mentions using an image generation service (FLUX, Imagen, Gemini, or GPT Image)",
|
|
13
|
+
"Output includes a file path under content-assets/images/ with a date-based directory",
|
|
14
|
+
"Output includes markdown embed code using  syntax",
|
|
15
|
+
"Output includes cost estimation or pricing information for the generation"
|
|
16
|
+
]
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"id": 2,
|
|
20
|
+
"name": "article-infographic-pipeline",
|
|
21
|
+
"category": "infographic",
|
|
22
|
+
"prompt": "I have an article at ./test-article.md about API design patterns. Analyze it and create infographics for the key concepts - a flowchart for the request lifecycle and an architecture diagram for the gateway pattern.",
|
|
23
|
+
"expected_output": "Mermaid diagrams rendered for the article's key concepts.",
|
|
24
|
+
"files": [
|
|
25
|
+
"test-article.md"
|
|
26
|
+
],
|
|
27
|
+
"assertions": [
|
|
28
|
+
"Output indicates the article was read/analyzed before creating diagrams",
|
|
29
|
+
"At least 2 diagrams were created (flowchart and architecture/gateway)",
|
|
30
|
+
"Output mentions Mermaid syntax or .mmd files",
|
|
31
|
+
"Output includes file paths for the rendered diagram images"
|
|
32
|
+
]
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"id": 3,
|
|
36
|
+
"name": "data-infographic-text-accuracy",
|
|
37
|
+
"category": "infographic",
|
|
38
|
+
"prompt": "I need a data infographic showing these SaaS metrics: MRR $45K, churn 2.1%, NPS 72, ARR growth 34% YoY. The text and numbers need to be perfectly legible.",
|
|
39
|
+
"expected_output": "Text-accurate method chosen due to legibility requirement.",
|
|
40
|
+
"files": [],
|
|
41
|
+
"assertions": [
|
|
42
|
+
"Output mentions choosing HTML conversion, Playwright screenshot, or GPT Image due to text accuracy needs",
|
|
43
|
+
"Output references all 4 metrics (MRR, churn, NPS, ARR growth)",
|
|
44
|
+
"Output includes a file path for the generated infographic",
|
|
45
|
+
"Output explains why a text-accurate method was chosen over standard AI generation"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"id": 4,
|
|
50
|
+
"name": "research-visuals",
|
|
51
|
+
"category": "research",
|
|
52
|
+
"prompt": "Create a research evaluation comparison chart showing transformer vs LSTM vs Mamba performance across 5 benchmarks: GLUE, SQuAD, WMT, MMLU, and HumanEval. Include accuracy scores and inference speed.",
|
|
53
|
+
"expected_output": "A data visualization comparing the 3 models across benchmarks.",
|
|
54
|
+
"files": [],
|
|
55
|
+
"assertions": [
|
|
56
|
+
"Output references all 3 models (transformer, LSTM, Mamba)",
|
|
57
|
+
"Output references at least 4 of the 5 benchmarks",
|
|
58
|
+
"Output includes a file path for the generated visualization",
|
|
59
|
+
"Output used a structured data method (HTML conversion, chart library, PaperBanana, or Mermaid)"
|
|
60
|
+
]
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"id": 5,
|
|
64
|
+
"name": "missing-api-keys-graceful",
|
|
65
|
+
"category": "error-handling",
|
|
66
|
+
"prompt": "Generate a hero image for my blog post about serverless computing.",
|
|
67
|
+
"expected_output": "Graceful error with instructions on configuring API keys.",
|
|
68
|
+
"env_override": {
|
|
69
|
+
"GOOGLE_API_KEY": "",
|
|
70
|
+
"OPENAI_API_KEY": "",
|
|
71
|
+
"FAL_KEY": "",
|
|
72
|
+
"GEMINI_API_KEY": ""
|
|
73
|
+
},
|
|
74
|
+
"assertions": [
|
|
75
|
+
"Output does NOT show a successfully generated image",
|
|
76
|
+
"Output mentions missing or unconfigured API keys",
|
|
77
|
+
"Output provides guidance on how to configure keys (referencing .env or configure command)"
|
|
78
|
+
]
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"id": 6,
|
|
82
|
+
"name": "ambiguous-prompt-clarification",
|
|
83
|
+
"category": "routing",
|
|
84
|
+
"prompt": "Make me a visual.",
|
|
85
|
+
"expected_output": "Skill asks clarifying questions or presents options before generating.",
|
|
86
|
+
"files": [],
|
|
87
|
+
"assertions": [
|
|
88
|
+
"Output asks what kind of visual (image, video, infographic) OR presents options to choose from",
|
|
89
|
+
"Output does NOT immediately generate a final image/video without any clarification",
|
|
90
|
+
"Output asks about the subject matter or purpose of the visual"
|
|
91
|
+
]
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"id": 7,
|
|
95
|
+
"name": "html-conversion-for-charts",
|
|
96
|
+
"category": "infographic",
|
|
97
|
+
"prompt": "Create a comparison table infographic showing pricing tiers: Starter at $9/mo with 1K API calls, Pro at $49/mo with 50K API calls, Enterprise at $199/mo with unlimited calls. Include exact pricing and feature counts.",
|
|
98
|
+
"expected_output": "HTML-to-screenshot path used for text-heavy pricing data.",
|
|
99
|
+
"files": [],
|
|
100
|
+
"assertions": [
|
|
101
|
+
"Output mentions using HTML conversion, Playwright, or screenshot-based approach for text accuracy",
|
|
102
|
+
"Output references all 3 pricing tiers (Starter $9, Pro $49, Enterprise $199)",
|
|
103
|
+
"Output includes a file path for the generated infographic"
|
|
104
|
+
]
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"id": 8,
|
|
108
|
+
"name": "service-fallback-chain",
|
|
109
|
+
"category": "routing",
|
|
110
|
+
"prompt": "Generate an illustration of a distributed microservices mesh using FLUX. High quality, 1792x1024.",
|
|
111
|
+
"expected_output": "Acknowledges FLUX preference, falls back if unavailable.",
|
|
112
|
+
"env_override": {
|
|
113
|
+
"FAL_KEY": ""
|
|
114
|
+
},
|
|
115
|
+
"assertions": [
|
|
116
|
+
"Output acknowledges the user's preference for FLUX",
|
|
117
|
+
"Output indicates FLUX/fal.ai is unavailable (missing FAL_KEY or connection error)",
|
|
118
|
+
"Output selects an alternative service (Gemini, Imagen, or GPT Image) as fallback",
|
|
119
|
+
"Output includes a file path for the generated image"
|
|
120
|
+
]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"id": 9,
|
|
124
|
+
"name": "standalone-mermaid-diagram",
|
|
125
|
+
"category": "infographic",
|
|
126
|
+
"prompt": "Create a sequence diagram showing OAuth 2.0 authorization code flow between Client, Auth Server, and Resource Server. Include all the standard steps.",
|
|
127
|
+
"expected_output": "Mermaid sequence diagram rendered with OAuth flow.",
|
|
128
|
+
"files": [],
|
|
129
|
+
"assertions": [
|
|
130
|
+
"Output uses Mermaid diagram approach (mentions Mermaid, sequenceDiagram, or .mmd)",
|
|
131
|
+
"Output references all 3 participants (Client, Auth Server, Resource Server)",
|
|
132
|
+
"Output includes standard OAuth steps (authorization, token exchange, resource access)",
|
|
133
|
+
"Output includes a file path for the rendered diagram image"
|
|
134
|
+
]
|
|
135
|
+
}
|
|
136
|
+
],
|
|
137
|
+
"trigger_evals": {
|
|
138
|
+
"should_trigger": [
|
|
139
|
+
"I need a thumbnail for my YouTube video about React hooks",
|
|
140
|
+
"Create a diagram showing our database schema",
|
|
141
|
+
"Generate an image for my blog header",
|
|
142
|
+
"Make me an architecture diagram of our microservices",
|
|
143
|
+
"I want a visual showing the CI/CD pipeline flow",
|
|
144
|
+
"Create a video walkthrough of the dashboard"
|
|
145
|
+
],
|
|
146
|
+
"should_not_trigger": [
|
|
147
|
+
"Can you update my spreadsheet with the latest sales figures?",
|
|
148
|
+
"Help me write CSS to style my image gallery",
|
|
149
|
+
"Fix the broken image link in my README",
|
|
150
|
+
"I need to resize an existing photo",
|
|
151
|
+
"Add alt text to all images in my HTML",
|
|
152
|
+
"Convert my PNG files to WebP format"
|
|
153
|
+
]
|
|
154
|
+
}
|
|
155
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Infographic Pipeline Reference
|
|
2
|
+
|
|
3
|
+
## Article-Aware Infographic Generation
|
|
4
|
+
|
|
5
|
+
When input is a markdown article file, run this pipeline:
|
|
6
|
+
|
|
7
|
+
1. **Analyze**: Read the article and identify sections suitable for diagrams
|
|
8
|
+
2. **Design**: Create Mermaid diagram source for each opportunity
|
|
9
|
+
3. **Render**: Use Mermaid CLI (`mmdc`) to render PNGs
|
|
10
|
+
4. **Insert**: Add `` references back into the article
|
|
11
|
+
5. **Save**: Put assets in `assets/` directory near the article
|
|
12
|
+
|
|
13
|
+
## Infographic Types
|
|
14
|
+
|
|
15
|
+
### Quick Mode (default choices)
|
|
16
|
+
- `flowchart` — Decision trees, processes
|
|
17
|
+
- `sequence-diagram` — API/service interactions
|
|
18
|
+
|
|
19
|
+
### Full Mode (when user requests richer output)
|
|
20
|
+
- `infographic-data` — Statistics, metrics, charts
|
|
21
|
+
- `infographic-process` — Step flows, workflows
|
|
22
|
+
- `infographic-comparison` — Side-by-side comparisons
|
|
23
|
+
- `infographic-timeline` — Chronological events
|
|
24
|
+
- `architecture-diagram` — System design, tech stacks
|
|
25
|
+
|
|
26
|
+
Ask quick-mode choices first. Only present the full set if the user asks for something beyond flowchart/sequence-diagram.
|
|
27
|
+
|
|
28
|
+
## Mermaid Rendering Configuration
|
|
29
|
+
|
|
30
|
+
Always use this config with `mmdc`:
|
|
31
|
+
|
|
32
|
+
```json
|
|
33
|
+
{
|
|
34
|
+
"flowchart": {
|
|
35
|
+
"htmlLabels": false,
|
|
36
|
+
"useMaxWidth": false
|
|
37
|
+
},
|
|
38
|
+
"sequence": {
|
|
39
|
+
"useMaxWidth": false
|
|
40
|
+
},
|
|
41
|
+
"gantt": {
|
|
42
|
+
"useMaxWidth": false
|
|
43
|
+
},
|
|
44
|
+
"theme": "default"
|
|
45
|
+
}
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Key rules:
|
|
49
|
+
- `htmlLabels: false` — prevents rendering issues in non-browser contexts
|
|
50
|
+
- `useMaxWidth: false` — ensures diagrams render at natural size
|
|
51
|
+
- Default to `png` format for compatibility; use `svg` only when explicitly requested
|
|
52
|
+
- Validate rendered output exists and is >1KB before inserting references
|
|
53
|
+
|
|
54
|
+
## Pipeline Output Format
|
|
55
|
+
|
|
56
|
+
When running as part of the content-writer pipeline, return:
|
|
57
|
+
|
|
58
|
+
```
|
|
59
|
+
INFOGRAPHICS COMPLETE
|
|
60
|
+
article: .content-session/draft.md
|
|
61
|
+
diagrams_created: {count}
|
|
62
|
+
diagrams_attempted: {count}
|
|
63
|
+
assets_dir: {path}
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Defaults
|
|
67
|
+
|
|
68
|
+
| Setting | Default |
|
|
69
|
+
|---------|---------|
|
|
70
|
+
| Style | modern |
|
|
71
|
+
| Theme | default |
|
|
72
|
+
| Format | png |
|
|
73
|
+
| Max diagrams | 8 |
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Research Visuals Reference (PaperBanana Integration)
|
|
2
|
+
|
|
3
|
+
Use this subcategory for publication-style academic visuals.
|
|
4
|
+
|
|
5
|
+
## Research Visual Types
|
|
6
|
+
|
|
7
|
+
| Type | Description | Tool |
|
|
8
|
+
|------|-------------|------|
|
|
9
|
+
| `research-diagram` | Methodology/framework diagram from research text | `paperbanana generate` |
|
|
10
|
+
| `research-plot` | Statistical plot from CSV/JSON data | `paperbanana plot` |
|
|
11
|
+
| `research-evaluation` | Compare generated diagram vs reference | `paperbanana evaluate` |
|
|
12
|
+
|
|
13
|
+
## Prerequisites
|
|
14
|
+
|
|
15
|
+
- Python 3.10+
|
|
16
|
+
- `pip install paperbanana`
|
|
17
|
+
- `GOOGLE_API_KEY` configured (required for default Gemini pipeline)
|
|
18
|
+
- Optional: `paperbanana setup` for local config
|
|
19
|
+
|
|
20
|
+
## Required User Inputs (minimum questions)
|
|
21
|
+
|
|
22
|
+
### research-diagram (minimum required)
|
|
23
|
+
1. Source context text (methodology description)
|
|
24
|
+
2. Figure caption / communicative intent
|
|
25
|
+
|
|
26
|
+
Defaults (do not ask unless needed):
|
|
27
|
+
- Style: `clean academic`
|
|
28
|
+
- Iterations: `3`
|
|
29
|
+
- Output path: auto-generated
|
|
30
|
+
|
|
31
|
+
### research-plot (minimum required)
|
|
32
|
+
1. Data file path (`.csv` or `.json`)
|
|
33
|
+
2. Plot intent (what comparison/story the chart should convey)
|
|
34
|
+
|
|
35
|
+
Defaults (do not ask unless needed):
|
|
36
|
+
- Style constraints: none
|
|
37
|
+
- Iterations: `3`
|
|
38
|
+
- Output path: auto-generated
|
|
39
|
+
|
|
40
|
+
### research-evaluation (required)
|
|
41
|
+
1. Generated diagram path
|
|
42
|
+
2. Human reference diagram path
|
|
43
|
+
3. Source context text path
|
|
44
|
+
4. Figure caption / intent
|
|
45
|
+
|
|
46
|
+
## CLI Commands
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
# Generate methodology diagram
|
|
50
|
+
paperbanana generate --context "methodology text" --caption "Figure 1: System overview"
|
|
51
|
+
|
|
52
|
+
# Generate statistical plot
|
|
53
|
+
paperbanana plot --data data.csv --intent "Compare latency across regions"
|
|
54
|
+
|
|
55
|
+
# Evaluate diagram quality
|
|
56
|
+
paperbanana evaluate --generated gen.png --reference ref.png --context ctx.txt --caption "Fig 1"
|
|
57
|
+
```
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# Visual Generation Services Reference
|
|
2
|
+
|
|
3
|
+
## Service Catalog
|
|
4
|
+
|
|
5
|
+
### SOTA Recommended Models
|
|
6
|
+
|
|
7
|
+
| Service | Type | Cost | Best For | API Key |
|
|
8
|
+
|---------|------|------|----------|---------|
|
|
9
|
+
| Gemini 3.0 Pro Image ("Nano Banana") | Image | $0.02 | Fast, diagrams, general use | `GEMINI_API_KEY` or `GOOGLE_API_KEY` |
|
|
10
|
+
| GPT Image 1.5 | Image | $0.02-$0.19 | Best text rendering, highest quality | `OPENAI_API_KEY` |
|
|
11
|
+
|
|
12
|
+
### Additional Models
|
|
13
|
+
|
|
14
|
+
| Service | Type | Cost | Best For | API Key |
|
|
15
|
+
|---------|------|------|----------|---------|
|
|
16
|
+
| Imagen 3 | Image | $0.03 | Premium quality heroes | `GEMINI_API_KEY` |
|
|
17
|
+
| GPT Image 1 | Image | $0.19 | High quality images | `OPENAI_API_KEY` |
|
|
18
|
+
| GPT Image 1 Mini | Image | $0.02 | Budget option, high volume | `OPENAI_API_KEY` |
|
|
19
|
+
| Nano Banana Pro | Image | $0.15 | High-quality branded visuals | `FAL_KEY` |
|
|
20
|
+
| FLUX 2 Pro | Image | $0.05 | Detailed illustrations, multi-ref | `FAL_KEY` |
|
|
21
|
+
| FLUX 2 Flex | Image | $0.04 | Developer-controlled params | `FAL_KEY` |
|
|
22
|
+
| FLUX 2 Dev | Image | $0.025 | 32B open-weight model | `FAL_KEY` |
|
|
23
|
+
| Veo 3 | Video | $0.40/sec | Product demos, tutorials | `FAL_KEY` |
|
|
24
|
+
|
|
25
|
+
### GPT Image 1.5 Quality Tiers
|
|
26
|
+
|
|
27
|
+
| Quality | Cost | Tokens |
|
|
28
|
+
|---------|------|--------|
|
|
29
|
+
| low | $0.02 | ~272 |
|
|
30
|
+
| medium | $0.07 | ~1056 |
|
|
31
|
+
| high | $0.19 | ~4160 |
|
|
32
|
+
|
|
33
|
+
## Service Selection Logic
|
|
34
|
+
|
|
35
|
+
Route based on visual type and text requirements:
|
|
36
|
+
|
|
37
|
+
| Scenario | Recommended Service |
|
|
38
|
+
|----------|-------------------|
|
|
39
|
+
| Hero image, artistic | FLUX 2 Pro or Imagen |
|
|
40
|
+
| Text-heavy visuals (exact numbers, labels) | GPT Image 1.5 or HTML Conversion |
|
|
41
|
+
| Fast/cheap general image | Gemini 3.0 Pro Image |
|
|
42
|
+
| Technical diagrams | Gemini or Mermaid render path |
|
|
43
|
+
| Video content | Veo 3 |
|
|
44
|
+
| Specialized models | fal.ai MCP discovery |
|
|
45
|
+
|
|
46
|
+
### HTML Conversion Alternative
|
|
47
|
+
|
|
48
|
+
For data-driven visuals requiring pixel-perfect text accuracy, use HTML-to-screenshot instead of AI generation:
|
|
49
|
+
|
|
50
|
+
| Use Case | Tool |
|
|
51
|
+
|----------|------|
|
|
52
|
+
| Exact numbers/data | HTML Conversion (Playwright) |
|
|
53
|
+
| Precise text labels | HTML/D2 Conversion |
|
|
54
|
+
| Charts and graphs | HTML Conversion |
|
|
55
|
+
| Creative/artistic | AI Generation |
|
|
56
|
+
|
|
57
|
+
When text fidelity is critical and the user explicitly says "perfectly legible" or similar, prefer HTML conversion even when AI services are available.
|
|
58
|
+
|
|
59
|
+
## fal.ai MCP Tools (When FAL_KEY is configured)
|
|
60
|
+
|
|
61
|
+
The fal.ai MCP server provides capabilities beyond the built-in SDK:
|
|
62
|
+
|
|
63
|
+
| Tool | Purpose |
|
|
64
|
+
|------|---------|
|
|
65
|
+
| Model search/discovery | Find specialized models across 600+ fal.ai models |
|
|
66
|
+
| Schema inspection | Understand model parameters before generation |
|
|
67
|
+
| Real-time pricing | Accurate cost estimation from live pricing data |
|
|
68
|
+
| File upload | Upload reference images to fal.ai CDN for FLUX 2 multi-ref |
|
|
69
|
+
| Request status/cancel | Monitor or cancel long-running generation requests |
|
|
70
|
+
|
|
71
|
+
### When to Use MCP vs SDK
|
|
72
|
+
|
|
73
|
+
| Scenario | Approach |
|
|
74
|
+
|----------|----------|
|
|
75
|
+
| Standard generation (FLUX 2, Veo 3) | SDK (`visual-generation-utils.js`) |
|
|
76
|
+
| Discover new/specialized models | MCP (model search tools) |
|
|
77
|
+
| Check real-time pricing | MCP (pricing tools) |
|
|
78
|
+
| Upload reference images for multi-ref | MCP (upload tool) then SDK |
|
|
79
|
+
| Generate with non-standard fal.ai models | MCP (generate/result tools) |
|
|
80
|
+
| Cancel or monitor long-running requests | MCP (status/cancel tools) |
|
|
81
|
+
|
|
82
|
+
## Budget Defaults
|
|
83
|
+
|
|
84
|
+
- Daily budget: $5.00 (`VISUAL_DAILY_BUDGET`)
|
|
85
|
+
- Monthly budget: $50.00 (`VISUAL_MONTHLY_BUDGET`)
|
|
86
|
+
|
|
87
|
+
## API Key Priority
|
|
88
|
+
|
|
89
|
+
The SDK supports both `GEMINI_API_KEY` (preferred) and `GOOGLE_API_KEY` (legacy). See `validateAPIKeys()` in the bundled script for the full resolution logic.
|