Investor Update Email
Run ID: 69cb137642bc43f7e3be72fb2026-03-31Business
PantheraHive BOS
BOS Dashboard

Craft polished monthly/quarterly investor update emails with KPI highlights, milestones, challenges, asks, and financial snapshot.

Audience Analysis: Investor Update Email

This document provides a comprehensive analysis of the target audience for your investor update emails. Understanding your investors' perspectives, motivations, and communication preferences is crucial for crafting effective and impactful updates.


1. Investor Demographics & Types

Your investor base can be diverse, and while a core message should resonate with all, subtle tailoring can enhance engagement.

  • Angel Investors: Often early-stage, high-net-worth individuals. They are typically more emotionally invested in the founder's vision, may offer mentorship, and are interested in the overall narrative and progress, even if early metrics are not yet stellar. They often appreciate direct, personal communication.
  • Venture Capital (VC) Firms: Professional institutional investors. Highly data-driven, focused on hyper-growth, scalability, market traction, competitive advantage, and clear path to exit (IPO or acquisition). They expect quantitative evidence of progress and a clear understanding of risk mitigation.
  • Private Equity (PE) Firms: Typically invest in more mature companies. Their focus is on profitability, operational efficiency, market share, and strong cash flow generation. They demand robust financial reporting and evidence of sustainable business models.
  • Family Offices: May have longer investment horizons and a focus on capital preservation, sustainable growth, and sometimes social impact (ESG). They appreciate transparency, stability, and a clear vision for long-term value creation.
  • Strategic Investors (Corporate VCs): Invest for both financial return and strategic alignment with their parent company. They look for synergies, market access, technology integration, and potential for future collaboration.

Data Insight: A recent survey by Carta showed that VC investors spend an average of 3-5 minutes reviewing an investor update, emphasizing the need for conciseness and clarity.


2. Key Investor Motivations & Concerns

Regardless of their type, all investors share fundamental motivations and concerns that your update must address.

  • Return on Investment (ROI): This is the paramount concern. Investors want to see a clear path to generating a return on their capital. Your update must demonstrate progress towards this goal.
  • Growth & Scalability: Are you growing quickly and sustainably? Is the market opportunity expanding? Investors want evidence that you can capture a significant share of a large market.
  • Risk Mitigation: What are the challenges, and how are you addressing them? Investors want transparency about obstacles (competition, market shifts, operational issues) and confidence in your team's ability to navigate them.
  • Team Competence & Execution: Investors back teams. They want to see that the leadership and broader team are capable, executing effectively, and adapting to market conditions.
  • Market Position & Competitive Landscape: How are you differentiated? Who are your competitors, and how are you staying ahead?
  • Financial Health & Runway: How are cash flow, burn rate, and runway looking? This is critical for assessing immediate stability and future fundraising needs.
  • Exit Strategy (for VCs/PE): While not always explicit in every update, investors (especially VCs and PE) are always thinking about the ultimate liquidity event. Progress towards milestones that enable this is key.
  • Transparency & Trust: Honest communication, even about setbacks, builds trust. Investors appreciate a balanced view rather than an overly optimistic one.

Trend: There's an increasing demand for ESG (Environmental, Social, Governance) reporting, especially from institutional investors and family offices. If applicable, brief updates on these initiatives can be valuable.


3. Desired Communication Style & Level of Detail

Investors are busy and receive numerous updates. Your communication must be efficient, professional, and impactful.

  • Concise & Scannable: Use clear headings, bullet points, and short paragraphs. An executive summary is highly recommended.
  • Data-Driven & Visual: Back up claims with quantitative data (KPIs, financial metrics). Charts, graphs, and infographics are highly effective for conveying trends quickly.
  • Professional & Confident Tone: Maintain a formal yet approachable tone. Be confident in your achievements but realistic about challenges. Avoid jargon where possible, or explain it clearly.
  • Balanced Perspective: Highlight successes and milestones, but also candidly discuss challenges, lessons learned, and proposed solutions.
  • Forward-Looking: What's next? What are the upcoming milestones, goals, and strategic priorities for the next quarter/period?
  • Actionable Asks (Optional but Recommended): If you have specific needs (e.g., introductions, strategic advice, feedback), clearly state them. Make it easy for investors to help.

Data Insight: Emails with visuals (charts, graphs) have a higher engagement rate. Consider embedding simple charts directly into the email or linking to a more detailed dashboard/report.


4. Recommendations for Content & Structure

Based on the audience analysis, here are specific recommendations for crafting your investor update email:

  1. Executive Summary (Mandatory): A 3-5 sentence overview of the most critical highlights, challenges, and key takeaways. This allows busy investors to grasp the core message immediately.
  2. Key Performance Indicators (KPIs):

* Selection: Prioritize 3-5 most critical metrics (e.g., MRR, CAC, LTV, user growth, conversion rates, retention).

* Visuals: Use simple charts to show trends (month-over-month, quarter-over-quarter).

* Context: Briefly explain what each KPI means and why it's important.

  1. Milestones & Achievements:

* Specifics: Detail key product launches, partnerships, hiring, fundraising progress, or significant customer wins.

* Impact: Explain the significance of each milestone.

  1. Challenges & Learnings:

* Transparency: Be honest about obstacles encountered.

* Solutions: Detail how you are addressing these challenges and what you've learned.

* Mitigation: Show you have a plan to overcome them.

  1. Financial Snapshot:

