AI Sales Script Generator
Run ID: 69cb046858b35c7ea758c1442026-03-30Business
PantheraHive BOS
BOS Dashboard

AI Sales Script Generator: Conversion-Optimized & Industry-Specific Sales Scripts

This deliverable provides a comprehensive overview of the AI Sales Script Generator, a powerful tool designed to equip your sales team with highly effective, conversion-optimized scripts tailored to specific industries and sales scenarios. Our goal is to streamline your sales process, enhance engagement, and ultimately drive higher conversion rates.


1. Introduction: Elevate Your Sales Conversations

The AI Sales Script Generator is an intelligent solution that leverages advanced AI to craft dynamic, persuasive sales scripts. Whether you're initiating a cold call, demonstrating a product, following up on a lead, or expertly handling objections, our system ensures your team speaks with confidence, clarity, and a deep understanding of your prospect's needs and industry context.


2. Key Features: Precision-Engineered for Sales Success

Our generator is built with a suite of features designed to maximize the impact of every sales interaction:

* Cold Calls: Engaging openers, qualification questions, value propositions, and clear next steps to pique interest.

* Demos: Structured narratives, benefit-driven feature highlights, interactive prompts, and compelling calls to action.

* Follow-Ups: Persistent yet professional messaging for post-call, post-demo, or post-event scenarios, designed to re-engage and advance the sale.

* Objection Handling: Pre-scripted responses for common objections (e.g., price, timing, competition, need) that pivot concerns into opportunities.

* Pain Point Identification: Immediately addressing prospect challenges.

* Value Proposition Clarity: Highlighting unique benefits and ROI.

* Scarcity & Urgency: Strategically integrated to encourage action.

* Social Proof & Testimonials: Leveraging credibility when appropriate.

* Clear Calls to Action (CTAs): Guiding prospects to the next logical step.


3. Benefits for Your Business: Tangible ROI

Implementing the AI Sales Script Generator provides significant advantages:


4. How It Works: Your Path to Powerful Scripts

The process for generating and utilizing your custom sales scripts is straightforward:

  1. Define Your Requirements: You provide key information:

* Product/Service: What are you selling? (e.g., "Cloud-based CRM for SMBs")

* Target Audience: Who are you selling to? (e.g., "Sales Managers in tech startups")

* Industry: Which industry are you targeting? (e.g., "Software as a Service (SaaS)")

* Sales Scenario: Which script type do you need? (e.g., "Cold Call," "Demo Introduction," "Price Objection Handling")

* Desired Outcome: What is the specific goal of this interaction? (e.g., "Schedule a follow-up demo," "Close the deal")

* Key Differentiators/Value Props: What makes your offering unique?

  1. AI Generation: Our system processes your input, drawing from its extensive knowledge base of sales best practices, linguistic patterns, and industry-specific insights to generate a detailed script.
  2. Review & Refine: You receive the initial script for review. You can provide feedback, suggest modifications, or request alternative phrasing. This human-in-the-loop step ensures the script perfectly aligns with your specific needs and brand voice.
  3. Finalization & Deployment: Once approved, the script is ready for immediate use by your sales team. We can provide it in various formats suitable for CRM integration, training manuals, or quick-reference guides.

5. Deliverable Examples: A Glimpse into Your Custom Scripts

Here are illustrative snippets of the type of detailed, professional output you can expect:

Example 1: Cold Call Script (Industry: SaaS - Product: AI-driven Marketing Analytics Platform)

Scenario: Initial outreach to a Marketing Director at a mid-sized e-commerce company.

Goal: Schedule a 15-minute discovery call.

text • 1,189 chars
**[Opening - Permission-Based & Value-Oriented]**
"Hi [Prospect Name], this is [Your Name] from [Your Company]. I know you're busy, so I'll be brief. We help e-commerce marketing teams like yours unlock deeper customer insights and optimize campaign ROI using AI. Is now a quick moment to explain how we're doing that for companies similar to [Prospect Company]?"

**[If Yes - Establish Pain Point & Introduce Solution]**
"Great. We've found many Marketing Directors struggle with fragmented data and the sheer volume of campaign metrics, making it hard to pinpoint what truly drives conversions. Our AI platform, [Product Name], consolidates all your marketing data, providing predictive analytics that identify your most profitable customer segments and campaign opportunities – often improving ROAS by 20% or more.

