{
  "project": {
    "title": "Refining Internal Communications",
    "icon": {
      "type": "emoji",
      "value": "✉️"
    }
  },
  "prompts": [
    {
      "title": "Refining Internal Communications",
      "icon": {
        "type": "emoji",
        "value": "💬"
      },
      "config": {
        "settings": {},
        "provider": "openai",
        "model": "gpt-4o"
      },
      "messages": [
        {
          "role": "system",
          "content": [
            {
              "modality": "text",
              "value": "You are an expert communication consultant specialising in workplace messaging and cross-functional collaboration. Your task is to transform technical, lengthy, or complex messages into clear, engaging, and well-toned communications that improve team understanding and reduce misinterpretations.\n\nWhen rewriting messages, ensure you:\n\n1. Maintain core information: Preserve all essential technical details and key points.\n2. Improve clarity: Break down complex concepts into digestible parts.\n3. Enhance tone: Match the desired communication style (professional, friendly, urgent, etc.).\n4. Add structure: Use formatting, bullets, or headers for better readability.\n5. Include context: Add necessary background for better understanding.\n6. Encourage action: Make next steps and expectations crystal clear.\n\nFocus on creating messages that foster collaboration, reduce back-and-forth clarifications, and maintain positive team dynamics while preserving technical accuracy."
            }
          ]
        },
        {
          "role": "user",
          "content": [
            {
              "modality": "text",
              "value": "Please rewrite this message with the following specifications:\n\n- Original message: {{original_message}}\n- Target audience: {{audience_type}}\n- Desired tone: {{communication_tone}}\n- Context: {{additional_context}}\n- Primary goal: {{communication_objective}}"
            }
          ]
        }
      ],
      "tools": [],
      "variables": {
        "original_message": {
          "modality": "text",
          "value": "",
          "linkedDataset": "Internal Comms - Dataset",
          "linkedDatasetColumn": "original_message"
        },
        "audience_type": {
          "modality": "text",
          "value": "",
          "linkedDataset": "Internal Comms - Dataset",
          "linkedDatasetColumn": "audience_type"
        },
        "communication_tone": {
          "modality": "text",
          "value": "",
          "linkedDataset": "Internal Comms - Dataset",
          "linkedDatasetColumn": "communication_tone"
        },
        "additional_context": {
          "modality": "text",
          "value": "",
          "linkedDataset": "Internal Comms - Dataset",
          "linkedDatasetColumn": "additional_context"
        },
        "communication_objective": {
          "modality": "text",
          "value": "",
          "linkedDataset": "Internal Comms - Dataset",
          "linkedDatasetColumn": "communication_objective"
        }
      },
      "playgrounds": [
        {
          "messages": [
            {
              "role": "assistant",
              "content": [
                {
                  "modality": "text",
                  "value": "Quick Update: API Issue Impacting Q2 Launch Timeline\n\nHi team,\n\nI wanted to loop everyone in on a technical issue affecting our Q2 release timeline and get us aligned on next steps.\n\nWhat's happening:\nOur API is hitting rate limits during peak usage times, causing connection errors for our mobile app. Think of it like a highway during rush hour — we're getting more traffic than our current lanes can handle.\n\nThe numbers:\n- Our system can handle 1,000 requests per minute\n- We're seeing 1,200–1,500 requests during busy periods\n- This is preventing our mobile team from completing their final testing\n\nImpact:\nThis is blocking mobile integration testing and could delay our Q2 launch if not resolved this week.\n\nProposed solutions:\n1. Quick fix: Increase our rate limits to handle current traffic\n2. Better fix: Implement smart retry logic so the app handles busy periods gracefully\n3. Bonus: Optimise database connections for better performance\n\nNext steps:\n- Engineering will implement option 1 by Wednesday for immediate relief\n- Option 2 is planned for next sprint as a permanent solution\n- Mobile team can resume testing by Thursday\n\nQuestions or concerns? Drop them here or ping me directly."
                }
              ]
            }
          ],
          "config": {
            "settings": {},
            "provider": "openai",
            "model": "gpt-4o"
          },
          "connectedDataset": "Internal Comms - Dataset"
        }
      ],
      "evaluators": [
        {
          "title": "Rewrite Quality",
          "state": "active",
          "weight": 1,
          "threshold": 0.7,
          "value": {
            "type": "llm-as-a-judge",
            "group": "ai-powered",
            "value": "Goal: The rewrite must apply all six required improvements to the original message.\n\nChecks:\n- All essential technical details from the original are preserved\n- Complex concepts are broken down into plain language\n- Tone matches the desired communication style specified in the input\n- Output uses structure (bullets, headers, or sections) for readability\n- Sufficient context is added for the target audience to understand the situation\n- Next steps and expectations are explicit and easy to act on\n\nScoring guidance:\n- 1: Missing 3 or more improvements; output is barely better than the original.\n- 2: Some improvements applied but significant gaps remain.\n- 3: Most improvements present; one or two areas are weak or missing.\n- 4: All improvements applied with good quality; minor gaps only.\n- 5: All six improvements fully and clearly applied throughout the rewrite."
          },
          "connectedDataset": "Internal Comms - Dataset",
          "runContinuously": true,
          "continuousSampleRate": 1
        },
        {
          "title": "Audience Fit",
          "state": "active",
          "weight": 1,
          "threshold": 0.7,
          "value": {
            "type": "llm-as-a-judge",
            "group": "ai-powered",
            "value": "Goal: The rewrite must be written specifically for the stated target audience — not a generic version of the original.\n\nChecks:\n- Technical jargon is explained or removed for non-technical audiences\n- Formality level matches the audience (executives vs. peers vs. all-hands)\n- Framing and emphasis reflect what matters most to the stated audience\n- The primary goal is clearly served by the way the message is written\n- No unexplained acronyms, systems, or concepts the audience wouldn't know\n\nScoring guidance:\n- 1: Output ignores the audience — jargon intact, wrong formality, wrong emphasis.\n- 2: Some audience awareness but significant mismatches remain.\n- 3: Generally appropriate for the audience; a few jarring moments.\n- 4: Well-matched to the audience; minor lapses only.\n- 5: Perfectly calibrated — language, tone, framing, and emphasis all fit the stated audience."
          },
          "connectedDataset": "Internal Comms - Dataset",
          "runContinuously": true,
          "continuousSampleRate": 1
        },
        {
          "title": "Response Length",
          "state": "active",
          "weight": 1,
          "threshold": 0.7,
          "value": {
            "type": "response-length",
            "group": "performance",
            "value": {
              "value": "600",
              "unit": "tokens",
              "operator": "less"
            }
          },
          "connectedDataset": "Internal Comms - Dataset",
          "runContinuously": true,
          "continuousSampleRate": 1
        }
      ]
    }
  ],
  "datasets": [
    {
      "title": "Internal Comms - Dataset",
      "icon": {
        "type": "emoji",
        "value": "💾"
      },
      "columns": [
        {
          "name": "original_message",
          "settings": {
            "type": "static"
          }
        },
        {
          "name": "audience_type",
          "settings": {
            "type": "static"
          }
        },
        {
          "name": "communication_tone",
          "settings": {
            "type": "static"
          }
        },
        {
          "name": "additional_context",
          "settings": {
            "type": "static"
          }
        },
        {
          "name": "communication_objective",
          "settings": {
            "type": "static"
          }
        }
      ],
      "rows": [
        {
          "original_message": "The API endpoint is returning 429 errors due to rate limiting. Threshold is 1,000 req/min but peak usage hits 1,200-1,500. Need to increase limits or implement exponential backoff. Blocking mobile team integration testing. DB connection pool also at 95% capacity.",
          "audience_type": "Cross-functional team: design, marketing, and executives",
          "communication_tone": "Professional but approachable, solution-focused",
          "additional_context": "Impacting a major product launch timeline",
          "communication_objective": "Get team alignment on next steps and timeline"
        },
        {
          "original_message": "Migrating primary DB from PostgreSQL 12 to 15 this Saturday 2-4am. Some foreign key constraints need manual migration. Read replicas stay up but writes will fail for ~45 min, possibly 90 min if schema edge cases arise.",
          "audience_type": "Product and operations team",
          "communication_tone": "Informative and reassuring",
          "additional_context": "Affects a customer-facing feature used during business hours",
          "communication_objective": "Ensure the team knows what to expect and who to contact if issues arise"
        },
        {
          "original_message": "Authentication refactor is 3 sprints behind due to undiscovered OAuth edge cases with enterprise SSO. Each enterprise customer has slightly different SAML configs and our abstraction layer doesn't handle it. Need 2 more sprints minimum.",
          "audience_type": "Executive leadership (CEO, CPO)",
          "communication_tone": "Direct and confident, not defensive",
          "additional_context": "Enterprise tier was a key Q3 commitment made to the board",
          "communication_objective": "Get exec buy-in on revised timeline without losing confidence"
        },
        {
          "original_message": "Detected unusual API access at 03:14 UTC. Misconfigured S3 bucket exposed read access to internal analytics logs for ~6 hours. No PII exposed. Bucket is locked. Reviewing access logs to confirm scope. Only aggregated event data was affected.",
          "audience_type": "All-hands company communication",
          "communication_tone": "Transparent and calm, no panic",
          "additional_context": "Team will see news before the internal memo goes out",
          "communication_objective": "Communicate facts clearly before speculation starts"
        }
      ]
    }
  ]
}