* Key Figures: Revenue, burn rate, cash on hand, runway.

* Accuracy: Ensure all financial data is precise and reconcilable.

* Context: Explain any significant variances from projections.

  1. "Asks" / How Investors Can Help:

* Clarity: Be specific about what you need (e.g., introductions to potential clients/hires, strategic advice on a specific market, feedback on a new product).

* Respectful: Frame asks as opportunities for investors to add value beyond capital.

  1. Outlook / Next Steps:

* Future Focus: Outline key objectives and priorities for the upcoming period.

* Vision: Reiterate the long-term vision and how current efforts align.

  1. Professional Closing: Thank investors for their continued support and offer to answer any questions.

5. Next Steps for Workflow

The insights from this audience analysis will directly inform the subsequent steps in crafting your investor update email.

  • Step 2: Content Generation (gemini → generate_content):

* Develop an Executive Summary based on the key highlights and challenges identified.

* Select and prepare data for the 3-5 most critical KPIs, ensuring visual representation where possible.

* Compile a list of key milestones achieved and planned.

* Articulate current challenges and proposed solutions.

* Gather and summarize financial data (revenue, burn, runway).

* Formulate specific "asks" for investors, if any.

* Outline the strategic priorities for the next period.

  • Step 3: Refinement & Review (gemini → refine_and_review):

* Ensure the tone is professional, confident, and transparent.

* Verify data accuracy and consistency.

* Check for clarity, conciseness, and scannability.

* Confirm all investor concerns identified in this analysis are adequately addressed.

* Proofread meticulously for grammar and spelling errors.

gemini Output

Here is the comprehensive, detailed, and professional output for your Investor Update Email, ready for publishing. This content is structured to be engaging and informative, covering all the specified elements.


Investor Update Email

This section provides a complete, publish-ready investor update email template. Remember to replace all bracketed placeholders [ ] with your company-specific information.

Subject Line Options

Choose one of the following professional and engaging subject lines:

  • Option 1 (General): [Company Name] Investor Update: [Reporting Period] Performance & Progress
  • Option 2 (Highlighting Growth): Accelerating Growth & Key Milestones: [Company Name] [Reporting Period] Investor Update
  • Option 3 (Focus on Metrics): [Company Name] [Reporting Period]: Strong KPIs, Strategic Milestones, and Future Outlook
  • Option 4 (Concise): [Company Name] - [Reporting Period] Investor Briefing

Email Body

Subject: [Choose one of the Subject Line Options above]

Salutation:

Dear Investors,

Opening:

We hope this email finds you well.

We are pleased to share our [Monthly/Quarterly] update for [Reporting Period], reflecting continued strong momentum and strategic progress at [Company Name]. This period has been marked by significant achievements, valuable learnings, and a clear path forward as we continue to execute on our vision.


Executive Summary & Key Highlights

This section provides a quick overview of the most critical updates.

  • [Highlight 1 - e.g., Record Revenue Growth]: Achieved a [X]% increase in [Key Metric, e.g., Monthly Recurring Revenue (MRR)] to reach $[X]M, surpassing our internal targets.
  • [Highlight 2 - e.g., Major Product Launch]: Successfully launched [New Product/Feature Name], which has already seen [X] user adoption and positive early feedback.
  • [Highlight 3 - e.g., Strategic Partnership]: Forged a pivotal partnership with [Partner Company Name], expanding our market reach into [New Market/Segment].

Performance & KPI Highlights

A detailed look at your key performance indicators.

We are proud to report robust performance across our core metrics:

  • Revenue Growth:

* [Monthly/Quarterly] Revenue: $[X]M (an increase of [Y]% from previous [month/quarter])

* [Monthly/Quarterly] Recurring Revenue (MRR/ARR): $[X]M (up [Y]% [month-over-month/quarter-over-quarter])

* Average Revenue Per User (ARPU): $[X] (up [Y]%)

  • Customer/User Growth:

* New Customers/Users Acquired: [X] (totaling [Y] active customers/users)

* Customer Acquisition Cost (CAC): $[X] (optimized by [Y]% through [specific initiative])

* Customer Churn Rate: [X]% (maintained below industry average of [Y]%)

  • Engagement & Product Metrics:

* Daily/Monthly Active Users (DAU/MAU): [X] DAU / [Y] MAU (showing [Z]% engagement)

* Key Feature Adoption: [X]% of users are now utilizing [Specific Feature], driving [Y]% higher retention.

* Net Promoter Score (NPS): [X] (indicating strong customer satisfaction)


Milestones & Achievements

Specific accomplishments and progress made during the reporting period.

This period saw us achieve several critical milestones:

  • Product Development:

* [Product Milestone 1]: Successfully completed the beta phase for [Product Feature], incorporating feedback from [X] early adopters.

* [Product Milestone 2]: Deployed [X] major product updates, enhancing [specific functionality] and improving user experience.

  • Market Expansion:

* [Market Milestone 1]: Officially entered the [New Geographic Market/Industry Sector] market, securing our first [X] clients.

* [Market Milestone 2]: Our marketing efforts in [Specific Channel] yielded a [X]% increase in qualified leads.

  • Team & Operations:

* [Team Milestone 1]: Welcomed [X] key hires to our [Department, e.g., engineering/sales] team, strengthening our capabilities in [specific area].