**[Bridge to Discovery Call]**
"Instead of diving into all the features now, I'd love to schedule a brief 15-minute discovery call next week. This would allow us to understand your specific marketing challenges and show you a tailored example of how [Product Name] could directly impact your current campaigns. Would Tuesday or Wednesday afternoon work better for you?"
Sandboxed live preview

Marketing Strategy: AI Sales Script Generator

This document outlines a comprehensive marketing strategy for the "AI Sales Script Generator," designed to drive awareness, generate leads, and secure customer acquisition. It encompasses target audience analysis, recommended marketing channels, a core messaging framework, and key performance indicators (KPIs) to measure success.


1. Target Audience Analysis

Understanding our ideal customer is paramount. We've identified primary and secondary target audiences based on their roles, company size, industry, pain points, and needs.

1.1 Primary Target Audience

  • Roles: Sales Managers, Sales Directors, VPs of Sales, Heads of Sales Enablement, Business Development Managers, SDR/BDR Team Leads.
  • Company Size:

* SMBs (Small to Medium-sized Businesses): Companies often lack dedicated sales enablement teams and struggle with inconsistent messaging or rapid onboarding.

* Mid-Market & Enterprises: Organizations seeking to optimize large sales teams, standardize best practices, and improve efficiency at scale.

  • Industries: B2B SaaS, Technology, Financial Services, Real Estate, Healthcare, Professional Services, and any industry with complex sales cycles, high-value products/services, or a large sales force.
  • Key Pain Points:

* Inconsistent Messaging: Sales teams delivering varied or off-brand messages, leading to confusion and reduced trust.

* Low Conversion Rates: Struggling to convert prospects from cold outreach, demos, or follow-ups.

* Time-Consuming Script Creation: Manual development and updating of sales scripts is resource-intensive and slow.

* Difficulty Onboarding: New sales reps take too long to become productive due to a lack of effective, readily available scripts.

* Ineffective Objection Handling: Reps struggle to overcome common objections consistently and persuasively.

* Lack of Personalization: Generic scripts fail to resonate with diverse buyer personas or industry-specific needs.

* Sales Team Turnover: High churn exacerbated by a lack of effective tools and support for reps.

  • Needs & Desired Outcomes:

* Automated, intelligent, and industry-specific script generation.

* Improved sales team efficiency and productivity.

* Higher conversion rates and accelerated sales cycles.

* Standardized, high-quality messaging across the entire sales organization.

* Faster and more effective onboarding for new sales representatives.

* Data-driven insights to continuously optimize sales conversations.

* Seamless integration with existing CRM and sales enablement tools.

1.2 Secondary Target Audience

  • Roles: Individual Sales Representatives, Marketing Managers (for lead nurturing and qualification scripts), Founders/CEOs of early-stage startups (wearing multiple hats).
  • Key Pain Points:

* Lack of confidence in sales conversations.

* Struggling to articulate value clearly and concisely.

* Difficulty responding to unexpected objections.

* Feeling unprepared for calls or meetings.

  • Needs & Desired Outcomes:

* An easy-to-use tool that provides instant, effective scripts.

* Increased confidence and reduced anxiety in sales interactions.

* Quick access to best-practice language for various scenarios.


2. Channel Recommendations

A multi-channel approach will be essential to reach our diverse target audience effectively.

2.1 Digital Marketing

  • Content Marketing:

* Blog Posts: Develop SEO-optimized articles addressing pain points (e.g., "How AI is Revolutionizing Cold Calling," "Mastering Objection Handling with Automated Scripts," "The ROI of Sales Script Generation Software").

* Whitepapers & E-books: In-depth guides on sales enablement, AI in sales, or specific industry sales strategies.

* Case Studies: Showcase success stories from early adopters, highlighting quantifiable results (e.g., "Company X Increased Conversion Rates by 25% Using AI Scripts").

* Webinars: Host educational webinars on topics like "Leveraging AI for Sales Efficiency" or "Building a High-Converting Sales Script Library."

* Templates & Checklists: Offer free, valuable resources (e.g., "Cold Call Script Template," "Objection Handling Framework") that require an email sign-up.

  • Search Engine Marketing (SEM):

