[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7BKE8FRS65EMGR5XV4GTZKX":3,"skill-same:01M7BKE8FRS65EMGR5XV4GTZKX":51},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":30,"install":31,"resources":44},"01M7BKE8FRS65EMGR5XV4GTZKX","dialogue-graph",null,"A library for building, validating, visualizing, and serializing dialogue graphs (line + choice nodes) using `Graph`, `Node`, and `Edge`.","linyouxue\u002Fskill-repair-benchmark","linyouxue","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F216151464?v=4","01M7BJEVCXKD74KH6FG9CBVSQB","林宥学","01M7BJEVE02NP217V93BKZFC0J",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fcontrolled-skill-repair-experiments\u002Fresult\u002Fmmg2skill-gpt5.2-xhigh\u002Ffinal\u002Flocation-dialogue-parser\u002Fskills\u002Fdialogue-graph\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: dialogue-graph\ndescription: A library for building, validating, visualizing, and serializing dialogue\n  graphs (line + choice nodes) using `Graph`, `Node`, and `Edge`.\n---\n\n## Steps\n1. Import the primitives and create a graph:\n   ```python\n   from dialogue_graph import Graph, Node, Edge\n   graph = Graph()\n   ```\n2. Add nodes (use unique IDs; add them in script order if you want a stable “first node” entry point):\n   ```python\n   # Regular spoken\u002Fnarration line node\n   graph.add_node(Node(id=\"GateScene\", speaker=\"Guard\", text=\"Halt!\", type=\"line\"))\n\n   # Choice hub node\n   graph.add_node(Node(id=\"NameChoice\", type=\"choice\"))\n   ```\n3. Add edges to connect nodes:\n   - For non-choice transitions, keep `text` empty (the spoken text belongs on the node):\n     ```python\n     graph.add_edge(Edge(source=\"GateScene\", target=\"NameChoice\", text=\"\"))\n     ```\n   - For choice options, set `Edge.text` to the option body **without** the numeric enumeration (`1.` \u002F `2.` \u002F …). Keep bracket tags like `[Lie]` \u002F `[Attack]` as part of the option body text:\n     ```python\n     graph.add_edge(Edge(source=\"NameChoice\", target=\"KnightPath\",\n                         text=\"I am Sir Aldric, Knight of the Realm.\"))\n     graph.add_edge(Edge(source=\"NameChoice\", target=\"MerchantPath\",\n                         text=\"[Lie] I'm a merchant with important goods.\"))\n     ```\n   - Use `\"End\"` as a terminal edge target string; it is treated as a special terminal and does not require a corresponding `Node(\"End\")`.\n4. Validate structure with the built-in validator:\n   ```python\n   errors = graph.validate()\n   ```\n   `validate()` checks that edge sources exist and that edge targets exist, with `\"End\"` allowed as a missing terminal target.\n5. Export the parsed graph directly (without normalizing the graph by adding\u002Fremoving nodes\u002Fedges):\n   ```python\n   data = graph.to_dict()     # {\"nodes\":[...], \"edges\":[...]}\n   json_str = graph.to_json() # JSON string of the same structure\n   ```\n6. Visualize:\n   ```python\n   graph.visualize('dialogue_graph')            # dialogue_graph.png\n   graph.visualize('dialogue_graph', format='svg')\n   ```\n   The built-in visualizer draws choice nodes as diamonds, line nodes as rounded boxes, and includes an `End` terminal node in the diagram.\n7. Load an existing graph when needed:\n   ```python\n   graph = Graph.from_file('dialogue.json')\n   ```\n\n## Expected Result\n- Nodes serialize as `{\"id\": ..., \"text\": ..., \"speaker\": ..., \"type\": ...}` with `type` in `{\"line\",\"choice\"}`.\n- Edges serialize as `{\"from\": ..., \"to\": ..., \"text\": ...}` where choice edges’ `text` is the option body (no `1.`\u002F`2.` prefix), and terminal transitions can target `\"End\"` without requiring an `\"End\"` node in `nodes`.\n- `graph.validate()` returns an empty list when all non-`End` edge targets exist.\n","## Steps\n1. Import the primitives and create a graph:\n   ```python\n   from dialogue_graph import Graph, Node, Edge\n   graph = Graph()\n   ```\n2. Add nodes (use unique IDs; add them in script order if you want a stable “first node” entry point):\n   ```python\n   # Regular spoken\u002Fnarration line node\n   graph.add_node(Node(id=\"GateScene\", speaker=\"Guard\", text=\"Halt!\", type=\"line\"))\n\n   # Choice hub node\n   graph.add_node(Node(id=\"NameChoice\", type=\"choice\"))\n   ```\n3. Add edges to connect nodes:\n   - For non-choice transitions, keep `text` empty (the spoken text belongs on the node):\n     ```python\n     graph.add_edge(Edge(source=\"GateScene\", target=\"NameChoice\", text=\"\"))\n     ```\n   - For choice options, set `Edge.text` to the option body **without** the numeric enumeration (`1.` \u002F `2.` \u002F …). Keep bracket tags like `[Lie]` \u002F `[Attack]` as part of the option body text:\n     ```python\n     graph.add_edge(Edge(source=\"NameChoice\", target=\"KnightPath\",\n                         text=\"I am Sir Aldric, Knight of the Realm.\"))\n     graph.add_edge(Edge(source=\"NameChoice\", target=\"MerchantPath\",\n                         text=\"[Lie] I'm a merchant with important goods.\"))\n     ```\n   - Use `\"End\"` as a terminal edge target string; it is treated as a special terminal and does not require a corresponding `Node(\"End\")`.\n4. Validate structure with the built-in validator:\n   ```python\n   errors = graph.validate()\n   ```\n   `validate()` checks that edge sources exist and that edge targets exist, with `\"End\"` allowed as a missing terminal target.\n5. Export the parsed graph directly (without normalizing the graph by adding\u002Fremoving nodes\u002Fedges):\n   ```python\n   data = graph.to_dict()     # {\"nodes\":[...], \"edges\":[...]}\n   json_str = graph.to_json() # JSON string of the same structure\n   ```\n6. Visualize:\n   ```python\n   graph.visualize('dialogue_graph')            # dialogue_graph.png\n   graph.visualize('dialogue_graph', format='svg')\n   ```\n   The built-in visualizer draws choice nodes as diamonds, line nodes as rounded boxes, and includes an `End` terminal node in the diagram.\n7. Load an existing graph when needed:\n   ```python\n   graph = Graph.from_file('dialogue.json')\n   ```\n\n## Expected Result\n- Nodes serialize as `{\"id\": ..., \"text\": ..., \"speaker\": ..., \"type\": ...}` with `type` in `{\"line\",\"choice\"}`.\n- Edges serialize as `{\"from\": ..., \"to\": ..., \"text\": ...}` where choice edges’ `text` is the option body (no `1.`\u002F`2.` prefix), and terminal transitions can target `\"End\"` without requiring an `\"End\"` node in `nodes`.\n- `graph.validate()` returns an empty list when all non-`End` edge targets exist.\n",{"name":5,"description":7},"main","cdcb6d230f3b15c3c33f8a2bdd16439f43602cbe","controlled-skill-repair-experiments\u002Fresult\u002Fmmg2skill-gpt5.2-xhigh\u002Ffinal\u002Flocation-dialogue-parser\u002Fskills\u002Fdialogue-graph",1,"https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark","https:\u002F\u002Fgithub.com\u002Flinyouxue","2026-11-14 20:28:35",{"source":8,"skillName":5,"commands":32,"prompt":42,"zipAvailable":43},[33,36,39],{"tool":34,"command":35},"npx","npx skills add linyouxue\u002Fskill-repair-benchmark --skill dialogue-graph",{"tool":37,"command":38},"bunx","bunx skills add linyouxue\u002Fskill-repair-benchmark --skill dialogue-graph",{"tool":40,"command":41},"pnpm","pnpm dlx skills add linyouxue\u002Fskill-repair-benchmark --skill dialogue-graph","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fcontrolled-skill-repair-experiments\u002Fresult\u002Fmmg2skill-gpt5.2-xhigh\u002Ffinal\u002Flocation-dialogue-parser\u002Fskills\u002Fdialogue-graph\u002FSKILL.md",true,[45],{"path":46,"resourceType":47,"resourceTypeDesc":48,"sizeBytes":49,"sourceHtmlUrl":50},"scripts\u002Fdialogue_graph.py","SCRIPT","脚本",5793,"https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fcontrolled-skill-repair-experiments\u002Fresult\u002Fmmg2skill-gpt5.2-xhigh\u002Ffinal\u002Flocation-dialogue-parser\u002Fskills\u002Fdialogue-graph\u002Fscripts\u002Fdialogue_graph.py",[52,59,66,73,78,83],{"skillNo":53,"name":54,"nameZh":6,"description":55,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":56,"categories":57,"keywords":58,"publishedAt":19},"01M7E1HGVRY73NBJ022CJG13X6","video-frame-extraction","Extract frames from video files and save them as images using OpenCV","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_03\u002Finputs\u002Fskills\u002Fvideo-frame-extraction\u002FSKILL.md",[],[],{"skillNo":60,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":63,"categories":64,"keywords":65,"publishedAt":19},"01M7E1HAG5R7CJ9C8NYJS771MB","openai-vision","Analyze images and multi-frame sequences using OpenAI GPT vision models","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_03\u002Finputs\u002Fskills\u002Fopenai-vision\u002FSKILL.md",[],[],{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":19},"01M7E1H7DADKB6QBWKC2KQ63SZ","image-ocr","Extract text content from images using Tesseract OCR via Python, including structured field extraction from receipts and forms","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_03\u002Finputs\u002Fskills\u002Fimage-ocr\u002FSKILL.md",[],[],{"skillNo":74,"name":54,"nameZh":6,"description":55,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":75,"categories":76,"keywords":77,"publishedAt":19},"01M7E1H0WBNT43TENGQY7AVZHD","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_02\u002Finputs\u002Fskills\u002Fvideo-frame-extraction\u002FSKILL.md",[],[],{"skillNo":79,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M7E1GTC7D4N4Q2EF03875J9E","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_02\u002Finputs\u002Fskills\u002Fopenai-vision\u002FSKILL.md",[],[],{"skillNo":84,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M7E1GQ92CWFMGH53KSSE4WER","https:\u002F\u002Fgithub.com\u002Flinyouxue\u002Fskill-repair-benchmark\u002Fblob\u002Fmain\u002Fjpg-ocr-stat\u002Fresult\u002Fskilltta-claude4.7\u002Fgroup_03\u002Frun_02\u002Finputs\u002Fskills\u002Fimage-ocr\u002FSKILL.md",[],[]]