算法艺术创作
algorithmic-art
通过代码和可调参数创作生成艺术与交互式视觉效果。
enhance-glyph【设计与创意】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 s…
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
改 viz/ 視化層既有之象形符號——審其當下之渲染、診視覺之疵、施針對性之改、重渲、比前後。適用於技能、代理、團隊之符號。
skill、agent 或 teamcommit-changes、mystic、tending)察當下之符號並識具體之疵。
viz/R/primitives*.R(19 域分文件),映於 viz/R/glyphs.Rviz/R/agent_primitives.R,映於 viz/R/agent_glyphs.Rviz/R/team_primitives.R,映於 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)? |
+----------------+------+-----------------------------------------------+
預期: 對符號之疵與待改維度有明之診。審宜具體:「比例:符號僅用 40% 之畫布」而非「看似不佳」。
失敗時: 若符號函數缺或實體未於其 *_glyphs.R 映射中,則符號或未建——應改用 create-glyph。
定所識之疵何以存。
size < 1.5)?s 過小或過大?ggfx::with_outer_glow() 相交:
col/bright 參數?預期: 根因直指代碼改。「符號過小」→「縮放因子為 0.6 宜 0.8」。「輝光過壓」→「三重疊之填充多邊形各生輝光」。
失敗時: 若根因不顯於代碼檢,以不同參數孤立渲符號以隔疵。用 render_glyph() 以單符號測之。
編符號函數以解所診之疵。
s 乘子或元素偏移col/bright 參數,加透明度以示深度glyph_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
}
預期: 改後之符號函數解步驟一二所識之具體疵。改乃針對而少——改之,非重設。
失敗時: 若改使他維劣(如修比例而壞可讀性),則回並試別法。若符號需全重設,改用 create-glyph。
渲改後之符號並驗其修。恒以 build.sh 為之——其處平台偵測與 R 二進制選擇。見 render-icon-pipeline 查全之旗標參考。
依實體類型重渲:
# 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
驗輸出文件於各色板之預期路徑存
查文件大小——圖示宜 2-15 KB(WebP):
預期: 為所有色板生新之圖示文件。文件大小於預期範圍。
失敗時: 若構建腳本錯,察 R 控制臺輸出以見具體錯。常因:符號函數缺閉括號、引未定之原語、或函數返非 list。若渲成而輸出空,符號之層或已出畫布界。
驗改善已改目標維度。
python3 -m http.server 8080 於 viz/預期: 目標維度可測之改善,他維無退。符號於二尺與跨色板皆更佳。
失敗時: 若改善微或有退,則回改並重思診。有時原符號之限為隱喻本身所致,非實作——此時隱喻本身或需改(升級至 create-glyph)。
build-icons.R,agents 用 build-agent-icons.R,teams 用 build-team-icons.R