* Google Ads: Target high-intent keywords such as "AI sales script generator," "sales script software," "cold call AI," "sales enablement AI," "objection handling scripts."

* Bing Ads: Don't overlook this platform, especially for B2B audiences.

  • Social Media Marketing:

* LinkedIn (Primary):

* Organic: Share thought leadership, product updates, customer testimonials, industry news, and engage in relevant groups (e.g., Sales Leaders, SaaS Sales).

* Paid: Run targeted ads based on job title, industry, company size, and interests.

* YouTube: Create product demo videos, "how-to" tutorials, customer success stories, and short educational clips.

* Twitter: Share quick tips, industry news, engage with influencers, and promote blog content.

  • Email Marketing:

* Lead Nurturing Sequences: Educate prospects who download content or sign up for a demo.

* Onboarding Campaigns: Guide new users through the product's features and benefits.

* Product Updates & Newsletters: Keep existing customers and interested leads informed.

2.2 Partnerships & Integrations

  • CRM & Sales Enablement Ecosystem:

* Seek integration partnerships with popular CRMs (e.g., Salesforce AppExchange, HubSpot Marketplace) and sales enablement platforms (e.g., Outreach, Salesloft). This positions the tool as a natural extension of existing workflows.

* Co-marketing opportunities with these partners.

  • Industry Associations & Influencers:

* Partner with sales leadership associations or prominent sales coaches/influencers for co-created content, webinars, or endorsements.

* Affiliate programs for sales consultants or agencies.

2.3 Direct Sales & Outbound

  • Sales Development Representatives (SDRs/BDRs): Employ an outbound sales team that uses the AI Sales Script Generator itself to craft their cold call and email scripts. This serves as a powerful, live demonstration of the product's value.
  • Targeted Account-Based Marketing (ABM): For larger enterprises, identify key accounts and develop highly personalized outreach strategies.

2.4 Public Relations (PR)

  • Media Outreach: Target tech publications (e.g., TechCrunch, VentureBeat), sales industry journals (e.g., Sales Hacker, Selling Power), and business media.
  • Press Releases: Announce product launches, significant feature updates, funding rounds, or key partnerships.
  • Thought Leadership: Position founders or key executives as experts in AI and sales optimization through interviews and contributed articles.

2.5 Events & Webinars

  • Industry Trade Shows: Exhibit at major sales and tech conferences (e.g., Dreamforce, SaaStr Annual, Sales 3.0, Revenue Summit) to showcase the product and network.
  • Host Virtual Events: Conduct online summits or multi-session webinars focused on the future of sales, AI in B2B, and sales productivity.

3. Messaging Framework

Our messaging will consistently communicate the unique value proposition, benefits, and differentiators of the AI Sales Script Generator.

3.1 Core Value Proposition

"Empower your sales team with AI-driven, conversion-optimized scripts that adapt to any conversation, ensuring consistent messaging, faster ramp-up, and significantly higher close rates."

3.2 Key Benefits (What we deliver)

  • Boost Conversions: Generate scripts meticulously crafted for cold calls, demos, follow-ups, and objection handling, leading to tangible improvements in conversion rates.
  • Maximize Efficiency: Automate the time-consuming process of script creation and updates, allowing sales managers and reps to focus on selling.
  • Ensure Consistency & Quality: Guarantee every sales interaction aligns with brand messaging and best practices, elevating the overall quality of sales conversations.
  • Accelerate Onboarding: Rapidly equip new sales hires with a comprehensive library of effective, battle-tested scripts, reducing ramp-up time.
  • Enable Hyper-Personalization: Instantly tailor scripts for specific industries, products, services, and individual buyer personas, making every interaction relevant.
  • Master Objections: Provide intelligent, pre-built responses to common objections, empowering reps to navigate challenging conversations with confidence.
  • Data-Driven Optimization: (Future Vision) Continuously learn and refine scripts based on performance data, ensuring ongoing improvement and peak effectiveness.

3.3 Unique Selling Points (USPs)

  • Industry-Specific AI Engine: Our AI is not generic; it's trained on vast datasets of successful sales interactions across various industries, generating truly relevant and impactful language.
  • Dynamic Script Adaptation: Go beyond static scripts. Our platform offers suggestions and adaptations in real-time or based on conversational context.
  • Comprehensive Sales Cycle Coverage: From initial outreach to closing and follow-up, our generator covers every stage of the sales journey.
  • Seamless CRM & Sales Tool Integration: Effortlessly integrate with existing tech stacks, embedding script generation directly into current workflows.