* [Team Milestone 2]: Implemented [New Process/System, e.g., new CRM], improving operational efficiency by [X]%.

  • Awards & Recognition (if applicable):

* [Company Name] was recognized as [Award/Accolade] by [Organization].


Challenges & Learnings

Transparent discussion of obstacles and how they are being addressed.

While we celebrate our successes, we also believe in transparency regarding challenges and our strategic responses:

  • [Challenge 1 - e.g., Increased Competition]: We observed increased competitive pressure in the [Specific Market Segment], particularly from [Competitor].

* Learning & Action: In response, we've accelerated our product roadmap to differentiate with [Unique Selling Proposition] and are enhancing our sales strategy with [Specific Tactic].

  • [Challenge 2 - e.g., Higher CAC]: Our Customer Acquisition Cost (CAC) saw a temporary increase due to [Reason, e.g., rising ad costs in Q3].

* Learning & Action: We are diversifying our acquisition channels, focusing more on [e.g., organic growth, content marketing, referral programs], and optimizing our ad spend with A/B testing to bring CAC back down.

  • [Challenge 3 - e.g., Technical Hurdle]: We encountered a technical challenge with [Specific System/Integration] that caused a [minor delay/brief outage].

* Learning & Action: Our engineering team swiftly resolved the issue, and we've implemented enhanced monitoring and redundant systems to prevent recurrence, strengthening our infrastructure.


Financial Snapshot

A high-level overview of your financial health.

(For a detailed financial breakdown, please refer to the attached financial statements.)

  • Cash Position: We currently have $[X]M in cash reserves, providing [Y] months of runway at our current burn rate.
  • Burn Rate: Our average monthly burn rate for the period was $[X]K.
  • Revenue vs. Expenses: Our revenue growth continues to outpace expense growth, moving us closer to profitability.
  • [Other Key Financials, e.g., Gross Margin]: Our gross margin remains strong at [X]%.

Asks & How You Can Help

Specific requests to your investors.

Your continued support is invaluable. Here are a few ways you might be able to assist us in the coming [month/quarter]:

  • Introductions: We are actively seeking introductions to [Type of Individuals/Companies, e.g., potential strategic partners in the retail sector, senior executives at enterprise clients, experienced candidates for our Head of Marketing role].
  • Feedback: We are refining our [e.g., Q4 product roadmap/go-to-market strategy] and would greatly appreciate your insights, particularly if you have expertise in [specific area].
  • Talent: If you know exceptional talent, especially in [Key Roles/Departments, e.g., AI/ML engineering, B2B SaaS sales], please connect them with us.
  • Advisory: We are exploring [Specific Strategic Initiative, e.g., international expansion into Europe] and would welcome any relevant advisory or connections you might have.

Looking Ahead

Brief on next steps and future outlook.

As we look to the next [month/quarter], our primary focus will be on:

  • [Strategic Priority 1]: Scaling our [Product/Service] to reach [X] active users/customers.
  • [Strategic Priority 2]: Launching [Next Major Product/Feature] to capture [New Market Segment].
  • [Strategic Priority 3]: Driving towards profitability by optimizing our operational efficiency and expanding our revenue streams.

We are incredibly excited about the opportunities ahead and remain committed to building a sustainable and impactful business.


Closing:

Thank you for your continued trust and investment in [Company Name]. We are grateful for your partnership and look forward to sharing more progress in our next update.

Sincerely,

[Your Name]

[Your Title]

[Company Name]

[Your Email Address]

[Company Website]


Attachments/Appendix

  • [Link or Mention]: A detailed financial report for [Reporting Period] is attached/can be accessed via [Link to Secure Investor Portal/Data Room].
  • [Link or Mention]: Our latest investor deck is available here: [Link].

gemini Output

This output provides a comprehensive, detailed, and professional investor update email template, optimized and finalized for direct use. It incorporates all requested elements and best practices for investor communications.


Investor Update Email: Optimized & Finalized Template

Purpose: To provide a clear, concise, and transparent update to investors, highlighting progress, financial health, challenges, and future plans.


1. Recommended Subject Line Options

Choose a subject line that is clear, concise, and immediately communicates the purpose and period of the update.

  • Option 1 (Standard): [Company Name] Investor Update - [Month/Quarter] [Year]

Example: PantheraHive Investor Update - Q4 2023*

  • Option 2 (Highlighting Growth): [Company Name] Investor Update: Strong Growth & Key Milestones in [Month/Quarter] [Year]

Example: PantheraHive Investor Update: Strong Growth & Key Milestones in Q4 2023*

  • Option 3 (Concise): [Company Name] Progress Report - [Month/Quarter] [Year]

Example: PantheraHive Progress Report - Q4 2023*


2. Email Body Template


Subject: [Company Name] Investor Update - [Month/Quarter] [Year]

Dear Investors,

We hope this email finds you well.

We are pleased to share our progress and key developments for [Company Name] during the [Month/Quarter] [Year] period, from [Start Date] to [End Date]. This update provides an overview of our operational achievements, financial health, challenges addressed, and our strategic outlook.

---

### **1. Executive Summary / Key Highlights**

This past [month/quarter] has been transformative for [Company Name], marked by significant progress in [mention 1-2 key areas, e.g., product launch, market expansion, revenue growth]. We are particularly proud of [specific major achievement, e.g., achieving 50% YoY revenue growth, securing a major partnership, launching our V2 product]. Our focus remains on [core strategic objective, e.g., scaling our user base, enhancing product stickiness, expanding into new markets].

