{
    "tailapp": 2,
    "manifest": {
        "format": 2,
        "app_id": "summarise",
        "name": "Summarise",
        "version": 1,
        "schema": "tailapps/v0",
        "exported_at": 1795564623,
        "from": "gallery",
        "connections": [],
        "files": {
            "app.json": "048418823266ed9bd2ba90d7f9a1e9456e431c32db5c5a36870511566920f6f1"
        },
        "signature": "uxHA+HBNj5I2dESGGzKf1Ez30Qv3eBnXSLUSNr2W2UnmUgxMjjxHSoYyjIyPNLuec3qQcBhdRziDWef7R672Ag==",
        "key_id": "gallery-1"
    },
    "app": {
        "schema": "tailapps/v0",
        "app": "summarise",
        "name": "Summarise",
        "description": "Paste any text and get a short summary and its to-dos from the AI model built into your Mac or iPhone, then translate the summary. Nothing leaves the device. Needs Apple Intelligence.",
        "icon": "sparkles",
        "version": 1,
        "permissions": [
            "ai.generate",
            "translate",
            "clipboard.write"
        ],
        "state": {
            "draft": {
                "type": "text",
                "default": ""
            },
            "result": {
                "type": "object",
                "default": []
            },
            "lang": {
                "type": "text",
                "default": "fr"
            },
            "translated": {
                "type": "text",
                "default": ""
            }
        },
        "actions": {
            "summarise": {
                "steps": [
                    {
                        "if": "$draft",
                        "then": [
                            {
                                "set": {
                                    "translated": ""
                                }
                            },
                            {
                                "ai.generate": {
                                    "prompt": "Summarise this in two or three sentences, and list any to-dos it mentions (none is fine):\n\n{$draft}",
                                    "shape": {
                                        "summary": "text",
                                        "todos": [
                                            "text"
                                        ]
                                    }
                                },
                                "as": "out"
                            },
                            {
                                "set": {
                                    "result": "$out"
                                }
                            }
                        ],
                        "else": [
                            {
                                "toast": "Paste some text first"
                            }
                        ]
                    }
                ]
            },
            "translate": {
                "steps": [
                    {
                        "translate": "$result.summary",
                        "to": "$lang",
                        "as": "text"
                    },
                    {
                        "set": {
                            "translated": "$text"
                        }
                    }
                ]
            },
            "copy": {
                "args": {
                    "text": "text"
                },
                "steps": [
                    {
                        "clipboard.write": {
                            "text": "$args.text"
                        }
                    },
                    {
                        "toast": "Copied"
                    }
                ]
            },
            "clear": {
                "steps": [
                    {
                        "set": {
                            "draft": "",
                            "result": [],
                            "translated": ""
                        }
                    }
                ]
            }
        },
        "cards": [
            {
                "id": "main",
                "layout": {
                    "column": [
                        {
                            "field": "",
                            "type": "textarea",
                            "bind": "$draft",
                            "placeholder": "Paste an email, notes or an article\u2026",
                            "on_submit": "summarise"
                        },
                        {
                            "row": [
                                {
                                    "button": "Summarise",
                                    "on": "summarise",
                                    "style": "primary",
                                    "icon": "sparkles"
                                },
                                {
                                    "spacer": true
                                },
                                {
                                    "button": "Clear",
                                    "on": "clear",
                                    "style": "plain",
                                    "when": "$draft"
                                }
                            ],
                            "align": "center"
                        },
                        {
                            "badge": "Thinking on this device",
                            "busy": true,
                            "tone": "accent",
                            "when": "$running.summarise"
                        },
                        {
                            "section": "Summary",
                            "when": "$result.summary",
                            "children": [
                                {
                                    "text": "$result.summary",
                                    "lines": 8
                                },
                                {
                                    "row": [
                                        {
                                            "field": "",
                                            "type": "select",
                                            "bind": "$lang",
                                            "options": [
                                                {
                                                    "label": "French",
                                                    "value": "fr"
                                                },
                                                {
                                                    "label": "German",
                                                    "value": "de"
                                                },
                                                {
                                                    "label": "Spanish",
                                                    "value": "es"
                                                },
                                                {
                                                    "label": "Polish",
                                                    "value": "pl"
                                                }
                                            ]
                                        },
                                        {
                                            "button": "Translate",
                                            "on": "translate",
                                            "style": "plain",
                                            "icon": "translate"
                                        },
                                        {
                                            "spacer": true
                                        },
                                        {
                                            "button": "Copy",
                                            "on": "copy",
                                            "args": {
                                                "text": "$result.summary"
                                            },
                                            "style": "plain"
                                        }
                                    ],
                                    "align": "center"
                                },
                                {
                                    "text": "$translated",
                                    "lines": 8,
                                    "emphasis": "subtle",
                                    "when": "$translated"
                                }
                            ]
                        },
                        {
                            "section": "To-dos",
                            "when": "$result.todos",
                            "children": [
                                {
                                    "list": "$result.todos",
                                    "limit": 10,
                                    "item": {
                                        "cell": "$item",
                                        "leading": "circle"
                                    }
                                }
                            ]
                        }
                    ],
                    "gap": "m"
                }
            }
        ],
        "views": {
            "menubar": {
                "icon": "sparkles",
                "card": "main"
            }
        }
    },
    "app_json": "{\n  \"schema\": \"tailapps/v0\",\n  \"app\": \"summarise\",\n  \"name\": \"Summarise\",\n  \"description\": \"Paste any text and get a short summary and its to-dos from the AI model built into your Mac or iPhone, then translate the summary. Nothing leaves the device. Needs Apple Intelligence.\",\n  \"icon\": \"sparkles\",\n  \"version\": 1,\n  \"permissions\": [\"ai.generate\", \"translate\", \"clipboard.write\"],\n  \"state\": {\n    \"draft\": { \"type\": \"text\", \"default\": \"\" },\n    \"result\": { \"type\": \"object\", \"default\": {} },\n    \"lang\": { \"type\": \"text\", \"default\": \"fr\" },\n    \"translated\": { \"type\": \"text\", \"default\": \"\" }\n  },\n  \"actions\": {\n    \"summarise\": {\n      \"steps\": [\n        {\n          \"if\": \"$draft\",\n          \"then\": [\n            { \"set\": { \"translated\": \"\" } },\n            {\n              \"ai.generate\": {\n                \"prompt\": \"Summarise this in two or three sentences, and list any to-dos it mentions (none is fine):\\n\\n{$draft}\",\n                \"shape\": { \"summary\": \"text\", \"todos\": [\"text\"] }\n              },\n              \"as\": \"out\"\n            },\n            { \"set\": { \"result\": \"$out\" } }\n          ],\n          \"else\": [{ \"toast\": \"Paste some text first\" }]\n        }\n      ]\n    },\n    \"translate\": {\n      \"steps\": [\n        { \"translate\": \"$result.summary\", \"to\": \"$lang\", \"as\": \"text\" },\n        { \"set\": { \"translated\": \"$text\" } }\n      ]\n    },\n    \"copy\": {\n      \"args\": { \"text\": \"text\" },\n      \"steps\": [\n        { \"clipboard.write\": { \"text\": \"$args.text\" } },\n        { \"toast\": \"Copied\" }\n      ]\n    },\n    \"clear\": {\n      \"steps\": [{ \"set\": { \"draft\": \"\", \"result\": {}, \"translated\": \"\" } }]\n    }\n  },\n  \"cards\": [\n    {\n      \"id\": \"main\",\n      \"layout\": {\n        \"column\": [\n          { \"field\": \"\", \"type\": \"textarea\", \"bind\": \"$draft\", \"placeholder\": \"Paste an email, notes or an article\u2026\", \"on_submit\": \"summarise\" },\n          {\n            \"row\": [\n              { \"button\": \"Summarise\", \"on\": \"summarise\", \"style\": \"primary\", \"icon\": \"sparkles\" },\n              { \"spacer\": true },\n              { \"button\": \"Clear\", \"on\": \"clear\", \"style\": \"plain\", \"when\": \"$draft\" }\n            ],\n            \"align\": \"center\"\n          },\n          { \"badge\": \"Thinking on this device\", \"busy\": true, \"tone\": \"accent\", \"when\": \"$running.summarise\" },\n          {\n            \"section\": \"Summary\",\n            \"when\": \"$result.summary\",\n            \"children\": [\n              { \"text\": \"$result.summary\", \"lines\": 8 },\n              {\n                \"row\": [\n                  { \"field\": \"\", \"type\": \"select\", \"bind\": \"$lang\", \"options\": [\n                    { \"label\": \"French\", \"value\": \"fr\" }, { \"label\": \"German\", \"value\": \"de\" },\n                    { \"label\": \"Spanish\", \"value\": \"es\" }, { \"label\": \"Polish\", \"value\": \"pl\" }\n                  ] },\n                  { \"button\": \"Translate\", \"on\": \"translate\", \"style\": \"plain\", \"icon\": \"translate\" },\n                  { \"spacer\": true },\n                  { \"button\": \"Copy\", \"on\": \"copy\", \"args\": { \"text\": \"$result.summary\" }, \"style\": \"plain\" }\n                ],\n                \"align\": \"center\"\n              },\n              { \"text\": \"$translated\", \"lines\": 8, \"emphasis\": \"subtle\", \"when\": \"$translated\" }\n            ]\n          },\n          {\n            \"section\": \"To-dos\",\n            \"when\": \"$result.todos\",\n            \"children\": [\n              { \"list\": \"$result.todos\", \"limit\": 10, \"item\": { \"cell\": \"$item\", \"leading\": \"circle\" } }\n            ]\n          }\n        ],\n        \"gap\": \"m\"\n      }\n    }\n  ],\n  \"views\": {\n    \"menubar\": { \"icon\": \"sparkles\", \"card\": \"main\" }\n  }\n}\n",
    "files": []
}