From agent-almanac
Improve an existing R-based pictogram glyph for the visualization layer. Covers visual audit of the current glyph, diagnosis of specific issues (proportions, readability, glow balance), targeted modifications to the glyph function, re-rendering, and before/after comparison. Works for skill, agent, and team glyphs. Use when a glyph renders poorly at small sizes, its visual metaphor is unclear, it has proportion issues, the neon glow effect is unbalanced, or after adding new palettes or changing the rendering pipeline.
npx claudepluginhub pjt222/agent-almanacThis skill is limited to using the following tools:
Improve an existing pictogram glyph in the `viz/` visualization layer — audit its current rendering, diagnose visual issues, apply targeted modifications, re-render, and compare before/after. Works for skill, agent, and team glyphs.
Create R-based pictogram glyphs for skill, agent, or team icons in the visualization layer. Covers concept sketching, ggplot2 layer composition using the primitives library, color strategy, registration in the appropriate glyph mapping file and manifest, rendering via the build pipeline, and visual verification of the neon-glow output. Use when a new entity has been added and needs a visual icon for the force-graph visualization, an existing glyph needs replacement, or when batch-creating glyphs for a new domain.
Generates and edits SVG logos, icons, and graphics. Covers path commands, shape primitives, styling, accessibility, gradients, masks, sprites, optimization, and animation techniques like CSS keyframes and SVG-specific methods.
Generates SVG icons and configurations for visual content tasks like diagrams and charts. Provides step-by-step guidance, best practices, and production-ready code. Auto-activates on 'svg icon generator' or 'svg' phrases.
Share bugs, ideas, or general feedback.
Improve an existing pictogram glyph in the viz/ visualization layer — audit its current rendering, diagnose visual issues, apply targeted modifications, re-render, and compare before/after. Works for skill, agent, and team glyphs.
skill, agent, or teamcommit-changes, mystic, tending)Examine the current glyph and identify specific issues.
viz/R/primitives*.R (19 domain-grouped files), mapped in viz/R/glyphs.Rviz/R/agent_primitives.R, mapped in viz/R/agent_glyphs.Rviz/R/team_primitives.R, mapped in viz/R/team_glyphs.Rviz/public/icons/cyberpunk/<domain>/<skillId>.webpviz/public/icons/cyberpunk/agents/<agentId>.webpviz/public/icons/cyberpunk/teams/<teamId>.webpGlyph Quality Dimensions:
+----------------+------+-----------------------------------------------+
| Dimension | 1-5 | Assessment Criteria |
+----------------+------+-----------------------------------------------+
| Readability | | Recognizable at 48px? Clear at 160px? |
| Proportions | | Well-centered? Good use of the 100x100 canvas?|
| Metaphor | | Does the shape clearly represent the entity? |
| Glow balance | | Glow enhances without overwhelming? |
| Palette compat | | Looks good across cyberpunk + viridis palettes?|
| Complexity | | Appropriate layer count (not too busy/sparse)? |
+----------------+------+-----------------------------------------------+
Expected: A clear diagnosis of what's wrong with the glyph and which dimensions to improve. The audit should be specific: "proportions: glyph uses only 40% of canvas" not "looks bad."
On failure: If the glyph function is missing or the entity isn't in its *_glyphs.R mapping, the glyph may not have been created yet — use create-glyph instead.
Determine why the identified issues exist.
size at s=1.0)?s too small or too large?ggfx::with_outer_glow():
col/bright parameters?Expected: Root causes that directly point to code changes. "The glyph is too small" -> "scale factor is 0.6 but should be 0.8." "Glow overwhelms" -> "three overlapping filled polygons each generate glow."
On failure: If the root cause isn't obvious from code inspection, render the glyph in isolation with different parameters to isolate the issue. Use render_glyph() with a single glyph to test.
Edit the glyph function to address the diagnosed issues.
s multiplier or element offsetscol/bright parameters, add alpha for depthglyph_name <- function(cx, cy, s, col, bright) {
# cx, cy = center (50, 50)
# s = scale (1.0 = ~70% of canvas)
# col = domain color, bright = brightened variant
# Returns: list() of ggplot2 layers
}
Expected: A modified glyph function that addresses the specific issues identified in Steps 1-2. Changes are targeted and minimal — enhance, don't redesign.
On failure: If the modifications make other dimensions worse (e.g., fixing proportions breaks readability), revert and try a different approach. If the glyph needs a complete redesign, use create-glyph instead.
Render the modified glyph and verify the fix. Always use build.sh — it handles platform detection and R binary selection. See render-icon-pipeline for the full flag reference.
Re-render based on entity type:
# From project root — use --no-cache to force re-render of modified glyph
bash viz/build.sh --only <domain> --no-cache # skills
bash viz/build.sh --type agent --only <id> --no-cache # agents
bash viz/build.sh --type team --only <id> --no-cache # teams
Verify the output files exist at the expected path for each palette
Check file sizes — icons should be 2-15 KB (WebP):
Expected: Fresh icon files generated for all palettes. File sizes are in the expected range.
On failure: If the build script errors, check the R console output for the specific error. Common causes: missing closing parenthesis in the glyph function, referencing undefined primitives, or returning non-list from the function. If rendering succeeds but output is blank, the glyph layers may be outside the canvas bounds.
Verify the enhancement improved the target dimensions.
python3 -m http.server 8080 from viz/Expected: Measurable improvement on the target dimensions with no regression on others. The glyph looks better at both sizes and across palettes.
On failure: If improvement is marginal or regression occurs, revert the changes and reconsider the diagnosis. Sometimes the original glyph's limitations are inherent to the metaphor, not the implementation — in that case, the metaphor itself may need to change (escalate to create-glyph).
build-icons.R, agents use build-agent-icons.R, teams use build-team-icons.R