---

### **2. Operational Highlights & Key Milestones**

We've made substantial strides across various facets of our operations:

*   **Product Development & Innovation:**
    *   [Specific Product Launch/Feature Release]: Successfully launched [Product/Feature Name] on [Date], resulting in [quantifiable impact, e.g., X% increase in user engagement, Y% reduction in customer support tickets].
    *   [Key Improvement/Iteration]: Implemented [Specific Improvement], enhancing [aspect, e.g., user experience, platform stability].
    *   [Upcoming Developments]: [Brief mention of next major product focus].
*   **Market & Customer Growth:**
    *   [New Customer Acquisition]: Acquired [Number] new customers/clients, bringing our total to [Total Number].
    *   [Market Expansion]: Successfully entered [New Market/Segment] with [specific initiative/partnership].
    *   [Strategic Partnerships]: Forged a key partnership with [Partner Name], expected to [quantifiable benefit, e.g., expand our reach by X%, unlock Y revenue stream].
*   **Team & Culture:**
    *   [Key Hires]: Welcomed [Number] new team members, including [Name/Role, e.g., a VP of Sales, a Senior Engineer], strengthening our capabilities in [area].
    *   [Team Achievements]: [Mention a significant team accomplishment or cultural initiative].
*   **Other Strategic Wins:**
    *   [Award/Recognition]: Recognized by [Organization] as [Award/Title].
    *   [Funding/Grants]: Secured [Amount] in [Type of Funding/Grant].

---

### **3. Key Performance Indicators (KPIs)**

Our performance metrics for the [Month/Quarter] [Year] period demonstrate continued momentum:

| KPI                       | Current Period ([Month/Quarter] [Year]) | Previous Period ([Month/Quarter] [Year-1] or [Previous Quarter]) | Target / Benchmark | Variance | Commentary                                                                |
| :------------------------ | :-------------------------------------- | :--------------------------------------------------------------- | :----------------- | :------- | :------------------------------------------------------------------------ |
| **Revenue (MRR/ARR/Total)** | $[X,XXX,XXX] ([+/- Y]%)                | $[Z,ZZZ,ZZZ]                                                    | $[A,AAA,AAA]       | [+/- B]% | [Brief explanation of revenue trend, e.g., exceeding targets due to...]   |
| **Customer Acquisition Cost (CAC)** | $[X.XX]                                | $[Y.YY]                                                         | $[Z.ZZ]            | [+/- B]% | [Insight into CAC efficiency, e.g., improved due to optimized campaigns.] |
| **Customer Lifetime Value (LTV)** | $[X.XX]                                | $[Y.YY]                                                         | $[Z.ZZ]            | [+/- B]% | [Comment on LTV trend, e.g., stable, growing with product stickiness.]    |
| **Churn Rate (Monthly/Quarterly)** | [X.X]%                                  | [Y.Y]%                                                           | [Z.Z]%             | [+/- B]% | [Reason for churn rate, e.g., stable, slightly increased due to market.]  |
| **Active Users (DAU/MAU)** | [X,XXX,XXX]                             | [Y,YYY,YYY]                                                      | [Z,ZZZ,ZZZ]        | [+/- B]% | [Growth or engagement trends, e.g., strong user growth driven by...]      |
| **Gross Margin**          | [X.X]%                                  | [Y.Y]%                                                           | [Z.Z]%             | [+/- B]% | [Efficiency of operations, e.g., stable, improving with scale.]           |
| *[Add other relevant KPIs]* |                                         |                                                                  |                    |          |                                                                           |

---

### **4. Financial Snapshot**

A high-level overview of our financial position:

| Financial Metric      | Current Period ([Month/Quarter] [Year]) | Previous Period ([Month/Quarter] [Year-1] or [Previous Quarter]) | Commentary                                                              |
| :-------------------- | :-------------------------------------- | :--------------------------------------------------------------- | :---------------------------------------------------------------------- |
| **Total Revenue**     | $[X,XXX,XXX]                             | $[Y,YYY,YYY]                                                    | [E.g., On track with projections, exceeded expectations due to...]      |
| **Gross Profit**      | $[X,XXX,XXX]                             | $[Y,YYY,YYY]                                                    | [E.g., Healthy margins maintained, slight dip due to...]                |
| **Operating Expenses** | $[X,XXX,XXX]                             | $[Y,YYY,YYY]                                                    | [E.g., Managed tightly, increased due to strategic hires/marketing.]    |
| **Net Burn Rate**     | $[X,XXX] / month                         | $[Y,YYY] / month                                                | [E.g., Consistent with plan, decreased due to revenue growth.]          |
| **Cash on Hand**      | $[X,XXX,XXX]                             | $[Y,YYY,YYY]                                                    | [E.g., Sufficient runway, actively managing cash flow.]                 |
| **Runway**            | [X] months                                | [Y] months                                                       | [E.g., Stable, providing ample time for next milestones/fundraising.]   |

*A more detailed financial report is attached for your review.*

---

### **5. Challenges & Learnings**

Transparency is crucial, and we want to share the challenges we've encountered and how we're addressing them:

*   **Challenge 1: [Specific Challenge]**
    *   *Description:* [Briefly explain the challenge, e.g., unexpected competitor move, slower-than-anticipated market adoption for a new feature, hiring difficulties.]
    *   *Action Taken:* [Detail the steps taken to mitigate or resolve the challenge, e.g., adjusted marketing strategy, re-prioritized product roadmap, initiated a new recruitment drive.]
    *   *Learning:* [Key takeaway from this challenge, e.g., reinforced the need for agile response, improved our market intelligence process.]
*   **Challenge 2: [Specific Challenge]**
    *   *Description:* [Another challenge, if applicable.]
    *   *Action Taken:* [Response.]
    *   *Learning:* [Key takeaway.]

We are confident in our team's ability to navigate these hurdles and continue to build resiliently.

---

### **6. Future Outlook & Asks**

Looking ahead to [Next Month/Quarter] [Year], our primary focus areas include:

*   **Strategic Goal 1:** [E.g., Launching our enterprise-grade solution, expanding into two new geographic markets.]
*   **Strategic Goal 2:** [E.g., Achieving X% MRR growth, reducing CAC by Y%.]
*   **Key Initiative:** [E.g., Strengthening our leadership team with X key hire, securing our Series A funding round.]

**How You Can Help (Our "Asks"):**

We value your continued support and expertise. Here are a few specific areas where your insights or connections would be invaluable:

*   **Introductions:** We are actively seeking introductions to [Type of individuals/companies, e.g., potential strategic partners in the [Industry] sector, experienced advisors in [Area of Expertise], specific talent for [Role]].
*   **Feedback/Advice:** We would appreciate any feedback on [Specific area, e.g., our recent product launch, our proposed market entry strategy for [Country]]. Please feel free to reply to this email or schedule a brief call.
*   **Mentorship:** If you have experience in [Specific Industry/Area], we would welcome a brief conversation to tap into your insights.

---

### **7. Closing**

Thank you for your continued trust and investment in [Company Name]. We are incredibly excited about the progress we're making and the opportunities that lie ahead. We remain committed to building a valuable and sustainable business.

Please do not hesitate to reach out with any questions or if you would like to schedule a deeper dive into any of these areas.

Sincerely,

[Your Name]
[Your Title]
[Company Name]
[Your Email Address]
[Your Phone Number (Optional)]
[Company Website]

---

### **8. Attachments / Links (Optional but Recommended)**

*   **[Link/Attachment]:** Detailed Financial Report - [Month/Quarter] [Year]
*   **[Link/Attachment]:** Latest Investor Deck (if updated)
*   **[Link/Attachment]:** Product Roadmap Overview
*   **[Link/Attachment]:** Link to a recent press release or significant media coverage

---

## Best Practices for Sending Investor Updates