3.4 Tone of Voice

Professional, Empowering, Innovative, Data-Driven, Solution-Oriented, Confident.

3.5 Tagline Ideas

  • "AI Sales Scripts: Convert Smarter, Sell Faster."
  • "Your Sales Team, Supercharged by AI."
  • "Precision Selling, Powered by AI."

4. Key Performance Indicators (KPIs)

Measuring success is crucial for optimizing our marketing efforts. The following KPIs will be tracked across different stages of the customer journey.

4.1 Awareness & Engagement KPIs

  • Website Traffic: Unique Visitors, Page Views, Bounce Rate, Time on Page.
  • SEO Performance: Keyword Rankings, Organic Search Traffic.
  • Social Media Engagement: Reach, Impressions, Likes, Shares, Comments, Follower Growth (especially on LinkedIn).
  • Brand Mentions: Mentions across media, social platforms, and forums.
  • Webinar & Event Attendance: Registrations and actual attendance rates.
  • PR Coverage: Number and quality of media placements.

4.2 Lead Generation & Acquisition KPIs

  • Marketing Qualified Leads (MQLs): Number of leads identified as having sales potential based on engagement.
  • Sales Qualified Leads (SQLs): Number of MQLs accepted by the sales team.
  • Conversion Rate (Visitor to Lead): Percentage of website visitors who convert into leads (
gemini Output

AI Sales Script Generator - Comprehensive Output

This document presents a detailed, conversion-optimized set of sales scripts generated by the PantheraHive AI Sales Script Generator. Our goal is to equip your sales team with effective, industry-specific language for various stages of the sales cycle, ensuring higher engagement and conversion rates.


Overview of the AI Sales Script Generator

The PantheraHive AI Sales Script Generator is designed to empower your sales force with intelligent, data-driven communication tools. Leveraging advanced AI models, it crafts bespoke sales scripts tailored to specific scenarios, target personas, and industry nuances.

Key Objectives:

  • Maximize Conversion Rates: Scripts are structured using proven sales methodologies (e.g., AIDA, SPIN, Challenger Sale principles) to guide prospects through the sales funnel effectively.
  • Enhance Rep Confidence: Provide clear, concise, and persuasive language for any interaction.
  • Ensure Consistency: Maintain a high standard of communication across your sales team.
  • Accelerate Onboarding: Quickly bring new reps up to speed with best-practice messaging.
  • Adaptability: Generate scripts for cold outreach, product demonstrations, follow-ups, and robust objection handling, with dynamic customization options.

Key Features and Customization Options

Our generator provides a robust framework for creating highly effective sales collateral:

  • Scenario-Based Scripting: Generates tailored content for specific sales situations:

* Cold Calls / Outreach

* Discovery Calls

* Product Demos

* Follow-up (Email & Call)

* Objection Handling (e.g., Price, Time, Need, Competition)

* Closing

  • Industry-Specific Language: Integrates terminology, pain points, and value propositions relevant to your target industry (e.g., SaaS, Healthcare, Manufacturing, Financial Services).
  • Persona-Based Targeting: Adapts messaging based on the role and challenges of your specific buyer persona (e.g., CTO, Marketing Director, Operations Manager).
  • Conversion Optimization Frameworks: Embeds psychological triggers and persuasive techniques to move prospects forward.
  • Dynamic Personalization Placeholders: Includes clear markers for easy customization with prospect-specific details ([Prospect Name], [Company Name], [Specific Pain Point]).
  • Multi-Channel Adaptability: Scripts are designed to be effective across various communication channels (phone, email, video call).

Sample Conversion-Optimized Sales Scripts

Below are sample scripts generated for a hypothetical B2B SaaS product: ConnectFlow AI – an AI-powered customer support automation platform designed to reduce ticket volume, improve response times, and enhance customer satisfaction for mid-market and enterprise businesses.


Script Type 1: Cold Call Opening (Discovery Focus)

Scenario: Calling a Head of Customer Service at a mid-sized e-commerce company experiencing high support ticket volume and agent burnout.

Goal: Secure a 15-minute discovery call to explore current challenges and potential solutions.

(Phone Call Script)

You: "Hi [Prospect Name], this is [Your Name] from [Your Company]. I hope I'm not catching you at a bad time?"

Prospect: "It's a bit busy, what's this regarding?"

You: "I understand, I'll be brief. The reason for my call is that we're working with companies like [Similar Company 1] and [Similar Company 2] in the e-commerce space, specifically their customer service departments. They were facing significant challenges with [Specific Pain Point - e.g., escalating support ticket volume and long resolution times], which was impacting both customer satisfaction and agent morale."

"We helped them implement ConnectFlow AI, an intelligent automation platform that [Key Benefit 1 - e.g., deflects up to 40% of routine inquiries] and [Key Benefit 2 - e.g., empowers agents with instant, accurate information], leading to [Quantifiable Result - e.g., a 25% reduction in operational costs and a 15-point increase in CSAT scores]."

"I don't know if any of that resonates with the challenges you might be facing at [Prospect's Company Name], but I noticed [Personalized Observation - e.g., your recent growth spurt often puts pressure on support teams]."

"Would you be open to a brief, 15-minute conversation next [Day] or [Day] to explore if ConnectFlow AI could offer similar value to your team? We could discuss your current processes without any obligation."

Key Elements:

  • Permission-Based Opening: Respects prospect's time, increasing likelihood of engagement.
  • Relevant Context: Immediately establishes industry relevance and addresses common pain points.
  • Social Proof: Mentions similar companies for credibility.
  • Problem-Solution-Benefit: Clearly articulates the problem, how the solution helps, and the tangible results.
  • Personalized Observation: Shows you've done your homework.
  • Low-Commitment CTA: Asks for a short, specific next step.

Script Type 2: Demo Introduction & Value Proposition

Scenario: Beginning a scheduled demo call with a Customer Service Manager and IT Lead who are interested in improving agent efficiency and data analytics.

Goal: Set the agenda, confirm understanding of their needs, and transition smoothly into showcasing ConnectFlow AI's core capabilities.

(Video/Phone Call Script)

You: "Welcome [Prospect Name 1] and [Prospect Name 2]. Thanks again for taking the time today. I'm [Your Name] from [Your Company]."

"Based on our previous conversation, I understand you're primarily looking to [Recap Key Pain Point 1 - e.g., reduce the manual effort involved in handling repetitive customer queries] and [Recap Key Pain Point 2 - e.g., gain deeper insights into customer interactions to drive continuous improvement]."

"Does that sound like an accurate summary of your main objectives for today's session?"

(Pause for confirmation)

"Great. My goal for the next [Time - e.g., 45 minutes] is to show you how ConnectFlow AI addresses these challenges directly. We'll cover three main areas:"

  1. "Intelligent Ticket Deflection: How our AI chatbot can resolve common issues autonomously."
  2. "Agent Assist & Empowerment: How ConnectFlow AI provides real-time support and knowledge to your human agents."
  3. "Actionable Analytics: How our reporting dashboards provide insights into customer trends and agent performance."

"We'll also leave plenty of time for your questions throughout. How does that agenda sound?"

(Pause for confirmation)

"Excellent. Let's dive in. I'd like to start by showing you how [Specific Feature related to Pain Point 1 - e.g., our Natural Language Processing engine] powers intelligent self-service..."

Key Elements:

  • Warm Welcome & Gratitude: Builds rapport.
  • Needs Confirmation: Recaps their identified pain points, showing you've listened and understood.
  • Agenda Setting: Clearly outlines what will be covered, managing expectations.
  • Benefit-Oriented Agenda: Frames each section around how it solves their problems.
  • Interactive Checks: Ensures engagement and agreement before proceeding.
  • Smooth Transition: Moves from agenda to the first demonstration point.

Script Type 3: Post-Demo Follow-up Email/Call Framework

Scenario: Following up with a prospect 24-48 hours after a successful demo of ConnectFlow AI.

Goal: Reinforce value, address any lingering questions, and propose a clear next step.

(Email Template)

Subject: Following Up: Your ConnectFlow AI Demo & Next Steps

Hi [Prospect Name],

It was a pleasure speaking with you and [Other Attendee Name(s)] yesterday/on [Date of Demo] and demonstrating how ConnectFlow AI can transform your customer support operations at [Prospect's Company Name].

I particularly enjoyed our discussion around [Specific Point of Discussion from Demo - e.g., how AI-powered self-service could significantly reduce your inbound ticket volume] and [Another Specific Point - e.g., the potential for our agent assist tools to boost your team's efficiency].

To recap, here are the key benefits we discussed that directly address your objectives:

  • [Benefit 1 - e.g., Up to 40% reduction in routine support tickets] through intelligent deflection.
  • [Benefit 2 - e.g., 20% faster resolution times] by empowering agents with real-time knowledge.
  • [Benefit 3 - e.g., Actionable insights] to continuously improve your customer experience.

I've attached a brief summary of our discussion and the ConnectFlow AI solution overview for your reference.

Do you have any initial thoughts or questions that have come up since our call?

Regarding next steps, I'd suggest we schedule a brief 20-minute call next week to [Proposed Next Step - e.g., discuss a tailored proposal based on your specific needs, or connect with your IT team to discuss integration]? Please let me know what day and time works best for you.

Looking forward to hearing from you.

Best regards,

[Your Name]

[Your Title]

[Your Company]

[Your Phone Number]

[Your Email Signature]

Key Elements:

  • Personalized & Timely: References the specific demo and attendees.
  • Value Reinforcement: Recaps key benefits directly tied to their needs.
  • Concise Summary: Provides a quick overview without overwhelming.
  • Open-Ended Question: Encourages engagement and addresses potential concerns.
  • Clear Call to Action: Proposes a specific next step with flexibility.
  • Resource Provision: Offers additional materials for review.

Script Type 4: Objection Handling - "It's Too Expensive"

Scenario: Prospect raises price as the primary objection after receiving a proposal.

Goal: Understand the underlying concern, reframe value, and explore options.

(Phone Call Script)

You: "I completely understand, [Prospect Name]. Cost is always a critical factor in any investment, and I appreciate your honesty. When you say 'too expensive,' are you comparing our solution to [Competitor Name/Current Solution] or is it more about the overall budget you've allocated for this type of solution?"

(Pause for their response)

You (Option A - If comparing to competitor/current): "Thank you for clarifying. It's true that on the surface, our initial investment might seem higher than [Competitor/Current Solution]. However, many of our clients, like [Similar Client Name], found that the long-term Return on Investment (ROI) with ConnectFlow AI far outweighed the initial cost."

"Are you primarily concerned about the upfront investment, or is it more about the total cost of ownership over [Timeframe - e.g., 1-3 years]?"

(Pause)

"Our platform isn't just about [Basic Function - e.g., automating basic chats]. It's about [Reframe Value - e.g., transforming your entire customer support ecosystem to proactively solve issues, reduce agent churn, and unlock actionable insights that drive revenue]. For [Similar Client Name], this translated to [Quantifiable Result - e.g., a 25% reduction in support costs and a 15% increase in customer lifetime value]."

"If we could demonstrate a clear path to achieving [Specific ROI metric important to them - e.g., a 2x ROI within 12 months], would that change your perspective on the investment?"

You (Option B - If budget constraint): "I appreciate you sharing that. It sounds like we might be hitting a budget constraint. To help me understand better, if budget weren't an issue, would ConnectFlow AI be a solution you'd be excited to implement?"

(Pause for their response - if yes)

"That's great to hear. Perhaps we could explore a phased implementation or a different package that aligns more closely with your current budget while still delivering significant value. Could we review the proposal together and see if there are areas we can adjust or prioritize to meet your immediate needs and budget?"

Key Elements:

  • Empathy & Acknowledgment: Validates their concern.
  • Clarification Question: Uncovers the true nature of the objection (price vs. value vs. budget).

*


6. Next Steps: Unlock Your Sales Potential

Ready to transform your sales conversations?

  • Provide Your Specific Requirements: Use the input fields to detail your product/service, target audience, industry, and desired script type.
  • Request a Custom Script: Let us generate your first conversion-optimized script tailored precisely to your needs.
  • Schedule a Consultation: If you have more complex requirements or wish to discuss integrating this generator into your existing sales ecosystem, please reach out for a personalized consultation.

We are committed to providing you with sales scripts that don't just talk, but convert.

ai_sales_script_generator.txt
Download source file
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);}});}