*   **Consistency is Key:** Send updates on a regular schedule (monthly or quarterly) to build trust and keep investors informed.
*   **Be Transparent:** Share both successes and challenges. Investors appreciate honesty and a realistic view of the business.
*   **Be Concise, Yet Comprehensive:** Provide enough detail without overwhelming the reader. Use bullet points and tables for readability.
*   **Quantify Everything Possible:** Use numbers, percentages, and data points to support your claims and demonstrate progress.
*   **Proofread Meticulously:** Ensure there are no typos, grammatical errors, or factual inaccuracies.
*   **Personalize (Where Appropriate):** While the core content is the same, a personalized opening or closing can strengthen relationships.
*   **Actionable Asks:** Make your "asks" specific and easy for investors to act upon.
*   **Follow Up:** Be prepared to answer questions and engage in further discussions after sending the update.
*   **Maintain Confidentiality:** Remind investors that the information is confidential and for their eyes only.
investor_update_email.md
Download as Markdown
Copy all content
Full output as text
Download ZIP
IDE-ready project ZIP
Copy share link
Permanent URL for this run
Get Embed Code
Embed this result on any website
Print / Save PDF
Use browser print dialog
\n\n\n"); var hasSrcMain=Object.keys(extracted).some(function(k){return k.indexOf("src/main")>=0;}); if(!hasSrcMain) zip.file(folder+"src/main."+ext,"import React from 'react'\nimport ReactDOM from 'react-dom/client'\nimport App from './App'\nimport './index.css'\n\nReactDOM.createRoot(document.getElementById('root')!).render(\n \n \n \n)\n"); var hasSrcApp=Object.keys(extracted).some(function(k){return k==="src/App."+ext||k==="App."+ext;}); if(!hasSrcApp) zip.file(folder+"src/App."+ext,"import React from 'react'\nimport './App.css'\n\nfunction App(){\n return(\n
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n
\n )\n}\nexport default App\n"); zip.file(folder+"src/index.css","*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#f0f2f5;color:#1a1a2e}\n.app{min-height:100vh;display:flex;flex-direction:column}\n.app-header{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:40px}\nh1{font-size:2.5rem;font-weight:700}\n"); zip.file(folder+"src/App.css",""); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/pages/.gitkeep",""); zip.file(folder+"src/hooks/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\n## Open in IDE\nOpen the project folder in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Vue (Vite + Composition API + TypeScript) --- */ function buildVue(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "type": "module",\n "scripts": {\n "dev": "vite",\n "build": "vue-tsc -b && vite build",\n "preview": "vite preview"\n },\n "dependencies": {\n "vue": "^3.5.13",\n "vue-router": "^4.4.5",\n "pinia": "^2.3.0",\n "axios": "^1.7.9"\n },\n "devDependencies": {\n "@vitejs/plugin-vue": "^5.2.1",\n "typescript": "~5.7.3",\n "vite": "^6.0.5",\n "vue-tsc": "^2.2.0"\n }\n}\n'); zip.file(folder+"vite.config.ts","import { defineConfig } from 'vite'\nimport vue from '@vitejs/plugin-vue'\nimport { resolve } from 'path'\n\nexport default defineConfig({\n plugins: [vue()],\n resolve: { alias: { '@': resolve(__dirname,'src') } }\n})\n"); zip.file(folder+"tsconfig.json",'{"files":[],"references":[{"path":"./tsconfig.app.json"},{"path":"./tsconfig.node.json"}]}\n'); zip.file(folder+"tsconfig.app.json",'{\n "compilerOptions":{\n "target":"ES2020","useDefineForClassFields":true,"module":"ESNext","lib":["ES2020","DOM","DOM.Iterable"],\n "skipLibCheck":true,"moduleResolution":"bundler","allowImportingTsExtensions":true,\n "isolatedModules":true,"moduleDetection":"force","noEmit":true,"jsxImportSource":"vue",\n "strict":true,"paths":{"@/*":["./src/*"]}\n },\n "include":["src/**/*.ts","src/**/*.d.ts","src/**/*.tsx","src/**/*.vue"]\n}\n'); zip.file(folder+"env.d.ts","/// \n"); zip.file(folder+"index.html","\n\n\n \n \n "+slugTitle(pn)+"\n\n\n
\n \n\n\n"); var hasMain=Object.keys(extracted).some(function(k){return k==="src/main.ts"||k==="main.ts";}); if(!hasMain) zip.file(folder+"src/main.ts","import { createApp } from 'vue'\nimport { createPinia } from 'pinia'\nimport App from './App.vue'\nimport './assets/main.css'\n\nconst app = createApp(App)\napp.use(createPinia())\napp.mount('#app')\n"); var hasApp=Object.keys(extracted).some(function(k){return k.indexOf("App.vue")>=0;}); if(!hasApp) zip.file(folder+"src/App.vue","\n\n\n\n\n"); zip.file(folder+"src/assets/main.css","*{margin:0;padding:0;box-sizing:border-box}body{font-family:system-ui,sans-serif;background:#fff;color:#213547}\n"); zip.file(folder+"src/components/.gitkeep",""); zip.file(folder+"src/views/.gitkeep",""); zip.file(folder+"src/stores/.gitkeep",""); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nnpm run dev\n\`\`\`\n\n## Build\n\`\`\`bash\nnpm run build\n\`\`\`\n\nOpen in VS Code or WebStorm.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n"); } /* --- Angular (v19 standalone) --- */ function buildAngular(zip,folder,app,code,panelTxt){ var pn=pkgName(app); var C=cc(pn); var sel=pn.replace(/_/g,"-"); var extracted=extractCode(panelTxt); zip.file(folder+"package.json",'{\n "name": "'+pn+'",\n "version": "0.0.0",\n "scripts": {\n "ng": "ng",\n "start": "ng serve",\n "build": "ng build",\n "test": "ng test"\n },\n "dependencies": {\n "@angular/animations": "^19.0.0",\n "@angular/common": "^19.0.0",\n "@angular/compiler": "^19.0.0",\n "@angular/core": "^19.0.0",\n "@angular/forms": "^19.0.0",\n "@angular/platform-browser": "^19.0.0",\n "@angular/platform-browser-dynamic": "^19.0.0",\n "@angular/router": "^19.0.0",\n "rxjs": "~7.8.0",\n "tslib": "^2.3.0",\n "zone.js": "~0.15.0"\n },\n "devDependencies": {\n "@angular-devkit/build-angular": "^19.0.0",\n "@angular/cli": "^19.0.0",\n "@angular/compiler-cli": "^19.0.0",\n "typescript": "~5.6.0"\n }\n}\n'); zip.file(folder+"angular.json",'{\n "$schema": "./node_modules/@angular/cli/lib/config/schema.json",\n "version": 1,\n "newProjectRoot": "projects",\n "projects": {\n "'+pn+'": {\n "projectType": "application",\n "root": "",\n "sourceRoot": "src",\n "prefix": "app",\n "architect": {\n "build": {\n "builder": "@angular-devkit/build-angular:application",\n "options": {\n "outputPath": "dist/'+pn+'",\n "index": "src/index.html",\n "browser": "src/main.ts",\n "tsConfig": "tsconfig.app.json",\n "styles": ["src/styles.css"],\n "scripts": []\n }\n },\n "serve": {"builder":"@angular-devkit/build-angular:dev-server","configurations":{"production":{"buildTarget":"'+pn+':build:production"},"development":{"buildTarget":"'+pn+':build:development"}},"defaultConfiguration":"development"}\n }\n }\n }\n}\n'); zip.file(folder+"tsconfig.json",'{\n "compileOnSave": false,\n "compilerOptions": {"baseUrl":"./","outDir":"./dist/out-tsc","forceConsistentCasingInFileNames":true,"strict":true,"noImplicitOverride":true,"noPropertyAccessFromIndexSignature":true,"noImplicitReturns":true,"noFallthroughCasesInSwitch":true,"paths":{"@/*":["src/*"]},"skipLibCheck":true,"esModuleInterop":true,"sourceMap":true,"declaration":false,"experimentalDecorators":true,"moduleResolution":"bundler","importHelpers":true,"target":"ES2022","module":"ES2022","useDefineForClassFields":false,"lib":["ES2022","dom"]},\n "references":[{"path":"./tsconfig.app.json"}]\n}\n'); zip.file(folder+"tsconfig.app.json",'{\n "extends":"./tsconfig.json",\n "compilerOptions":{"outDir":"./dist/out-tsc","types":[]},\n "files":["src/main.ts"],\n "include":["src/**/*.d.ts"]\n}\n'); zip.file(folder+"src/index.html","\n\n\n \n "+slugTitle(pn)+"\n \n \n \n\n\n \n\n\n"); zip.file(folder+"src/main.ts","import { bootstrapApplication } from '@angular/platform-browser';\nimport { appConfig } from './app/app.config';\nimport { AppComponent } from './app/app.component';\n\nbootstrapApplication(AppComponent, appConfig)\n .catch(err => console.error(err));\n"); zip.file(folder+"src/styles.css","* { margin: 0; padding: 0; box-sizing: border-box; }\nbody { font-family: system-ui, -apple-system, sans-serif; background: #f9fafb; color: #111827; }\n"); var hasComp=Object.keys(extracted).some(function(k){return k.indexOf("app.component")>=0;}); if(!hasComp){ zip.file(folder+"src/app/app.component.ts","import { Component } from '@angular/core';\nimport { RouterOutlet } from '@angular/router';\n\n@Component({\n selector: 'app-root',\n standalone: true,\n imports: [RouterOutlet],\n templateUrl: './app.component.html',\n styleUrl: './app.component.css'\n})\nexport class AppComponent {\n title = '"+pn+"';\n}\n"); zip.file(folder+"src/app/app.component.html","
\n
\n

"+slugTitle(pn)+"

\n

Built with PantheraHive BOS

\n
\n \n
\n"); zip.file(folder+"src/app/app.component.css",".app-header{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:60vh;gap:16px}h1{font-size:2.5rem;font-weight:700;color:#6366f1}\n"); } zip.file(folder+"src/app/app.config.ts","import { ApplicationConfig, provideZoneChangeDetection } from '@angular/core';\nimport { provideRouter } from '@angular/router';\nimport { routes } from './app.routes';\n\nexport const appConfig: ApplicationConfig = {\n providers: [\n provideZoneChangeDetection({ eventCoalescing: true }),\n provideRouter(routes)\n ]\n};\n"); zip.file(folder+"src/app/app.routes.ts","import { Routes } from '@angular/router';\n\nexport const routes: Routes = [];\n"); Object.keys(extracted).forEach(function(p){ var fp=p.startsWith("src/")?p:"src/"+p; zip.file(folder+fp,extracted[p]); }); zip.file(folder+"README.md","# "+slugTitle(pn)+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\nng serve\n# or: npm start\n\`\`\`\n\n## Build\n\`\`\`bash\nng build\n\`\`\`\n\nOpen in VS Code with Angular Language Service extension.\n"); zip.file(folder+".gitignore","node_modules/\ndist/\n.env\n.DS_Store\n*.local\n.angular/\n"); } /* --- Python --- */ function buildPython(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var reqMap={"numpy":"numpy","pandas":"pandas","sklearn":"scikit-learn","tensorflow":"tensorflow","torch":"torch","flask":"flask","fastapi":"fastapi","uvicorn":"uvicorn","requests":"requests","sqlalchemy":"sqlalchemy","pydantic":"pydantic","dotenv":"python-dotenv","PIL":"Pillow","cv2":"opencv-python","matplotlib":"matplotlib","seaborn":"seaborn","scipy":"scipy"}; var reqs=[]; Object.keys(reqMap).forEach(function(k){if(src.indexOf("import "+k)>=0||src.indexOf("from "+k)>=0)reqs.push(reqMap[k]);}); var reqsTxt=reqs.length?reqs.join("\n"):"# add dependencies here\n"; zip.file(folder+"main.py",src||"# "+title+"\n# Generated by PantheraHive BOS\n\nprint(title+\" loaded\")\n"); zip.file(folder+"requirements.txt",reqsTxt); zip.file(folder+".env.example","# Environment variables\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n\`\`\`\n\n## Run\n\`\`\`bash\npython main.py\n\`\`\`\n"); zip.file(folder+".gitignore",".venv/\n__pycache__/\n*.pyc\n.env\n.DS_Store\n"); } /* --- Node.js --- */ function buildNode(zip,folder,app,code){ var title=slugTitle(app); var pn=pkgName(app); var src=code.replace(/^\`\`\`[\w]*\n?/m,"").replace(/\n?\`\`\`$/m,"").trim(); var depMap={"mongoose":"^8.0.0","dotenv":"^16.4.5","axios":"^1.7.9","cors":"^2.8.5","bcryptjs":"^2.4.3","jsonwebtoken":"^9.0.2","socket.io":"^4.7.4","uuid":"^9.0.1","zod":"^3.22.4","express":"^4.18.2"}; var deps={}; Object.keys(depMap).forEach(function(k){if(src.indexOf(k)>=0)deps[k]=depMap[k];}); if(!deps["express"])deps["express"]="^4.18.2"; var pkgJson=JSON.stringify({"name":pn,"version":"1.0.0","main":"src/index.js","scripts":{"start":"node src/index.js","dev":"nodemon src/index.js"},"dependencies":deps,"devDependencies":{"nodemon":"^3.0.3"}},null,2)+"\n"; zip.file(folder+"package.json",pkgJson); var fallback="const express=require(\"express\");\nconst app=express();\napp.use(express.json());\n\napp.get(\"/\",(req,res)=>{\n res.json({message:\""+title+" API\"});\n});\n\nconst PORT=process.env.PORT||3000;\napp.listen(PORT,()=>console.log(\"Server on port \"+PORT));\n"; zip.file(folder+"src/index.js",src||fallback); zip.file(folder+".env.example","PORT=3000\n"); zip.file(folder+".gitignore","node_modules/\n.env\n.DS_Store\n"); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Setup\n\`\`\`bash\nnpm install\n\`\`\`\n\n## Run\n\`\`\`bash\nnpm run dev\n\`\`\`\n"); } /* --- Vanilla HTML --- */ function buildVanillaHtml(zip,folder,app,code){ var title=slugTitle(app); var isFullDoc=code.trim().toLowerCase().indexOf("=0||code.trim().toLowerCase().indexOf("=0; var indexHtml=isFullDoc?code:"\n\n\n\n\n"+title+"\n\n\n\n"+code+"\n\n\n\n"; zip.file(folder+"index.html",indexHtml); zip.file(folder+"style.css","/* "+title+" — styles */\n*{margin:0;padding:0;box-sizing:border-box}\nbody{font-family:system-ui,-apple-system,sans-serif;background:#fff;color:#1a1a2e}\n"); zip.file(folder+"script.js","/* "+title+" — scripts */\n"); zip.file(folder+"assets/.gitkeep",""); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\n## Open\nDouble-click \`index.html\` in your browser.\n\nOr serve locally:\n\`\`\`bash\nnpx serve .\n# or\npython3 -m http.server 3000\n\`\`\`\n"); zip.file(folder+".gitignore",".DS_Store\nnode_modules/\n.env\n"); } /* ===== MAIN ===== */ var sc=document.createElement("script"); sc.src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.10.1/jszip.min.js"; sc.onerror=function(){ if(lbl)lbl.textContent="Download ZIP"; alert("JSZip load failed — check connection."); }; sc.onload=function(){ var zip=new JSZip(); var base=(_phFname||"output").replace(/\.[^.]+$/,""); var app=base.toLowerCase().replace(/[^a-z0-9]+/g,"_").replace(/^_+|_+$/g,"")||"my_app"; var folder=app+"/"; var vc=document.getElementById("panel-content"); var panelTxt=vc?(vc.innerText||vc.textContent||""):""; var lang=detectLang(_phCode,panelTxt); if(_phIsHtml){ buildVanillaHtml(zip,folder,app,_phCode); } else if(lang==="flutter"){ buildFlutter(zip,folder,app,_phCode,panelTxt); } else if(lang==="react-native"){ buildReactNative(zip,folder,app,_phCode,panelTxt); } else if(lang==="swift"){ buildSwift(zip,folder,app,_phCode,panelTxt); } else if(lang==="kotlin"){ buildKotlin(zip,folder,app,_phCode,panelTxt); } else if(lang==="react"){ buildReact(zip,folder,app,_phCode,panelTxt); } else if(lang==="vue"){ buildVue(zip,folder,app,_phCode,panelTxt); } else if(lang==="angular"){ buildAngular(zip,folder,app,_phCode,panelTxt); } else if(lang==="python"){ buildPython(zip,folder,app,_phCode); } else if(lang==="node"){ buildNode(zip,folder,app,_phCode); } else { /* Document/content workflow */ var title=app.replace(/_/g," "); var md=_phAll||_phCode||panelTxt||"No content"; zip.file(folder+app+".md",md); var h=""+title+""; h+="

"+title+"

"; var hc=md.replace(/&/g,"&").replace(//g,">"); hc=hc.replace(/^### (.+)$/gm,"

$1

"); hc=hc.replace(/^## (.+)$/gm,"

$1

"); hc=hc.replace(/^# (.+)$/gm,"

$1

"); hc=hc.replace(/\*\*(.+?)\*\*/g,"$1"); hc=hc.replace(/\n{2,}/g,"

"); h+="

"+hc+"

Generated by PantheraHive BOS
"; zip.file(folder+app+".html",h); zip.file(folder+"README.md","# "+title+"\n\nGenerated by PantheraHive BOS.\n\nFiles:\n- "+app+".md (Markdown)\n- "+app+".html (styled HTML)\n"); } zip.generateAsync({type:"blob"}).then(function(blob){ var a=document.createElement("a"); a.href=URL.createObjectURL(blob); a.download=app+".zip"; a.click(); URL.revokeObjectURL(a.href); if(lbl)lbl.textContent="Download ZIP"; }); }; document.head.appendChild(sc); } function phShare(){navigator.clipboard.writeText(window.location.href).then(function(){var el=document.getElementById("ph-share-lbl");if(el){el.textContent="Link copied!";setTimeout(function(){el.textContent="Copy share link";},2500);}});}function phEmbed(){var runId=window.location.pathname.split("/").pop().replace(".html","");var embedUrl="https://pantherahive.com/embed/"+runId;var code='';navigator.clipboard.writeText(code).then(function(){var el=document.getElementById("ph-embed-lbl");if(el){el.textContent="Embed code copied!";setTimeout(function(){el.textContent="Get Embed Code";},2500);}});}